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

#include <ladspa_plugin.h>

Inheritance diagram for ARDOUR::LadspaPlugin:
[legend]

Public Member Functions

 LadspaPlugin (std::string module_path, ARDOUR::AudioEngine &, ARDOUR::Session &, uint32_t index, samplecnt_t sample_rate)
 
 LadspaPlugin (const LadspaPlugin &)
 
 ~LadspaPlugin ()
 
std::string unique_id () const
 
const char * label () const
 
const char * name () const
 
const char * maker () const
 
uint32_t parameter_count () const
 
float default_value (uint32_t port)
 
void set_parameter (uint32_t port, float val, sampleoffset_t)
 
float get_parameter (uint32_t port) const
 
int get_parameter_descriptor (uint32_t which, ParameterDescriptor &) const
 
uint32_t nth_parameter (uint32_t port, bool &ok) const
 
std::set< Evoral::Parameterautomatable () const
 
void activate ()
 
void deactivate ()
 
void cleanup ()
 
int set_block_size (pframes_t)
 
int connect_and_run (BufferSet &bufs, samplepos_t start, samplepos_t end, double speed, ChanMapping const &in, ChanMapping const &out, pframes_t nframes, samplecnt_t offset)
 
std::string describe_parameter (Evoral::Parameter)
 
std::string state_node_name () const
 
bool parameter_is_audio (uint32_t) const
 
bool parameter_is_control (uint32_t) const
 
bool parameter_is_input (uint32_t) const
 
bool parameter_is_output (uint32_t) const
 
bool parameter_is_toggled (uint32_t) const
 
std::shared_ptr< ScalePointsget_scale_points (uint32_t port_index) const
 
int set_state (const XMLNode &, int version)
 
bool load_preset (PresetRecord)
 
bool has_editor () const
 
LADSPA_Properties properties () const
 
uint32_t index () const
 
const char * copyright () const
 
LADSPA_PortDescriptor port_descriptor (uint32_t i) const
 
const LADSPA_PortRangeHintport_range_hints () const
 
const char *const * port_names () const
 
void set_gain (float gain)
 
void run_adding (uint32_t nsamples)
 
void connect_port (uint32_t port, float *ptr)
 
- Public Member Functions inherited from ARDOUR::Plugin
 Plugin (ARDOUR::AudioEngine &, ARDOUR::Session &)
 
 Plugin (const Plugin &)
 
virtual ~Plugin ()
 
XMLNodeget_state () const
 
virtual void set_insert_id (PBD::ID id)
 
virtual void set_state_dir (const std::string &d="")
 
void set_insert (PlugInsertBase *pib, uint32_t num)
 
PlugInsertBaseplugin_insert () const
 
uint32_t plugin_number () const
 
virtual std::string get_docs () const
 
virtual std::string get_parameter_docs (uint32_t) const
 
virtual std::string parameter_label (uint32_t which) const
 
virtual void flush ()
 
virtual bool print_parameter (uint32_t, std::string &) const
 
virtual uint32_t designated_bypass_port ()
 
virtual IOPortDescription describe_io_port (DataType dt, bool input, uint32_t id) const
 
virtual PluginOutputConfiguration possible_output () const
 
virtual void set_automation_control (uint32_t, std::shared_ptr< ARDOUR::AutomationControl >)
 
samplecnt_t signal_latency () const
 
samplecnt_t signal_tailtime () const
 
virtual samplecnt_t max_latency () const
 
virtual bool requires_fixed_sized_buffers () const
 
virtual bool inplace_broken () const
 
virtual bool connect_all_audio_outputs () const
 
bool write_immediate_event (Evoral::EventType event_type, size_t size, const uint8_t *buf)
 
void realtime_handle_transport_stopped ()
 
void realtime_locate (bool)
 
void monitoring_changed ()
 
virtual void set_non_realtime (bool)
 
virtual void add_slave (std::shared_ptr< Plugin >, bool realtime)
 
