1
0
Fork 0
mirror of https://github.com/zeldaret/oot.git synced 2025-08-11 09:20:17 +00:00

Partially label audio_synthesis

To some extent copied from sm64.
This commit is contained in:
zelda2774 2021-08-24 12:47:22 +02:00
parent df800139af
commit 6c76c1875d
5 changed files with 336 additions and 365 deletions

View file

@ -339,45 +339,23 @@ typedef short ENVMIX_STATE[40];
_a->words.w1 = (unsigned int)(c); \
}
/*
#define aEnvMixer(pkt, f, s) \
#define aEnvMixer(pkt, dmemi, count, swapLR, x0, x1, x2, x3, m, bits) \
{ \
Acmd *_a = (Acmd *)pkt; \
\
_a->words.w0 = _SHIFTL(A_ENVMIXER, 24, 8) | _SHIFTL(f, 16, 8); \
_a->words.w1 = (unsigned int)(s); \
}
*/
extern u32 D_801304A0;
#define aEnvMixer(pkt, dmemi, count, swapLR, x0, x1, x2, x3, m) \
{ \
Acmd *_a = (Acmd *)pkt; \
\
_a->words.w0 = (D_801304A0 | _SHIFTL(dmemi >> 4, 16, 8) | \
_a->words.w0 = (bits | _SHIFTL(dmemi >> 4, 16, 8) | \
_SHIFTL(count, 8, 8) | _SHIFTL(swapLR, 4, 1) | \
_SHIFTL(x0, 3, 1) | _SHIFTL(x1, 2, 1) | \
_SHIFTL(x2, 1, 1) | _SHIFTL(x3, 0, 1)); \
_a->words.w1 = (unsigned int)(m); \
}
/*
#define aInterleave(pkt, l, r) \
{ \
Acmd *_a = (Acmd *)pkt; \
\
_a->words.w0 = _SHIFTL(A_INTERLEAVE, 24, 8); \
_a->words.w1 = _SHIFTL(l, 16, 16) | _SHIFTL(r, 0, 16); \
}
*/
#define aInterleave(pkt, count, d, l, r) \
#define aInterleave(pkt, o, l, r, c) \
{ \
Acmd *_a = (Acmd *)pkt; \
\
_a->words.w0 = (_SHIFTL(A_INTERLEAVE, 24, 8) | \
_SHIFTL(count >> 4, 16, 8) | _SHIFTL(d, 0, 16)); \
_SHIFTL(c >> 4, 16, 8) | _SHIFTL(o, 0, 16)); \
_a->words.w1 = _SHIFTL(l, 16, 16) | _SHIFTL(r, 0, 16); \
}
@ -390,16 +368,6 @@ extern u32 D_801304A0;
_a->words.w1 = _SHIFTL(dmemi, 16, 16) | _SHIFTL(dmemo, 0, 16); \
}
/*
#define aLoadBuffer(pkt, s) \
{ \
Acmd *_a = (Acmd *)pkt; \
\
_a->words.w0 = _SHIFTL(A_LOADBUFF, 24, 8); \
_a->words.w1 = (unsigned int)(s); \
}
*/
#define aLoadBuffer(pkt, s, d, c) \
{ \
Acmd *_a = (Acmd *)pkt; \
@ -436,16 +404,6 @@ extern u32 D_801304A0;
_a->words.w1 = (unsigned int)(s); \
}
/*
#define aSaveBuffer(pkt, s) \
{ \
Acmd *_a = (Acmd *)pkt; \
\
_a->words.w0 = _SHIFTL(A_SAVEBUFF, 24, 8); \
_a->words.w1 = (unsigned int)(s); \
}
*/
#define aSaveBuffer(pkt, s, d, c) \
{ \
Acmd *_a = (Acmd *)pkt; \