Ardour  9.0-pre0-582-g084a23a80d
ARDOUR::PortEngineSharedImpl Class Referenceabstract

#include <port_engine_shared.h>

Inheritance diagram for ARDOUR::PortEngineSharedImpl:
[legend]

Classes

struct  PortConnectData
 
struct  SortByPortName
 

Public Member Functions

 PortEngineSharedImpl (PortManager &mgr, std::string const &instance_name)
 
virtual ~PortEngineSharedImpl ()
 
bool port_is_physical (PortEngine::PortHandle) const
 
void get_physical_outputs (DataType type, std::vector< std::string > &)
 
void get_physical_inputs (DataType type, std::vector< std::string > &)
 
ChanCount n_physical_outputs () const
 
ChanCount n_physical_inputs () const
 
uint32_t port_name_size () const
 
int set_port_name (PortEngine::PortHandle, const std::string &)
 
std::string get_port_name (PortEngine::PortHandle) const
 
PortFlags get_port_flags (PortEngine::PortHandle) const
 
PortEngine::PortPtr get_port_by_name (const std::string &) const
 
int get_port_property (PortEngine::PortHandle, const std::string &key, std::string &value, std::string &type) const
 
int set_port_property (PortEngine::PortHandle, const std::string &key, const std::string &value, const std::string &type)
 
int get_ports (const std::string &port_name_pattern, DataType type, PortFlags flags, std::vector< std::string > &) const
 
DataType port_data_type (PortEngine::PortHandle) const
 
PortEngine::PortPtr register_port (const std::string &shortname, ARDOUR::DataType, ARDOUR::PortFlags)
 
virtual void unregister_port (PortEngine::PortHandle)
 
int connect (const std::string &src, const std::string &dst)
 
int disconnect (const std::string &src, const std::string &dst)
 
int connect (PortEngine::PortHandle, const std::string &)
 
int disconnect (PortEngine::PortHandle, const std::string &)
 
int disconnect_all (PortEngine::PortHandle)
 
bool connected (PortEngine::PortHandle, bool process_callback_safe)
 
bool connected_to (PortEngine::PortHandle, const std::string &, bool process_callback_safe)
 
bool physically_connected (PortEngine::PortHandle, bool process_callback_safe)
 
int get_connections (PortEngine::PortHandle, std::vector< std::string > &, bool process_callback_safe)
 

Protected Types

typedef std::map< std::string, BackendPortPtrPortMap
 
typedef std::set< BackendPortPtr, SortByPortNamePortIndex
 
typedef std::set< BackendPortPtrPortRegistry
 

Protected Member Functions

void port_connect_callback (const std::string &a, const std::string &b, bool conn)
 
void process_connection_queue_locked (PortManager &mgr)
 
void port_connect_add_remove_callback ()
 
virtual void update_system_port_latencies ()
 
void clear_ports ()
 
BackendPortPtr add_port (const std::string &shortname, ARDOUR::DataType, ARDOUR::PortFlags)
 
void unregister_ports (bool system_only=false)
 
bool valid_port (BackendPortHandle port) const
 
BackendPortPtr find_port (const std::string &port_name) const
 
virtual BackendPortport_factory (std::string const &name, ARDOUR::DataType dt, ARDOUR::PortFlags flags)=0
 
void list_ports () const
 

Protected Attributes

std::string _instance_name
 
std::vector< BackendPortPtr_system_inputs
 
std::vector< BackendPortPtr_system_outputs
 
std::vector< BackendPortPtr_system_midi_in
 
std::vector< BackendPortPtr_system_midi_out
 
std::vector< PortConnectData * > _port_connection_queue
 
pthread_mutex_t _port_callback_mutex
 
std::atomic< int > _port_change_flag
 
SerializedRCUManager< PortMap_portmap
 
SerializedRCUManager< PortIndex_ports
 
SerializedRCUManager< PortRegistry_portregistry
 

Friends

class BackendPort
 

Detailed Description

Definition at line 134 of file port_engine_shared.h.

Member Typedef Documentation

◆ PortIndex

Definition at line 225 of file port_engine_shared.h.

◆ PortMap

typedef std::map<std::string, BackendPortPtr> ARDOUR::PortEngineSharedImpl::PortMap
protected

Definition at line 224 of file port_engine_shared.h.

◆ PortRegistry