virtual void remove_slave (std::shared_ptr< Plugin >)
 
virtual bool has_inline_display ()
 
virtual bool inline_display_in_gui ()
 
virtual Display_Image_Surfacerender_inline_display (uint32_t, uint32_t)
 
virtual bool has_midnam ()
 
virtual bool read_midnam ()
 
virtual std::string midnam_model ()
 
virtual bool knows_bank_patch ()
 
virtual uint32_t bank_patch (uint8_t chn)
 
PresetRecord save_preset (std::string name)
 
void remove_preset (std::string)
 
void clear_preset ()
 
const PresetRecordpreset_by_label (const std::string &)
 
const PresetRecordpreset_by_uri (const std::string &)
 
virtual std::vector< PresetRecordget_presets ()
 
PresetRecord last_preset () const
 
bool parameter_changed_since_last_preset () const
 
virtual int first_user_preset_index () const
 
virtual bool reconfigure_io (ChanCount, ChanCount, ChanCount)
 
virtual bool match_variable_io (ChanCount &, ChanCount &, ChanCount &)
 
virtual ChanCount output_streams () const
 
virtual ChanCount input_streams () const
 
virtual void set_info (const PluginInfoPtr info)
 
PluginInfoPtr get_info () const
 
virtual void set_owner (SessionObject *o)
 
SessionObjectowner () const
 
void set_cycles (uint32_t c)
 
cycles_t cycles () const
 
void use_for_impulse_analysis ()
 
ARDOUR::AudioEngineengine () const
 
ARDOUR::Sessionsession () const
 
virtual const PropertyDescriptorsget_supported_properties () const
 
virtual const ParameterDescriptorget_property_descriptor (uint32_t id) const
 
virtual void set_property (uint32_t key, const Variant &value)
 
virtual Variant get_property_value (uint32_t) const
 
virtual void announce_property_values ()
 
- 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 ARDOUR::HasLatency
virtual ~HasLatency ()
 
- Public Member Functions inherited from ARDOUR::HasTailTime
virtual ~HasTailTime ()
 

Private Member Functions

float _default_value (uint32_t port) const
 
samplecnt_t plugin_latency () const
 
void find_presets ()
 
void init (std::string module_path, uint32_t index, samplecnt_t rate)
 
void run_in_place (pframes_t nsamples)
 
void latency_compute_run ()
 
int set_state_2X (const XMLNode &, int version)
 
std::string do_save_preset (std::string name)
 
void do_remove_preset (std::string name)
 
std::string preset_source () const
 
bool write_preset_file ()
 
void add_state (XMLNode *) const
 

Private Attributes

std::string _module_path
 
Glib::Module * _module
 
const LADSPA_Descriptor_descriptor
 
LADSPA_Handle _handle
 
samplecnt_t _sample_rate
 
LADSPA_Data_control_data
 
LADSPA_Data_shadow_data
 
LADSPA_Data_latency_control_port
 
uint32_t _index
 
bool _was_activated
 

Additional Inherited Members

- Public Types inherited from ARDOUR::Plugin
typedef std::map< uint32_t, ParameterDescriptorPropertyDescriptors
 
- Public Attributes inherited from ARDOUR::Plugin
PBD::Signal< void()> QueueDraw
 
PBD::Signal< void()> UpdateMidnam
 
PBD::Signal< void()> UpdatedMidnam
 
PBD::Signal< void(uint8_t)> BankPatchChange
 
PBD::Signal< void()> PresetAdded
 
PBD::Signal< void()> PresetRemoved
 
PBD::Signal< void()> PresetLoaded
 
PBD::Signal< void()> PresetDirty
 
PBD::Signal< void(uint32_t, float)> PresetPortSetValue
 
PBD::Signal< void(uint32_t, float)> ParameterChangedExternally
 
PBD::Signal< void(uint32_t, Variant)> PropertyChanged
 
