{"type": "func", "start": 5369099600, "end": 5369099867, "name": "FMODAudioEngine::pitchForIdx", "pseudocode": "// \n// FMODAudioEngine::pitchForIdx from 0x14005f550 to 0x14005f65b (267 bytes)\n// \n// 20 xrefs:\n// > GameManager::playSFXTrigger @ 0x140276c6a\n// > GameManager::playSFXTrigger @ 0x140276cbc\n// > GameManager::playSFXTrigger @ 0x140276d66\n// > GameManager::playSFXTrigger @ 0x140276dba\n// > GameManager::playSFXTrigger @ 0x140276e02\n// > GameManager::playSFXTrigger @ 0x140276ec4\n// > GameManager::playSFXTrigger @ 0x140276f17\n// > GameManager::playSFXTrigger @ 0x140276f5f\n// > GJBaseGameLayer::activateSongTrigger @ 0x14034b987\n// > GJBaseGameLayer::applySFXEditTrigger @ 0x14034c362\n// > GJBaseGameLayer::activatedAudioTrigger @ 0x14034d16f\n// > GJBaseGameLayer::processActivatedAudioTriggers @ 0x14034dbeb\n// > GJBaseGameLayer::processActivatedAudioTriggers @ 0x14034edc6\n// > GJBaseGameLayer::processSongState @ 0x14034f7bc\n// > GJBaseGameLayer::processSongState @ 0x14034f913\n// > SetupSFXPopup::onClose @ 0x1405ddce1\n// > SetupSFXPopup::updateLength @ 0x1405ddddd\n// > SetupSFXPopup::createSFXWidget @ 0x1405de3ad\n// > SetupSongTriggerPopup::updateLength @ 0x1405f3184\n// > SetupSongTriggerPopup::onPlayback @ 0x1405f3657\n// \n// This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!\n// \n// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA\n// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings\n// Generated at Fri, 27 Nov 2026 11:25:43 +0000\n// \n\nfloat __fastcall FMODAudioEngine::pitchForIdx(int a1)\n{\n  float result; // xmm0_4\n\n  if ( !a1 )\n    return 1.0;\n  switch ( a1 )\n  {\n    case -12:\n      result = 0.5;\n      break;\n    case -11:\n      result = 0.52973157;\n      break;\n    case -10:\n      result = 0.56123102;\n      break;\n    case -9:\n      result = 0.59460354;\n      break;\n    case -8:\n      result = 0.62996054;\n      break;\n    case -7:\n      result = 0.66741991;\n      break;\n    case -6:\n      result = 0.70710677;\n      break;\n    case -5:\n      result = 0.74915355;\n      break;\n    case -4:\n      result = 0.79370052;\n      break;\n    case -3:\n      result = 0.84089643;\n      break;\n    case -2:\n      result = 0.8908987;\n      break;\n    case -1:\n      result = 0.9438743;\n      break;\n    case 1:\n      result = 1.0594631;\n      break;\n    case 2:\n      result = 1.1225621;\n      break;\n    case 3:\n      result = 1.1892071;\n      break;\n    case 4:\n      result = 1.2599211;\n      break;\n    case 5:\n      result = 1.3348398;\n      break;\n    case 6:\n      result = 1.4142135;\n      break;\n    case 7:\n      result = 1.4983071;\n      break;\n    case 8:\n      result = 1.587401;\n      break;\n    case 9:\n      result = 1.6817929;\n      break;\n    case 10:\n      result = 1.7817974;\n      break;\n    case 11:\n      result = 1.8877486;\n      break;\n    case 12:\n      result = 2.0;\n      break;\n    default:\n      return 1.0;\n  }\n  return result;\n}", "assembly": "; \n; FMODAudioEngine::pitchForIdx from 0x14005f550 to 0x14005f65b (267 bytes)\n; \n; 20 xrefs:\n; > GameManager::playSFXTrigger @ 0x140276c6a\n; > GameManager::playSFXTrigger @ 0x140276cbc\n; > GameManager::playSFXTrigger @ 0x140276d66\n; > GameManager::playSFXTrigger @ 0x140276dba\n; > GameManager::playSFXTrigger @ 0x140276e02\n; > GameManager::playSFXTrigger @ 0x140276ec4\n; > GameManager::playSFXTrigger @ 0x140276f17\n; > GameManager::playSFXTrigger @ 0x140276f5f\n; > GJBaseGameLayer::activateSongTrigger @ 0x14034b987\n; > GJBaseGameLayer::applySFXEditTrigger @ 0x14034c362\n; > GJBaseGameLayer::activatedAudioTrigger @ 0x14034d16f\n; > GJBaseGameLayer::processActivatedAudioTriggers @ 0x14034dbeb\n; > GJBaseGameLayer::processActivatedAudioTriggers @ 0x14034edc6\n; > GJBaseGameLayer::processSongState @ 0x14034f7bc\n; > GJBaseGameLayer::processSongState @ 0x14034f913\n; > SetupSFXPopup::onClose @ 0x1405ddce1\n; > SetupSFXPopup::updateLength @ 0x1405ddddd\n; > SetupSFXPopup::createSFXWidget @ 0x1405de3ad\n; > SetupSongTriggerPopup::updateLength @ 0x1405f3184\n; > SetupSongTriggerPopup::onPlayback @ 0x1405f3657\n; \n; This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!\n; \n; Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA\n; Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings\n; Generated at Fri, 27 Nov 2026 11:25:43 +0000\n; \ntest    ecx, ecx                                                       ; +0x0, 0x14005f550\njz      def_14005F578; jumptable 000000014005F578 default case, case 0 ; +0x2, 0x14005f552\nadd     ecx, 0Ch; switch 25 cases                                      ; +0x8, 0x14005f558\ncmp     ecx, 18h                                                       ; +0xb, 0x14005f55b\nja      def_14005F578; jumptable 000000014005F578 default case, case 0 ; +0xe, 0x14005f55e\nmovsxd  rax, ecx                                                       ; +0x14, 0x14005f564\nlea     rdx, cs:140000000h                                             ; +0x17, 0x14005f567\nmov     ecx, ds:(jpt_14005F578 - 140000000h)[rdx+rax*4]                ; +0x1e, 0x14005f56e\nadd     rcx, rdx                                                       ; +0x25, 0x14005f575\njmp     rcx; switch jump                                               ; +0x28, 0x14005f578\nmovss   xmm0, cs:dword_140834F20; jumptable 000000014005F578 case -12  ; +0x2a, 0x14005f57a\nretn                                                                   ; +0x32, 0x14005f582\nmovss   xmm0, cs:dword_140834F30; jumptable 000000014005F578 case -11  ; +0x33, 0x14005f583\nretn                                                                   ; +0x3b, 0x14005f58b\nmovss   xmm0, cs:dword_140834F48; jumptable 000000014005F578 case -10  ; +0x3c, 0x14005f58c\nretn                                                                   ; +0x44, 0x14005f594\nmovss   xmm0, cs:dword_140834F60; jumptable 000000014005F578 case -9   ; +0x45, 0x14005f595\nretn                                                                   ; +0x4d, 0x14005f59d\nmovss   xmm0, cs:dword_140834F84; jumptable 000000014005F578 case -8   ; +0x4e, 0x14005f59e\nretn                                                                   ; +0x56, 0x14005f5a6\nmovss   xmm0, cs:dword_140834FA4; jumptable 000000014005F578 case -7   ; +0x57, 0x14005f5a7\nretn                                                                   ; +0x5f, 0x14005f5af\nmovss   xmm0, cs:dword_140834FB0; jumptable 000000014005F578 case -6   ; +0x60, 0x14005f5b0\nretn                                                                   ; +0x68, 0x14005f5b8\nmovss   xmm0, cs:dword_140834FC8; jumptable 000000014005F578 case -5   ; +0x69, 0x14005f5b9\nretn                                                                   ; +0x71, 0x14005f5c1\nmovss   xmm0, cs:dword_140834FE4; jumptable 000000014005F578 case -4   ; +0x72, 0x14005f5c2\nretn                                                                   ; +0x7a, 0x14005f5ca\nmovss   xmm0, cs:dword_14083500C; jumptable 000000014005F578 case -3   ; +0x7b, 0x14005f5cb\nretn                                                                   ; +0x83, 0x14005f5d3\nmovss   xmm0, cs:dword_140835028; jumptable 000000014005F578 case -2   ; +0x84, 0x14005f5d4\nretn                                                                   ; +0x8c, 0x14005f5dc\nmovss   xmm0, cs:dword_140835048; jumptable 000000014005F578 case -1   ; +0x8d, 0x14005f5dd\nretn                                                                   ; +0x95, 0x14005f5e5\nmovss   xmm0, cs:dword_1408350A4; jumptable 000000014005F578 case 1    ; +0x96, 0x14005f5e6\nretn                                                                   ; +0x9e, 0x14005f5ee\nmovss   xmm0, cs:dword_1408350B4; jumptable 000000014005F578 case 2    ; +0x9f, 0x14005f5ef\nretn                                                                   ; +0xa7, 0x14005f5f7\nmovss   xmm0, cs:dword_1408350D8; jumptable 000000014005F578 case 3    ; +0xa8, 0x14005f5f8\nretn                                                                   ; +0xb0, 0x14005f600\nmovss   xmm0, cs:dword_1408350F8; jumptable 000000014005F578 case 4    ; +0xb1, 0x14005f601\nretn                                                                   ; +0xb9, 0x14005f609\nmovss   xmm0, cs:dword_140835120; jumptable 000000014005F578 case 5    ; +0xba, 0x14005f60a\nretn                                                                   ; +0xc2, 0x14005f612\nmovss   xmm0, cs:dword_14083513C; jumptable 000000014005F578 case 6    ; +0xc3, 0x14005f613\nretn                                                                   ; +0xcb, 0x14005f61b\nmovss   xmm0, cs:dword_140835160; jumptable 000000014005F578 case 7    ; +0xcc, 0x14005f61c\nretn                                                                   ; +0xd4, 0x14005f624\nmovss   xmm0, cs:dword_140835184; jumptable 000000014005F578 case 8    ; +0xd5, 0x14005f625\nretn                                                                   ; +0xdd, 0x14005f62d\nmovss   xmm0, cs:dword_1408351C8; jumptable 000000014005F578 case 9    ; +0xde, 0x14005f62e\nretn                                                                   ; +0xe6, 0x14005f636\nmovss   xmm0, cs:dword_140835218; jumptable 000000014005F578 case 10   ; +0xe7, 0x14005f637\nretn                                                                   ; +0xef, 0x14005f63f\nmovss   xmm0, cs:dword_140835290; jumptable 000000014005F578 case 11   ; +0xf0, 0x14005f640\nretn                                                                   ; +0xf8, 0x14005f648\nmovss   xmm0, cs:width; jumptable 000000014005F578 case 12             ; +0xf9, 0x14005f649\nretn                                                                   ; +0x101, 0x14005f651\nmovss   xmm0, cs:flt_140835080; jumptable 000000014005F578 default case, case 0 ; +0x102, 0x14005f652\nretn                                                                   ; +0x10a, 0x14005f65a", "xrefs": ["GameManager::playSFXTrigger @ 0x140276c6a", "GameManager::playSFXTrigger @ 0x140276cbc", "GameManager::playSFXTrigger @ 0x140276d66", "GameManager::playSFXTrigger @ 0x140276dba", "GameManager::playSFXTrigger @ 0x140276e02", "GameManager::playSFXTrigger @ 0x140276ec4", "GameManager::playSFXTrigger @ 0x140276f17", "GameManager::playSFXTrigger @ 0x140276f5f", "GJBaseGameLayer::activateSongTrigger @ 0x14034b987", "GJBaseGameLayer::applySFXEditTrigger @ 0x14034c362", "GJBaseGameLayer::activatedAudioTrigger @ 0x14034d16f", "GJBaseGameLayer::processActivatedAudioTriggers @ 0x14034dbeb", "GJBaseGameLayer::processActivatedAudioTriggers @ 0x14034edc6", "GJBaseGameLayer::processSongState @ 0x14034f7bc", "GJBaseGameLayer::processSongState @ 0x14034f913", "SetupSFXPopup::onClose @ 0x1405ddce1", "SetupSFXPopup::updateLength @ 0x1405ddddd", "SetupSFXPopup::createSFXWidget @ 0x1405de3ad", "SetupSongTriggerPopup::updateLength @ 0x1405f3184", "SetupSongTriggerPopup::onPlayback @ 0x1405f3657"], "is_objc": false, "is_32_bit": false, "is_64_bit": true, "idp_name": "pc", "bida_info": "8.3.0 @ https://github.com/Stazzical/BromaIDA", "bindings_info": "commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings"}