]> git.sesse.net Git - nageru/blobdiff - nageru/mixer.h
Heed the Exif white point when playing back (MJPEG) video.
[nageru] / nageru / mixer.h
index 9aa375636722d0e6d06be47bc8ca90c232b04d9b..49afa7f1f2f7a0e1ce7254e05e0bef3b2b6f8027 100644 (file)
@@ -23,6 +23,7 @@
 #include <thread>
 #include <vector>
 
 #include <thread>
 #include <vector>
 
+#include <movit/effect.h>
 #include <movit/image_format.h>
 
 #include "audio_mixer.h"
 #include <movit/image_format.h>
 
 #include "audio_mixer.h"
@@ -537,6 +538,7 @@ private:
                        std::function<void()> upload_func;  // Needs to be called to actually upload the texture to OpenGL.
                        unsigned dropped_frames = 0;  // Number of dropped frames before this one.
                        std::chrono::steady_clock::time_point received_timestamp = std::chrono::steady_clock::time_point::min();
                        std::function<void()> upload_func;  // Needs to be called to actually upload the texture to OpenGL.
                        unsigned dropped_frames = 0;  // Number of dropped frames before this one.
                        std::chrono::steady_clock::time_point received_timestamp = std::chrono::steady_clock::time_point::min();
+                       movit::RGBTriplet neutral_color{1.0f, 1.0f, 1.0f};
 
                        // Used for MJPEG encoding. (upload_func packs everything it needs
                        // into the functor, but would otherwise also use these.)
 
                        // Used for MJPEG encoding. (upload_func packs everything it needs
                        // into the functor, but would otherwise also use these.)
@@ -575,6 +577,7 @@ private:
        JitterHistory output_jitter_history;
        CaptureCard cards[MAX_VIDEO_CARDS];  // Protected by <card_mutex>.
        YCbCrInterpretation ycbcr_interpretation[MAX_VIDEO_CARDS];  // Protected by <card_mutex>.
        JitterHistory output_jitter_history;
        CaptureCard cards[MAX_VIDEO_CARDS];  // Protected by <card_mutex>.
        YCbCrInterpretation ycbcr_interpretation[MAX_VIDEO_CARDS];  // Protected by <card_mutex>.
+       movit::RGBTriplet last_received_neutral_color[MAX_VIDEO_CARDS];  // Used by the mixer thread only. Constructor-initialiezd.
        std::unique_ptr<AudioMixer> audio_mixer;  // Same as global_audio_mixer (see audio_mixer.h).
        bool input_card_is_master_clock(unsigned card_index, unsigned master_card_index) const;
        struct OutputFrameInfo {
        std::unique_ptr<AudioMixer> audio_mixer;  // Same as global_audio_mixer (see audio_mixer.h).
        bool input_card_is_master_clock(unsigned card_index, unsigned master_card_index) const;
        struct OutputFrameInfo {