TracktionEngine
Loading...
Searching...
No Matches
engine::RackType Class Reference

#include <tracktion_RackType.h>

Inheritance diagram for engine::RackType:

Classes

struct  WindowState

Public Types

using Ptr = juce::ReferenceCountedObjectPtr<RackType>
Public Types inherited from engine::Selectable
using WeakRef = juce::WeakReference<Selectable>

Public Member Functions

 RackType (Edit &, const juce::ValueTree &)
 ~RackType () override
juce::ValueTree createStateCopy (bool includeAutomation)
juce::Result restoreStateFromValueTree (const juce::ValueTree &)
void registerInstance (RackInstance *, const PluginInitialisationInfo &)
void initialisePluginsIfNeeded (const PluginInitialisationInfo &) const
void deregisterInstance (RackInstance *)
void updateAutomatableParamPositions (TimePosition)
double getLatencySeconds (double sampleRate, int blockSize)
juce::Array< Plugin * > getPlugins () const
bool addPlugin (const Plugin::Ptr &, juce::Point< float > pos, bool canAutoConnect)
 Adds a plugin to the Rack optionally connecting it to the input and outputs.
Plugin * getPluginForID (EditItemID)
juce::Point< float > getPluginPosition (const Plugin::Ptr &) const
juce::Point< float > getPluginPosition (int index) const
void setPluginPosition (int index, juce::Point< float > pos)
void flushStateToValueTree ()
juce::Array< const RackConnection * > getConnections () const noexcept
bool addConnection (EditItemID source, int sourcePin, EditItemID dest, int destPin)
bool removeConnection (EditItemID source, int sourcePin, EditItemID dest, int destPin)
bool isConnectionLegal (EditItemID source, int sourcePin, EditItemID dest, int destPin) const
juce::Array< EditItemID > getPluginsWhichTakeInputFrom (EditItemID) const
void checkConnections ()
void createInstanceForSideChain (Track &, const juce::BigInteger &channelMask, EditItemID pluginID, int pinIndex)
juce::String getName () const override
juce::StringArray getInputNames () const
juce::StringArray getOutputNames () const
int addInput (int index, const juce::String &name)
int addOutput (int index, const juce::String &name)
void removeInput (int index)
void removeOutput (int index)
void renameInput (int index, const juce::String &name)
void renameOutput (int index, const juce::String &name)
bool pasteClipboard ()
ModifierList & getModifierList () const noexcept
juce::UndoManager * getUndoManager () const
juce::String getSelectableDescription () override
 Subclasses must return a description of what they are.
juce::StringArray getAudioInputNamesWithChannels () const
juce::StringArray getAudioOutputNamesWithChannels () const
juce::Array< WindowState * > getWindowStates () const
void loadWindowPosition ()
void saveWindowPosition ()
void hideWindowForShutdown ()
Public Member Functions inherited from engine::EditItem
 EditItem (EditItemID, Edit &)
 EditItem (Edit &, const juce::ValueTree &)
virtual ~EditItem ()=default
Public Member Functions inherited from engine::Selectable
 Selectable ()
virtual ~Selectable ()
virtual void selectionStatusChanged (bool isNowSelected)
 Can be overridden to tell this object that it has just been selected or deselected.
virtual void changed ()
 This should be called to send a change notification to any SelectableListeners that are registered with this object.
virtual void selectableAboutToBeDeleted ()
 Called just before the selectable is about to be deleted so any subclasses should still be valid at this point.
void addListener (SelectableListener *)
void removeListener (SelectableListener *)
void addSelectableListener (SelectableListener *)
void removeSelectableListener (SelectableListener *)
void cancelAnyPendingUpdates ()
 If changed() has been called, this will cancel any pending async change notificaions.
void deselect ()
void propertiesChanged ()
void notifyListenersOfDeletion ()
WeakRef getWeakRef ()
Public Member Functions inherited from engine::MacroParameterElement
 MacroParameterElement (Edit &, const juce::ValueTree &)
 Constructor.
