MCPcopy Create free account
hub / github.com/EasyRPG/Player / AudioThreadCallback

Method AudioThreadCallback

src/platform/libretro/audio.cpp:44–53  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

42}
43
44void LibretroAudio::AudioThreadCallback() {
45 if (!enable_audio)
46 return;
47
48 instance->LockMutex();
49 instance->Decode(buffer.data(), samples_per_frame * 2 * 2);
50 instance->UnlockMutex();
51
52 RenderAudioFrames((const int16_t*)buffer.data(), samples_per_frame);
53}
54
55void LibretroAudio::EnableAudio(bool enabled) {
56 enable_audio = enabled;

Callers

nothing calls this directly

Calls 4

dataMethod · 0.80
LockMutexMethod · 0.45
DecodeMethod · 0.45
UnlockMutexMethod · 0.45

Tested by

no test coverage detected