PBD::Signal< void(uint32_t)> StartTouch
 
PBD::Signal< void(uint32_t)> EndTouch
 
- 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
 
- Static Public Attributes inherited from ARDOUR::Plugin
static PBD::Signal< void(std::string, Plugin *, bool)> PresetsChanged
 
- Static Public Attributes inherited from PBD::Stateful
static int current_state_version
 
static int loading_state_version
 
- Protected Member Functions inherited from ARDOUR::Plugin
virtual void parameter_changed_externally (uint32_t which, float val)
 
void state_changed ()
 
- 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 Attributes inherited from ARDOUR::Plugin
ARDOUR::AudioEngine_engine
 
ARDOUR::Session_session
 
PluginInfoPtr _info
 
uint32_t _cycles
 
SessionObject_owner
 
bool _for_impulse_analysis
 
std::map< std::string, PresetRecord_presets
 
- 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

Definition at line 40 of file ladspa_plugin.h.

Constructor & Destructor Documentation

◆ LadspaPlugin() [1/2]

ARDOUR::LadspaPlugin::LadspaPlugin ( std::string  module_path,
ARDOUR::AudioEngine ,
ARDOUR::Session ,
uint32_t  index,
samplecnt_t  sample_rate 
)

◆ LadspaPlugin() [2/2]

ARDOUR::LadspaPlugin::LadspaPlugin ( const LadspaPlugin )

◆ ~LadspaPlugin()

ARDOUR::LadspaPlugin::~LadspaPlugin ( )

Member Function Documentation

◆ _default_value()

float ARDOUR::LadspaPlugin::_default_value ( uint32_t  port) const
private

◆ activate()

void ARDOUR::LadspaPlugin::activate ( )
inlinevirtual

Implements ARDOUR::Plugin.

Definition at line 62 of file ladspa_plugin.h.

◆ add_state()

void ARDOUR::LadspaPlugin::add_state ( XMLNode ) const
privatevirtual

Add state to an existing XMLNode

Implements ARDOUR::Plugin.

◆ automatable()

std::set<Evoral::Parameter> ARDOUR::LadspaPlugin::automatable ( ) const
virtual

Implements ARDOUR::Plugin.

◆ cleanup()

void ARDOUR::LadspaPlugin::cleanup ( )
inline

Definition at line 76 of file ladspa_plugin.h.

◆ connect_and_run()

int ARDOUR::LadspaPlugin::connect_and_run ( BufferSet bufs,
samplepos_t  start,
samplepos_t  end,
double  speed,
ChanMapping const &  in,
ChanMapping const &  out,
pframes_t  nframes,
samplecnt_t  offset 
)
virtual

Reimplemented from ARDOUR::Plugin.

◆ connect_port()

void ARDOUR::LadspaPlugin::connect_port ( uint32_t  port,
float *  ptr 
)
inline

Definition at line 120 of file ladspa_plugin.h.

◆ copyright()

const char* ARDOUR::LadspaPlugin::copyright ( ) const
inline

Definition at line 113 of file ladspa_plugin.h.

◆ deactivate()

void ARDOUR::LadspaPlugin::deactivate ( )
inlinevirtual

Implements ARDOUR::Plugin.

Definition at line 69 of file ladspa_plugin.h.

◆ default_value()

float ARDOUR::LadspaPlugin::default_value ( uint32_t  port)
inlinevirtual

Implements ARDOUR::Plugin.

Definition at line 54 of file ladspa_plugin.h.

◆ describe_parameter()

std::string ARDOUR::LadspaPlugin::describe_parameter ( Evoral::Parameter  )
virtual

Implements ARDOUR::Plugin.

◆ do_remove_preset()

void ARDOUR::LadspaPlugin::do_remove_preset ( std::string  )
privatevirtual

Do the actual removal of a preset of the provided name

Implements ARDOUR::Plugin.

◆ do_save_preset()

