//
// kmGLMatrixMode from 0x5ca8f8 to 0x5ca936 (62 bytes)
//
// 10 xrefs:
// > cocos2d::CCDirector::setProjection @ 0x5c304a
// > cocos2d::CCDirector::setProjection @ 0x5c3076
// > cocos2d::CCDirector::setProjection @ 0x5c30a0
// > cocos2d::CCDirector::setProjection @ 0x5c30d4
// > cocos2d::CCGridBase::set2DProjection @ 0x5c7324
// > cocos2d::CCGridBase::set2DProjection @ 0x5c7350
// > cocos2d::CCRenderTexture::begin @ 0x5d8508
// > cocos2d::CCRenderTexture::begin @ 0x5d8514
// > cocos2d::CCRenderTexture::end @ 0x5d87c0
// > cocos2d::CCRenderTexture::end @ 0x5d87cc
//
// 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 __fastcall kmGLMatrixMode(int a1)
{
int (**v2)[2]; // r2
lazyInitialize();
switch ( a1 )
{
case 5889:
v2 = projection_matrix_stack_ptr;
break;
case 5890:
v2 = &texture_matrix_stack_ptr;
break;
case 5888:
v2 = modelview_matrix_stack_ptr;
break;
default:
return;
}
current_stack = (int)*v2;
}