virtual ~MacroParameterElement ()=default
 Destructor.
MacroParameterList * getMacroParameterList ()
 If no parameters have been created, this may return nullptr.
MacroParameterList & getMacroParameterListForWriting ()
 This ensures that the list has been created.
juce::ReferenceCountedArray< MacroParameter > getMacroParameters () const

Static Public Member Functions

static Ptr createTypeToWrapPlugins (const Plugin::Array &, Edit &)
static bool isPluginAllowed (const Plugin::Ptr &)
static void removeBrokenConnections (juce::ValueTree &, juce::UndoManager *)
static RackType::Ptr findRackTypeContaining (const Plugin &)
static const char * getRackPresetPrefix () noexcept
Static Public Member Functions inherited from engine::Selectable
static void initialise ()
static bool isSelectableValid (const Selectable *) noexcept
 checks whether this object has been deleted.

Public Attributes

juce::ValueTree state
juce::CachedValue< juce::String > rackName
Public Attributes inherited from engine::EditItem
Edit & edit
const EditItemID itemID
 Every EditItem has an ID which is unique within the edit.
Public Attributes inherited from engine::Selectable
WeakRef::Master masterReference
Public Attributes inherited from engine::MacroParameterElement
Edit & ownerEdit
juce::ValueTree parentStateForList

Member Typedef Documentation

◆ Ptr

using engine::RackType::Ptr = juce::ReferenceCountedObjectPtr<RackType>

Constructor & Destructor Documentation

◆ RackType()

engine::RackType::RackType ( Edit & ,
const juce::ValueTree &  )

◆ ~RackType()

engine::RackType::~RackType ( )
override

Member Function Documentation

◆ createStateCopy()

juce::ValueTree engine::RackType::createStateCopy ( bool includeAutomation)

◆ restoreStateFromValueTree()

juce::Result engine::RackType::restoreStateFromValueTree ( const juce::ValueTree & )

◆ createTypeToWrapPlugins()

Ptr engine::RackType::createTypeToWrapPlugins ( const Plugin::Array & ,
Edit &  )
static

◆ registerInstance()

void engine::RackType::registerInstance ( RackInstance * ,
const PluginInitialisationInfo &  )

◆ initialisePluginsIfNeeded()

void engine::RackType::initialisePluginsIfNeeded ( const PluginInitialisationInfo & ) const

◆ deregisterInstance()

void engine::RackType::deregisterInstance ( RackInstance * )

◆ updateAutomatableParamPositions()

void engine::RackType::updateAutomatableParamPositions ( TimePosition )

◆ getLatencySeconds()

double engine::RackType::getLatencySeconds ( double sampleRate,
int blockSize )

◆ getPlugins()

juce::Array< Plugin * > engine::RackType::getPlugins ( ) const

◆ isPluginAllowed()

bool engine::RackType::isPluginAllowed ( const Plugin::Ptr & )
static

◆ addPlugin()

bool engine::RackType::addPlugin ( const Plugin::Ptr & ,
juce::Point< float > pos,
bool canAutoConnect )

Adds a plugin to the Rack optionally connecting it to the input and outputs.

Returns
true if the plugin was added, false otherwise

◆ getPluginForID()

Plugin * engine::RackType::getPluginForID ( EditItemID )

◆ getPluginPosition() [1/2]

juce::Point< float > engine::RackType::getPluginPosition ( const Plugin::Ptr & ) const

◆ getPluginPosition() [2/2]

juce::Point< float > engine::RackType::getPluginPosition ( int index) const

◆ setPluginPosition()

void engine::RackType::setPluginPosition ( int index,
juce::Point< float > pos )

◆ flushStateToValueTree()

void engine::RackType::flushStateToValueTree ( )

◆ getConnections()

