//
// SetupShaderEffectPopup::setupGrayscale from 0x68c8cc to 0x68cb80 (692 bytes)
//
// 1 xrefs:
// > SetupShaderEffectPopup::init @ 0x68de8c
//
// This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!
//
// 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:56:09 +0000
//
int __fastcall SetupShaderEffectPopup::setupGrayscale(cocos2d::CCDictionary **this)
{
cocos2d::CCDirector *v2; // r0
float v4[2]; // [sp+34h] [bp-40h] BYREF
_BYTE v5[8]; // [sp+3Ch] [bp-38h] BYREF
_BYTE v6[8]; // [sp+44h] [bp-30h] BYREF
_BYTE v7[8]; // [sp+4Ch] [bp-28h] BYREF
int v8[3]; // [sp+54h] [bp-20h] BYREF
int v9; // [sp+60h] [bp-14h] BYREF
int v10; // [sp+64h] [bp-10h]
int v11; // [sp+68h] [bp-Ch]
v9 = 0;
v10 = 0;
v11 = 0;
std::string::__init(&v9, "Setup Grayscale", 0xFu);
SetupTriggerPopup::addTitle((int)this, (unsigned __int8 *)&v9);
std::string::~string((int)&v9);
memset(v8, 0, sizeof(v8));
std::string::__init(v8, "Help", 4u);
v9 = 0;
v10 = 0;
v11 = 0;
std::string::__init(
&v9,
"Applies a grayscale filter to the screen.\n"
"Target is how much of the filter to apply.\n"
"FadeTime is time until final state is reached.\n"
"Tint Channel lets you set a color channel to tint towards.\n"
"UseLum uses a different conversion to grayscale.",
0x117u);
SetupTriggerPopup::addHelpButton((int)this, (int)v8, (int)&v9, 1065353216);
std::string::~string((int)&v9);
v2 = (cocos2d::CCDirector *)std::string::~string((int)v8);
cocos2d::CCDirector::sharedDirector(v2);
cocos2d::CCDirector::getWinSize((cocos2d::CCDirector *)v4);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v5, v4[0] * 0.5, (float)(v4[1] * 0.5) + 85.0);
v9 = 0;
v10 = 0;
v11 = 0;
std::string::__init(&v9, "Target:", 7u);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v6, -100.0, 0.0);
cocos2d::CCPoint::operator+(v7, v5, v6);
SetupTriggerPopup::createValueControl(this, 176, (int)&v9, (const cocos2d::CCPoint *)v7, 1060320051, 0, 0);
std::string::~string((int)&v9);
v9 = 0;
v10 = 0;
v11 = 0;
std::string::__init(&v9, "FadeTime:", 9u);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v6, 100.0, 0.0);
cocos2d::CCPoint::operator+(v7, v5, v6);
SetupTriggerPopup::createValueControl(this, 10, (int)&v9, (const cocos2d::CCPoint *)v7, 1060320051, 0, 0);
std::string::~string((int)&v9);
v9 = 0;
v10 = 0;
v11 = 0;
std::string::__init(&v9, "UseLum", 6u);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v6, 55.0, -55.0);
cocos2d::CCPoint::operator+(v7, v5, v6);
SetupTriggerPopup::createToggleValueControl((int)this, 188, (int)&v9, (const cocos2d::CCPoint *)v7, 0, 0, 0, 1.0);
std::string::~string((int)&v9);
v9 = 0;
v10 = 0;
v11 = 0;
std::string::__init(&v9, " ", 1u);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v6, -24.0, -55.0);
cocos2d::CCPoint::operator+(v7, v5, v6);
SetupTriggerPopup::createToggleValueControl((int)this, 190, (int)&v9, (const cocos2d::CCPoint *)v7, 0, 0, 0, 1.0);
std::string::~string((int)&v9);
v9 = 0;
v10 = 0;
v11 = 0;
std::string::__init(&v9, "Tint\nChannel:", 0xDu);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v6, -100.0, -55.0);
cocos2d::CCPoint::operator+(v7, v5, v6);
SetupTriggerPopup::createValueControlAdvanced(
this,
51,
(unsigned __int8 *)&v9,
(int)v7,
1060320051,
1,
2,
6,
0,
0,
0,
0,
0,
0,
2,
0);
std::string::~string((int)&v9);
cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)v6, 0.0, -100.0);
cocos2d::CCPoint::operator+(v7, v5, v6);
return SetupTriggerPopup::createEasingControls((int)this, (int)v7, 1.0, 0, 0);
}