#include <SoundModule.h>
Public Member Functions | |
CEncodedVoicePlayer () | |
Constructor. This does not initiate sound playing. | |
void | Start (const char *options) |
void | PushVoiceData (const ALbyte *data, int len) |
void | Stop () |
Stops the voice playing,. | |
~CEncodedVoicePlayer () | |
Destructor. | |
void | SetVolume (float v) |
float | GetVolume () |
Returns the amount of current volume. | |
Protected Attributes | |
char * | options |
Holds the sound options string. | |
CVoicePlayer | vp |
The voice player used. | |
CSoundCodec | codec |
The sound codec used. |
void CEncodedVoicePlayer::Start | ( | const char * | options | ) |
Initiates the encoded sound playing if it is not playing.
options | The sound options string. Refer to the design report. |
void CEncodedVoicePlayer::PushVoiceData | ( | const ALbyte * | data, | |
int | len | |||
) |
Pushes encoded voice data to the encoded voice player so that this data is played. Start must be called before calling this.
data | The address of the encoded voice data. | |
len | The length of the encoded voice data. |
void CEncodedVoicePlayer::SetVolume | ( | float | v | ) |
Sets the volume of the encoded voice player. param v The amount of volume. It should be between 0.0 and 1.0 inclusively.