//
// -[CCDirectorCaller startMainLoop] from 0x10039c1f0 to 0x10039c28c (156 bytes)
//
// 1 xrefs:
// > ??> @ 0x10099a410
//
// This function is hookable on this platform!
//
// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings
//
void __cdecl -[CCDirectorCaller startMainLoop](CCDirectorCaller *self, SEL a2)
{
id v2; // r14
id v3; // rax
_CGLContextObject *v4; // r15
id v5; // rax
_CGLPixelFormatObject *v6; // rax
CVDisplayLinkCreateWithActiveCGDisplays(&self->displayLink);
CVDisplayLinkSetOutputCallback(self->displayLink, callback, self);
v2 = +[EAGLView sharedEGLView](&OBJC_CLASS___EAGLView, "sharedEGLView");
v3 = objc_msgSend(v2, "openGLContext");
v4 = (_CGLContextObject *)objc_msgSend(v3, "CGLContextObj");
v5 = objc_msgSend(v2, "pixelFormat");
v6 = (_CGLPixelFormatObject *)objc_msgSend(v5, "CGLPixelFormatObj");
CVDisplayLinkSetCurrentCGDisplayFromOpenGLContext(self->displayLink, v4, v6);
CVDisplayLinkStart(self->displayLink);
}