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

#include <location.h>

Inheritance diagram for ARDOUR::Locations:
[legend]

Public Types

typedef std::list< Location * > LocationList
 
typedef std::pair< Temporal::timepos_t, Location * > LocationPair
 

Public Member Functions

 Locations (Session &)
 
 ~Locations ()
 
const LocationListlist () const
 
LocationList list ()
 
void add (Location *, bool make_current=false)
 
Locationadd_range (timepos_t const &start, timepos_t const &end)
 
void remove (Location *)
 
bool clear ()
 
bool clear_markers ()
 
bool clear_xrun_markers ()
 
bool clear_ranges ()
 
bool clear_cue_markers (samplepos_t start, samplepos_t end)
 
bool clear_scene_markers (samplepos_t start, samplepos_t end)
 
void cut_copy_section (timepos_t const &start, timepos_t const &end, timepos_t const &to, SectionOperation const op)
 
void ripple (timepos_t const &at, timecnt_t const &distance, bool include_locked)
 
XMLNodeget_state () const
 
int set_state (const XMLNode &, int version)
 
Locationget_location_by_id (PBD::ID)
 
Locationauto_loop_location () const
 
Locationauto_punch_location () const
 
Locationsession_range_location () const
 
Locationclock_origin_location () const
 
int next_available_name (std::string &result, std::string base)
 
uint32_t num_range_markers () const
 
int set_current (Location *, bool want_lock=true)
 
Locationcurrent () const
 
Locationmark_at (timepos_t const &, timecnt_t const &slop=timecnt_t::zero(Temporal::AudioTime), Location::Flags flags=Location::Flags(0)) const
 
void set_clock_origin (Location *, void *src)
 
timepos_t first_mark_before_flagged (timepos_t const &, bool include_special_ranges=false, Location::Flags whitelist=Location::Flags(0), Location::Flags blacklist=Location::Flags(0), Location::Flags equalist=Location::Flags(0), Location **retval=nullptr)
 
timepos_t first_mark_after_flagged (timepos_t const &, bool include_special_ranges=false, Location::Flags whitelist=Location::Flags(0), Location::Flags blacklist=Location::Flags(0), Location::Flags equalist=Location::Flags(0), Location **retval=nullptr)
 
timepos_t first_mark_after (timepos_t const &t, bool include_special_ranges=false)
 
timepos_t first_mark_before (timepos_t const &t, bool include_special_ranges=false)
 
Locationnext_section (Location *, timepos_t &, timepos_t &) const
 
Locationnext_section_iter (Location *, timepos_t &, timepos_t &, std::vector< LocationPair > &cache) const
 
Locationsection_at (timepos_t const &, timepos_t &, timepos_t &) const
 
void marks_either_side (timepos_t const &, timepos_t &, timepos_t &) const
 
Locationrange_starts_at (timepos_t const &pos, timecnt_t const &slop=timecnt_t(Temporal::AudioTime), bool incl=false) const
 
void find_all_between (timepos_t const &start, timepos_t const &end, LocationList &, Location::Flags)
 
void set_time_domain (Temporal::TimeDomain)
 
void start_domain_bounce (Temporal::DomainBounceInfo &)
 
void finish_domain_bounce (Temporal::DomainBounceInfo &)
 
void time_domain_changed ()
 
template<class T >
void apply (T &obj, void(T::*method)(const LocationList &)) const
 
- 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 ()
 
- 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 Temporal::TimeDomainProvider
 TimeDomainProvider ()
 
 TimeDomainProvider (TimeDomain td)
 
 TimeDomainProvider (TimeDomain td, TimeDomainProvider const &p)
 
 TimeDomainProvider (TimeDomainProvider const &other)
 
 TimeDomainProvider (TimeDomainProvider const &parnt, bool)
 
virtual ~TimeDomainProvider ()
 
XMLNodeget_state () const
 
int set_state (const XMLNode &, int version)
 
TimeDomainProvideroperator= (TimeDomainProvider const &other)
 
TimeDomain time_domain () const
 
bool has_own_time_domain () const
 
void clear_time_domain ()
 
void set_time_domain (TimeDomain td)
 
TimeDomainProvider const * time_domain_parent () const
 
bool has_time_domain_parent () const
 
void clear_time_domain_parent ()
 
void set_time_domain_parent (TimeDomainProvider const &p)
 
- Public Member Functions inherited from Temporal::TimeDomainSwapper
virtual ~TimeDomainSwapper ()
 

Public Attributes

PBD::Signal< void(Location *)> current_changed
 
