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

Function gxCmdQueueInterrupt

libctru/source/gpu/gxqueue.c:27–51  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

25}
26
27void gxCmdQueueInterrupt(GSPGPU_Event irq)
28{
29 if (!isRunning || irq==GSPGPU_EVENT_PSC1 || irq==GSPGPU_EVENT_VBlank0 || irq==GSPGPU_EVENT_VBlank1)
30 return;
31 gxCmdQueue_s* runCb = NULL;
32 LightLock_Lock(&queueLock);
33 curQueue->lastEntry++;
34 if (shouldStop)
35 {
36 curQueue = NULL;
37 isActive = false;
38 isRunning = false;
39 shouldStop = false;
40 }
41 else if (curQueue->lastEntry < curQueue->numEntries)
42 gxCmdQueueDoCommands();
43 else
44 {
45 runCb = curQueue;
46 isRunning = false;
47 }
48 LightLock_Unlock(&queueLock);
49 if (runCb && runCb->callback)
50 runCb->callback(runCb);
51}
52
53void gxCmdQueueClear(gxCmdQueue_s* queue)
54{

Callers

nothing calls this directly

Calls 3

LightLock_LockFunction · 0.85
gxCmdQueueDoCommandsFunction · 0.85
LightLock_UnlockFunction · 0.85

Tested by

no test coverage detected