IDSP cleanup

This commit is contained in:
bnnm 2018-08-12 18:04:19 +02:00
parent efb01a921c
commit 5720278d2d
6 changed files with 28 additions and 27 deletions

View File

@ -820,7 +820,9 @@ static const meta_info meta_info_list[] = {
{meta_FFXI_BGW, "BGW BGMStream header"},
{meta_FFXI_SPW, "SPW SeWave header"},
{meta_PS2_ASS, "ASS Header"},
{meta_IDSP, "IDSP Header"},
{meta_NUB_IDSP, "Namco NUB IDSP header"},
{meta_IDSP_NL, "Next Level IDSP header"},
{meta_IDSP_IE, "Inevitable Entertainment IDSP Header"},
{meta_UBI_JADE, "Ubisoft Jade RIFF header"},
{meta_PS2_SEG, "SEG (PS2) Header"},
{meta_XBOX_SEG, "SEG (XBOX) Header"},

View File

@ -1,11 +1,9 @@
#include "meta.h"
#include "../util.h"
/* "idsp/IDSP"
Soul Calibur Legends (Wii)
Sky Crawlers: Innocent Aces (Wii)
*/
VGMSTREAM * init_vgmstream_idsp2(STREAMFILE *streamFile) {
//todo cleanup
/* "idsp" - from Namco's Wii NUB archives [Soul Calibur Legends (Wii), Sky Crawlers: Innocent Aces (Wii)] */
VGMSTREAM * init_vgmstream_nub_idsp(STREAMFILE *streamFile) {
VGMSTREAM * vgmstream = NULL;
char filename[PATH_LIMIT];
int loop_flag;
@ -18,8 +16,8 @@ VGMSTREAM * init_vgmstream_idsp2(STREAMFILE *streamFile) {
if (strcasecmp("idsp",filename_extension(filename))) goto fail;
/* check header */
if (read_32bitBE(0x00,streamFile) != 0x69647370 || /* "idsp" */
read_32bitBE(0xBC,streamFile) != 0x49445350) /* IDSP */
if (read_32bitBE(0x00,streamFile) != 0x69647370 || /* "idsp" */
read_32bitBE(0xBC,streamFile) != 0x49445350) /* "IDSP" */
goto fail;
loop_flag = read_32bitBE(0x20,streamFile);
@ -56,7 +54,7 @@ VGMSTREAM * init_vgmstream_idsp2(STREAMFILE *streamFile) {
}
}
vgmstream->meta_type = meta_IDSP;
vgmstream->meta_type = meta_NUB_IDSP;
{
if (vgmstream->coding_type == coding_NGC_DSP) {
@ -94,9 +92,8 @@ fail:
return NULL;
}
/* IDSP (Mario Strikers Charged)
- Single "IDSP" header... */
VGMSTREAM * init_vgmstream_idsp3(STREAMFILE *streamFile) {
/* IDSP - from Next Level games [Mario Strikers Charged (Wii)] */
VGMSTREAM * init_vgmstream_idsp_nl(STREAMFILE *streamFile) {
VGMSTREAM * vgmstream = NULL;
char filename[PATH_LIMIT];
int loop_flag = 1;
@ -133,7 +130,7 @@ VGMSTREAM * init_vgmstream_idsp3(STREAMFILE *streamFile) {
vgmstream->interleave_last_block_size = ((vgmstream->num_samples/7*8)%(vgmstream->interleave_block_size)/vgmstream->channels);
vgmstream->layout_type = layout_interleave;
vgmstream->meta_type = meta_IDSP;
vgmstream->meta_type = meta_IDSP_NL;
if (vgmstream->coding_type == coding_NGC_DSP) {
int i;
@ -170,8 +167,8 @@ fail:
return NULL;
}
/* IDSP (Defender NGC) */
VGMSTREAM * init_vgmstream_idsp4(STREAMFILE *streamFile) {
/* IDSP - from Inevitable Entertainment games [Defender (GC)] */
VGMSTREAM * init_vgmstream_idsp_ie(STREAMFILE *streamFile) {
VGMSTREAM * vgmstream = NULL;
char filename[PATH_LIMIT];
int loop_flag = 0;
@ -212,7 +209,7 @@ VGMSTREAM * init_vgmstream_idsp4(STREAMFILE *streamFile) {
vgmstream->interleave_block_size = read_32bitBE(0x10,streamFile);
}
vgmstream->meta_type = meta_IDSP;
vgmstream->meta_type = meta_IDSP_IE;
{
int i;

View File

@ -260,7 +260,7 @@ VGMSTREAM * init_vgmstream_dc_idvi(STREAMFILE *streamFile);
VGMSTREAM * init_vgmstream_ps2_rnd(STREAMFILE *streamFile);
VGMSTREAM * init_vgmstream_wii_idsp(STREAMFILE *streamFile);
VGMSTREAM * init_vgmstream_idsp_tt(STREAMFILE *streamFile);
VGMSTREAM * init_vgmstream_kraw(STREAMFILE *streamFile);
@ -268,9 +268,9 @@ VGMSTREAM * init_vgmstream_ps2_omu(STREAMFILE *streamFile);
VGMSTREAM * init_vgmstream_ps2_xa2(STREAMFILE * streamFile);
VGMSTREAM * init_vgmstream_idsp2(STREAMFILE * streamFile);
VGMSTREAM * init_vgmstream_idsp3(STREAMFILE * streamFile);
VGMSTREAM * init_vgmstream_idsp4(STREAMFILE * streamFile);
VGMSTREAM * init_vgmstream_nub_idsp(STREAMFILE * streamFile);
VGMSTREAM * init_vgmstream_idsp_nl(STREAMFILE * streamFile);
VGMSTREAM * init_vgmstream_idsp_ie(STREAMFILE * streamFile);
VGMSTREAM * init_vgmstream_ngc_ymf(STREAMFILE * streamFile);

View File

@ -868,7 +868,7 @@ fail:
}
/* IDSP - Traveller's Tales header + interleaved dsps [Lego Batman (Wii), Lego Dimensions (Wii U)] */
VGMSTREAM * init_vgmstream_wii_idsp(STREAMFILE *streamFile) {
VGMSTREAM * init_vgmstream_idsp_tt(STREAMFILE *streamFile) {
dsp_meta dspm = {0};
int version_main, version_sub;

View File

@ -141,13 +141,13 @@ VGMSTREAM * (*init_vgmstream_functions[])(STREAMFILE *streamFile) = {
init_vgmstream_sat_sap,
init_vgmstream_dc_idvi,
init_vgmstream_ps2_rnd,
init_vgmstream_wii_idsp,
init_vgmstream_idsp_tt,
init_vgmstream_kraw,
init_vgmstream_ps2_omu,
init_vgmstream_ps2_xa2,
init_vgmstream_idsp2,
init_vgmstream_idsp3,
init_vgmstream_idsp4,
init_vgmstream_nub_idsp,
init_vgmstream_idsp_nl,
init_vgmstream_idsp_ie,
init_vgmstream_ngc_ymf,
init_vgmstream_sadl,
init_vgmstream_ps2_ccc,

View File

@ -401,7 +401,9 @@ typedef enum {
meta_KRAW, /* Geometry Wars - Galaxies */
meta_PS2_OMU, /* PS2 Int file with Header */
meta_PS2_XA2, /* XG3 Extreme-G Racing */
meta_IDSP, /* Chronicles of Narnia, Soul Calibur Legends, Mario Strikers Charged */
meta_NUB_IDSP, /* Soul Calibur Legends (Wii) */
meta_IDSP_NL, /* Mario Strikers Charged (Wii) */
meta_IDSP_IE, /* Defencer (GC) */
meta_SPT_SPD, /* Various (SPT+SPT DSP) */
meta_ISH_ISD, /* Various (ISH+ISD DSP) */
meta_GSP_GSB, /* Tecmo games (Super Swing Golf 1 & 2, Quamtum Theory) */