- void set_cut_all (bool);
- void set_dim_all (bool);
- void set_polarity (uint32_t, bool invert);
- void set_cut (uint32_t, bool cut);
- void set_dim (uint32_t, bool dim);
- void set_solo (uint32_t, bool);
- void set_mono (bool);
-
- void set_dim_level (gain_t);
- void set_solo_boost_level (gain_t);
-
- gain_t dim_level() const { return _dim_level; }
- gain_t solo_boost_level() const { return _solo_boost_level; }
-
- bool dimmed (uint32_t chn) const;
- bool soloed (uint32_t chn) const;
- bool inverted (uint32_t chn) const;
- bool cut (uint32_t chn) const;
- bool cut_all () const;
- bool dim_all () const;
- bool mono () const;
-
- PBD::Signal0<void> Changed;
-
- boost::shared_ptr<PBD::Controllable> channel_cut_control (uint32_t) const;
- boost::shared_ptr<PBD::Controllable> channel_dim_control (uint32_t) const;
- boost::shared_ptr<PBD::Controllable> channel_polarity_control (uint32_t) const;
- boost::shared_ptr<PBD::Controllable> channel_solo_control (uint32_t) const;
-
- boost::shared_ptr<PBD::Controllable> dim_control () const { return _dim_all_control; }
- boost::shared_ptr<PBD::Controllable> cut_control () const { return _cut_all_control; }
- boost::shared_ptr<PBD::Controllable> mono_control () const { return _mono_control; }
- boost::shared_ptr<PBD::Controllable> dim_level_control () const { return _dim_level_control; }
- boost::shared_ptr<PBD::Controllable> solo_boost_control () const { return _solo_boost_level_control; }
-
- private:
- struct ChannelRecord {
- gain_t current_gain;
-
- /* pointers - created first, but managed by boost::shared_ptr<> */
-
- MPControl<gain_t>* cut_ptr;
- MPControl<bool>* dim_ptr;
- MPControl<gain_t>* polarity_ptr;
- MPControl<bool>* soloed_ptr;
-
- /* shared ptr access and lifetime management, for external users */
-
- boost::shared_ptr<PBD::Controllable> cut_control;
- boost::shared_ptr<PBD::Controllable> dim_control;
- boost::shared_ptr<PBD::Controllable> polarity_control;
- boost::shared_ptr<PBD::Controllable> soloed_control;
-
- /* typed controllables for internal use */
-
- MPControl<gain_t>& cut;
- MPControl<bool>& dim;
- MPControl<gain_t>& polarity;
- MPControl<bool>& soloed;
-
- ChannelRecord (uint32_t chn) : current_gain(1.0)
- , cut_ptr (new MPControl<gain_t> (1.0, string_compose (_("cut control %1"), chn), PBD::Controllable::GainLike))
- , dim_ptr (new MPControl<bool> (false, string_compose (_("dim control"), chn), PBD::Controllable::Toggle))
- , polarity_ptr (new MPControl<gain_t> (1.0, string_compose (_("polarity control"), chn), PBD::Controllable::Toggle))
- , soloed_ptr (new MPControl<bool> (false, string_compose (_("solo control"), chn), PBD::Controllable::Toggle))
-
- , cut_control (cut_ptr)
- , dim_control (dim_ptr)
- , polarity_control (polarity_ptr)
- , soloed_control (soloed_ptr)
-
- , cut (*cut_ptr)
- , dim (*dim_ptr)
- , polarity (*polarity_ptr)
- , soloed (*soloed_ptr)
-
- {}
- };
-
- std::vector<ChannelRecord*> _channels;
-
- uint32_t solo_cnt;
-
- /* pointers - created first, but managed by boost::shared_ptr<> */
-
- MPControl<bool>* _dim_all_ptr;
- MPControl<bool>* _cut_all_ptr;
- MPControl<bool>* _mono_ptr;
- MPControl<volatile gain_t>* _dim_level_ptr;
- MPControl<volatile gain_t>* _solo_boost_level_ptr;
-
- /* shared ptr access and lifetime management, for external users */
-
- boost::shared_ptr<PBD::Controllable> _dim_all_control;
- boost::shared_ptr<PBD::Controllable> _cut_all_control;
- boost::shared_ptr<PBD::Controllable> _mono_control;
- boost::shared_ptr<PBD::Controllable> _dim_level_control;
- boost::shared_ptr<PBD::Controllable> _solo_boost_level_control;
-
- /* typed controllables for internal use */
-
- MPControl<bool>& _dim_all;
- MPControl<bool>& _cut_all;
- MPControl<bool>& _mono;
- MPControl<volatile gain_t>& _dim_level;
- MPControl<volatile gain_t>& _solo_boost_level;
-
- void allocate_channels (uint32_t);
+ void set_cut_all (bool);
+ void set_dim_all (bool);
+ void set_polarity (uint32_t, bool invert);
+ void set_cut (uint32_t, bool cut);
+ void set_dim (uint32_t, bool dim);
+ void set_solo (uint32_t, bool);
+ void set_mono (bool);
+
+ gain_t dim_level() const { return _dim_level; }
+ gain_t solo_boost_level() const { return _solo_boost_level; }
+
+ bool dimmed (uint32_t chn) const;
+ bool soloed (uint32_t chn) const;
+ bool inverted (uint32_t chn) const;
+ bool cut (uint32_t chn) const;
+ bool cut_all () const;
+ bool dim_all () const;
+ bool mono () const;
+
+ PBD::Signal0<void> Changed;
+
+ boost::shared_ptr<PBD::Controllable> channel_cut_control (uint32_t) const;
+ boost::shared_ptr<PBD::Controllable> channel_dim_control (uint32_t) const;
+ boost::shared_ptr<PBD::Controllable> channel_polarity_control (uint32_t) const;
+ boost::shared_ptr<PBD::Controllable> channel_solo_control (uint32_t) const;
+
+ boost::shared_ptr<PBD::Controllable> dim_control () const { return _dim_all_control; }
+ boost::shared_ptr<PBD::Controllable> cut_control () const { return _cut_all_control; }
+ boost::shared_ptr<PBD::Controllable> mono_control () const { return _mono_control; }
+ boost::shared_ptr<PBD::Controllable> dim_level_control () const { return _dim_level_control; }
+ boost::shared_ptr<PBD::Controllable> solo_boost_control () const { return _solo_boost_level_control; }
+
+private:
+ struct ChannelRecord {
+ gain_t current_gain;
+
+ /* pointers - created first, but managed by boost::shared_ptr<> */
+
+ MPControl<gain_t>* cut_ptr;
+ MPControl<bool>* dim_ptr;
+ MPControl<gain_t>* polarity_ptr;
+ MPControl<bool>* soloed_ptr;
+
+ /* shared ptr access and lifetime management, for external users */
+
+ boost::shared_ptr<PBD::Controllable> cut_control;
+ boost::shared_ptr<PBD::Controllable> dim_control;
+ boost::shared_ptr<PBD::Controllable> polarity_control;
+ boost::shared_ptr<PBD::Controllable> soloed_control;
+
+ /* typed controllables for internal use */
+
+ MPControl<gain_t>& cut;
+ MPControl<bool>& dim;
+ MPControl<gain_t>& polarity;
+ MPControl<bool>& soloed;
+
+ ChannelRecord (uint32_t);
+ };
+
+ std::vector<ChannelRecord*> _channels;
+
+ uint32_t solo_cnt;
+
+ /* pointers - created first, but managed by boost::shared_ptr<> */
+
+ MPControl<bool>* _dim_all_ptr;
+ MPControl<bool>* _cut_all_ptr;
+ MPControl<bool>* _mono_ptr;
+ MPControl<volatile gain_t>* _dim_level_ptr;
+ MPControl<volatile gain_t>* _solo_boost_level_ptr;
+
+ /* shared ptr access and lifetime management, for external users */
+
+ boost::shared_ptr<PBD::Controllable> _dim_all_control;
+ boost::shared_ptr<PBD::Controllable> _cut_all_control;
+ boost::shared_ptr<PBD::Controllable> _mono_control;
+ boost::shared_ptr<PBD::Controllable> _dim_level_control;
+ boost::shared_ptr<PBD::Controllable> _solo_boost_level_control;
+
+ /* typed controllables for internal use */
+
+ MPControl<bool>& _dim_all;
+ MPControl<bool>& _cut_all;
+ MPControl<bool>& _mono;
+ MPControl<volatile gain_t>& _dim_level;
+ MPControl<volatile gain_t>& _solo_boost_level;
+
+ void allocate_channels (uint32_t);