// // Generated By: dol2asm // Translation Unit: JASLfo // #include "JSystem/JAudio2/JASLfo.h" #include "SSystem/SComponent/c_math.h" // // Types: // // // Forward References: // // // External References: // // // Declarations: // /* ############################################################################################## */ /* 8029BD14-8029BD44 296654 0030+00 1/1 1/1 0/0 .text __ct__6JASLfoFv */ JASLfo::JASLfo() { field_0x0 = 0; field_0x4 = 1; field_0x8 = 0.0f; mDepth = 0.0f; mPitch = 1.0f; mDelay = 0; field_0x16 = 0; } /* ############################################################################################## */ /* 8029BD44-8029BDD8 296684 0094+00 0/0 3/3 0/0 .text getValue__6JASLfoCFv */ f32 JASLfo::getValue() const { if (field_0x16) { return 0.0f; } if (mDepth == 0.0f) { return 0.0f; } return mDepth * JMASinLap(field_0x8); } /* ############################################################################################## */ /* 8029BDD8-8029BE2C 296718 0054+00 0/0 2/2 0/0 .text incCounter__6JASLfoFf */ void JASLfo::incCounter(f32 param_0) { if (field_0x16) { field_0x16--; return; } field_0x8 += param_0 * ((1.0f / 72.0f) * mPitch); if (field_0x8 >= 1.0f) { field_0x8 -= 1.0f; } } /* ############################################################################################## */ /* 80431C40-80431C58 05E960 0018+00 2/2 1/1 0/0 .bss sFreeRunLfo__6JASLfo */ JASLfo JASLfo::sFreeRunLfo; /* 8029BE2C-8029BE6C 29676C 0040+00 0/0 1/1 0/0 .text resetCounter__6JASLfoFv */ void JASLfo::resetCounter() { field_0x16 = mDelay; switch (field_0x4) { case 0: field_0x8 = sFreeRunLfo.field_0x8; break; case 1: field_0x8 = 0.0f; break; } } /* 8029BE6C-8029BE94 2967AC 0028+00 0/0 1/0 0/0 .text __sinit_JASLfo_cpp */