![]() |
UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
|
#include <ISoundfieldEndpoint.h>
Protected Member Functions | |
| virtual bool | EndpointRequiresCallback () const |
| virtual float | GetDesiredCallbackPeriodicity () const |
| virtual void | OnAudioCallback (TUniquePtr< ISoundfieldAudioPacket > &&InPacket, const ISoundfieldEndpointSettingsProxy *InSettings) |
| AUDIOEXTENSIONS_API TUniquePtr< ISoundfieldAudioPacket > | PopAudio () |
| AUDIOEXTENSIONS_API void | PollSettings (TFunctionRef< void(const ISoundfieldEndpointSettingsProxy *)> SettingsCallback) |
| AUDIOEXTENSIONS_API void | StartRunningCallback () |
| AUDIOEXTENSIONS_API void | StopRunningCallback () |
| AUDIOEXTENSIONS_API void | RunCallbackSynchronously () |
Class that allows soundfield-encoded audio to be sent to an arbitrary locale. For endpoint types that support receiving our downmixed interleaved audio data directly, implement IAudioEndpoint instead.
| ISoundfieldEndpoint::ISoundfieldEndpoint | ( | int32 | NumRenderCallbacksToBuffer | ) |
| [NumRenderCallbacksToBuffer] | Maximum number of ISoundfieldPackets that should be buffered. |
|
inlinevirtual |
OPTIONAL OVERRIDES: For endpoints that do not explicitly fire a timed callback to poll audio data, this should be overridden to return true, and OnAudioCallback and GetDesiredCallbackFrequency should be overridden.
For endpoints that return true for EndpointRequiresCallback, this should return the duration between OnAudioCallback calls in seconds.
| int32 ISoundfieldEndpoint::GetNumPacketsBuffer | ( | ) |
| int32 ISoundfieldEndpoint::GetRemainderInPacketBuffer | ( | ) |
|
inlineprotectedvirtual |
For endpoints that override EndpointRequiresCallback to return true, this callback will be called every (GetDesiredNumFrames() / GetSampleRate()) seconds.
| [in] | InPacket | the next buffer of audio. Can be nullptr if PushAudio hasn't been called in a while and the buffer is starved. |
| [in] | InSettings | is the most recent soundfield settings for this endpoint. Can be null. |
|
protected |
Use this as a thread safe way to use the current settings posted to this IAudioEndpoint. Locks with IAudioEndpoint::SetSettings.
| [in] | NewSettingsRetrieved | lambda used to work with the retrieved settings. This lambda is called immediately and synchronously, but is used to safely scope usage of the IAudioEndpointSettingsProxy pointer. Note that the resulting ISoundfieldEndpointSettingsProxy can be null. |
|
protected |
METHODS USED BY IMPLEMENTATIONS OF ISoundfieldEndpoint: This is used by the IAudioEndpoint implementation to poll buffered audio to process or send to the endpoint. Note that this is NOT thread safe if EndpointRequiresCallback() is overridden to return true. If that is the case, use an override of OnAudioCallback instead.
| void ISoundfieldEndpoint::ProcessAudioIfNecessary | ( | ) |
If this endpoint hasn't created it's own async callback thread but still requires an explicit callback, this should be called.
| bool ISoundfieldEndpoint::PushAudio | ( | TUniquePtr< ISoundfieldAudioPacket > && | InPacket | ) |
Push a soundfield packet to the buffer.
|
protected |
| void ISoundfieldEndpoint::SetNewSettings | ( | TUniquePtr< ISoundfieldEndpointSettingsProxy > && | InNewSettings | ) |
Post new settings for this endpoint. There is no type safety on this call, so make sure that you are using the correct implementation of IAudioEndpointSettingsProxy for this implementation of IAudioEndpoint.
|
protected |
If EndpointRequiresCallback() returns true, this will be used to spawn an async thread and begin calling OnAudioCallback.
|
protected |