Ardour  9.0-pre0-582-g084a23a80d
ARDOUR::AutomationControl Class Reference

#include <automation_control.h>

Inheritance diagram for ARDOUR::AutomationControl:
[legend]

Public Member Functions

 AutomationControl (ARDOUR::Session &, const Evoral::Parameter &parameter, const ParameterDescriptor &desc, std::shared_ptr< ARDOUR::AutomationList > l=std::shared_ptr< ARDOUR::AutomationList >(), const std::string &name="", PBD::Controllable::Flag flags=PBD::Controllable::Flag(0))
 
virtual ~AutomationControl ()
 
std::shared_ptr< AutomationListalist () const
 
void set_list (std::shared_ptr< Evoral::ControlList >)
 
bool automation_playback () const
 
bool automation_write () const
 
AutoState automation_state () const
 
void set_automation_state (AutoState as)
 
void start_touch (timepos_t const &when)
 
void stop_touch (timepos_t const &when)
 
virtual double get_value () const
 
virtual double get_save_value () const
 
void set_value (double value, PBD::Controllable::GroupControlDisposition group_override)
 
virtual bool writable () const
 
void set_value_unchecked (double val)
 
virtual void automation_run (samplepos_t start, pframes_t nframes)
 
double lower () const
 
double upper () const
 
double normal () const
 
bool toggled () const
 
double internal_to_interface (double, bool rotary=false) const
 
double interface_to_internal (double, bool rotary=false) const
 
virtual std::string get_user_string () const
 
const ParameterDescriptordesc () const
 
const ARDOUR::Sessionsession () const
 
void commit_transaction (bool did_write)
 
AutomationControlList grouped_controls () const
 
void add_visually_linked_control (std::shared_ptr< AutomationControl > ctrl)
 
void clear_visually_linked_control ()
 
WeakAutomationControlList visually_linked_controls () const
 
- Public Member Functions inherited from PBD::Controllable
 Controllable (const std::string &name, Flag f=Flag(0))
 
virtual float get_interface (bool rotary=false) const
 
virtual void set_interface (float fraction, bool rotary=false, GroupControlDisposition gcd=NoGroup)
 
int set_state (const XMLNode &, int version)
 
virtual XMLNodeget_state () const
 
std::string name () const
 
bool touching () const
 
bool is_toggle () const
 
bool is_gain_like () const
 
Flag flags () const
 
void set_flags (Flag f)
 
void set_flag (Flag f)
 _flags |= f; More...
 
void clear_flag (Flag f)
 _flags &= ~f; More...
 
- Public Member Functions inherited from PBD::Stateful
 Stateful ()
 
virtual ~Stateful ()
 
virtual bool apply_change (PropertyBase const &)
 
PropertyChange apply_changes (PropertyList const &)
 
const OwnedPropertyListproperties () const
 
void add_property (PropertyBase &s)
 
void add_extra_xml (XMLNode &)
 
XMLNodeextra_xml (const std::string &str, bool add_if_missing=false)
 
void save_extra_xml (const XMLNode &)
 
const PBD::IDid () const
 
bool set_id (const XMLNode &)
 
void set_id (const std::string &)
 
void reset_id ()
 
void clear_changes ()
 
virtual void clear_owned_changes ()
 
PropertyListget_changes_as_properties (PBD::Command *) const
 
virtual void rdiff (std::vector< PBD::Command * > &) const
 
bool changed () const
 
virtual PropertyListproperty_factory (const XMLNode &) const
 
virtual void suspend_property_changes ()
 
virtual void resume_property_changes ()
 
bool property_changes_suspended () const
 
- Public Member Functions inherited from PBD::Destructible
virtual ~Destructible ()
 
virtual void drop_references ()
 
- Public Member Functions inherited from Evoral::Control
 Control (const Parameter &parameter, const ParameterDescriptor &desc, std::shared_ptr< ControlList > list)
 
virtual ~Control ()
 
virtual void set_double (double val, Temporal::timepos_t const &when=Temporal::timepos_t(), bool to_list=false)
 
virtual double get_double () const
 
void set_list (std::shared_ptr< ControlList >)
 
std::shared_ptr< ControlListlist ()
 
std::shared_ptr< const ControlListlist () const
 
const Parameterparameter () const
 
