mirror of
https://github.com/switchbrew/libnx.git
synced 2025-06-21 04:22:50 +02:00
add audrvVoiceIsPaused
This commit is contained in:
parent
d6c6431a22
commit
00d1a696b9
@ -62,6 +62,7 @@ struct AudioDriverWaveBuf {
|
||||
bool audrvVoiceInit(AudioDriver* d, int id, int num_channels, PcmFormat format, int sample_rate);
|
||||
void audrvVoiceDrop(AudioDriver* d, int id);
|
||||
void audrvVoiceStop(AudioDriver* d, int id);
|
||||
bool audrvVoiceIsPaused(AudioDriver* d, int id);
|
||||
bool audrvVoiceIsPlaying(AudioDriver* d, int id);
|
||||
bool audrvVoiceAddWaveBuf(AudioDriver* d, int id, AudioDriverWaveBuf* wavebuf);
|
||||
u32 audrvVoiceGetWaveBufSeq(AudioDriver* d, int id);
|
||||
|
@ -106,6 +106,11 @@ void audrvVoiceStop(AudioDriver* d, int id)
|
||||
_audrvVoiceResetInternalState(d, id);
|
||||
}
|
||||
|
||||
bool audrvVoiceIsPaused(AudioDriver* d, int id)
|
||||
{
|
||||
return d->in_voices[id].state == AudioRendererVoicePlayState_Paused && d->etc->voices[id].first_wavebuf;
|
||||
}
|
||||
|
||||
bool audrvVoiceIsPlaying(AudioDriver* d, int id)
|
||||
{
|
||||
return d->in_voices[id].state == AudioRendererVoicePlayState_Started && d->etc->voices[id].first_wavebuf;
|
||||
|
Loading…
Reference in New Issue
Block a user