std::string ARDOUR::LadspaPlugin::do_save_preset ( std::string  )
privatevirtual

Do the actual saving of the current plugin settings to a preset of the provided name. Should return a URI on success, or an empty string on failure.

Implements ARDOUR::Plugin.

◆ find_presets()

void ARDOUR::LadspaPlugin::find_presets ( )
privatevirtual

Fill _presets with our presets

Implements ARDOUR::Plugin.

◆ get_parameter()

float ARDOUR::LadspaPlugin::get_parameter ( uint32_t  port) const
virtual

Implements ARDOUR::Plugin.

◆ get_parameter_descriptor()

int ARDOUR::LadspaPlugin::get_parameter_descriptor ( uint32_t  which,
ParameterDescriptor  
) const
virtual

Implements ARDOUR::Plugin.

◆ get_scale_points()

std::shared_ptr<ScalePoints> ARDOUR::LadspaPlugin::get_scale_points ( uint32_t  port_index) const
virtual

Reimplemented from ARDOUR::Plugin.

◆ has_editor()

bool ARDOUR::LadspaPlugin::has_editor ( ) const
inlinevirtual
Returns
true if plugin has a custom plugin GUI

Implements ARDOUR::Plugin.

Definition at line 107 of file ladspa_plugin.h.

◆ index()

uint32_t ARDOUR::LadspaPlugin::index ( ) const
inline

Definition at line 112 of file ladspa_plugin.h.

◆ init()

void ARDOUR::LadspaPlugin::init ( std::string  module_path,
uint32_t  index,
samplecnt_t  rate 
)
private

◆ label()

const char* ARDOUR::LadspaPlugin::label ( ) const
inlinevirtual

Implements ARDOUR::Plugin.

Definition at line 50 of file ladspa_plugin.h.

◆ latency_compute_run()

void ARDOUR::LadspaPlugin::latency_compute_run ( )
private

◆ load_preset()

bool ARDOUR::LadspaPlugin::load_preset ( PresetRecord  )
virtual

Set parameters using a preset

Reimplemented from ARDOUR::Plugin.

◆ maker()

const char* ARDOUR::LadspaPlugin::maker ( ) const
inlinevirtual

Implements ARDOUR::Plugin.

Definition at line 52 of file ladspa_plugin.h.

◆ name()

const char* ARDOUR::LadspaPlugin::name ( ) const
inlinevirtual

Implements ARDOUR::Plugin.

Definition at line 51 of file ladspa_plugin.h.

◆ nth_parameter()

uint32_t ARDOUR::LadspaPlugin::nth_parameter ( uint32_t  port,
bool &  ok 
) const
virtual

Implements ARDOUR::Plugin.

◆ parameter_count()

uint32_t ARDOUR::LadspaPlugin::parameter_count ( ) const
inlinevirtual

Implements ARDOUR::Plugin.

Definition at line 53 of file ladspa_plugin.h.

◆ parameter_is_audio()

bool ARDOUR::LadspaPlugin::parameter_is_audio ( uint32_t  ) const
virtual

Implements ARDOUR::Plugin.

◆ parameter_is_control()

bool ARDOUR::LadspaPlugin::parameter_is_control ( uint32_t  ) const
virtual

Implements ARDOUR::Plugin.

◆ parameter_is_input()

bool ARDOUR::LadspaPlugin::parameter_is_input ( uint32_t  ) const
virtual

Implements ARDOUR::Plugin.

◆ parameter_is_output()

bool ARDOUR::LadspaPlugin::parameter_is_output ( uint32_t  ) const
virtual

Implements ARDOUR::Plugin.

◆ parameter_is_toggled()

bool ARDOUR::LadspaPlugin::parameter_is_toggled ( uint32_t  ) const

◆ plugin_latency()

samplecnt_t ARDOUR::LadspaPlugin::plugin_latency ( ) const
privatevirtual

Implements ARDOUR::Plugin.