- Public Member Functions inherited from ARDOUR::ControlGroupMember
virtual ~ControlGroupMember ()
 
- Public Member Functions inherited from ARDOUR::SessionHandleRef
 SessionHandleRef (ARDOUR::Session &s)
 
virtual ~SessionHandleRef ()
 
- Public Member Functions inherited from PBD::ScopedConnectionList
 ScopedConnectionList ()
 
 ScopedConnectionList (const ScopedConnectionList &)=delete
 
ScopedConnectionListoperator= (const ScopedConnectionList &)=delete
 
virtual ~ScopedConnectionList ()
 
void add_connection (const UnscopedConnection &c)
 
void drop_connections ()
 

Protected Member Functions

bool check_rt (double val, Controllable::GroupControlDisposition gcd)
 
virtual void actually_set_value (double value, PBD::Controllable::GroupControlDisposition)
 
void pre_realtime_queue_stuff (double new_value, PBD::Controllable::GroupControlDisposition)
 
virtual void do_pre_realtime_queue_stuff (double new_value)
 
void session_going_away ()
 
- Protected Member Functions inherited from PBD::Controllable
void set_touching (bool yn)
 
- Protected Member Functions inherited from PBD::Stateful
void add_instant_xml (XMLNode &, const std::string &directory_path)
 
XMLNodeinstant_xml (const std::string &str, const std::string &directory_path)
 
void add_properties (XMLNode &) const
 
PropertyChange set_values (XMLNode const &)
 
virtual void post_set (const PropertyChange &)
 
virtual void send_change (const PropertyChange &)
 
virtual void mid_thaw (const PropertyChange &)
 
bool regenerate_xml_or_string_ids () const
 
- Protected Member Functions inherited from ARDOUR::SessionHandleRef
virtual void insanity_check ()
 

Protected Attributes

std::shared_ptr< ControlGroup_group
 
std::shared_ptr< ControlGroup_pushed_group
 
const ParameterDescriptor _desc
 
WeakAutomationControlList _visually_linked_ctrls
 
- Protected Attributes inherited from PBD::Stateful
XMLNode_extra_xml
 
XMLNode_instant_xml
 
PBD::PropertyChange _pending_changed
 
Glib::Threads::Mutex _lock
 
std::string _xml_node_name
 name of node to use for this object in XML More...
 
OwnedPropertyList_properties
 
- Protected Attributes inherited from Evoral::Control
Parameter _parameter
 
std::shared_ptr< ControlList_list
 
double _user_value
 
PBD::ScopedConnection _list_marked_dirty_connection
 
- Protected Attributes inherited from ARDOUR::SessionHandleRef
ARDOUR::Session_session
 

Private Member Functions

void set_group (std::shared_ptr< ControlGroup >)
 
bool push_group (std::shared_ptr< ControlGroup >)
 
bool pop_group ()
 

Private Attributes

PBD::ScopedConnection _state_changed_connection
 
bool _no_session
 

Friends

class Session
 
class ControlGroup
 

Additional Inherited Members

- Public Types inherited from PBD::Controllable
enum  Flag {
  Toggle = 0x01 , GainLike = 0x02 , RealTime = 0x04 , NotAutomatable = 0x08 ,
  InlineControl = 0x10 , HiddenControl = 0x20 , MonitorControl = 0x40
}
 
enum  GroupControlDisposition { InverseGroup , NoGroup , UseGroup , ForGroup }
 
- Static Public Member Functions inherited from PBD::Controllable
static std::shared_ptr< Controllableby_id (const PBD::ID &)
 
static void dump_registry ()
 
static ControllableSet registered_controllables ()
 
- Public Attributes inherited from PBD::Controllable
PBD::Signal< void()> LearningFinished
 
PBD::Signal< void(bool, PBD::Controllable::GroupControlDisposition)> Changed
 
PBD::Signal< void()> TouchChanged
 
- Public Attributes inherited from PBD::Stateful
PBD::Signal< void(const PropertyChange &)> PropertyChanged
 
- Public Attributes inherited from PBD::Destructible
PBD::Signal< void()> Destroyed
 
PBD::Signal< void()> DropReferences
 
- Public Attributes inherited from Evoral::Control
PBD::Signal< void()> ListMarkedDirty
 
