Navigation
API > API/Plugins > API/Plugins/MetasoundGraphCore
References
| Module | MetasoundGraphCore |
| Header | /Engine/Plugins/Runtime/Metasound/Source/MetasoundGraphCore/Public/MetasoundOperatorSettings.h |
| Include | #include "MetasoundOperatorSettings.h" |
Syntax
class FOperatorSettings
Remarks
Audio settings for Metasound IOperators including audio sample rate, block rate and frames per block.
The audio SampleRate defines the number of audio samples per a second of a mono waveform.
The BlockRate defines the number of times an IOperator's execution function will be triggered per a second of audio content.
The NumFramesPerBlock defines the number of audio frames written-to and/or read-from during a single call to an IOperator's execution function.
GetNumFramesPerBlock() is required to return a value that abides by the alignment requirements of FAudioBuffer, FAlignedFloatBuffer and the math routines declared in BufferVectorOperations.h. This enables the vast majority of Metasound IOperators to take advantage of SIMD hardware accelerations.
In order to achieve SIMD alignment, desired block rates must be slightly adjusted to match the boundaries of the given sample rate and SIMD alignment. GetActualBlockRate() returns the true block rate after adhering to sample rate and SIMD boundaries.
Constructors
| Type | Name | Description | |
|---|---|---|---|
FOperatorSettings
(
FSampleRate InSampleRate, |
FOperatorSettings constructor. |
Functions
| Type | Name | Description | |
|---|---|---|---|
| float | Get the actual block rate in Hz after adhering to sample rate and SIMD alignment. | ||
| int32 | Get the number of audio frames in a block. | ||
| float | Get the audio sample rate in Hz. | ||
| float | Get the target block rate in Hz. | ||
| void | SetSampleRate
(
FSampleRate InSampleRate |
Set the audio sample rate in Hz. | |
| void | SetTargetBlockRate
(
float InTargetBlockRate |
Set the target block rate in Hz. |