]> git.sesse.net Git - nageru/blobdiff - mixer.h
Make it possible for the user to select Rec. 601/709 for each input from the UI.
[nageru] / mixer.h
diff --git a/mixer.h b/mixer.h
index 6828bc66364d27d20d9f0a264816d29d42293882..84ef32db0efac732975c1a5e7d86e94c0db13d4e 100644 (file)
--- a/mixer.h
+++ b/mixer.h
@@ -23,6 +23,8 @@
 #include <thread>
 #include <vector>
 
+#include <movit/image_format.h>
+
 #include "audio_mixer.h"
 #include "bmusb/bmusb.h"
 #include "defs.h"
@@ -216,6 +218,11 @@ public:
                return theme->set_signal_mapping(signal, card);
        }
 
+       void get_input_ycbcr_interpretation(unsigned card_index, bool *ycbcr_coefficients_auto,
+                                           movit::YCbCrLumaCoefficients *ycbcr_coefficients, bool *full_range);
+       void set_input_ycbcr_interpretation(unsigned card_index, bool ycbcr_coefficients_auto,
+                                           movit::YCbCrLumaCoefficients ycbcr_coefficients, bool full_range);
+
        bool get_supports_set_wb(unsigned channel) const
        {
                return theme->get_supports_set_wb(channel);
@@ -439,6 +446,10 @@ private:
                QueueLengthPolicy queue_length_policy;  // Refers to the "new_frames" queue.
 
                int last_timecode = -1;  // Unwrapped.
+
+               bool ycbcr_coefficients_auto = true;
+               movit::YCbCrLumaCoefficients ycbcr_coefficients = movit::YCBCR_REC_709;
+               bool full_range = false;
        };
        CaptureCard cards[MAX_VIDEO_CARDS];  // Protected by <card_mutex>.
        AudioMixer audio_mixer;  // Same as global_audio_mixer (see audio_mixer.h).