- Static Public Attributes inherited from PBD::Controllable
static PBD::Signal< bool(std::weak_ptr< PBD::Controllable >)> StartLearning
 
static PBD::Signal< void(std::weak_ptr< PBD::Controllable >)> StopLearning
 
static PBD::Signal< void(std::weak_ptr< PBD::Controllable >)> GUIFocusChanged
 
static PBD::Signal< void(std::weak_ptr< PBD::Controllable >)> ControlTouched
 
static const std::string xml_node_name
 
- Static Public Attributes inherited from PBD::Stateful
static int current_state_version
 
static int loading_state_version
 

Detailed Description

A PBD::Controllable with associated automation data (AutomationList)

Definition at line 50 of file automation_control.h.

Constructor & Destructor Documentation

◆ AutomationControl()

ARDOUR::AutomationControl::AutomationControl ( ARDOUR::Session ,
const Evoral::Parameter parameter,
const ParameterDescriptor desc,
std::shared_ptr< ARDOUR::AutomationList l = std::shared_ptr< ARDOUR::AutomationList >(),
const std::string &  name = "",
PBD::Controllable::Flag  flags = PBD::Controllable::Flag(0) 
)

◆ ~AutomationControl()

virtual ARDOUR::AutomationControl::~AutomationControl ( )
virtual

Member Function Documentation

◆ actually_set_value()

◆ add_visually_linked_control()

void ARDOUR::AutomationControl::add_visually_linked_control ( std::shared_ptr< AutomationControl ctrl)
inline

Definition at line 126 of file automation_control.h.

◆ alist()

std::shared_ptr<AutomationList> ARDOUR::AutomationControl::alist ( ) const
inline

Definition at line 67 of file automation_control.h.

◆ automation_playback()

bool ARDOUR::AutomationControl::automation_playback ( ) const
inline

Definition at line 73 of file automation_control.h.

◆ automation_run()

virtual void ARDOUR::AutomationControl::automation_run ( samplepos_t  start,
pframes_t  nframes 
)
virtual

◆ automation_state()

AutoState ARDOUR::AutomationControl::automation_state ( ) const
inline

Definition at line 81 of file automation_control.h.

◆ automation_write()

bool ARDOUR::AutomationControl::automation_write ( ) const
inline

Definition at line 77 of file automation_control.h.

◆ check_rt()

bool ARDOUR::AutomationControl::check_rt ( double  val,
Controllable::GroupControlDisposition  gcd 
)
protected

◆ clear_visually_linked_control()

void ARDOUR::AutomationControl::clear_visually_linked_control ( )
inline

Definition at line 130 of file automation_control.h.

◆ commit_transaction()

void ARDOUR::AutomationControl::commit_transaction ( bool  did_write)

◆ desc()

const ParameterDescriptor& ARDOUR::AutomationControl::desc ( ) const
inline

Definition at line 119 of file automation_control.h.

◆ do_pre_realtime_queue_stuff()

virtual void ARDOUR::AutomationControl::do_pre_realtime_queue_stuff ( double  new_value)
inlineprotectedvirtual

Reimplemented in ARDOUR::RecordEnableControl.

Definition at line 160 of file automation_control.h.

◆ get_save_value()

virtual double ARDOUR::AutomationControl::get_save_value ( ) const
virtual

This is used when saving state. By default it just calls get_value(), but a class with more complex semantics might override this to save some value that differs from what get_value() would return.

Reimplemented from PBD::Controllable.

Reimplemented in ARDOUR::SoloControl, and ARDOUR::MuteControl.

◆ get_user_string()

virtual std::string ARDOUR::AutomationControl::get_user_string ( ) const
virtual

◆ get_value()

virtual double ARDOUR::AutomationControl::get_value ( ) const
virtual

◆ grouped_controls()

AutomationControlList ARDOUR::AutomationControl::grouped_controls ( ) const

◆ interface_to_internal()

double ARDOUR::AutomationControl::interface_to_internal ( double  ,
bool  rotary = false 
) const
virtual

Reimplemented from PBD::Controllable.

◆ internal_to_interface()

double ARDOUR::AutomationControl::internal_to_interface ( double  i,
bool  rotary = false 
) const
virtual

Conversions between ‘internal’, 'interface', and 'user' values

Reimplemented from PBD::Controllable.

◆ lower()

