:
:
:
static void user_filter_callback_func(void *obj,
CriSint32 num_channels, CriSint32 num_samples, void *data[])
{
CriSint32 i, j;
if (format == CRIATOM_PCM_FORMAT_SINT16) {
for (i = 0; i < num_channels; i++) {
CriSint16 *pcm = (CriSint16*)data[i];
for (j = 0; j < num_samples; j++) {
pcm[j] >>= 1;
}
}
} else if (format == CRIATOM_PCM_FORMAT_FLOAT32) {
for (i = 0; i < num_channels; i++) {
CriFloat32 *pcm = (CriFloat32*)data[i];
for (j = 0; j < num_samples; j++) {
pcm[j] *= 0.5f;
}
}
}
}
void criAtomExPlayer_SetFilterCallback(CriAtomExPlayerHn player, CriAtomExPlayerFilterCbFunc func, void *obj)
波形フィルターコールバック関数の登録
CriAtomExPlaybackId criAtomExPlayer_Start(CriAtomExPlayerHn player)
再生の開始
CriAtomExPlayerObj * CriAtomExPlayerHn
プレーヤーハンドル
Definition: cri_le_atom_ex.h:3628
CriAtomExPlayerHn criAtomExPlayer_Create(const CriAtomExPlayerConfig *config, void *work, CriSint32 work_size)
AtomExPlayerの作成
void criAtomExPlayer_SetCueId(CriAtomExPlayerHn player, CriAtomExAcbHn acb_hn, CriAtomExCueId id)
音声データのセット(キューID指定)
CriUint32 CriAtomExPlaybackId
再生ID
Definition: cri_le_atom_ex.h:3728
enum CriAtomPcmFormatTag CriAtomPcmFormat
PCMフォーマット