IAudioSpatialization

[IAudioSpatialization](API\Runtime\Engine\IAudioSpatialization)

Windows
MacOS
Linux

Inheritance Hierarchy

IAudioSpatialization

FITDSpatialization

Syntax

class IAudioSpatialization

Remarks

IAudioSpatialization

This class represents instances of a plugin that will process spatialization for a stream of audio. Currently used to process a mono-stream through an HRTF spatialization algorithm into a stereo stream. This algorithm contains an audio effect assigned to every VoiceId (playing sound instance). It assumes the effect is updated in the audio engine update loop with new position information.

Destructors

Name Description

Public function Virtual

~IAudioSpatialization()

Virtual destructor

Functions

Name Description

Public function Virtual

bool

 

CreateSpatializationEffect

(
    uint32 SourceId
)

Creates an audio spatialization effect.

Public function Virtual

void *

 

GetSpatializationEffect

(
    uint32 SourceId
)

Returns the spatialization effect for the given voice id.

Public function Virtual

void

 

GetSpatializationParameters

(
    uint32 SourceId,
    FSpatializationParams& OutParams
)

DEPRECATED: Gets the spatialization effect parameters.

Public function Virtual

void

 

Initialize

(
    const FAudioPluginInitializationPar...
)

Initializes the spatialization plugin with the given buffer length.

Public function Virtual

void

 

InitializeSpatializationEffect

(
    uint32 BufferLength
)

DEPRECATED: Initializes the spatialization effect with the given buffer length.

Public function Virtual Const

bool

 

IsSpatializationEffectInitialized()

Returns whether or not the spatialization effect has been initialized

Public function Virtual

void

 

OnAllSourcesProcessed()

Called when all sources have finished processing.

Public function Virtual

void

 

OnDeviceShutdown

(
    FAudioDevice* AudioDevice
)

Public function Virtual

void

 

OnInitSource

(
    const uint32 SourceId,
    const FName& AudioComponentUserId,
    USpatializationPluginSourceSettings...
)

Called when a source is assigned to a voice.

Public function Virtual

void

 

OnReleaseSource

(
    const uint32 SourceId
)

Called when a source is done playing and is released.

Public function Virtual

void

 

ProcessAudio

(
    const FAudioPluginSourceInputData&...,
    FAudioPluginSourceOutputData& Outp...
)

Processes audio with the given input and output data structs.

Public function Virtual

void

 

ProcessSpatializationForVoice

(
    uint32 SourceId,
    float* InSamples,
    float* OutSamples
)

DEPRECATED: Uses the given HRTF algorithm to spatialize a mono audio stream, assumes the parameters have already been set before processing.

Public function Virtual

void

 

ProcessSpatializationForVoice

(
    uint32 SourceId,
    float* InSamples,
    float* OutSamples,
    const FVector& Position
)

DEPRECATED: Uses the given HRTF algorithm to spatialize a mono audio stream.

Public function Virtual

void

 

SetSpatializationParameters

(
    uint32 SourceId,
    const FSpatializationParams& Param...
)

DEPRECATED: sets the spatialization effect parameters.

Public function Virtual

void

 

Shutdown()

Shuts down the audio plugin.

References

Module

Engine

Header

Runtime/Engine/Public/IAudioExtensionPlugin.h

Welcome to the new Unreal Engine 4 Documentation site!

We're working on lots of new features including a feedback system so you can tell us how we are doing. It's not quite ready for use in the wild yet, so head over to the Documentation Feedback forum to tell us about this page or call out any issues you are encountering in the meantime.

We'll be sure to let you know when the new system is up and running.

Post Feedback