double ARDOUR::AutomationControl::lower ( ) const
inlinevirtual

Reimplemented from PBD::Controllable.

Definition at line 109 of file automation_control.h.

◆ normal()

double ARDOUR::AutomationControl::normal ( ) const
inlinevirtual

Reimplemented from PBD::Controllable.

Definition at line 111 of file automation_control.h.

◆ pop_group()

bool ARDOUR::AutomationControl::pop_group ( )
privatevirtual

◆ pre_realtime_queue_stuff()

void ARDOUR::AutomationControl::pre_realtime_queue_stuff ( double  new_value,
PBD::Controllable::GroupControlDisposition   
)
protected

◆ push_group()

bool ARDOUR::AutomationControl::push_group ( std::shared_ptr< ControlGroup )
privatevirtual

◆ session()

const ARDOUR::Session& ARDOUR::AutomationControl::session ( ) const
inline

Definition at line 121 of file automation_control.h.

◆ session_going_away()

void ARDOUR::AutomationControl::session_going_away ( )
protectedvirtual

Reimplemented from ARDOUR::SessionHandleRef.

◆ set_automation_state()

void ARDOUR::AutomationControl::set_automation_state ( AutoState  as)

◆ set_group()

void ARDOUR::AutomationControl::set_group ( std::shared_ptr< ControlGroup )
privatevirtual

◆ set_list()

void ARDOUR::AutomationControl::set_list ( std::shared_ptr< Evoral::ControlList )

◆ set_value()

void ARDOUR::AutomationControl::set_value ( double  value,
PBD::Controllable::GroupControlDisposition  group_override 
)
virtual

Set ‘internal’ value

All derived classes must implement this.

Basic derived classes will ignore group_override but more sophisticated children, notably those that proxy the value setting logic via an object that is aware of group relationships between this control and others, will find it useful.

Parameters
valueraw numeric value to set
group_overrideif and how to propagate value to grouped controls

Implements PBD::Controllable.

Reimplemented in ARDOUR::RecordEnableControl.

◆ set_value_unchecked()

void ARDOUR::AutomationControl::set_value_unchecked ( double  val)
inline

Definition at line 103 of file automation_control.h.

◆ start_touch()

void ARDOUR::AutomationControl::start_touch ( timepos_t const &  when)

◆ stop_touch()

void ARDOUR::AutomationControl::stop_touch ( timepos_t const &  when)

◆ toggled()

bool ARDOUR::AutomationControl::toggled ( ) const
inline

Definition at line 112 of file automation_control.h.

◆ upper()

double ARDOUR::AutomationControl::upper ( ) const
inlinevirtual

Reimplemented from PBD::Controllable.

Definition at line 110 of file automation_control.h.

◆ visually_linked_controls()

WeakAutomationControlList ARDOUR::AutomationControl::visually_linked_controls ( ) const
inline

Definition at line 134 of file automation_control.h.

◆ writable()

virtual bool ARDOUR::AutomationControl::writable ( ) const
virtual

Reimplemented in ARDOUR::MidiTrack::MidiControl.

Friends And Related Function Documentation

◆ ControlGroup

friend class ControlGroup
friend

Definition at line 171 of file automation_control.h.

◆ Session

friend class Session
friend

Definition at line 156 of file automation_control.h.

Member Data Documentation

◆ _desc

const ParameterDescriptor ARDOUR::AutomationControl::_desc
protected

Definition at line 142 of file automation_control.h.

◆ _group

std::shared_ptr<ControlGroup> ARDOUR::AutomationControl::_group
protected

Definition at line 139 of file automation_control.h.

◆ _no_session

bool ARDOUR::AutomationControl::_no_session
private

Definition at line 176 of file automation_control.h.

◆ _pushed_group

std::shared_ptr<ControlGroup> ARDOUR::AutomationControl::_pushed_group
protected

Definition at line 140 of file automation_control.h.

◆ _state_changed_connection

PBD::ScopedConnection ARDOUR::AutomationControl::_state_changed_connection
private

Definition at line 175 of file automation_control.h.

◆ _visually_linked_ctrls

WeakAutomationControlList ARDOUR::AutomationControl::_visually_linked_ctrls
protected

Definition at line 164 of file automation_control.h.


The documentation for this class was generated from the following file: