#include <sidplayer.h>
Collaboration diagram for CSidPlayer:

Public Member Functions | |
| virtual | ~CSidPlayer () |
| D'tor. | |
| void | InitL () |
| initialise everything, but do not start playing (yet) | |
| void | Play () |
| start playing using the CIdle class | |
| void | Stop () |
| stop playing | |
| void | Pause () |
| pause the player | |
| TBool | IsPaused () |
| return ETrue if paused | |
| void | Thread () |
| wow. | |
| sidTune & | CurrentSidTune () const |
| TInt | VolumeDelta (TInt aDelta) |
| increase/decrease volume and return the new volume | |
| TInt | SongDelta (TInt aDelta) |
| skip song up/down and return the new song numer | |
| TInt | SongSelect (TInt &aSong) |
| select a new song to play | |
| TInt | NewTune (const TDesC &aTune) |
| open a new SID tune, delete the old one | |
Static Public Member Functions | |
| CSidPlayer * | NewL (const TDesC &aSong) |
Public Attributes | |
| emuEngine * | iEmuEngine |
| pointer to the emulator engine | |
| CIdle * | iIdlePlay |
| pointer to the CIdle playback object | |
| TBuf< 128 > | iSongName |
| name of the song | |
| audioDriver * | iAudio |
| pointer to the audio driver | |
Protected Member Functions | |
| void | ConstructL () |
| safe constructor | |
| CSidPlayer (const TDesC &aSong) | |
| C'tor. | |
Private Attributes | |
| sidTune * | iTune |
| pointer to the SID tune | |
| ubyte * | iBuffer |
| buffer used for sound | |
| TInt | iBufSize |
| size of the sound buffer | |
| TBool | iIsReady |
| ETrue if inited and ready to play. | |
Definition at line 31 of file sidplayer.h.
|
|
D'tor.
Definition at line 65 of file sidplayer.cpp. References DTOR, iAudio, iBuffer, iEmuEngine, iIdlePlay, and iTune. |
|
|
C'tor.
Definition at line 91 of file sidplayer.cpp. References CTOR, and iSongName. Referenced by NewL(). |
|
|
safe constructor
Definition at line 82 of file sidplayer.cpp. References InitL(). Referenced by NewL(). |
|
|
Definition at line 43 of file sidplayer.h. References iTune. Referenced by CSidPlayAppUi::HandleCommandL(), and CSidPlayAppUi::UpdateCbaL(). |
|
|
initialise everything, but do not start playing (yet)
Definition at line 103 of file sidplayer.cpp. References emuConfig::autoPanning, emuConfig::bitsPerSample, emuConfig::channels, audioDriver::ConstructL(), ELOG1, ERR_ENDIANESS, EXIT_ERROR_STATUS, fragments, fragSizeBase, emuConfig::frequency, audioDriver::GetBlockSize(), emuEngine::getConfig(), audioDriver::GetFrequency(), sidTune::getInfo(), audioDriver::GetSampleEncoding(), audioDriver::GetSamplePrecision(), iAudio, iBuffer, iBufSize, iEmuEngine, iIsReady, iSongName, audioDriver::IsThere(), iTune, audioDriver::Open(), SAMPLE_FREQ, emuConfig::sampleFormat, selectedSong, emuEngine::setConfig(), SIDEMU_16BIT, SIDEMU_8BIT, SIDEMU_FULLPANNING, SIDEMU_MONO, SIDEMU_NONE, SIDEMU_STEREO, sidEmuInitializeSong(), ubyte, uword, emuEngine::verifyEndianess(), and emuConfig::volumeControl. Referenced by ConstructL(), and CSidPlayAppUi::ConstructL(). |
|
|
return ETrue if paused
Definition at line 324 of file sidplayer.cpp. Referenced by SidPlayerThread(). |
|
|
Definition at line 55 of file sidplayer.cpp. References ConstructL(), and CSidPlayer(). Referenced by CSidPlayAppUi::ConstructL(). |
|
|
open a new SID tune, delete the old one
Definition at line 422 of file sidplayer.cpp. References iEmuEngine, iSongName, iTune, and sidEmuInitializeSong(). Referenced by CSidPlayAppUi::DoBrowseFileL(), and CSidPlayAppUi::ProcessCommandParametersL(). |
|
|
pause the player
Definition at line 304 of file sidplayer.cpp. References ELOG1, iIdlePlay, and Play(). Referenced by CSidPlayAppUi::HandleCommandL(). |
|
|
start playing using the CIdle class
Definition at line 262 of file sidplayer.cpp. References ELOG1, iIdlePlay, iIsReady, and SidPlayerThread(). Referenced by CSidPlayAppUi::DoBrowseFileL(), CSidPlayAppUi::HandleCommandL(), Pause(), CSidPlayAppUi::ProcessCommandParametersL(), SongDelta(), and SongSelect(). |
|
|
skip song up/down and return the new song numer
Definition at line 371 of file sidplayer.cpp. References sidTuneInfo::currentSong, ELOG1, sidTune::getInfo(), iAudio, iEmuEngine, iTune, Play(), sidEmuInitializeSong(), sidTuneInfo::songs, audioDriver::StopStream(), and uword. Referenced by CSidPlayAppUi::HandleCommandL(), and CSidPlayAppUi::HandleKeyEventL(). |
|
|
select a new song to play
Definition at line 401 of file sidplayer.cpp. References sidTuneInfo::currentSong, sidTune::getInfo(), iAudio, iEmuEngine, iTune, Play(), sidEmuInitializeSong(), audioDriver::StopStream(), and uword. Referenced by CSidPlayAppUi::HandleKeyEventL(). |
|
|
stop playing
Definition at line 285 of file sidplayer.cpp. References ELOG1, iAudio, iEmuEngine, iIdlePlay, iTune, sidEmuInitializeSong(), and audioDriver::StopStream(). Referenced by CSidPlayAppUi::DoBrowseFileL(), CSidPlayAppUi::HandleCommandL(), and CSidPlayAppUi::ProcessCommandParametersL(). |
|
|
wow. here is the actual core loop of the system; fill the buffer, then play it. repeat 1000 times. Definition at line 333 of file sidplayer.cpp. References emuEngine::FillBuffer(), iAudio, audioDriver::iBlocksInQueue, iBuffer, iBufSize, iEmuEngine, audioDriver::iIsReady, audioDriver::iPrefilled, iTune, audioDriver::Play(), and ubyte. Referenced by SidPlayerThread(). |
|
|
increase/decrease volume and return the new volume
Definition at line 362 of file sidplayer.cpp. References iAudio, and audioDriver::VolumeDelta(). Referenced by CSidPlayAppView::ConstructL(), and CSidPlayAppUi::HandleKeyEventL(). |
|
|
pointer to the audio driver
Definition at line 55 of file sidplayer.h. Referenced by CSidPlayAppUi::HandleCommandL(), InitL(), SongDelta(), SongSelect(), Stop(), Thread(), VolumeDelta(), and ~CSidPlayer(). |
|
|
buffer used for sound
Definition at line 58 of file sidplayer.h. Referenced by InitL(), Thread(), and ~CSidPlayer(). |
|
|
size of the sound buffer
Definition at line 59 of file sidplayer.h. |
|
|
pointer to the emulator engine
Definition at line 52 of file sidplayer.h. Referenced by CSidPlayAppUi::HandleCommandL(), InitL(), NewTune(), SidPlayExceptionHandler(), SongDelta(), SongSelect(), Stop(), Thread(), and ~CSidPlayer(). |
|
|
pointer to the CIdle playback object
Definition at line 53 of file sidplayer.h. Referenced by Pause(), Play(), Stop(), CSidPlayAppUi::UpdateCbaL(), and ~CSidPlayer(). |
|
|
ETrue if inited and ready to play.
Definition at line 60 of file sidplayer.h. |
|
|
name of the song
Definition at line 54 of file sidplayer.h. Referenced by CSidPlayer(), CSidPlayAppUi::HandleCommandL(), InitL(), and NewTune(). |
|
|
pointer to the SID tune
Definition at line 57 of file sidplayer.h. Referenced by CurrentSidTune(), InitL(), NewTune(), SongDelta(), SongSelect(), Stop(), Thread(), and ~CSidPlayer(). |
1.3.3