; ; cocos2d::CCRenderTexture::begin from 0x18005f3a0 to 0x18005f636 (662 bytes) ; ; 9 xrefs: ; > cocos2d::CCTransitionCrossFade::onEnter @ 0x180054c73 ; > cocos2d::CCTransitionCrossFade::onEnter @ 0x180054d2a ; > cocos2d::CCTransitionProgress::onEnter @ 0x180057670 ; > cocos2d::CCRenderTexture::beginWithClear @ 0x18005f672 ; > cocos2d::CCRenderTexture::clearDepth @ 0x18005f8f5 ; > cocos2d::CCRenderTexture::draw @ 0x18005fbba ; > cocos2d::CCRenderTexture::newCCImage @ 0x180060373 ; > @ 0x1801438a8 ; > @ 0x1801b3384 ; ; 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 ; mov rax, rsp ; +0x0, 0x18005f3a0 mov [rax+10h], rbx ; +0x3, 0x18005f3a3 push rdi ; +0x7, 0x18005f3a7 sub rsp, 0E0h ; +0x8, 0x18005f3a8 movaps xmmword ptr [rax-18h], xmm6 ; +0xf, 0x18005f3af movaps xmmword ptr [rax-28h], xmm7 ; +0x13, 0x18005f3b3 mov rax, cs:__security_cookie ; +0x17, 0x18005f3b7 xor rax, rsp ; +0x1e, 0x18005f3be mov [rsp+0E8h+var_38], rax ; +0x21, 0x18005f3c1 mov rbx, rcx ; +0x29, 0x18005f3c9 mov ecx, 1701h ; +0x2c, 0x18005f3cc call kmGLMatrixMode ; +0x31, 0x18005f3d1 call kmGLPushMatrix ; +0x36, 0x18005f3d6 mov ecx, 1700h ; +0x3b, 0x18005f3db call kmGLMatrixMode ; +0x40, 0x18005f3e0 call kmGLPushMatrix ; +0x45, 0x18005f3e5 call ?sharedDirector@CCDirector@cocos2d@@SAPEAV12@XZ; cocos2d::CCDirector::sharedDirector(void) ; +0x4a, 0x18005f3ea mov rdi, rax ; +0x4f, 0x18005f3ef mov edx, [rax+134h] ; +0x52, 0x18005f3f2 mov rcx, rax ; +0x58, 0x18005f3f8 call ?setProjection@CCDirector@cocos2d@@QEAAXW4ccDirectorProjection@2@@Z; cocos2d::CCDirector::setProjection(cocos2d::ccDirectorProjection) ; +0x5b, 0x18005f3fb mov rcx, [rbx+158h]; this ; +0x60, 0x18005f400 call ?getContentSizeInPixels@CCTexture2D@cocos2d@@QEAAAEBVCCSize@2@XZ; cocos2d::CCTexture2D::getContentSizeInPixels(void) ; +0x67, 0x18005f407 mov rdx, rax ; +0x6c, 0x18005f40c lea rcx, [rsp+0E8h+var_A8] ; +0x6f, 0x18005f40f call ??4cc_timeval@cocos2d@@QEAAAEAU01@$$QEAU01@@Z; cocos2d::cc_timeval::operator=(cocos2d::cc_timeval &&) ; +0x74, 0x18005f414 movss xmm0, dword ptr [rbx+194h] ; +0x79, 0x18005f419 xorps xmm6, xmm6 ; +0x81, 0x18005f421 comiss xmm0, xmm6 ; +0x84, 0x18005f424 jbe short loc_18005F43A ; +0x87, 0x18005f427 mulss xmm0, [rsp+0E8h+var_A8]; X ; +0x89, 0x18005f429 call roundf ; +0x8f, 0x18005f42f movss [rsp+0E8h+var_A8], xmm0 ; +0x94, 0x18005f434 movss xmm0, dword ptr [rbx+198h] ; +0x9a, 0x18005f43a comiss xmm0, xmm6 ; +0xa2, 0x18005f442 jbe short loc_18005F458 ; +0xa5, 0x18005f445 mulss xmm0, [rsp+0E8h+var_A4]; X ; +0xa7, 0x18005f447 call roundf ; +0xad, 0x18005f44d movss [rsp+0E8h+var_A4], xmm0 ; +0xb2, 0x18005f452 lea rdx, [rsp+0E8h+var_A0] ; +0xb8, 0x18005f458 mov rcx, rdi ; +0xbd, 0x18005f45d call ?getWinSizeInPixels@CCDirector@cocos2d@@QEAA?AVCCSize@2@XZ; cocos2d::CCDirector::getWinSizeInPixels(void) ; +0xc0, 0x18005f460 movss xmm7, [rsp+0E8h+var_A0] ; +0xc5, 0x18005f465 divss xmm7, [rsp+0E8h+var_A8] ; +0xcb, 0x18005f46b movss xmm6, [rsp+0E8h+var_9C] ; +0xd1, 0x18005f471 divss xmm6, [rsp+0E8h+var_A4] ; +0xd7, 0x18005f477 cvttss2si r9d, [rsp+0E8h+var_A4]; height ; +0xdd, 0x18005f47d cvttss2si r8d, [rsp+0E8h+var_A8]; width ; +0xe4, 0x18005f484 xor edx, edx; y ; +0xeb, 0x18005f48b xor ecx, ecx; x ; +0xed, 0x18005f48d call cs:glViewport ; +0xef, 0x18005f48f movss xmm4, cs:flt_1800E61A8 ; +0xf5, 0x18005f495 movaps xmm5, xmm4 ; +0xfd, 0x18005f49d divss xmm5, xmm6 ; +0x100, 0x18005f4a0 movss xmm0, cs:dword_1800E6B20 ; +0x104, 0x18005f4a4 movaps xmm3, xmm0 ; +0x10c, 0x18005f4ac divss xmm3, xmm6 ; +0x10f, 0x18005f4af movaps xmm2, xmm4 ; +0x113, 0x18005f4b3 divss xmm2, xmm7 ; +0x116, 0x18005f4b6 movaps xmm1, xmm0 ; +0x11a, 0x18005f4ba divss xmm1, xmm7 ; +0x11d, 0x18005f4bd movss [rsp+0E8h+var_B8], xmm4 ; +0x121, 0x18005f4c1 movss [rsp+0E8h+var_C0], xmm0 ; +0x127, 0x18005f4c7 movss [rsp+0E8h+var_C8], xmm5 ; +0x12d, 0x18005f4cd lea rcx, [rsp+0E8h+var_78] ; +0x133, 0x18005f4d3 call kmMat4OrthographicProjection ; +0x138, 0x18005f4d8 lea rcx, [rsp+0E8h+var_78] ; +0x13d, 0x18005f4dd call kmGLMultMatrix ; +0x142, 0x18005f4e2 lea rdx, [rbx+150h]; params ; +0x147, 0x18005f4e7 mov ecx, 8CA6h; pname ; +0x14e, 0x18005f4ee call cs:glGetIntegerv ; +0x153, 0x18005f4f3 mov edx, [rbx+148h] ; +0x159, 0x18005f4f9 mov ecx, 8D40h ; +0x15f, 0x18005f4ff mov rax, cs:__glewBindFramebuffer ; +0x164, 0x18005f504 call qword ptr [rax] ; +0x16b, 0x18005f50b xorps xmm0, xmm0 ; +0x16d, 0x18005f50d movups xmmword ptr [rsp+0E8h+Block], xmm0 ; +0x170, 0x18005f510 mov [rsp+0E8h+var_88], 7 ; +0x175, 0x18005f515 mov [rsp+0E8h+var_80], 0Fh ; +0x17e, 0x18005f51e mov rax, cs:qword_1800F9FD8 ; +0x187, 0x18005f527 mov dword ptr [rsp+0E8h+Block], eax ; +0x18e, 0x18005f52e movzx eax, word ptr cs:qword_1800F9FD8+4 ; +0x192, 0x18005f532 mov word ptr [rsp+0E8h+Block+4], ax ; +0x199, 0x18005f539 movzx eax, byte ptr cs:qword_1800F9FD8+6 ; +0x19e, 0x18005f53e mov byte ptr [rsp+0E8h+Block+6], al ; +0x1a5, 0x18005f545 mov byte ptr [rsp+0E8h+Block+7], 0 ; +0x1a9, 0x18005f549 call ?sharedConfiguration@CCConfiguration@cocos2d@@SAPEAV12@XZ; cocos2d::CCConfiguration::sharedConfiguration(void) ; +0x1ae, 0x18005f54e mov rcx, rax ; +0x1b3, 0x18005f553 lea rdx, [rsp+0E8h+Block] ; +0x1b6, 0x18005f556 call ?checkForGLExtension@CCConfiguration@cocos2d@@QEBA_NAEBV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z; cocos2d::CCConfiguration::checkForGLExtension(std::string const &) ; +0x1bb, 0x18005f55b movzx edi, al ; +0x1c0, 0x18005f560 mov rdx, [rsp+0E8h+var_80] ; +0x1c3, 0x18005f563 cmp rdx, 0Fh ; +0x1c8, 0x18005f568 jbe short loc_18005F5A3 ; +0x1cc, 0x18005f56c inc rdx ; +0x1ce, 0x18005f56e mov rcx, [rsp+0E8h+Block]; Block ; +0x1d1, 0x18005f571 mov rax, rcx ; +0x1d6, 0x18005f576 cmp rdx, 1000h ; +0x1d9, 0x18005f579 jb short loc_18005F59E ; +0x1e0, 0x18005f580 add rdx, 27h ; ''' ; +0x1e2, 0x18005f582 mov rcx, [rcx-8] ; +0x1e6, 0x18005f586 sub rax, rcx ; +0x1ea, 0x18005f58a add rax, 0FFFFFFFFFFFFFFF8h ; +0x1ed, 0x18005f58d cmp rax, 1Fh ; +0x1f1, 0x18005f591 jbe short loc_18005F59E ; +0x1f5, 0x18005f595 call cs:_invalid_parameter_noinfo_noreturn ; +0x1f7, 0x18005f597 align 2 ; +0x1fd, 0x18005f59d call j_j_free_0 ; +0x1fe, 0x18005f59e test dil, dil ; +0x203, 0x18005f5a3 jz short loc_18005F60B ; +0x206, 0x18005f5a6 mov rcx, [rbx+160h] ; +0x208, 0x18005f5a8 mov rax, [rcx] ; +0x20f, 0x18005f5af call qword ptr [rax+60h] ; +0x212, 0x18005f5b2 mov r9d, eax ; +0x215, 0x18005f5b5 xor edi, edi ; +0x218, 0x18005f5b8 mov [rsp+0E8h+var_C8], edi ; +0x21a, 0x18005f5ba mov edx, 8CE0h ; +0x21e, 0x18005f5be lea ecx, [rdx+60h] ; +0x223, 0x18005f5c3 mov r8d, 0DE1h ; +0x226, 0x18005f5c6 mov rax, cs:__glewFramebufferTexture2D ; +0x22c, 0x18005f5cc call qword ptr [rax] ; +0x233, 0x18005f5d3 mov ecx, 4100h; mask ; +0x235, 0x18005f5d5 call cs:glClear ; +0x23a, 0x18005f5da mov rcx, [rbx+158h] ; +0x240, 0x18005f5e0 mov rax, [rcx] ; +0x247, 0x18005f5e7 call qword ptr [rax+60h] ; +0x24a, 0x18005f5ea mov r9d, eax ; +0x24d, 0x18005f5ed mov [rsp+0E8h+var_C8], edi ; +0x250, 0x18005f5f0 mov edx, 8CE0h ; +0x254, 0x18005f5f4 lea ecx, [rdx+60h] ; +0x259, 0x18005f5f9 mov r8d, 0DE1h ; +0x25c, 0x18005f5fc mov rax, cs:__glewFramebufferTexture2D ; +0x262, 0x18005f602 call qword ptr [rax] ; +0x269, 0x18005f609 mov rcx, [rsp+0E8h+var_38] ; +0x26b, 0x18005f60b xor rcx, rsp; StackCookie ; +0x273, 0x18005f613 call __security_check_cookie ; +0x276, 0x18005f616 lea r11, [rsp+0E8h+var_8] ; +0x27b, 0x18005f61b mov rbx, [r11+18h] ; +0x283, 0x18005f623 movaps xmm6, xmmword ptr [r11-10h] ; +0x287, 0x18005f627 movaps xmm7, xmmword ptr [r11-20h] ; +0x28c, 0x18005f62c mov rsp, r11 ; +0x291, 0x18005f631 pop rdi ; +0x294, 0x18005f634 retn ; +0x295, 0x18005f635