+ if (res == S_OK) {
+ scheduled_frames.insert(frame.release()); // Owned by the driver now.
+ ++metric_decklink_output_inflight_frames;
+ } else {
+ fprintf(stderr, "Could not schedule video frame! (error=0x%08x)\n", res);
+
+ frame_freelist.push(move(frame));
+ }
+ } else {
+ HRESULT res = output->DisplayVideoFrameSync(frame.get());
+ if (res != S_OK) {
+ fprintf(stderr, "Could not schedule video frame! (error=0x%08x)\n", res);
+ }