PBD::Signal< void(Location *)> added
 
PBD::Signal< void(Location *)> removed
 
PBD::Signal< void()> changed
 
- 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 Temporal::TimeDomainProvider
PBD::Signal< void()> TimeDomainChanged
 

Private Member Functions

void sorted_section_locations (std::vector< LocationPair > &) const
 
int set_current_unlocked (Location *)
 
void location_changed (Location *)
 
void listen_to (Location *)
 

Private Attributes

LocationList locations
 
Locationcurrent_location
 
Glib::Threads::RWLock _lock
 

Additional Inherited Members

- Static Public Attributes inherited from PBD::Stateful
static int current_state_version
 
static int loading_state_version
 
- Protected Member Functions inherited from ARDOUR::SessionHandleRef
virtual void session_going_away ()
 
virtual void insanity_check ()
 
- 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 Temporal::TimeDomainProvider
void listen ()
 
- Protected Attributes inherited from ARDOUR::SessionHandleRef
ARDOUR::Session_session
 
- 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
 

Detailed Description

A collection of session locations including unique dedicated locations (loop, punch, etc)

Definition at line 248 of file location.h.

Member Typedef Documentation

◆ LocationList

Definition at line 251 of file location.h.

◆ LocationPair

Definition at line 252 of file location.h.

Constructor & Destructor Documentation

◆ Locations()

ARDOUR::Locations::Locations ( Session )

◆ ~Locations()

ARDOUR::Locations::~Locations ( )

Member Function Documentation

◆ add()

void ARDOUR::Locations::add ( Location ,
bool  make_current = false 
)

◆ add_range()

Location* ARDOUR::Locations::add_range ( timepos_t const &  start,
timepos_t const &  end 
)

Add new range to the collection

Parameters
startstart position
endend position
Returns
New location object

◆ apply()

template<class T >
void ARDOUR::Locations::apply ( T &  obj,
void(T::*)(const LocationList &)  method 
) const
inline

Definition at line 347 of file location.h.

◆ auto_loop_location()

Location* ARDOUR::Locations::auto_loop_location ( ) const

◆ auto_punch_location()

Location* ARDOUR::Locations::auto_punch_location ( ) const

◆ clear()

bool ARDOUR::Locations::clear ( )

◆ clear_cue_markers()

bool ARDOUR::Locations::clear_cue_markers ( samplepos_t  start,
samplepos_t  end 
)

◆ clear_markers()

bool ARDOUR::Locations::clear_markers ( )

◆ clear_ranges()

bool ARDOUR::Locations::clear_ranges ( )

◆ clear_scene_markers()

bool ARDOUR::Locations::clear_scene_markers ( samplepos_t  start,
samplepos_t  end 
)

◆ clear_xrun_markers()

bool ARDOUR::Locations::clear_xrun_markers ( )

◆ clock_origin_location()

Location* ARDOUR::Locations::clock_origin_location ( ) const

◆ current()

Location* ARDOUR::Locations::current ( ) const
inline

Definition at line 297 of file location.h.

◆ cut_copy_section()

void ARDOUR::Locations::cut_copy_section ( timepos_t const &  start,
timepos_t const &  end,
timepos_t const &  to,
SectionOperation const  op 
)

◆ find_all_between()

void ARDOUR::Locations::find_all_between ( timepos_t const &  start,
timepos_t const &  end,
LocationList ,
Location::Flags   
)

◆ finish_domain_bounce()

void ARDOUR::Locations::finish_domain_bounce ( Temporal::DomainBounceInfo )
virtual

◆ first_mark_after()

timepos_t ARDOUR::Locations::first_mark_after ( timepos_t const &  t,
bool  include_special_ranges = false 
)
inline

Definition at line 306 of file location.h.

◆ first_mark_after_flagged()

timepos_t ARDOUR::Locations::first_mark_after_flagged ( timepos_t const &  ,
bool  include_special_ranges = false,
Location::Flags  whitelist = Location::Flags(0),
Location::Flags  blacklist = Location::Flags(0),
Location::Flags  equalist = Location::Flags(0),
Location **  retval = nullptr 
)

◆ first_mark_before()

timepos_t ARDOUR::Locations::first_mark_before ( timepos_t const &  t,
bool  include_special_ranges = false 
)
inline

Definition at line 309 of file location.h.

◆ first_mark_before_flagged()

