Interface ISoundModifier
A sound modifier can be implemented in order to modify one or more properties of a sound on-the-fly. For example, the engine has an audio rule (IAudioRule) that adds a modifier to all non-speech sounds, which reduces the volume of those sounds when a speech sound plays.
Namespace: AGS.API
Assembly: AGS.API.dll
Syntax
public interface ISoundModifier
Properties
| Improve this Doc View SourceOnChange
Fires an event when the modifier changes. The sound subscribes to this event to be notified it that it needs to re-calculate its properties.
Declaration
IBlockingEvent OnChange { get; }
Property Value
Type | Description |
---|---|
IBlockingEvent | The on change. |
Methods
| Improve this Doc View SourceGetPanning(Single)
Gets the panning after modification.
Declaration
float GetPanning(float panning)
Parameters
Type | Name | Description |
---|---|---|
System.Single | panning | Panning before modification. |
Returns
Type | Description |
---|---|
System.Single | The panning after modification. |
GetPitch(Single)
Gets the pitch after modification.
Declaration
float GetPitch(float pitch)
Parameters
Type | Name | Description |
---|---|---|
System.Single | pitch | Pitch before modification. |
Returns
Type | Description |
---|---|
System.Single | The pitch after modification. |
GetVolume(Single)
Gets the volume after modification.
Declaration
float GetVolume(float volume)
Parameters
Type | Name | Description |
---|---|---|
System.Single | volume | Volume before modification. |
Returns
Type | Description |
---|---|
System.Single | The volume after modification. |