mirror of
https://github.com/zeldaret/oot.git
synced 2025-07-12 02:44:54 +00:00
audio_heap: 1 non-matching (#381)
* Audio_AllocDmaMemory * Audio_AllocDmaMemoryZeroed * func_800DE238 * Audio_SessionPoolsInit * func_800DE2B0 * func_800DE258 * Audio_DiscardSequence * Audio_DiscardBank * func_800DE12C * Audio_ResetLoadStatus * func_800DDE3C * func_800DDE20 * Audio_InitMainPools * Audio_SoundAllocPoolInit * Audio_PersistentPoolClear * Audio_TemporaryPoolClear * func_800DE4A0 * Audio_PersistentPoolsInit * Audio_TemporaryPoolsInit * Formatting * Audio_SeqAndBankPoolInit * Audio_Alloc * Audio_AllocZeroed * func_800DE4B0 * func_800DF0CC * func_800DF074 * func_800DF1D8 * func_800DF688 * func_800DF5DC, func_800DF630 * func_800DF7BC * func_800DF7C4 * func_800DF888 * Fix AudioBufferParameters * Audio_ResetStep * Struct work * oops * structsss * wip on func_800DFBF8 * func_800E04E8 * func_800E0540 * func_800E0964 * func_800E1148 * func_800DF5AC * func_800E0E6C * func_800E0E90 * func_800E0BF8 * func_800E0634 * func_800E05C4 * func_800E0CBC * func_800E0C80 * naming * func_800E0BB4 * func_800E0AD8 * func_800E0E0C * func_800E0EB4 * func_800E06CC * Audio_AllocBankOrSeq * Use true/false macros * fixup * Format * comments * review * unk instrument -> sfx * Reword comment * Change AVOID_UB to a comment Co-authored-by: zelda2774 <zelda2774@invalid>
This commit is contained in:
parent
9018841660
commit
055d1d2bae
66 changed files with 1725 additions and 3420 deletions
|
@ -21,7 +21,7 @@ void Audio_SequenceChannelProcessSound(SequenceChannel* seqChannel, s32 recalcul
|
|||
chanFreqScale = seqChannel->freqScale;
|
||||
if (b != 0) {
|
||||
chanFreqScale *= seqChannel->seqPlayer->unk_34;
|
||||
seqChannel->changes.s.freqScale = 1;
|
||||
seqChannel->changes.s.freqScale = true;
|
||||
}
|
||||
|
||||
for (i = 0; i < 4; i++) {
|
||||
|
@ -31,7 +31,7 @@ void Audio_SequenceChannelProcessSound(SequenceChannel* seqChannel, s32 recalcul
|
|||
layer->noteFreqScale = layer->freqScale * chanFreqScale;
|
||||
layer->noteVelocity = layer->velocitySquare2 * seqChannel->appliedVolume;
|
||||
layer->notePan = (seqChannel->pan + layer->pan * (0x80 - seqChannel->panChannelWeight)) >> 7;
|
||||
layer->notePropertiesNeedInit = 0;
|
||||
layer->notePropertiesNeedInit = false;
|
||||
} else {
|
||||
if (seqChannel->changes.s.freqScale) {
|
||||
layer->noteFreqScale = layer->freqScale * chanFreqScale;
|
||||
|
@ -53,7 +53,7 @@ void Audio_SequencePlayerProcessSound(SequencePlayer* seqPlayer) {
|
|||
|
||||
if (seqPlayer->fadeTimer != 0) {
|
||||
seqPlayer->fadeVolume += seqPlayer->fadeVelocity;
|
||||
seqPlayer->recalculateVolume = 1;
|
||||
seqPlayer->recalculateVolume = true;
|
||||
|
||||
if (seqPlayer->fadeVolume > 1.0f) {
|
||||
seqPlayer->fadeVolume = 1.0f;
|
||||
|
@ -78,7 +78,7 @@ void Audio_SequencePlayerProcessSound(SequencePlayer* seqPlayer) {
|
|||
}
|
||||
}
|
||||
|
||||
seqPlayer->recalculateVolume = 0;
|
||||
seqPlayer->recalculateVolume = false;
|
||||
}
|
||||
|
||||
f32 Audio_GetPortamentoFreqScale(Portamento* p) {
|
||||
|
@ -258,7 +258,7 @@ f32 Audio_AdsrUpdate(AdsrState* adsr) {
|
|||
break;
|
||||
|
||||
default:
|
||||
adsr->delay *= gAudioContext.unk_286C;
|
||||
adsr->delay *= gAudioContext.gAudioBufferParameters.unk_24;
|
||||
if (adsr->delay == 0) {
|
||||
adsr->delay = 1;
|
||||
}
|
||||
|
@ -313,12 +313,12 @@ f32 Audio_AdsrUpdate(AdsrState* adsr) {
|
|||
|
||||
if (adsr->action.s.decay) {
|
||||
adsr->action.s.state = ADSR_STATE_DECAY;
|
||||
adsr->action.s.decay = 0;
|
||||
adsr->action.s.decay = false;
|
||||
}
|
||||
|
||||
if (adsr->action.s.release) {
|
||||
adsr->action.s.state = ADSR_STATE_RELEASE;
|
||||
adsr->action.s.release = 0;
|
||||
adsr->action.s.release = false;
|
||||
}
|
||||
|
||||
if (adsr->current < 0.0f) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue