]> git.sesse.net Git - nageru/blobdiff - mixer.h
Wire the transition names through to the UI.
[nageru] / mixer.h
diff --git a/mixer.h b/mixer.h
index 80d18ff00395c3651ff461b72b03e72da51b7f7a..b2561d15c0b395f2d82e2a5d92b682b7ab634942 100644 (file)
--- a/mixer.h
+++ b/mixer.h
@@ -32,18 +32,16 @@ public:
        void start();
        void quit();
 
-       enum Source {
-               SOURCE_INPUT1,
-               SOURCE_INPUT2,
-               SOURCE_SBS,
-       };
-       void cut(Source source);
+       void transition_clicked(int transition_num);
+       void channel_clicked(int preview_num);
 
        enum Output {
                OUTPUT_LIVE = 0,
                OUTPUT_PREVIEW,
                OUTPUT_INPUT0,
                OUTPUT_INPUT1,
+               OUTPUT_INPUT2,
+               OUTPUT_INPUT3,
                NUM_OUTPUTS
        };
 
@@ -79,6 +77,11 @@ public:
                output_channel[output].set_frame_ready_callback(callback);
        }
 
+       std::vector<std::string> get_transition_names()
+       {
+               return theme->get_transition_names(frame / 60.0);
+       }
+
 private:
        void bm_frame(int card_index, uint16_t timecode,
                FrameAllocator::Frame video_frame, size_t video_offset, uint16_t video_format,
@@ -98,7 +101,6 @@ private:
        // Effects part of <display_chain>. Owned by <display_chain>.
        movit::FlatInput *display_input;
 
-       Source current_source = SOURCE_INPUT1;
        int frame = 0;
 
        std::mutex bmusb_mutex;
@@ -106,8 +108,7 @@ private:
                BMUSBCapture *usb;
                std::unique_ptr<PBOFrameAllocator> frame_allocator;
 
-               // Threading stuff
-               bool thread_initialized = false;
+               // Stuff for the OpenGL context (for texture uploading).
                QSurface *surface;
                QOpenGLContext *context;
 
@@ -122,6 +123,7 @@ private:
 
        class OutputChannel {
        public:
+               ~OutputChannel();
                void output_frame(DisplayFrame frame);
                bool get_display_frame(DisplayFrame *frame);
                void set_frame_ready_callback(new_frame_ready_callback_t callback);