juce::Array< const RackConnection * > engine::RackType::getConnections ( ) const
noexcept

◆ addConnection()

bool engine::RackType::addConnection ( EditItemID source,
int sourcePin,
EditItemID dest,
int destPin )

References addConnection().

Referenced by addConnection().

◆ removeConnection()

bool engine::RackType::removeConnection ( EditItemID source,
int sourcePin,
EditItemID dest,
int destPin )

References removeConnection().

Referenced by removeConnection().

◆ isConnectionLegal()

bool engine::RackType::isConnectionLegal ( EditItemID source,
int sourcePin,
EditItemID dest,
int destPin ) const

References isConnectionLegal().

Referenced by isConnectionLegal().

◆ getPluginsWhichTakeInputFrom()

juce::Array< EditItemID > engine::RackType::getPluginsWhichTakeInputFrom ( EditItemID ) const

◆ checkConnections()

void engine::RackType::checkConnections ( )

References checkConnections().

Referenced by checkConnections().

◆ removeBrokenConnections()

void engine::RackType::removeBrokenConnections ( juce::ValueTree & ,
juce::UndoManager *  )
static

◆ createInstanceForSideChain()

void engine::RackType::createInstanceForSideChain ( Track & ,
const juce::BigInteger & channelMask,
EditItemID pluginID,
int pinIndex )

◆ getName()

juce::String engine::RackType::getName ( ) const
overridevirtual

Implements engine::EditItem.

References getName(), and rackName.

Referenced by getName().

◆ getInputNames()

juce::StringArray engine::RackType::getInputNames ( ) const

◆ getOutputNames()

juce::StringArray engine::RackType::getOutputNames ( ) const

◆ addInput()

int engine::RackType::addInput ( int index,
const juce::String & name )

◆ addOutput()

int engine::RackType::addOutput ( int index,
const juce::String & name )

◆ removeInput()

void engine::RackType::removeInput ( int index)

◆ removeOutput()

void engine::RackType::removeOutput ( int index)

◆ renameInput()

void engine::RackType::renameInput ( int index,
const juce::String & name )

◆ renameOutput()

void engine::RackType::renameOutput ( int index,
const juce::String & name )

◆ pasteClipboard()

bool engine::RackType::pasteClipboard ( )

◆ getModifierList()

ModifierList & engine::RackType::getModifierList ( ) const
noexcept

◆ getUndoManager()

juce::UndoManager * engine::RackType::getUndoManager ( ) const

References getUndoManager().

Referenced by getUndoManager().

◆ getSelectableDescription()

juce::String engine::RackType::getSelectableDescription ( )
overridevirtual

Subclasses must return a description of what they are.

Implements engine::Selectable.

References getSelectableDescription().

Referenced by getSelectableDescription().

◆ getAudioInputNamesWithChannels()

juce::StringArray engine::RackType::getAudioInputNamesWithChannels ( ) const

◆ getAudioOutputNamesWithChannels()

juce::StringArray engine::RackType::getAudioOutputNamesWithChannels ( ) const

◆ findRackTypeContaining()

RackType::Ptr engine::RackType::findRackTypeContaining ( const Plugin & )
static

◆ getRackPresetPrefix()

const char * engine::RackType::getRackPresetPrefix ( )
staticnoexcept

References getRackPresetPrefix().

Referenced by getRackPresetPrefix().

◆ getWindowStates()

juce::Array< WindowState * > engine::RackType::getWindowStates ( ) const

◆ loadWindowPosition()

void engine::RackType::loadWindowPosition ( )

◆ saveWindowPosition()

void engine::RackType::saveWindowPosition ( )

◆ hideWindowForShutdown()

void engine::RackType::hideWindowForShutdown ( )

Member Data Documentation

◆ state

juce::ValueTree engine::RackType::state

◆ rackName

juce::CachedValue<juce::String> engine::RackType::rackName

Referenced by getName().


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