nw::snd::SoundSystem::LockSoundThread Member Function

Syntax

#include <nw/snd/snd_SoundSystem.h>
static void LockSoundThread();

Arguments

None.

Return Values

None.

Description

Locks sound threads.

When the nn::snd::AllocVoice, nn::snd::FreeVoice, or nn::snd::Voice functions in the CTR_SDK are called, be sure to lock the sound thread with this function.

However, when the above function is called in the callback registered with the RegisterSoundFrameUserCallback function while the sound thread is being operated by the application core, there is no need to lock.

When calling the above function from outside the callback or when the sound thread is being run by the system core, it must be locked with this function.

After using the above function, use UnlockSoundThread to release the lock.

If the thread is locked for an extended period of time, the nwsnd sound processing may stagnate, the sound may skip, or some other negative impact may be experienced.

Also see the demos/snd/withSdk sample demo.

See Also

UnlockSoundThread

Revision History

2010/10/27
Initial version.

CONFIDENTIAL