Definition at line 226 of file port_engine_shared.h.

Constructor & Destructor Documentation

◆ PortEngineSharedImpl()

ARDOUR::PortEngineSharedImpl::PortEngineSharedImpl ( PortManager mgr,
std::string const &  instance_name 
)

◆ ~PortEngineSharedImpl()

virtual ARDOUR::PortEngineSharedImpl::~PortEngineSharedImpl ( )
virtual

Member Function Documentation

◆ add_port()

BackendPortPtr ARDOUR::PortEngineSharedImpl::add_port ( const std::string &  shortname,
ARDOUR::DataType  ,
ARDOUR::PortFlags   
)
protected

◆ clear_ports()

void ARDOUR::PortEngineSharedImpl::clear_ports ( )
protected

◆ connect() [1/2]

int ARDOUR::PortEngineSharedImpl::connect ( const std::string &  src,
const std::string &  dst 
)

◆ connect() [2/2]

int ARDOUR::PortEngineSharedImpl::connect ( PortEngine::PortHandle  ,
const std::string &   
)

◆ connected()

bool ARDOUR::PortEngineSharedImpl::connected ( PortEngine::PortHandle  ,
bool  process_callback_safe 
)

◆ connected_to()

bool ARDOUR::PortEngineSharedImpl::connected_to ( PortEngine::PortHandle  ,
const std::string &  ,
bool  process_callback_safe 
)

◆ disconnect() [1/2]

int ARDOUR::PortEngineSharedImpl::disconnect ( const std::string &  src,
const std::string &  dst 
)

◆ disconnect() [2/2]

int ARDOUR::PortEngineSharedImpl::disconnect ( PortEngine::PortHandle  ,
const std::string &   
)

◆ disconnect_all()

int ARDOUR::PortEngineSharedImpl::disconnect_all ( PortEngine::PortHandle  )

◆ find_port()

BackendPortPtr ARDOUR::PortEngineSharedImpl::find_port ( const std::string &  port_name) const
inlineprotected

Definition at line 237 of file port_engine_shared.h.

◆ get_connections()

int ARDOUR::PortEngineSharedImpl::get_connections ( PortEngine::PortHandle  ,
std::vector< std::string > &  ,
bool  process_callback_safe 
)

◆ get_physical_inputs()

void ARDOUR::PortEngineSharedImpl::get_physical_inputs ( DataType  type,
std::vector< std::string > &   
)

◆ get_physical_outputs()

void ARDOUR::PortEngineSharedImpl::get_physical_outputs ( DataType  type,
std::vector< std::string > &   
)

◆ get_port_by_name()

PortEngine::PortPtr ARDOUR::PortEngineSharedImpl::get_port_by_name ( const std::string &  ) const

◆ get_port_flags()

PortFlags ARDOUR::PortEngineSharedImpl::get_port_flags ( PortEngine::PortHandle  ) const

◆ get_port_name()

std::string ARDOUR::PortEngineSharedImpl::get_port_name ( PortEngine::PortHandle  ) const

◆ get_port_property()

int ARDOUR::PortEngineSharedImpl::get_port_property ( PortEngine::PortHandle  ,
const std::string &  key,
std::string &  value,
std::string &  type 
) const

◆ get_ports()

int ARDOUR::PortEngineSharedImpl::get_ports ( const std::string &  port_name_pattern,
DataType  type,
PortFlags  flags,
std::vector< std::string > &   
) const

◆ list_ports()

void ARDOUR::PortEngineSharedImpl::list_ports ( ) const
protected

◆ n_physical_inputs()

ChanCount ARDOUR::PortEngineSharedImpl::n_physical_inputs ( ) const

◆ n_physical_outputs()

ChanCount ARDOUR::PortEngineSharedImpl::n_physical_outputs ( ) const

◆ physically_connected()

bool ARDOUR::PortEngineSharedImpl::physically_connected ( PortEngine::PortHandle  ,
bool  process_callback_safe 
)

◆ port_connect_add_remove_callback()

void ARDOUR::PortEngineSharedImpl::port_connect_add_remove_callback ( )
inlineprotected

Definition at line 207 of file port_engine_shared.h.

◆ port_connect_callback()

void ARDOUR::PortEngineSharedImpl::port_connect_callback ( const std::string &  a,
const std::string &  b,
bool  conn 
)
inlineprotected

