Navigation
API > API/Runtime > API/Runtime/AudioMixer
| Name | FMixerSubmix |
| Type | class |
| Header File | /Engine/Source/Runtime/AudioMixer/Public/AudioMixerSubmix.h |
| Include Path | #include "AudioMixerSubmix.h" |
Syntax
class FMixerSubmix
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
FMixerSubmix
(
FMixerDevice* InMixerDevice |
AudioMixerSubmix.h |
Destructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual ~FMixerSubmix() |
AudioMixerSubmix.h |
Structs
| Name | Remarks |
|---|---|
| FEndpointData | |
| FSoundfieldEffectProcessorData | Individual processor in our |
| FSoundfieldStreams | |
| FSpectralAnalysisBandInfo | |
| FSpectrumAnalysisDelegateInfo | |
| FSubmixBufferListenerInfo | |
| FSubmixEffectFadeInfo |
Variables
Protected
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| AudioBuses | TMap< Audio::FAudioBusKey, Audio::FPatchInput > | Registered audio buses. | AudioMixerSubmix.h | |
| AudioBusSendBuffer | FAlignedFloatBuffer | AudioMixerSubmix.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
void AddChildSubmix
(
TWeakPtr< FMixerSubmix, ESPMode::ThreadSafe > Submix |
Adds the given submix to this submix's children. | AudioMixerSubmix.h | |
void AddEnvelopeFollowerDelegate
(
const FOnSubmixEnvelopeBP& OnSubmixEnvelopeBP |
Adds an envelope follower delegate. | AudioMixerSubmix.h | |
void AddOrSetSourceVoice
(
FMixerSourceVoice* InSourceVoice, |
Add (if not already added) or sets the amount of the source voice's send amount. | AudioMixerSubmix.h | |
FPatchOutputStrongPtr AddPatch
(
float InGain |
AudioMixerSubmix.h | ||
void AddSoundEffectSubmix
(
FSoundEffectSubmixPtr InSoundEffectSubmix |
Appends the effect submix to the effect submix chain. | AudioMixerSubmix.h | |
void AddSpectralAnalysisDelegate
(
const FSoundSpectrumAnalyzerDelegateSettings& InDelegateSettings, |
Adds an spectral analysis delegate. | AudioMixerSubmix.h | |
void BroadcastDelegates() |
Broadcast the envelope and submix delegates on the game thread. | AudioMixerSubmix.h | |
void ClearSoundEffectSubmixes() |
Clears all submix effects from the effect submix chain. | AudioMixerSubmix.h | |
void ClearSubmixEffectChainOverride
(
float InFadeTimeSec |
Clears any submix effect chain overrides in the given fade time in seconds. | AudioMixerSubmix.h | |
const TMap< uint32, FChildSubmixInfo > & GetChildren() |
AudioMixerSubmix.h | ||
FSoundfieldSpeakerPositionalData GetDefaultPositionalDataForAudioDevice() |
AudioMixerSubmix.h | ||
uint32 GetId() |
Returns the mixer submix Id. | AudioMixerSubmix.h | |
FAudioPluginInitializationParams GetInitializationParamsForSoundfieldStream() |
AudioMixerSubmix.h | ||
FSoundfieldEncodingKey GetKeyForSubmixEncoding () |
Get a unique key for this submix's format and settings. | AudioMixerSubmix.h | |
void GetMagnitudeForFrequencies
(
const TArray< float >& InFrequencies, |
Gets the most recent magnitude values for each corresponding value in InFrequencies (in Hz). | AudioMixerSubmix.h | |
const FString & GetName() |
Return the owners name. | AudioMixerSubmix.h | |
int32 GetNumChainEffects() |
Returns the number of effects in this submix's effect chain. | AudioMixerSubmix.h | |
int32 GetNumEffects() |
Returns the number of wet effects in this submix. | AudioMixerSubmix.h | |
int32 GetNumOutputChannels() |
Returns the output channels this submix is rendering to. | AudioMixerSubmix.h | |
int32 GetNumSourceVoices() |
Returns the number of source voices currently a part of this submix. | AudioMixerSubmix.h | |
FModulationDestination * GetOutputVolumeDestination() |
AudioMixerSubmix.h | ||
TWeakPtr< FMixerSubmix, ESPMode::ThreadSafe > GetParent() |
AudioMixerSubmix.h | ||
TWeakPtr< FMixerSubmix, ESPMode::ThreadSafe > GetParentSubmix() |
Gets this submix's parent submix. | AudioMixerSubmix.h | |
void GetPhaseForFrequencies
(
const TArray< float >& InFrequencies, |
Gets the most recent phase values for each corresponding value in InFrequencies (in Hz). | AudioMixerSubmix.h | |
int32 GetSampleRate() |
Returns the device sample rate this submix is rendering to. | AudioMixerSubmix.h | |
int32 GetSizeOfSubmixChain() |
Returns the size of the submix chain. | AudioMixerSubmix.h | |
ISoundfieldFactory * GetSoundfieldFactory() |
AudioMixerSubmix.h | ||
ISoundfieldEncodingSettingsProxy & GetSoundfieldSettings() |
AudioMixerSubmix.h | ||
int32 GetSubmixChannels() |
Gets the submix channels channels. | AudioMixerSubmix.h | |
FSoundEffectSubmixPtr GetSubmixEffect
(
const int32 InIndex |
Returns the submix effect at the given effect chain index. | AudioMixerSubmix.h | |
FModulationDestination * GetWetVolumeDestination() |
AudioMixerSubmix.h | ||
void Init
(
const USoundSubmixBase* InSoundSubmix, |
Initialize the submix object with the USoundSubmix ptr. Sets up child and parent connects. | AudioMixerSubmix.h | |
bool IsDefaultEndpointSubmix() |
Returns true if this submix sends it's audio to the default endpoint. | AudioMixerSubmix.h | |
bool IsDummyEndpointSubmix() |
Returns true if this is an endpoint type that should no-op for this platform. | AudioMixerSubmix.h | |
bool IsExternalEndpointSubmix() |
Returns true if this submix sends its audio to an IAudioEndpoint. | AudioMixerSubmix.h | |
bool IsRenderingAudio() |
Returns true if the submix is currently rendering audio. The current rendering time is passed in. | AudioMixerSubmix.h | |
bool IsSoundfieldEndpointSubmix() |
Returns true if this submix sends its audio to an ISoundfieldEndpoint. | AudioMixerSubmix.h | |
bool IsSoundfieldSubmix() |
Returns true if this submix is encoded to a soundfield. | AudioMixerSubmix.h | |
bool IsValid () |
Checks to see if submix is valid. | AudioMixerSubmix.h | |
void OnStartRecordingOutput
(
float ExpectedDuration |
This is called by the corresponding USoundSubmix when StartRecordingOutput is called. | AudioMixerSubmix.h | |
FAlignedFloatBuffer & OnStopRecordingOutput
(
float& OutNumChannels, |
This is called by the corresponding USoundSubmix when StopRecordingOutput is called. | AudioMixerSubmix.h | |
void PauseRecordingOutput() |
This is called by the corresponding USoundSubmix when PauseRecording is called. | AudioMixerSubmix.h | |
void ProcessAudio
(
ISoundfieldAudioPacket& OutputAudio |
AudioMixerSubmix.h | ||
void ProcessAudio
(
FAlignedFloatBuffer& OutAudio |
Function which processes audio. | AudioMixerSubmix.h | |
void ProcessAudioAndSendToEndpoint() |
This should be called if this submix doesn't send it's audio to a parent submix, but rather an external endpoint. | AudioMixerSubmix.h | |
void RegisterAudioBus
(
const Audio::FAudioBusKey& InAudioBusKey, |
Registers the given audiobus to this submix. | AudioMixerSubmix.h | |
void RegisterBufferListener
(
ISubmixBufferListener* BufferListener |
Register buffer listener with this submix Unregister buffer listener with this submix | AudioMixerSubmix.h | |
void RegisterBufferListener
(
TSharedRef< ISubmixBufferListener, ESPMode::ThreadSafe > BufferListener |
AudioMixerSubmix.h | ||
void RemoveChildSubmix
(
TWeakPtr< FMixerSubmix, ESPMode::ThreadSafe > SubmixWeakPtr |
Removes the given submix from this submix's children. | AudioMixerSubmix.h | |
void RemoveEnvelopeFollowerDelegate
(
const FOnSubmixEnvelopeBP& OnSubmixEnvelopeBP |
Removes an existing envelope follower delegate. | AudioMixerSubmix.h | |
void RemoveSoundEffectSubmix
(
uint32 SubmixPresetId |
Removes the submix effect from the effect submix chain. | AudioMixerSubmix.h | |
void RemoveSoundEffectSubmixAtIndex
(
int32 InIndex |
Removes the submix effect from the effect submix chain at the given submix index. | AudioMixerSubmix.h | |
void RemoveSourceVoice
(
FMixerSourceVoice* InSourceVoice |
Removes the given source voice from the submix. | AudioMixerSubmix.h | |
void RemoveSpectralAnalysisDelegate
(
const FOnSubmixSpectralAnalysisBP& OnSubmixSpectralAnalysisBP |
Removes an existing spectral analysis delegate. | AudioMixerSubmix.h | |
void ReplaceSoundEffectSubmix
(
int32 InIndex, |
Swaps effect for provided submix at the given index. Fails if effect at index doesn't exist | AudioMixerSubmix.h | |
void ResumeRecordingOutput() |
This is called by the corresponding USoundSubmix when ResumeRecording is called. | AudioMixerSubmix.h | |
void SendAudioToSubmixBufferListeners
(
FAlignedFloatBuffer& OutAudioBuffer |
AudioMixerSubmix.h | ||
void SetAutoDisable
(
bool bInAutoDisable |
Set whether or not this submix is told to auto disable. | AudioMixerSubmix.h | |
void SetAutoDisableTime
(
float InAutoDisableTime |
Sets the auto-disable time. | AudioMixerSubmix.h | |
void SetBackgroundMuted
(
bool bInMuted |
Whether or not this submix instance is muted. | AudioMixerSubmix.h | |
void SetDryLevel
(
float InDryLevel |
Sets the static output volume of the submix in linear gain. | AudioMixerSubmix.h | |
void SetModulationBaseLevels
(
float InVolumeModBaseDb, |
Update modulation settings of the submix with Decibel values. | AudioMixerSubmix.h | |
void SetOutputVolume
(
float InOutputLevel |
Sets the output level of the submix in linear gain. | AudioMixerSubmix.h | |
void SetParentSubmix
(
TWeakPtr< FMixerSubmix, ESPMode::ThreadSafe > Submix |
Sets the parent submix to the given submix. | AudioMixerSubmix.h | |
void SetSoundfieldFactory
(
ISoundfieldFactory* InSoundfieldFactory |
This must be called on the entire submix graph before calling SetupSoundfieldStreams. | AudioMixerSubmix.h | |
void SetSubmixEffectChainOverride
(
const TArray< FSoundEffectSubmixPtr >& InSubmixEffectPresetChain, |
Sets a submix effect chain override with the given fade time in seconds. | AudioMixerSubmix.h | |
void SetupEndpoint
(
ISoundfieldEndpointFactory* InFactory, |
AudioMixerSubmix.h | ||
void SetupEndpoint
(
IAudioEndpointFactory* InFactory, |
AudioMixerSubmix.h | ||
void SetupSoundfieldStreams
(
const USoundfieldEncodingSettingsBase* SoundfieldSettings, |
Updates settings, potentially creating or removing ambisonics streams based on what types of submixes this submix is connected to. | AudioMixerSubmix.h | |
void SetWetLevel
(
float InWetLevel |
Sets the wet level of the submix in linear gain. | AudioMixerSubmix.h | |
void StartEnvelopeFollowing
(
int32 AttackTime, |
Starts envelope following with the given attack time and release time. | AudioMixerSubmix.h | |
void StartSpectrumAnalysis
(
const FSoundSpectrumAnalyzerSettings& InSettings |
Initializes a new FFT analyzer for this submix and immediately begins feeding audio to it. | AudioMixerSubmix.h | |
void StopEnvelopeFollowing() |
Stops envelope following the submix. | AudioMixerSubmix.h | |
void StopSpectrumAnalysis() |
Terminates whatever FFT Analyzer is being used for this submix. | AudioMixerSubmix.h | |
void TeardownSoundfieldStreams() |
AudioMixerSubmix.h | ||
void UnregisterAudioBus
(
const Audio::FAudioBusKey& InAudioBusKey |
Unregisters a registered audiobus from this submix (if any) | AudioMixerSubmix.h | |
void UnregisterBufferListener
(
ISubmixBufferListener* BufferListener |
AudioMixerSubmix.h | ||
void UnregisterBufferListener
(
TSharedRef< ISubmixBufferListener, ESPMode::ThreadSafe > BufferListener |
AudioMixerSubmix.h | ||
void UpdateEndpointSettings
(
TUniquePtr< IAudioEndpointSettingsProxy >&& InSettings |
AudioMixerSubmix.h | ||
void UpdateEndpointSettings
(
TUniquePtr< ISoundfieldEndpointSettingsProxy >&& InSettings |
AudioMixerSubmix.h | ||
void UpdateModulationSettings
(
const TSet< TObjectPtr< USoundModulatorBase > >& InOutputModulators, |
Update modulation settings of the submix. | AudioMixerSubmix.h |
Protected
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
bool GenerateEffectChainAudio
(
FSoundEffectSubmixInputData& InputData, |
Generates audio from the given effect chain into the given buffer. | AudioMixerSubmix.h | |
FName GetSoundfieldFormat() |
AudioMixerSubmix.h | ||
TUniquePtr< ISoundfieldTranscodeStream > GetTranscoderForChildSubmix
(
const TSharedPtr< Audio::FMixerSubmix, ESPMode::ThreadSafe >& InChildSubmix |
AudioMixerSubmix.h | ||
void InitInternal() |
Initialize the submix internal. | AudioMixerSubmix.h | |
void MixBufferDownToMono
(
const FAlignedFloatBuffer& InBuffer, |
AudioMixerSubmix.h | ||
void MixInChildSubmix
(
FChildSubmixInfo& Child, |
Calls ProcessAudio on the child submix, performs all necessary conversions and mixes in it's resulting audio. | AudioMixerSubmix.h | |
void MixInSource
(
const ISoundfieldAudioPacket& InAudio, |
Encode a source and sum it into the mixed soundfield. | AudioMixerSubmix.h | |
void PumpCommandQueue() |
Pump command queue. | AudioMixerSubmix.h | |
void SetupSoundfieldEncodersForChildren() |
AudioMixerSubmix.h | ||
void SetupSoundfieldEncodingForChild
(
FChildSubmixInfo& InChild |
AudioMixerSubmix.h | ||
void SetUpSoundfieldPositionalData
(
const TSharedPtr< Audio::FMixerSubmix, ESPMode::ThreadSafe >& InParentSubmix |
This sets up the ambisonics positional data for speakers, based on what new format we need to convert to. | AudioMixerSubmix.h | |
void SetupSoundfieldStreamForParent() |
Check to see if we need to decode from ambisonics for parent. | AudioMixerSubmix.h | |
void SubmixCommand
(
TFunction< void()> Command |
Add command to the command queue. | AudioMixerSubmix.h | |
void UpdateListenerRotation
(
const FQuat& InRotation |
AudioMixerSubmix.h |
Static
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
static void DownmixBuffer
(
const int32 InChannels, |
Down mix the given buffer to the desired down mix channel count. | AudioMixerSubmix.h |