MCPcopy Create free account
hub / github.com/devkitPro/libctru / ndspThreadMain

Function ndspThreadMain

libctru/source/ndsp/ndsp.c:427–451  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

425}
426
427static void ndspThreadMain(void* arg)
428{
429 ndspThreadRun = true;
430 while (ndspThreadRun)
431 {
432 ndspSync();
433
434 if (ndspMaster.callback)
435 ndspMaster.callback(ndspMaster.callbackData);
436
437 if (bSleeping || bCancelReceived || !bDspReady)
438 continue;
439
440 ndspUpdateMaster();
441 // TODO: call aux user callback if enabled
442 // TODO: execute DSP effects
443 ndspiUpdateChn();
444
445 ndspSetCounter(ndspBufferCurId, ndspFrameId++);
446 svcSignalEvent(dspSem);
447 ndspBufferCurId = ndspFrameId & 1;
448
449 frameCount++;
450 }
451}
452
453void ndspUseComponent(const void* binary, u32 size, u16 progMask, u16 dataMask)
454{

Callers

nothing calls this directly

Calls 4

ndspSyncFunction · 0.85
ndspUpdateMasterFunction · 0.85
ndspiUpdateChnFunction · 0.85
ndspSetCounterFunction · 0.85

Tested by

no test coverage detected