Samples Directory
/CRIWARE/SDK/pc/samples/criatomex/pause_playback
Sample Description
- If you want to synchronize starting timing of multiple streaming playbacks, use the criAtomExPlayer_Prepare function.
Using the criAtomExPlayer_Prepare function, you can prepare playback so that playback can be started immediately.
- You can determine whether the playback is ready or not by checking if the status of the playback ID is CRIATOMEXPLAYBACK_STATUS_PLAYING.
(When playback is not ready, status is CRIATOMEXPLAYBACK_STATUS_PREP.)
Playback ID is received as a return value of the criAtomExPlayer_Prepare function, which should be stored in application.
- When the playback is ready, in order to start playback, use the criAtomExPlayback_Pause function to resume playback for the playback ID.
CriAtomExPlayeBackId playback_id;
for(;;) {
sleep(1);
break;
}
}
void criAtomEx_ExecuteMain(void)
Execute the server processing.
CriAtomExPlaybackStatus criAtomExPlayback_GetStatus(CriAtomExPlaybackId id)
Get the playback status.
void criAtomExPlayback_Pause(CriAtomExPlaybackId id, CriBool sw)
Pause/resume the sound.
enum CriAtomExPlaybackStatusTag CriAtomExPlaybackStatus
Playback status.
@ CRIATOMEXPLAYBACK_STATUS_PLAYING
Definition: cri_le_atom_ex.h:4180
CriAtomExPlayerObj * CriAtomExPlayerHn
Player handle.
Definition: cri_le_atom_ex.h:3622
CriAtomExPlaybackId criAtomExPlayer_Prepare(CriAtomExPlayerHn player)
Prepare the playback.
void criAtomExPlayer_SetCueId(CriAtomExPlayerHn player, CriAtomExAcbHn acb_hn, CriAtomExCueId id)
Set the sound data to play (specifying a Cue ID)
- When you want to synchronize playback start timing, use one player and prepare playback for multiple Voices, then resume the player to start playback together.
In this case, you can determine whether playback is ready or not by checking the status of CriAtomExPlayerHn.
for(;;) {
sleep(1);
break;
}
}
CriAtomExPlayerStatus criAtomExPlayer_GetStatus(CriAtomExPlayerHn player)
Get the player status.
enum CriAtomExPlayerStatusTag CriAtomExPlayerStatus
Player status.
void criAtomExPlayer_Pause(CriAtomExPlayerHn player, CriBool sw)
Pause/resume.
@ CRIATOMEXPLAYER_STATUS_PLAYING
Definition: cri_le_atom_ex.h:3669