#include <SoundAgent.h>
Public Member Functions | |
SoundAgent () | |
virtual | ~SoundAgent () |
virtual OStatus | DoInit (const OSystemEvent &event) |
virtual OStatus | DoStart (const OSystemEvent &event) |
virtual OStatus | DoStop (const OSystemEvent &event) |
virtual OStatus | DoDestroy (const OSystemEvent &event) |
void | NotifyCommand (const ONotifyEvent &event) |
void | ReadyPlay (const OReadyEvent &event) |
Public Attributes | |
OSubject * | subject [numOfSubject] |
OObserver * | observer [numOfObserver] |
Private Member Functions | |
MoNetStatus | Play (int index, OVRSyncKey syncKey, byte *data) |
void | OpenSpeaker () |
void | NewSoundVectorData () |
void | LoadODA () |
void | SetPowerAndVolume () |
WAVError | CopyWAVTo (RCRegion *region) |
RCRegion * | FindFreeRegion () |
void | ReplyAgentResult (MoNetAgentID agt, int idx, MoNetStatus st) |
Private Attributes | |
SoundAgentState | soundAgentState |
OPrimitiveID | speakerID |
ODesignDataID | soundDataID |
ODA | soundODA |
int | playingIndex |
WAV | playingWAV |
RCRegion * | region [SOUND_NUM_BUFFER] |
Static Private Attributes | |
const size_t | SOUND_UNIT_SIZE = 1024 |
const size_t | SOUND_NUM_BUFFER = 4 |
|
Definition at line 17 of file SoundAgent.cc. |
|
Definition at line 36 of file SoundAgent.h. |
|
Definition at line 315 of file SoundAgent.cc. References WAV::CopyTo(), and playingWAV. Referenced by Play(), and ReadyPlay(). |
|
Definition at line 63 of file SoundAgent.cc. References soundDataID. |
|
Definition at line 26 of file SoundAgent.cc. References LoadODA(), NewSoundVectorData(), OpenSpeaker(), and SetPowerAndVolume(). |
|
Definition at line 41 of file SoundAgent.cc. References soundAgentState. |
|
Definition at line 52 of file SoundAgent.cc. References soundAgentState. |
|
Definition at line 322 of file SoundAgent.cc. References region. Referenced by Play(), and ReadyPlay(). |
|
Definition at line 231 of file SoundAgent.cc. References byte, ODA::Set(), soundDataID, and soundODA. Referenced by DoInit(). |
|
Definition at line 202 of file SoundAgent.cc. References region, WAV::Set(), SOUND_UNIT_SIZE, and speakerID. Referenced by DoInit(). |
|
Definition at line 73 of file SoundAgent.cc. References MoNetAgentCommand::agent, byte, ODA::GetData(), MoNetAgentCommand::index, monetBUSY, monetINVALID_ARG, MoNetStatus, observer, Play(), ReplyAgentResult(), soundAgentState, soundODA, and MoNetAgentCommand::syncKey. |
|
Definition at line 176 of file SoundAgent.cc. References speakerID. Referenced by DoInit(). |
|
Definition at line 128 of file SoundAgent.cc. References CopyWAVTo(), FindFreeRegion(), WAV::GetBitsPerSample(), WAV::GetSamplingRate(), playingIndex, playingWAV, WAV::Set(), speakerID, and subject. Referenced by NotifyCommand(). |
|
Definition at line 111 of file SoundAgent.cc. References CopyWAVTo(), FindFreeRegion(), monetagentSOUND, monetCOMPLETION, playingIndex, ReplyAgentResult(), soundAgentState, and subject. |
|
Definition at line 332 of file SoundAgent.cc. References monetpostureANY, and subject. Referenced by NotifyCommand(), and ReadyPlay(). |
|
Definition at line 250 of file SoundAgent.cc. References speakerID. Referenced by DoInit(). |
|
Definition at line 39 of file SoundAgent.h. Referenced by NotifyCommand(). |
|
Definition at line 70 of file SoundAgent.h. Referenced by Play(), and ReadyPlay(). |
|
Definition at line 71 of file SoundAgent.h. Referenced by CopyWAVTo(), and Play(). |
|
Definition at line 72 of file SoundAgent.h. Referenced by FindFreeRegion(), NewSoundVectorData(), and SoundAgent(). |
|
Definition at line 64 of file SoundAgent.h. |
|
Definition at line 63 of file SoundAgent.h. Referenced by NewSoundVectorData(). |
|
Definition at line 66 of file SoundAgent.h. Referenced by DoStart(), DoStop(), NotifyCommand(), and ReadyPlay(). |
|
Definition at line 68 of file SoundAgent.h. Referenced by DoDestroy(), and LoadODA(). |
|
Definition at line 69 of file SoundAgent.h. Referenced by LoadODA(), and NotifyCommand(). |
|
Definition at line 67 of file SoundAgent.h. Referenced by NewSoundVectorData(), OpenSpeaker(), Play(), and SetPowerAndVolume(). |
|
Definition at line 38 of file SoundAgent.h. Referenced by Play(), ReadyPlay(), and ReplyAgentResult(). |