]> git.sesse.net Git - nageru/blobdiff - video_encoder.cpp
Support switching Y'CbCr coefficients midway, which will allow doing the Right Thing...
[nageru] / video_encoder.cpp
index e00465c25a67b8b72e364e39ae29db897c1c76c3..fe0ecb1a17a14a305fe05cc176b5df4bde3fe235 100644 (file)
@@ -120,11 +120,11 @@ void VideoEncoder::add_audio(int64_t pts, std::vector<float> audio)
        stream_audio_encoder->encode_audio(audio, pts + quicksync_encoder->global_delay());
 }
 
-bool VideoEncoder::begin_frame(int64_t pts, int64_t duration, const std::vector<RefCountedFrame> &input_frames, GLuint *y_tex, GLuint *cbcr_tex)
+bool VideoEncoder::begin_frame(int64_t pts, int64_t duration, movit::YCbCrLumaCoefficients ycbcr_coefficients, const std::vector<RefCountedFrame> &input_frames, GLuint *y_tex, GLuint *cbcr_tex)
 {
        lock_guard<mutex> lock(qs_mu);
        qs_needing_cleanup.clear();  // Since we have an OpenGL context here, and are called regularly.
-       return quicksync_encoder->begin_frame(pts, duration, input_frames, y_tex, cbcr_tex);
+       return quicksync_encoder->begin_frame(pts, duration, ycbcr_coefficients, input_frames, y_tex, cbcr_tex);
 }
 
 RefCountedGLsync VideoEncoder::end_frame()