mirror of
https://github.com/izzy2lost/Diddy-Kong-Racing.git
synced 2026-06-19 01:16:26 -07:00
Match audioline_init (#497)
* Fix some AVOID_UB stuff, and some small documenting. * Fix m2ctx.py and add NON_EQUIV func_80045C48 * Minor issue cleanups * Clean up audioline_ambient_create match * Match func_80008040 as audioline_init, fix the generate ctx script, and some small warning stuff. * Minor work on func_80008174 so it can be NON_EQUIVALENT again * redefine asm abs * Hackishly fix the ctx file when generated. * Use some more constants and got rid of some start: auto stuff which is not recommended in splat anymore for BSS * Do some documenting, and slightly better matches using JFG source. * Formatting * Clean up some more audio stuff * Further cleanup and naming of things
This commit is contained in:
+27
-3
@@ -486,6 +486,7 @@ enum AL_MIDIstatus {
|
||||
|
||||
enum AL_MIDIctrl {
|
||||
AL_MIDI_VOLUME_CTRL = 0x07,
|
||||
AL_MIDI_UNK_8 = 0x08,
|
||||
AL_MIDI_PAN_CTRL = 0x0A,
|
||||
AL_MIDI_PRIORITY_CTRL = 0x10, /* use general purpose controller for priority */
|
||||
AL_MIDI_FX_CTRL_0 = 0x14,
|
||||
@@ -591,6 +592,28 @@ typedef struct {
|
||||
u8 chan;
|
||||
} ALOscEvent;
|
||||
|
||||
typedef struct ALSoundState {
|
||||
/* 0x00 */ struct ALSoundState *next;
|
||||
/* 0x04 */ struct ALSoundState *prev;
|
||||
/* 0x08 */ struct ALSoundState *unk8;
|
||||
/* 0x0C */ ALVoice voice;
|
||||
/* 0x28 */ ALSound *sound; /* sound referenced here */
|
||||
/* 0x2C */ s16 priority;
|
||||
/* 0x30 */ f32 pitch; /* current playback pitch */
|
||||
/* 0x34 */ u8 pad34[0x2];
|
||||
/* 0x34 */ u8 soundPriority;
|
||||
/* 0x38 */ s16 vol; /* volume - combined with volume from bank */
|
||||
/* 0x3A */ ALPan pan; /* pan - 0 = left, 127 = right */
|
||||
/* 0x3C */ u8 fxMix; /* wet/dry mix - 0 = dry, 127 = wet */
|
||||
/* 0x3C */ u8 pad3C[2];
|
||||
/* 0x3E */ u8 flags;
|
||||
/* 0x3F */ u8 soundState;
|
||||
} ALSoundState;
|
||||
|
||||
typedef struct {
|
||||
ALSoundState *soundState;
|
||||
} ALSoundEvent;
|
||||
|
||||
typedef struct {
|
||||
s16 type;
|
||||
union {
|
||||
@@ -601,10 +624,11 @@ typedef struct {
|
||||
ALVolumeEvent vol;
|
||||
ALSeqpLoopEvent loop;
|
||||
ALSeqpVolEvent spvol;
|
||||
ALSeqpPriorityEvent sppriority;
|
||||
ALSeqpSeqEvent spseq;
|
||||
ALSeqpBankEvent spbank;
|
||||
ALSeqpPriorityEvent sppriority;
|
||||
ALSeqpSeqEvent spseq;
|
||||
ALSeqpBankEvent spbank;
|
||||
ALOscEvent osc;
|
||||
ALSoundEvent sndpevent;
|
||||
} msg;
|
||||
} ALEvent;
|
||||
|
||||
|
||||
+3
-3
@@ -3,8 +3,8 @@
|
||||
|
||||
#define M_PI 3.14159265358979323846
|
||||
|
||||
f32 sinf(f32 x); //official name: fsin
|
||||
f32 cosf(f32 x);
|
||||
f32 sqrtf(f32 x);
|
||||
float sinf(float x); //official name: fsin
|
||||
float cosf(float x);
|
||||
float sqrtf(float x);
|
||||
|
||||
#endif
|
||||
|
||||
@@ -4,14 +4,14 @@
|
||||
#include "types.h"
|
||||
#include "structs.h"
|
||||
#include "macros.h"
|
||||
#include "save_layout.h"
|
||||
#include "src/save_data.h"
|
||||
#include "PR/os_cont.h"
|
||||
|
||||
/**
|
||||
* File contains the struct and macro definitions for the save layout for DKR.
|
||||
*/
|
||||
|
||||
#define NUMBER_OF_SAVE_FILES 3
|
||||
|
||||
#define TT_COURSES \
|
||||
unsigned courseAL : 1; \
|
||||
unsigned courseFC : 1; \
|
||||
|
||||
Reference in New Issue
Block a user