Definition at line 199 of file port_engine_shared.h.

◆ port_data_type()

DataType ARDOUR::PortEngineSharedImpl::port_data_type ( PortEngine::PortHandle  ) const

◆ port_factory()

virtual BackendPort* ARDOUR::PortEngineSharedImpl::port_factory ( std::string const &  name,
ARDOUR::DataType  dt,
ARDOUR::PortFlags  flags 
)
protectedpure virtual

◆ port_is_physical()

bool ARDOUR::PortEngineSharedImpl::port_is_physical ( PortEngine::PortHandle  ) const

◆ port_name_size()

uint32_t ARDOUR::PortEngineSharedImpl::port_name_size ( ) const

◆ process_connection_queue_locked()

void ARDOUR::PortEngineSharedImpl::process_connection_queue_locked ( PortManager mgr)
protected

◆ register_port()

PortEngine::PortPtr ARDOUR::PortEngineSharedImpl::register_port ( const std::string &  shortname,
ARDOUR::DataType  ,
ARDOUR::PortFlags   
)

◆ set_port_name()

int ARDOUR::PortEngineSharedImpl::set_port_name ( PortEngine::PortHandle  ,
const std::string &   
)

◆ set_port_property()

int ARDOUR::PortEngineSharedImpl::set_port_property ( PortEngine::PortHandle  ,
const std::string &  key,
const std::string &  value,
const std::string &  type 
)

◆ unregister_port()

virtual void ARDOUR::PortEngineSharedImpl::unregister_port ( PortEngine::PortHandle  )
virtual

◆ unregister_ports()

void ARDOUR::PortEngineSharedImpl::unregister_ports ( bool  system_only = false)
protected

◆ update_system_port_latencies()

virtual void ARDOUR::PortEngineSharedImpl::update_system_port_latencies ( )
protectedvirtual

Reimplemented in ARDOUR::AlsaAudioBackend.

◆ valid_port()

bool ARDOUR::PortEngineSharedImpl::valid_port ( BackendPortHandle  port) const
inlineprotected

Definition at line 232 of file port_engine_shared.h.

Friends And Related Function Documentation

◆ BackendPort

friend class BackendPort
friend

Definition at line 177 of file port_engine_shared.h.

Member Data Documentation

◆ _instance_name

std::string ARDOUR::PortEngineSharedImpl::_instance_name
protected

Definition at line 178 of file port_engine_shared.h.

◆ _port_callback_mutex

pthread_mutex_t ARDOUR::PortEngineSharedImpl::_port_callback_mutex
protected

Definition at line 195 of file port_engine_shared.h.

◆ _port_change_flag

std::atomic<int> ARDOUR::PortEngineSharedImpl::_port_change_flag
protected

Definition at line 197 of file port_engine_shared.h.

◆ _port_connection_queue

std::vector<PortConnectData *> ARDOUR::PortEngineSharedImpl::_port_connection_queue
protected

Definition at line 194 of file port_engine_shared.h.

◆ _portmap

SerializedRCUManager<PortMap> ARDOUR::PortEngineSharedImpl::_portmap
protected

Definition at line 228 of file port_engine_shared.h.

◆ _portregistry

SerializedRCUManager<PortRegistry> ARDOUR::PortEngineSharedImpl::_portregistry
protected

Definition at line 230 of file port_engine_shared.h.

◆ _ports

SerializedRCUManager<PortIndex> ARDOUR::PortEngineSharedImpl::_ports
protected

Definition at line 229 of file port_engine_shared.h.

◆ _system_inputs

std::vector<BackendPortPtr> ARDOUR::PortEngineSharedImpl::_system_inputs
protected

Definition at line 180 of file port_engine_shared.h.

◆ _system_midi_in

std::vector<BackendPortPtr> ARDOUR::PortEngineSharedImpl::_system_midi_in
protected

Definition at line 182 of file port_engine_shared.h.

◆ _system_midi_out

std::vector<BackendPortPtr> ARDOUR::PortEngineSharedImpl::_system_midi_out
protected

Definition at line 183 of file port_engine_shared.h.

◆ _system_outputs

std::vector<BackendPortPtr> ARDOUR::PortEngineSharedImpl::_system_outputs
protected

Definition at line 181 of file port_engine_shared.h.


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