]> git.sesse.net Git - bmusb/commitdiff
Unbreak 8-bit fake inputs.
authorSteinar H. Gunderson <sgunderson@bigfoot.com>
Thu, 8 Nov 2018 23:15:43 +0000 (00:15 +0100)
committerSteinar H. Gunderson <sgunderson@bigfoot.com>
Thu, 8 Nov 2018 23:15:43 +0000 (00:15 +0100)
fake_capture.cpp

index d8f5144adf727008277dcd537f2dbeb6ace98de8..072864fa26536fa16d692fef52584db9507297a6 100644 (file)
@@ -302,10 +302,10 @@ void FakeCapture::producer_thread_func()
                                memset2(video_frame.data, cbcr, width * height / 2);
                                memset(video_frame.data2, y, width * height);
                        } else {
-                               fill_color_noninterleaved(video_frame.data, y, cb, cr, video_format, current_pixel_format);
+                               fill_color_noninterleaved(video_frame.data, y, cb, cr, video_format, current_pixel_format == PixelFormat_10BitYCbCr);
                        }
                        if (video_frame.data_copy != nullptr) {
-                               fill_color_noninterleaved(video_frame.data_copy, y, cb, cr, video_format, current_pixel_format);
+                               fill_color_noninterleaved(video_frame.data_copy, y, cb, cr, video_format, current_pixel_format == PixelFormat_10BitYCbCr);
                        }
                        video_frame.len = video_format.stride * height;
                        video_frame.received_timestamp = timestamp;