From ff471fa82b2e6449852eb4097bb2eac854797920 Mon Sep 17 00:00:00 2001 From: ProjectRevoTPP Date: Sat, 14 Sep 2024 18:31:03 -0400 Subject: [PATCH] n_syndelete and n_synallocfx --- src/50990.c | 5 ----- src/libnaudio/n_synallocfx.c | 25 +++++++++++++++++++++++++ src/libnaudio/n_syndelete.c | 25 +++++++++++++++++++++++++ yamls/us/rom.yaml | 3 ++- 4 files changed, 52 insertions(+), 6 deletions(-) delete mode 100644 src/50990.c create mode 100644 src/libnaudio/n_synallocfx.c create mode 100644 src/libnaudio/n_syndelete.c diff --git a/src/50990.c b/src/50990.c deleted file mode 100644 index 8b01f1b..0000000 --- a/src/50990.c +++ /dev/null @@ -1,5 +0,0 @@ -#include "global.h" - -#pragma GLOBAL_ASM("asm/us/nonmatchings/50990/n_alSynDelete.s") - -#pragma GLOBAL_ASM("asm/us/nonmatchings/50990/n_alSynAllocFX.s") diff --git a/src/libnaudio/n_synallocfx.c b/src/libnaudio/n_synallocfx.c new file mode 100644 index 0000000..ee4d73c --- /dev/null +++ b/src/libnaudio/n_synallocfx.c @@ -0,0 +1,25 @@ +/*==================================================================== + * + * Copyright 1993, Silicon Graphics, Inc. + * All Rights Reserved. + * + * This is UNPUBLISHED PROPRIETARY SOURCE CODE of Silicon Graphics, + * Inc.; the contents of this file may not be disclosed to third + * parties, copied or duplicated in any form, in whole or in part, + * without the prior written permission of Silicon Graphics, Inc. + * + * RESTRICTED RIGHTS LEGEND: + * Use, duplication or disclosure by the Government is subject to + * restrictions as set forth in subdivision (c)(1)(ii) of the Rights + * in Technical Data and Computer Software clause at DFARS + * 252.227-7013, and/or in similar or successor clauses in the FAR, + * DOD or NASA FAR Supplement. Unpublished - rights reserved under the + * Copyright Laws of the United States. + *====================================================================*/ +#include "n_synthInternals.h" + +ALFxRef n_alSynAllocFX(s16 bus, ALSynConfig *c, ALHeap *hp) +{ + n_alFxNew(&n_syn->auxBus->fx_array[bus], c, hp); + return(n_syn->auxBus->fx_array[bus]); +} diff --git a/src/libnaudio/n_syndelete.c b/src/libnaudio/n_syndelete.c new file mode 100644 index 0000000..8d1f1ce --- /dev/null +++ b/src/libnaudio/n_syndelete.c @@ -0,0 +1,25 @@ +/*==================================================================== + * + * Copyright 1993, Silicon Graphics, Inc. + * All Rights Reserved. + * + * This is UNPUBLISHED PROPRIETARY SOURCE CODE of Silicon Graphics, + * Inc.; the contents of this file may not be disclosed to third + * parties, copied or duplicated in any form, in whole or in part, + * without the prior written permission of Silicon Graphics, Inc. + * + * RESTRICTED RIGHTS LEGEND: + * Use, duplication or disclosure by the Government is subject to + * restrictions as set forth in subdivision (c)(1)(ii) of the Rights + * in Technical Data and Computer Software clause at DFARS + * 252.227-7013, and/or in similar or successor clauses in the FAR, + * DOD or NASA FAR Supplement. Unpublished - rights reserved under the + * Copyright Laws of the United States. + *====================================================================*/ +#include "n_synthInternals.h" + +void n_alSynDelete(void) +{ + n_syn->head = 0; +} + diff --git a/yamls/us/rom.yaml b/yamls/us/rom.yaml index 14f39a0..47fe08b 100644 --- a/yamls/us/rom.yaml +++ b/yamls/us/rom.yaml @@ -110,7 +110,8 @@ - [0x4FF50, c] - [0x50120, c] - [0x50860, c] - - [0x50990, c] + - [0x50990, c, libnaudio/n_syndelete] + - [0x509A0, c, libnaudio/n_synallocfx] - [0x50A00, c] - [0x50C20, c] - [0x50CC0, c]