◆ port_descriptor()

LADSPA_PortDescriptor ARDOUR::LadspaPlugin::port_descriptor ( uint32_t  i) const

◆ port_names()

const char* const* ARDOUR::LadspaPlugin::port_names ( ) const
inline

Definition at line 116 of file ladspa_plugin.h.

◆ port_range_hints()

const LADSPA_PortRangeHint* ARDOUR::LadspaPlugin::port_range_hints ( ) const
inline

Definition at line 115 of file ladspa_plugin.h.

◆ preset_source()

std::string ARDOUR::LadspaPlugin::preset_source ( ) const
private

◆ properties()

LADSPA_Properties ARDOUR::LadspaPlugin::properties ( ) const
inline

Definition at line 111 of file ladspa_plugin.h.

◆ run_adding()

void ARDOUR::LadspaPlugin::run_adding ( uint32_t  nsamples)
inline

Definition at line 119 of file ladspa_plugin.h.

◆ run_in_place()

void ARDOUR::LadspaPlugin::run_in_place ( pframes_t  nsamples)
private

◆ set_block_size()

int ARDOUR::LadspaPlugin::set_block_size ( pframes_t  )
inlinevirtual

Implements ARDOUR::Plugin.

Definition at line 84 of file ladspa_plugin.h.

◆ set_gain()

void ARDOUR::LadspaPlugin::set_gain ( float  gain)
inline

Definition at line 118 of file ladspa_plugin.h.

◆ set_parameter()

void ARDOUR::LadspaPlugin::set_parameter ( uint32_t  port,
float  val,
sampleoffset_t   
)
virtual

Reimplemented from ARDOUR::Plugin.

◆ set_state()

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

Reimplemented from ARDOUR::Plugin.

◆ set_state_2X()

int ARDOUR::LadspaPlugin::set_state_2X ( const XMLNode ,
int  version 
)
private

◆ state_node_name()

std::string ARDOUR::LadspaPlugin::state_node_name ( ) const
inlinevirtual

Implements ARDOUR::Plugin.

Definition at line 92 of file ladspa_plugin.h.

◆ unique_id()

std::string ARDOUR::LadspaPlugin::unique_id ( ) const
virtual

Implements ARDOUR::Plugin.

◆ write_preset_file()

bool ARDOUR::LadspaPlugin::write_preset_file ( )
private

Member Data Documentation

◆ _control_data

LADSPA_Data* ARDOUR::LadspaPlugin::_control_data
private

Definition at line 129 of file ladspa_plugin.h.

◆ _descriptor

const LADSPA_Descriptor* ARDOUR::LadspaPlugin::_descriptor
private

Definition at line 126 of file ladspa_plugin.h.

◆ _handle

LADSPA_Handle ARDOUR::LadspaPlugin::_handle
private

Definition at line 127 of file ladspa_plugin.h.

◆ _index

uint32_t ARDOUR::LadspaPlugin::_index
private

Definition at line 132 of file ladspa_plugin.h.

◆ _latency_control_port

LADSPA_Data* ARDOUR::LadspaPlugin::_latency_control_port
private

Definition at line 131 of file ladspa_plugin.h.

◆ _module

Glib::Module* ARDOUR::LadspaPlugin::_module
private

Definition at line 125 of file ladspa_plugin.h.

◆ _module_path

std::string ARDOUR::LadspaPlugin::_module_path
private

Definition at line 124 of file ladspa_plugin.h.

◆ _sample_rate

samplecnt_t ARDOUR::LadspaPlugin::_sample_rate
private

Definition at line 128 of file ladspa_plugin.h.

◆ _shadow_data

LADSPA_Data* ARDOUR::LadspaPlugin::_shadow_data
private

Definition at line 130 of file ladspa_plugin.h.

◆ _was_activated

bool ARDOUR::LadspaPlugin::_was_activated
private

Definition at line 133 of file ladspa_plugin.h.


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