Skip to content

Commit

Permalink
audio_seqplayer.c cleanup (zeldaret#1274)
Browse files Browse the repository at this point in the history
* Audio Seqplayer Cleanup

* More

* Edit description

* PR Suggestions

* while true

* Cleanup function declarations

* Extra space, oops

* Small fix

* PR Suggestions

* tatums per beat

* Edit comment
  • Loading branch information
engineer124 authored and louist103 committed Jan 3, 2023
1 parent 9d729dc commit 249a2a0
Show file tree
Hide file tree
Showing 4 changed files with 676 additions and 593 deletions.
1 change: 1 addition & 0 deletions include/z64audio.h
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
#define TATUMS_PER_BEAT 48

#define IS_SEQUENCE_CHANNEL_VALID(ptr) ((u32)(ptr) != (u32)&gAudioContext.sequenceChannelNone)
#define SEQ_NUM_CHANNELS 16

#define MAX_CHANNELS_PER_BANK 3

Expand Down
2 changes: 1 addition & 1 deletion src/code/audio_load.c
Original file line number Diff line number Diff line change
Expand Up @@ -1844,7 +1844,7 @@ s32 AudioLoad_ProcessSamplePreloads(s32 resetStatus) {

// Pop requests with isFree = true off the stack, as far as possible,
// and dispatch the next DMA.
for (;;) {
while (true) {
if (gAudioContext.preloadSampleStackTop <= 0) {
break;
}
Expand Down
2 changes: 1 addition & 1 deletion src/code/audio_playback.c
Original file line number Diff line number Diff line change
Expand Up @@ -652,7 +652,7 @@ void Audio_NotePoolClear(NotePool* pool) {
break;
}

for (;;) {
while (true) {
cur = source->next;
if (cur == source || cur == NULL) {
break;
Expand Down
Loading

0 comments on commit 249a2a0

Please sign in to comment.