tracktion-engine
3.0-10-g034fdde4aa5
Tracktion Engine — High level data model for audio applications
« « « Anklang Documentation
Loading...
Searching...
No Matches
tracktion_engine
playback
graph
tracktion_LiveMidiOutputNode.h
Go to the documentation of this file.
1
/*
2
,--. ,--. ,--. ,--.
3
,-' '-.,--.--.,--,--.,---.| |,-.,-' '-.`--' ,---. ,--,--, Copyright 2024
4
'-. .-'| .--' ,-. | .--'| /'-. .-',--.| .-. || \ Tracktion Software
5
| | | | \ '-' \ `--.| \ \ | | | |' '-' '| || | Corporation
6
`---' `--' `--`--'`---'`--'`--' `---' `--' `---' `--''--' www.tracktion.com
7
8
Tracktion Engine uses a GPL/commercial licence - see LICENCE.md for details.
9
*/
10
11
namespace
tracktion
{
inline
namespace
engine
12
{
13
14
//==============================================================================
15
//==============================================================================
19
class
LiveMidiOutputNode
final :
public
tracktion::graph::Node
,
20
private
juce::AsyncUpdater
21
{
22
public
:
23
LiveMidiOutputNode
(
AudioTrack
&,
std::unique_ptr<tracktion::graph::Node>
);
24
LiveMidiOutputNode
(
Clip
&,
std::unique_ptr<tracktion::graph::Node>
);
25
26
//==============================================================================
27
tracktion::graph::NodeProperties
getNodeProperties
()
override
;
28
std::vector<Node*>
getDirectInputNodes
()
override
;
29
void
prepareToPlay
(
const
tracktion::graph::PlaybackInitialisationInfo
&)
override
;
30
bool
isReadyToProcess
()
override
;
31
void
process
(
ProcessContext
&)
override
;
32
33
private
:
34
//==============================================================================
35
AudioTrack
* track =
nullptr
;
36
Track::Ptr
trackPtr;
37
38
Clip::Ptr
clipPtr;
39
40
std::unique_ptr<tracktion::graph::Node>
input;
41
42
RealTimeSpinLock
mutex;
43
MidiMessageArray
pendingMessages, dispatchingMessages;
44
45
//==============================================================================
46
void
handleAsyncUpdate()
override
;
47
};
48
49
}}
// namespace tracktion { inline namespace engine
juce::AsyncUpdater
juce::ReferenceCountedObjectPtr< Track >
tracktion::engine::AudioTrack
Definition
tracktion_AudioTrack.h:18
tracktion::engine::Clip
A clip in an edit.
Definition
tracktion_Clip.h:70
tracktion::engine::LiveMidiOutputNode
A Node that calls the listeners of an AudioTrack with any incomming MIDI.
Definition
tracktion_LiveMidiOutputNode.h:21
tracktion::engine::LiveMidiOutputNode::getDirectInputNodes
std::vector< Node * > getDirectInputNodes() override
Should return all the inputs directly feeding in to this node.
Definition
tracktion_LiveMidiOutputNode.cpp:49
tracktion::engine::LiveMidiOutputNode::isReadyToProcess
bool isReadyToProcess() override
Should return true when this node is ready to be processed.
Definition
tracktion_LiveMidiOutputNode.cpp:58
tracktion::engine::LiveMidiOutputNode::process
void process(ProcessContext &) override
Called when the node is to be processed.
Definition
tracktion_LiveMidiOutputNode.cpp:63
tracktion::engine::LiveMidiOutputNode::getNodeProperties
tracktion::graph::NodeProperties getNodeProperties() override
Should return the properties of the node.
Definition
tracktion_LiveMidiOutputNode.cpp:41
tracktion::engine::LiveMidiOutputNode::prepareToPlay
void prepareToPlay(const tracktion::graph::PlaybackInitialisationInfo &) override
Called once before playback begins for each node.
Definition
tracktion_LiveMidiOutputNode.cpp:54
tracktion::graph::Node
Main graph Node processor class.
Definition
tracktion_Node.h:217
tracktion::graph::Node::ProcessContext
Struct to describe a single iteration of a process call.
Definition
tracktion_Node.h:303
tracktion::graph::RealTimeSpinLock
A basic spin lock that uses an atomic_flag to store the locked state so should never result in a syst...
Definition
tracktion_RealTimeSpinLock.h:24
tracktion
Definition
tracktion_AudioReader.h:23
tracktion::engine::MidiMessageArray
Definition
tracktion_MidiMessageArray.h:17
tracktion::graph::NodeProperties
Holds some really basic properties of a node.
Definition
tracktion_Node.h:152
tracktion::graph::PlaybackInitialisationInfo
Passed into Nodes when they are being initialised, to give them useful contextual information that th...
Definition
tracktion_Node.h:140
std::unique_ptr
std::vector
« « « Anklang Documentation