AISetDSPSampleRate

Syntax

#include <revolution/ai.h>

#define AI_SAMPLERATE_48KHZ     0x01

void AISetDSPSampleRate(u8 samplerate);

Arguments

samplerate Sampling frequency for the DSP audio data.

Return Values

None.

Description

The AISetDSPSampleRate function sets the sampling frequency for the audio data that the DSP outputs. The default sampling frequency is 32 kHz.

When the sampling frequency setting is at 32kHz, the hardware sampling rate converter (SRC) within the AI is enabled. The DSP audio data is converted from 32 kHz to 48 kHz by the SRC and passed to DAC.

When the sampling frequency is set to 48kHz in the AISetDSPSampleRate function, the SRC becomes disabled, and the DSP audio data will be passed to the DAC as is.

Noise may be generated if the sampling frequency is changed using the AISetDSPSampleRate function during audio playback. Be sure to change the sampling frequency after you stop playback.

Note: Once the sampling frequency is changed to 48kHz in the game, it cannot be changed back to 32kHz.

See Also

None.

Revision History

2006/09/22 Added notes regarding frequency changes.
2006/03/01 Initial version.


CONFIDENTIAL