timepos_t ARDOUR::Locations::first_mark_before_flagged ( timepos_t const &  ,
bool  include_special_ranges = false,
Location::Flags  whitelist = Location::Flags(0),
Location::Flags  blacklist = Location::Flags(0),
Location::Flags  equalist = Location::Flags(0),
Location **  retval = nullptr 
)

◆ get_location_by_id()

Location* ARDOUR::Locations::get_location_by_id ( PBD::ID  )

◆ get_state()

XMLNode& ARDOUR::Locations::get_state ( ) const
virtual

Implements PBD::Stateful.

◆ list() [1/2]

LocationList ARDOUR::Locations::list ( )
inline

Definition at line 258 of file location.h.

◆ list() [2/2]

const LocationList& ARDOUR::Locations::list ( ) const
inline

Definition at line 257 of file location.h.

◆ listen_to()

void ARDOUR::Locations::listen_to ( Location )
private

◆ location_changed()

void ARDOUR::Locations::location_changed ( Location )
private

◆ mark_at()

Location* ARDOUR::Locations::mark_at ( timepos_t const &  ,
timecnt_t const &  slop = timecnt_t::zero(Temporal::AudioTime),
Location::Flags  flags = Location::Flags(0) 
) const

◆ marks_either_side()

void ARDOUR::Locations::marks_either_side ( timepos_t const &  ,
timepos_t ,
timepos_t  
) const

◆ next_available_name()

int ARDOUR::Locations::next_available_name ( std::string &  result,
std::string  base 
)

◆ next_section()

Location* ARDOUR::Locations::next_section ( Location ,
timepos_t ,
timepos_t  
) const

◆ next_section_iter()

Location* ARDOUR::Locations::next_section_iter ( Location ,
timepos_t ,
timepos_t ,
std::vector< LocationPair > &  cache 
) const

◆ num_range_markers()

uint32_t ARDOUR::Locations::num_range_markers ( ) const

◆ range_starts_at()

Location* ARDOUR::Locations::range_starts_at ( timepos_t const &  pos,
timecnt_t const &  slop = timecnt_t(Temporal::AudioTime),
bool  incl = false 
) const

Return range with closest start pos to the where argument

Parameters
pospoint to compare with start pos
sloparea around point to search for start pos
incl(optional) look only for ranges that includes 'where' point
Returns
Location object or nil

◆ remove()

void ARDOUR::Locations::remove ( Location )

◆ ripple()

void ARDOUR::Locations::ripple ( timepos_t const &  at,
timecnt_t const &  distance,
bool  include_locked 
)

◆ section_at()

Location* ARDOUR::Locations::section_at ( timepos_t const &  ,
timepos_t ,
timepos_t  
) const

◆ session_range_location()

Location* ARDOUR::Locations::session_range_location ( ) const

◆ set_clock_origin()

void ARDOUR::Locations::set_clock_origin ( Location ,
void *  src 
)

◆ set_current()

int ARDOUR::Locations::set_current ( Location ,
bool  want_lock = true 
)

◆ set_current_unlocked()

int ARDOUR::Locations::set_current_unlocked ( Location )
private

◆ set_state()

int ARDOUR::Locations::set_state ( const XMLNode ,
int  version 
)
virtual

Implements PBD::Stateful.

◆ set_time_domain()

void ARDOUR::Locations::set_time_domain ( Temporal::TimeDomain  )

◆ sorted_section_locations()

void ARDOUR::Locations::sorted_section_locations ( std::vector< LocationPair > &  ) const
private

◆ start_domain_bounce()

void ARDOUR::Locations::start_domain_bounce ( Temporal::DomainBounceInfo )
virtual

◆ time_domain_changed()

void ARDOUR::Locations::time_domain_changed ( )
virtual

Reimplemented from Temporal::TimeDomainProvider.

Member Data Documentation

◆ _lock

Glib::Threads::RWLock ARDOUR::Locations::_lock
mutableprivate

Definition at line 364 of file location.h.

◆ added

PBD::Signal<void(Location*)> ARDOUR::Locations::added

Definition at line 343 of file location.h.

◆ changed

PBD::Signal<void()> ARDOUR::Locations::changed

Definition at line 345 of file location.h.

◆ current_changed

PBD::Signal<void(Location*)> ARDOUR::Locations::current_changed

Definition at line 337 of file location.h.

◆ current_location

Location* ARDOUR::Locations::current_location
private

Definition at line 363 of file location.h.

◆ locations

LocationList ARDOUR::Locations::locations
private

Definition at line 362 of file location.h.

◆ removed

PBD::Signal<void(Location*)> ARDOUR::Locations::removed

Definition at line 344 of file location.h.


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