Firelight Technologies FMOD Studio API
Channel::setFrequency
Sets the channel frequency or playback rate, in Hz.
C++ Syntax
FMOD_RESULT Channel::setFrequency(
float frequency
);
C Syntax
FMOD_RESULT FMOD_Channel_SetFrequency(
FMOD_CHANNEL *channel,
float frequency
);
C# Syntax
RESULT Channel.setFrequency(
float frequency
);
JavaScript Syntax
Channel.setFrequency(
frequency
);
Parameters
- frequency
- Frequency value in Hz. This value can also be negative to play the sound backwards (negative frequencies allowed with non-stream sounds only).
Return Values
If the function succeeds then the return value is FMOD_OK.
If the function fails then the return value will be one of the values defined in the FMOD_RESULT enumeration.
Remarks
When a sound is played, it plays at the default frequency of the sound which can be set by Sound::setDefaults.
For most file formats, the default frequency is determined by the audio format.
See Also
Version 1.10.03 Built on Feb 1, 2018