JUCE  v5.4.1-191-g0ab5e696f
JUCE API
Looking for a senior C++ dev?
I'm looking for work. Hire me!
juce::AudioProcessorGraph::Node Class Reference

Represents one of the nodes, or processors, in an AudioProcessorGraph. More...

#include <juce_AudioProcessorGraph.h>

Inheritance diagram for juce::AudioProcessorGraph::Node:
Collaboration diagram for juce::AudioProcessorGraph::Node:

Classes

struct  Connection
 

Public Types

using Ptr = ReferenceCountedObjectPtr< Node >
 A convenient typedef for referring to a pointer to a node object. More...
 

Public Member Functions

void decReferenceCount () noexcept
 Decreases the object's reference count. More...
 
bool decReferenceCountWithoutDeleting () noexcept
 Decreases the object's reference count. More...
 
AudioProcessorgetProcessor () const noexcept
 The actual processor object that this node represents. More...
 
int getReferenceCount () const noexcept
 Returns the object's current reference count. More...
 
void incReferenceCount () noexcept
 Increments the object's reference count. More...
 
bool isBypassed () const noexcept
 Returns if the node is bypassed or not. More...
 
void setBypassed (bool shouldBeBypassed) noexcept
 Tell this node to bypass processing. More...
 

Public Attributes

const NodeID nodeID
 The ID number assigned to this node. More...
 
NamedValueSet properties
 A set of user-definable properties that are associated with this node. More...
 

Protected Member Functions

void resetReferenceCount () noexcept
 Resets the reference count to zero without deleting the object. More...
 

Private Member Functions

 Node (NodeID, AudioProcessor *) noexcept
 
void prepare (double newSampleRate, int newBlockSize, AudioProcessorGraph *, ProcessingPrecision)
 
void setParentGraph (AudioProcessorGraph *) const
 
void unprepare ()
 

Private Attributes

bool bypassed = false
 
Array< Connectioninputs
 
bool isPrepared = false
 
Array< Connectionoutputs
 
const std::unique_ptr< AudioProcessorprocessor
 

Friends

class AudioProcessorGraph
 

Detailed Description

Represents one of the nodes, or processors, in an AudioProcessorGraph.

To create a node, call AudioProcessorGraph::addNode().

Member Typedef Documentation

◆ Ptr

A convenient typedef for referring to a pointer to a node object.

Constructor & Destructor Documentation

◆ Node()

juce::AudioProcessorGraph::Node::Node ( NodeID  ,
AudioProcessor  
)
privatenoexcept

Member Function Documentation

◆ decReferenceCount()

void juce::ReferenceCountedObject::decReferenceCount ( )
inlinenoexceptinherited

Decreases the object's reference count.

If the count gets to zero, the object will be deleted.

References jassert.

◆ decReferenceCountWithoutDeleting()

bool juce::ReferenceCountedObject::decReferenceCountWithoutDeleting ( )
inlinenoexceptinherited

Decreases the object's reference count.

If the count gets to zero, the object will not be deleted, but this method will return true, allowing the caller to take care of deletion.

References jassert.

◆ getProcessor()

AudioProcessor* juce::AudioProcessorGraph::Node::getProcessor ( ) const
inlinenoexcept

The actual processor object that this node represents.

◆ getReferenceCount()

int juce::ReferenceCountedObject::getReferenceCount ( ) const
inlinenoexceptinherited

Returns the object's current reference count.

◆ incReferenceCount()

void juce::ReferenceCountedObject::incReferenceCount ( )
inlinenoexceptinherited

Increments the object's reference count.

This is done automatically by the smart pointer, but is public just in case it's needed for nefarious purposes.

◆ isBypassed()

bool juce::AudioProcessorGraph::Node::isBypassed ( ) const
noexcept

Returns if the node is bypassed or not.

◆ prepare()

void juce::AudioProcessorGraph::Node::prepare ( double  newSampleRate,
int  newBlockSize,
AudioProcessorGraph ,
ProcessingPrecision   
)
private

◆ resetReferenceCount()

void juce::ReferenceCountedObject::resetReferenceCount ( )
inlineprotectednoexceptinherited

Resets the reference count to zero without deleting the object.

You should probably never need to use this!

◆ setBypassed()

void juce::AudioProcessorGraph::Node::setBypassed ( bool  shouldBeBypassed)
noexcept

Tell this node to bypass processing.

◆ setParentGraph()

void juce::AudioProcessorGraph::Node::setParentGraph ( AudioProcessorGraph ) const
private

◆ unprepare()

void juce::AudioProcessorGraph::Node::unprepare ( )
private

Friends And Related Function Documentation

◆ AudioProcessorGraph

friend class AudioProcessorGraph
friend

Member Data Documentation

◆ bypassed

bool juce::AudioProcessorGraph::Node::bypassed = false
private

◆ inputs

Array<Connection> juce::AudioProcessorGraph::Node::inputs
private

◆ isPrepared

bool juce::AudioProcessorGraph::Node::isPrepared = false
private

◆ nodeID

const NodeID juce::AudioProcessorGraph::Node::nodeID

The ID number assigned to this node.

This is assigned by the graph that owns it, and can't be changed.

◆ outputs

Array<Connection> juce::AudioProcessorGraph::Node::outputs
private

◆ processor

const std::unique_ptr<AudioProcessor> juce::AudioProcessorGraph::Node::processor
private

◆ properties

NamedValueSet juce::AudioProcessorGraph::Node::properties

A set of user-definable properties that are associated with this node.

This can be used to attach values to the node for whatever purpose seems useful. For example, you might store an x and y position if your application is displaying the nodes on-screen.


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