]> git.sesse.net Git - nageru/blobdiff - mixer.h
Make signal mapping changeable by right-clicking on the preview.
[nageru] / mixer.h
diff --git a/mixer.h b/mixer.h
index 961c2a6c20948d72db4ca150aa7ec8c570d8e44d..32e8168f64cc96a62c3cdc58a51d4773417c7e48 100644 (file)
--- a/mixer.h
+++ b/mixer.h
@@ -126,6 +126,21 @@ public:
                return theme->get_channel_name(channel);
        }
 
+       int get_channel_signal(unsigned channel) const
+       {
+               return theme->get_channel_signal(channel);
+       }
+
+       int map_signal(unsigned channel)
+       {
+               return theme->map_signal(channel);
+       }
+
+       void set_signal_mapping(int signal, int card)
+       {
+               return theme->set_signal_mapping(signal, card);
+       }
+
        bool get_supports_set_wb(unsigned channel) const
        {
                return theme->get_supports_set_wb(channel);
@@ -141,6 +156,11 @@ public:
                locut_cutoff_hz = cutoff_hz;
        }
 
+       void set_locut_enabled(bool enabled)
+       {
+               locut_enabled = enabled;
+       }
+
        float get_limiter_threshold_dbfs()
        {
                return limiter_threshold_dbfs;
@@ -204,6 +224,13 @@ public:
 
        void reset_meters();
 
+       unsigned get_num_cards() const { return num_cards; }
+
+       std::string get_card_description(unsigned card_index) const {
+               assert(card_index < num_cards);
+               return cards[card_index].usb->get_description();
+       }
+
 private:
        void bm_frame(unsigned card_index, uint16_t timecode,
                FrameAllocator::Frame video_frame, size_t video_offset, uint16_t video_format,
@@ -295,8 +322,9 @@ private:
        Resampler peak_resampler;
        std::atomic<float> peak{0.0f};
 
-       StereoFilter locut;  // Default cutoff 150 Hz, 24 dB/oct.
+       StereoFilter locut;  // Default cutoff 120 Hz, 24 dB/oct.
        std::atomic<float> locut_cutoff_hz;
+       std::atomic<bool> locut_enabled{true};
 
        // First compressor; takes us up to about -12 dBFS.
        StereoCompressor level_compressor;  // Under compressor_mutex. Used to set/override gain_staging_db if <level_compressor_enabled>.