]> git.sesse.net Git - nageru/commitdiff
The DeckLink manual recommends pause + flush over stop for changing mode.
authorSteinar H. Gunderson <sgunderson@bigfoot.com>
Sun, 22 Jan 2017 21:52:01 +0000 (22:52 +0100)
committerSteinar H. Gunderson <sgunderson@bigfoot.com>
Sun, 22 Jan 2017 21:52:01 +0000 (22:52 +0100)
decklink_capture.cpp

index 16c187d2e56b55c6553bd69478e0c34ea432cd08..92fd6ae296e567a402928bb3fd15a7e4f9300042 100644 (file)
@@ -443,8 +443,12 @@ void DeckLinkCapture::stop_dequeue_thread()
 
 void DeckLinkCapture::set_video_mode(uint32_t video_mode_id)
 {
-       if (input->StopStreams() != S_OK) {
-               fprintf(stderr, "StopStreams failed\n");
+       if (input->PauseStreams() != S_OK) {
+               fprintf(stderr, "PauseStreams failed\n");
+               exit(1);
+       }
+       if (input->FlushStreams() != S_OK) {
+               fprintf(stderr, "FlushStreams failed\n");
                exit(1);
        }