Class IAudioControlComponent

Inheritance Relationships

Derived Types

Class Documentation

class IAudioControlComponent

Controls the audio properties of a component.

Subclassed by csp::multiplayer::AudioSpaceComponent, csp::multiplayer::VideoPlayerSpaceComponent

Public Functions

virtual AudioType GetAudioType() const = 0

Gets the type of the audio of this audio component.

Returns

The type of the audio of this audio component.

virtual void SetAudioType(AudioType Value) = 0

Sets the type of the audio of this audio component.

Parameters

Value – Type of the audio of this audio component.

virtual float GetAttenuationRadius() const = 0

Gets the attenuation for the audio when a spatial audio type.

The radius is the minimum distance between the origin of this audio component and the position of the player, from within which the player can start hearing the spatial audio in range. The radius is expressed in meters.

Returns

The minimum radius in meters from the origin of the audio component to hear the spatial audio.

virtual void SetAttenuationRadius(float Value) = 0

Sets the attenuation for the audio when a spatial audio type.

The radius is the minimum distance between the origin of this audio component and the position of the player, from within which the player can start hearing the spatial audio in range. The radius is expressed in meters.

Parameters

Value – The minimum radius in meters from the origin of the audio component to hear the spatial audio.

virtual float GetVolume() const = 0

Gets the volume of the audio in a ratio between 0 and 1.

Volume 1 represents the full volume of the audio clip of this component.

Returns

The volume of the audio, in a ratio between 0 and 1.

virtual void SetVolume(float Value) = 0

Sets the volume of the audio in a ratio between 0 and 1.

Volume 1 represents the full volume of the audio clip of this component.

Parameters

Value – The volume of the audio, in a ratio between 0 and 1.

Protected Functions

virtual ~IAudioControlComponent() = default