private void UpdateRecordingTime()
        {
            var ts = VideoCapture1.Duration_Time();

            if (Math.Abs(ts.TotalMilliseconds) < 0.01)
            {
                return;
            }

            Dispatcher.BeginInvoke((Action)(() =>
            {
                lbTimestamp.Text = "Recording time: " + ts.ToString(@"hh\:mm\:ss");
            }));
        }
Esempio n. 2
0
        private void UpdateRecordingTime()
        {
            long timestamp = VideoCapture1.Duration_Time();

            if (timestamp < 0)
            {
                return;
            }

            Dispatcher.BeginInvoke((Action)(() =>
            {
                TimeSpan ts = TimeSpan.FromMilliseconds(timestamp);
                lbTimestamp.Text = "Recording time: " + ts.ToString(@"hh\:mm\:ss");
            }));
        }