//
// SetupShaderEffectPopup::setupChromatic from 0x1405e34e0 to 0x1405e3a5d (1405 bytes)
//
// 2 xrefs:
// > SetupShaderEffectPopup::init @ 0x1405dfad0
// > ??> @ 0x14092ee38
//
// This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!
//
// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings
// Generated at Fri, 27 Nov 2026 11:35:01 +0000
//
// Hidden C++ exception states: #wind=3
double __fastcall SetupShaderEffectPopup::setupChromatic(__int64 a1)
{
__int64 v2; // rcx
__int64 v3; // rax
__int64 v4; // rax
__int64 v5; // rax
__int64 v6; // rax
__int64 v7; // rax
__int64 v8; // rax
int v9; // eax
__int64 v10; // rax
int v11; // r8d
int v12; // r9d
__int128 *v14; // [rsp+48h] [rbp-59h] BYREF
__int128 *v15; // [rsp+50h] [rbp-51h] BYREF
__int128 v16; // [rsp+58h] [rbp-49h] BYREF
__int64 v17; // [rsp+68h] [rbp-39h]
__int64 v18; // [rsp+70h] [rbp-31h]
__int128 v19; // [rsp+78h] [rbp-29h] BYREF
__int64 v20; // [rsp+88h] [rbp-19h]
__int64 v21; // [rsp+90h] [rbp-11h]
char v22; // [rsp+110h] [rbp+6Fh] BYREF
float v23; // [rsp+118h] [rbp+77h] BYREF
float v24; // [rsp+11Ch] [rbp+7Bh]
__int128 *v25; // [rsp+120h] [rbp+7Fh] BYREF
v17 = 15;
v18 = 15;
strcpy((char *)&v16, "Setup Chromatic");
SetupTriggerPopup::addTitle(a1, &v16);
v25 = &v16;
v16 = 0;
v17 = 0;
v18 = 0;
*(_QWORD *)&v16 = sub_14003D460(0xD0u);
v17 = 202;
v18 = 207;
strcpy(
(char *)v16,
"Applies chromatic aberration.\n"
"Use X and Y sets which axis is affected.\n"
"TargetX and TargetY define how strong the effect is.\n"
"FadeTime is time until final state is reached.");
v19 = 0;
v20 = 4;
v21 = 15;
strcpy((char *)&v19, "Help");
SetupTriggerPopup::addHelpButton(a1, &v19, &v16);
v3 = cocos2d::CCDirector::sharedDirector(v2);
cocos2d::CCDirector::getWinSize(v3, &v23);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v22, v23 * 0.5, (float)(v24 * 0.5) + 85.0);
v14 = &v19;
v20 = 8;
v21 = 15;
v19 = 0x3A58746567726154uLL;
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v15, -100.0, 0.0);
cocos2d::CCPoint::operator+(&v22, &v25, v4);
SetupTriggerPopup::createValueControl(a1, 180, (unsigned int)&v19, (unsigned int)&v25, 1060320051, 0, 1084227584);
v15 = &v19;
v20 = 8;
v21 = 15;
v19 = 0x3A59746567726154uLL;
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v14, 100.0, 0.0);
cocos2d::CCPoint::operator+(&v22, &v25, v5);
SetupTriggerPopup::createValueControl(a1, 189, (unsigned int)&v19, (unsigned int)&v25, 1060320051, 0, 1084227584);
v15 = &v16;
*((_QWORD *)&v16 + 1) = 58;
v17 = 9;
v18 = 15;
*(_QWORD *)&v16 = 0x656D695465646146LL;
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v14, -100.0, -50.0);
cocos2d::CCPoint::operator+(&v22, &v25, v6);
SetupTriggerPopup::createValueControl(a1, 10, (unsigned int)&v16, (unsigned int)&v25, 1060320051, 0, 0);
v15 = &v16;
v16 = 0;
v17 = 5;
v18 = 15;
strcpy((char *)&v16, "Use X");
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v14, 45.0, -55.0);
cocos2d::CCPoint::operator+(&v22, &v25, v7);
SetupTriggerPopup::createToggleValueControl(a1, 188, (unsigned int)&v16, (unsigned int)&v25, 0, 0, 0, 1065353216);
v15 = &v16;
v16 = 0;
v17 = 5;
v18 = 15;
strcpy((char *)&v16, "Use Y");
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v14, 130.0, -55.0);
cocos2d::CCPoint::operator+(&v22, &v25, v8);
SetupTriggerPopup::createToggleValueControl(a1, 190, (unsigned int)&v16, (unsigned int)&v25, 0, 0, 0, 1065353216);
v25 = &v19;
v20 = 8;
v21 = 15;
v19 = 0x65766974616C6552uLL;
cocos2d::CCPoint::CCPoint(
(cocos2d::CCPoint *)&v15,
(float)((float)((float)(*(float *)(a1 + 732) * 0.5) + (float)(v23 * 0.5)) - 72.0) - 90.0,
(float)((float)(v24 * 0.5) - (float)(*(float *)(a1 + 736) * 0.5)) + 20.0);
SetupTriggerPopup::createToggleValueControl(a1, 514, (unsigned int)&v19, v9, 0, 0, 0, 1065353216);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v15, 0.0, -100.0);
cocos2d::CCPoint::operator+(&v22, &v25, v10);
return SetupTriggerPopup::createEasingControls(a1, (unsigned int)&v25, v11, v12, 0);
}