Holds the state of a process call.
More...
#include <tracktion_TracktionEngineNode.h>
Holds the state of a process call.
◆ UpdateContinuityFlags
An enum to indicate if the PlayHeadState continuity should be updated.
◆ ProcessState() [1/3]
| engine::ProcessState::ProcessState |
( |
tracktion::graph::PlayHeadState & |
| ) |
|
◆ ProcessState() [2/3]
| engine::ProcessState::ProcessState |
( |
tracktion::graph::PlayHeadState & |
, |
|
|
const TempoSequence & |
|
|
) |
| |
Creates a ProcessState that will update the editBeatRange field.
◆ ProcessState() [3/3]
| engine::ProcessState::ProcessState |
( |
tracktion::graph::PlayHeadState & |
, |
|
|
const tempo::Sequence & |
|
|
) |
| |
Creates a ProcessState that will update the editBeatRange field.
◆ update()
| void engine::ProcessState::update |
( |
double |
sampleRate, |
|
|
juce::Range< int64_t > |
referenceSampleRange, |
|
|
UpdateContinuityFlags |
|
|
) |
| |
Updates the internal state based on a reference sample range.
- Parameters
-
| UpdateContinuityFlags | If yes, the PlayHeadState will be updated, if no it won't be. If you are calling update more than once in a block, for example to update the reference sample range for timeline position, updating the continuity flags more than once will render it useless as it tracks changes from one call to the next. This flag lets you ensure it is only called once per block. |
◆ setPlaybackSpeedRatio()
| void engine::ProcessState::setPlaybackSpeedRatio |
( |
double |
newRatio | ) |
|
Sets a playback speed ratio.
Some Nodes might use this to adjust their playback speeds.
◆ setTempoSequence()
| void engine::ProcessState::setTempoSequence |
( |
const tempo::Sequence * |
| ) |
|
◆ getTempoSequence()
| const tempo::Sequence * engine::ProcessState::getTempoSequence |
( |
| ) |
const |
Returns the tempo::Sequence this state has been initialised with one.
◆ getTempoSequencePosition()
| const tempo::Sequence::Position * engine::ProcessState::getTempoSequencePosition |
( |
| ) |
const |
Returns the tempo::Sequence::Position this state uses.
◆ getSyncRange()
| SyncRange engine::ProcessState::getSyncRange |
( |
| ) |
const |
Returns the SyncRange for the current audio block.
Technically, this is only valid during processing but the end of the range can be used to schedule future events assuming the tempo doesn't change between now and the sceduled time.
If the tempo does change, the time will be incorrect but the MonotonicBeat will still be in sync.
◆ getSyncPoint()
| SyncPoint engine::ProcessState::getSyncPoint |
( |
| ) |
const |
◆ setSyncRange()
| void engine::ProcessState::setSyncRange |
( |
SyncRange |
| ) |
|
◆ onContinuityUpdated
| std::function<void()> engine::ProcessState::onContinuityUpdated |
Callback which can be set to be called when the continuity changes.
This will be made on the audio thread so shouldn't block.
◆ playHeadState
| tracktion::graph::PlayHeadState& engine::ProcessState::playHeadState |
◆ sampleRate
| double engine::ProcessState::sampleRate = 44100.0 |
◆ playbackSpeedRatio
| double engine::ProcessState::playbackSpeedRatio = 1.0 |
◆ numSamples
| int engine::ProcessState::numSamples = 0 |
◆ referenceSampleRange
| juce::Range<int64_t> engine::ProcessState::referenceSampleRange |
◆ timelineSampleRange
| juce::Range<int64_t> engine::ProcessState::timelineSampleRange |
◆ editTimeRange
| TimeRange engine::ProcessState::editTimeRange |
◆ editBeatRange
| BeatRange engine::ProcessState::editBeatRange |
The documentation for this struct was generated from the following file: