Merge pull request #1390 from bnnm/torus-misc-cleanup

- Add Torus Games SqueakStream format
- Fix some .bnk [Fat Princess (PS3)]
- Fix TXTH dynamic chunks in some cases
- Remove fake extension .hgc1 (use .str)
- Remove fake extension .filp (use .fil)
- Remove fake extension .sl3 (use .ms)
- Remove .gsb extension (use .gsp)
- Remove fake extension .matx (use TXTH)
- Remove fake format .wad (use TXTH)
- Add HCA key
This commit is contained in:
bnnm 2023-07-08 18:09:11 +02:00 committed by GitHub
commit 3dca67b3df
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
34 changed files with 690 additions and 832 deletions

View File

@ -25,9 +25,9 @@ different internally (encrypted, different versions, etc) and not always can be
### List
- **adx.c**
- CRI ADX header type 03 [*ADX_03*]
- CRI ADX header type 04 [*ADX_04*]
- CRI ADX header type 05 [*ADX_05*]
- CRI ADX header (type 03) [*ADX_03*]
- CRI ADX header (type 04) [*ADX_04*]
- CRI ADX header (type 05) [*ADX_05*]
- *adx*
- Subfiles: *adx_subkey*
- *adx_subkey*: `.adx .adp + .(external)`
@ -198,7 +198,7 @@ different internally (encrypted, different versions, etc) and not always can be
- Codecs: NGC_DSP
- **ea_schl.c**
- Electronic Arts BNK header [*EA_BNK*]
- Electronic Arts SCHl header (variable) [*EA_SCHL*]
- Electronic Arts SCHl header [*EA_SCHL*]
- *ea_schl*: `.asf .lasf .str .chk .eam .exa .sng .aud .sx .xa .strm .stm .hab .xsf .gsf .(extensionless)`
- *ea_schl_video*: `.uv .dct .mad .wve .vp6`
- *ea_bnk*: `.bnk .sdt .hdt .ldt .abk .ast`
@ -239,8 +239,8 @@ different internally (encrypted, different versions, etc) and not always can be
- *wsi*: `.wsi`
- Codecs: NGC_DSP
- **aifc.c**
- Apple AIFF-C (Audio Interchange File Format) header [*AIFC*]
- Apple AIFF (Audio Interchange File Format) header [*AIFF*]
- Apple AIFF-C header [*AIFC*]
- Apple AIFF header [*AIFF*]
- *aifc*: `.aif .laif .wav .lwav .(extensionless) .aifc .laifc .afc .cbd2 .bgm .fda .n64 .xa .aiff .laiff .acm .adp .ai .pcm`
- Codecs: SDX2 CBD2 DVI_IMA_int APPLE_IMA4 RELIC VADPCM PCM8 PCM16BE XA
- **str_snds.c**
@ -265,12 +265,12 @@ different internally (encrypted, different versions, etc) and not always can be
- Codecs: PSX
- **riff.c**
- RIFF WAVE header [*RIFF_WAVE*]
- RIFF WAVE header with loop markers [*RIFF_WAVE_labl*]
- RIFF WAVE header with sample looping info [*RIFF_WAVE_smpl*]
- RIFF WAVE header with wsmp looping info [*RIFF_WAVE_wsmp*]
- RIFF WAVE header with .mwv flavoring [*RIFF_WAVE_MWV*]
- RIFF WAVE header (labl looping) [*RIFF_WAVE_labl*]
- RIFF WAVE header (smpl looping) [*RIFF_WAVE_smpl*]
- RIFF WAVE header (wsmp looping) [*RIFF_WAVE_wsmp*]
- RIFF WAVE header (ctrl looping) [*RIFF_WAVE_MWV*]
- RIFX WAVE header [*RIFX_WAVE*]
- RIFX WAVE header with sample looping info [*RIFX_WAVE_smpl*]
- RIFX WAVE header (smpl looping) [*RIFX_WAVE_smpl*]
- *riff*: `.wav .lwav .xwav .mwv .da .dax .cd .med .snd .adx .adp .xss .xsew .adpcm .adw .wd .(extensionless) .sbv .wvx .str .at3 .rws .aud .at9 .ckd .saf .ima .nsa .pcm .xvag .ogg .logg .p1d .xms .mus .dat .ldat`
- *rifx*: `.wav .lwav`
- Codecs: AICA_int PCM24LE PCM16BE PCM16LE PCM8_U MSADPCM IMA MS_IMA AICA MPEG_custom XBOX_IMA MS_IMA_3BIT DVI_IMA L5_555 OGG_VORBIS ATRAC9 ATRAC3 MPEG MSADPCM_int
@ -290,13 +290,13 @@ different internally (encrypted, different versions, etc) and not always can be
- Dino Crisis 3 XSS File [*XSS*]
- *xss*: `.xss`
- Codecs: PCM16LE
- **ps2_sl3.c**
- **sl3.c**
- Atari Melbourne House SL3 header [*SL3*]
- *sl3*: `.ms .sl3`
- *sl3*: `.ms`
- Codecs: PSX
- **ps2_hgc1.c**
- Knights of the Temple 2 hgC1 Header [*HGC1*]
- *hgc1*: `.hgc1`
- **hgc1.c**
- Cauldron HGC1 header [*HGC1*]
- *hgc1*: `.str`
- Codecs: PSX
- **aus.c**
- Capcom AUS Header [*AUS*]
@ -340,9 +340,9 @@ different internally (encrypted, different versions, etc) and not always can be
- Eurocom MUSX header [*MUSX*]
- *musx*: `.sfx .musx`
- Codecs: PSX DAT4_IMA DVI_IMA_int XBOX_IMA NGC_DSP PCM16BE PCM16LE
- **ps2_filp.c**
- Bio Hazard - Gun Survivor FILp Header [*FILP*]
- *filp*: `.filp`
- **filp.c**
- cavia FILp Header [*FILP*]
- *filp*: `.fil`
- Codecs: PSX
- **ikm.c**
- MiCROViSiON IKM header [*IKM*]
@ -356,16 +356,16 @@ different internally (encrypted, different versions, etc) and not always can be
- ALCHEMY STER header [*STER*]
- *ster*: `.ster .sfs`
- Codecs: PSX
- **ps2_bg00.c**
- Falcom BG00 Header [*BG00*]
- **bg00.c**
- Cave BG00 header [*BG00*]
- *bg00*: `.bg00`
- Codecs: PSX
- **sat_dvi.c**
- Konami KCEN DVI. header [*SAT_DVI*]
- Konami DVI. header [*SAT_DVI*]
- *sat_dvi*: `.pcm .dvi`
- Codecs: DVI_IMA_int
- **dc_kcey.c**
- Konami KCEY KCEYCOMP header [*DC_KCEY*]
- Konami KCEY header [*DC_KCEY*]
- *dc_kcey*: `.pcm .kcey`
- Codecs: DVI_IMA
- **rstm_rockstar.c**
@ -393,7 +393,7 @@ different internally (encrypted, different versions, etc) and not always can be
- *vsv*: `.vsv .psh`
- Codecs: PSX
- **ps2_pcm.c**
- Konami KCEJ East .PCM header [*PS2_PCM*]
- Konami .PCM header [*PS2_PCM*]
- *ps2_pcm*: `.pcm`
- Codecs: PCM16LE
- **rkv.c**
@ -429,12 +429,8 @@ different internally (encrypted, different versions, etc) and not always can be
- *wvs_xbox*: `.wvs`
- *wvs_ngc*: `.wvs`
- Codecs: XBOX_IMA NGC_DSP
- **xbox_ims.c**
- assumed Matrix file by .matx extension [*XBOX_MATX*]
- *xbox_matx*: `.matx`
- Codecs: XBOX_IMA
- **dec.c**
- Falcom DEC RIFF header [*DEC*]
- Falcom .DEC RIFF header [*DEC*]
- *dec*: `.dec .de2 + .(external)`
- Codecs: MSADPCM
- **vs.c**
@ -464,7 +460,7 @@ different internally (encrypted, different versions, etc) and not always can be
- *dc_idvi*: `.dvi .idvi`
- Codecs: DVI_IMA_int
- **ps2_rnd.c**
- Knights of the Temple 2 hgC1 Header [*HGC1*]
- Cauldron HGC1 header [*HGC1*]
- *ps2_rnd*: `.rnd`
- Codecs: PSX
- **kraw.c**
@ -504,9 +500,9 @@ different internally (encrypted, different versions, etc) and not always can be
- *ngc_pdt*: `.pdt`
- *ngc_pdt_split*: `.pdt`
- Codecs: NGC_DSP
- **wii_mus.c**
- mus header [*DSP_WII_MUS*]
- *wii_mus*: `.mus`
- **mus_krone.c**
- Krone .MUS header [*MUS_KRONE*]
- *mus_krone*: `.mus`
- Codecs: NGC_DSP
- **dc_asd.c**
- ASD Header [*DC_ASD*]
@ -562,9 +558,9 @@ different internally (encrypted, different versions, etc) and not always can be
- ISH+ISD DSP Header [*ISH_ISD*]
- *ish_isd*: `.isd + .ish`
- Codecs: NGC_DSP
- **gsp_gsb.c**
- Tecmo GSP+GSB Header [*GSP_GSB*]
- *gsp_gsb*: `.gsb + .gsp`
- **gsnd.c**
- Tecmo GSND Header [*GSND*]
- *gsnd*: `.gsp + .gsb`
- Codecs: NGC_DSP ATRAC3 XMA
- **ydsp.c**
- Yuke's YDSP Header [*YDSP*]
@ -730,9 +726,9 @@ different internally (encrypted, different versions, etc) and not always can be
- Sensaura SAB header [*SAB*]
- *sab*: `.sab + .sob`
- Codecs: PCM16LE PSX XBOX_IMA
- **wii_bns.c**
- Nintendo BNS header [*WII_BNS*]
- *wii_bns*: `.bin .lbin .bns`
- **bns.c**
- Nintendo BNS header [*BNS*]
- *bns*: `.bin .lbin .bns`
- Codecs: NGC_DSP
- **pona.c**
- Policenauts BGM header [*PONA_3DO*]
@ -771,9 +767,9 @@ different internally (encrypted, different versions, etc) and not always can be
- Konami DSP header [*NGC_DSP_KONAMI*]
- *ngc_dsp_konami*: `.dsp`
- Codecs: NGC_DSP
- **ps2_wb.c**
- Shooting Love. ~TRIZEAL~ WB header [*PS2_WB*]
- *ps2_wb*: `.wb`
- **wb.c**
- Triangle Service .WB header [*WB*]
- *wb*: `.wb`
- Codecs: PCM16LE
- **bnsf.c**
- Namco Bandai BNSF header [*BNSF*]
@ -811,10 +807,6 @@ different internally (encrypted, different versions, etc) and not always can be
- B1S header [*PS2_B1S*]
- *ps2_b1s*: `.b1s`
- Codecs: PSX
- **ps2_wad.c**
- WAD header [*PS2_WAD*]
- *ps2_wad*: `.wad`
- Codecs: PSX
- **lpcm_shade.c**
- Shade LPCM header [*LPCM_SHADE*]
- *lpcm_shade*: `.w .lpcm`
@ -952,7 +944,7 @@ different internally (encrypted, different versions, etc) and not always can be
- *ps2_2pfs*: `.sap .2pfs`
- Codecs: PSX
- **xnb.c**
- Microsoft XNA Game Studio 4.0 header [*XNB*]
- Microsoft XNA Game Studio header [*XNB*]
- *xnb*: `.xnb + .(external)`
- Subfiles: *ogg_vorbis riff opus_std ffmpeg*
- Codecs: PCM8_U PCM16LE MSADPCM MS_IMA XMA2 NGC_DSP
@ -1797,6 +1789,10 @@ different internally (encrypted, different versions, etc) and not always can be
- Double Fine WB header [*PWB*]
- *pwb*: `.pwb`
- Codecs: PSX
- **rawi.c**
- Torus SqueakStream RAWI header [*RAWI*]
- *rawi*: `(base) + .asset .(external) .raw`
- Codecs: NGC_DSP PCM16BE PSX PCM8 MS_IMA
- **scd_pcm.c**
- Lunar: Eternal Blue .PCM header [*SCD_PCM*]
- *scd_pcm*: `.pcm`
@ -1830,7 +1826,7 @@ different internally (encrypted, different versions, etc) and not always can be
- *tgc*: `.4`
- Codecs: TGC
- **pos.c**
- RIFF WAVE header and .pos for looping [*RIFF_WAVE_POS*]
- RIFF WAVE header (.pos looping) [*RIFF_WAVE_POS*]
- *pos*: `.pos + .wav`
- Subfiles: *riff*
- **sli.c**
@ -1838,7 +1834,7 @@ different internally (encrypted, different versions, etc) and not always can be
- *sli_loops*: `.sli + .(external)`
- Subfiles: *ogg_opus ogg_vorbis riff*
- **ngc_adpdtk.c**
- Nintendo DTK raw header [*DTK*]
- Nintendo .DTK raw header [*DTK*]
- *dtk*: `.dtk .adp .trk .wav .lwav`
- Codecs: NGC_DTK
- **mpeg.c**

View File

@ -423,7 +423,7 @@ int decode_get_samples_per_frame(VGMSTREAM* vgmstream) {
return 64;
case coding_MS_IMA:
case coding_REF_IMA:
return ((vgmstream->interleave_block_size - 0x04*vgmstream->channels) * 2 / vgmstream->channels) + 1;/* +1 from header sample */
return ((vgmstream->frame_size - 0x04*vgmstream->channels) * 2 / vgmstream->channels) + 1;/* +1 from header sample */
case coding_MS_IMA_mono:
return ((vgmstream->frame_size - 0x04) * 2) + 1; /* +1 from header sample */
case coding_RAD_IMA:

View File

@ -274,7 +274,6 @@ int render_layout(sample_t* buf, int32_t sample_count, VGMSTREAM* vgmstream) {
case layout_blocked_wsi:
case layout_blocked_str_snds:
case layout_blocked_ws_aud:
case layout_blocked_matx:
case layout_blocked_dec:
case layout_blocked_vs:
case layout_blocked_mul:

View File

@ -206,8 +206,8 @@ static const char* extension_list[] = {
"gin",
"gms",
"grn",
"gsb",
"gsf",
"gsp",
"gtd",
"gwm",
@ -217,7 +217,6 @@ static const char* extension_list[] = {
"hd3",
"hdr",
"hdt",
"hgc1",
"his",
"hps",
"hsf",
@ -326,7 +325,6 @@ static const char* extension_list[] = {
"mab",
"mad",
"map",
"matx",
"mc3",
"mca",
"mcadpcm",
@ -501,7 +499,6 @@ static const char* extension_list[] = {
"sgd",
"sgt",
"sgx",
"sl3",
"slb", //txth/reserved [THE Nekomura no Hitobito (PS2)]
"sli",
"smc",
@ -932,7 +929,6 @@ static const layout_info layout_info_list[] = {
{layout_blocked_xvas, "blocked (.xvas)"},
{layout_blocked_str_snds, "blocked (.str SNDS)"},
{layout_blocked_ws_aud, "blocked (Westwood Studios .aud)"},
{layout_blocked_matx, "blocked (Matrix .matx)"},
{layout_blocked_dec, "blocked (DEC)"},
{layout_blocked_vs, "blocked (Melbourne House VS)"},
{layout_blocked_mul, "blocked (MUL)"},
@ -966,16 +962,16 @@ static const meta_info meta_info_list[] = {
{meta_SILENCE, "Silence"},
{meta_RSTM, "Nintendo RSTM header"},
{meta_STRM, "Nintendo STRM header"},
{meta_ADX_03, "CRI ADX header type 03"},
{meta_ADX_04, "CRI ADX header type 04"},
{meta_ADX_05, "CRI ADX header type 05"},
{meta_ADX_03, "CRI ADX header (type 03)"},
{meta_ADX_04, "CRI ADX header (type 04)"},
{meta_ADX_05, "CRI ADX header (type 05)"},
{meta_AIX, "CRI AIX header"},
{meta_AAX, "CRI AAX header"},
{meta_UTF_DSP, "CRI ADPCM_WII header"},
{meta_AGSC, "Retro Studios AGSC header"},
{meta_CSMP, "Retro Studios CSMP header"},
{meta_RFRM, "Retro Studios RFRM header"},
{meta_DTK, "Nintendo DTK raw header"},
{meta_DTK, "Nintendo .DTK raw header"},
{meta_RSF, "Retro Studios .RSF raw header"},
{meta_AFC, "Nintendo .AFC header"},
{meta_AST, "Nintendo .AST header"},
@ -1016,7 +1012,7 @@ static const meta_info meta_info_list[] = {
{meta_PWB, "Double Fine WB header"},
{meta_RAW_WAVM, "Xbox .wavm raw header"},
{meta_DSP_STR, "Cauldron .STR header"},
{meta_EA_SCHL, "Electronic Arts SCHl header (variable)"},
{meta_EA_SCHL, "Electronic Arts SCHl header"},
{meta_EA_SCHL_fixed, "Electronic Arts SCHl header (fixed)"},
{meta_CAF, "tri-Crescendo CAF Header"},
{meta_VPK, "SCE America VPK Header"},
@ -1025,19 +1021,19 @@ static const meta_info meta_info_list[] = {
{meta_SADL, "Procyon Studio SADL header"},
{meta_PS2_BMDX, "Beatmania .bmdx header"},
{meta_DSP_WSI, "Alone in the Dark .WSI header"},
{meta_AIFC, "Apple AIFF-C (Audio Interchange File Format) header"},
{meta_AIFF, "Apple AIFF (Audio Interchange File Format) header"},
{meta_AIFC, "Apple AIFF-C header"},
{meta_AIFF, "Apple AIFF header"},
{meta_STR_SNDS, "3DO SNDS header"},
{meta_WS_AUD, "Westwood Studios .AUD header"},
{meta_PS2_IVB, "IVB/BVII header"},
{meta_SVS, "Square SVS header"},
{meta_RIFF_WAVE, "RIFF WAVE header"},
{meta_RIFF_WAVE_POS, "RIFF WAVE header and .pos for looping"},
{meta_RIFF_WAVE_POS, "RIFF WAVE header (.pos looping)"},
{meta_NWA, "VisualArt's NWA header"},
{meta_NWA_NWAINFOINI, "VisualArt's NWA header (NWAINFO.INI looping)"},
{meta_NWA_GAMEEXEINI, "VisualArt's NWA header (Gameexe.ini looping)"},
{meta_XSS, "Dino Crisis 3 XSS File"},
{meta_HGC1, "Knights of the Temple 2 hgC1 Header"},
{meta_HGC1, "Cauldron HGC1 header"},
{meta_AUS, "Capcom AUS Header"},
{meta_RWS, "RenderWare RWS header"},
{meta_EA_1SNH, "Electronic Arts 1SNh header"},
@ -1053,34 +1049,33 @@ static const meta_info meta_info_list[] = {
{meta_PS2_XA30, "Reflections XA30 PS2 header"},
{meta_MUSC, "Krome MUSC header"},
{meta_MUSX, "Eurocom MUSX header"},
{meta_FILP, "Bio Hazard - Gun Survivor FILp Header"},
{meta_FILP, "cavia FILp Header"},
{meta_IKM, "MiCROViSiON IKM header"},
{meta_STER, "ALCHEMY STER header"},
{meta_SAT_DVI, "Konami KCEN DVI. header"},
{meta_DC_KCEY, "Konami KCEY KCEYCOMP header"},
{meta_BG00, "Falcom BG00 Header"},
{meta_SAT_DVI, "Konami DVI. header"},
{meta_DC_KCEY, "Konami KCEY header"},
{meta_BG00, "Cave BG00 header"},
{meta_RSTM_ROCKSTAR, "Rockstar Games RSTM Header"},
{meta_ACM, "InterPlay ACM Header"},
{meta_MUS_ACM, "InterPlay MUS ACM header"},
{meta_PS2_KCES, "Konami KCES Header"},
{meta_HXD, "Tecmo HXD Header"},
{meta_VSV, "Square Enix .vsv Header"},
{meta_RIFF_WAVE_labl, "RIFF WAVE header with loop markers"},
{meta_RIFF_WAVE_smpl, "RIFF WAVE header with sample looping info"},
{meta_RIFF_WAVE_wsmp, "RIFF WAVE header with wsmp looping info"},
{meta_RIFF_WAVE_labl, "RIFF WAVE header (labl looping)"},
{meta_RIFF_WAVE_smpl, "RIFF WAVE header (smpl looping)"},
{meta_RIFF_WAVE_wsmp, "RIFF WAVE header (wsmp looping)"},
{meta_RIFX_WAVE, "RIFX WAVE header"},
{meta_RIFX_WAVE_smpl, "RIFX WAVE header with sample looping info"},
{meta_XNB, "Microsoft XNA Game Studio 4.0 header"},
{meta_RIFX_WAVE_smpl, "RIFX WAVE header (smpl looping)"},
{meta_XNB, "Microsoft XNA Game Studio header"},
{meta_SCD_PCM, "Lunar: Eternal Blue .PCM header"},
{meta_PS2_PCM, "Konami KCEJ East .PCM header"},
{meta_PS2_PCM, "Konami .PCM header"},
{meta_PS2_RKV, "Legacy of Kain - Blood Omen 2 RKV PS2 header"},
{meta_PS2_VAS, "Konami .VAS header"},
{meta_LP_AP_LEP, "Konami LP/AP/LEP header"},
{meta_SDT, "High Voltage .sdt header"},
{meta_NGC_TYDSP, ".tydsp Header"},
{meta_WVS, "Swingin' Ape .WVS header"},
{meta_XBOX_MATX, "assumed Matrix file by .matx extension"},
{meta_DEC, "Falcom DEC RIFF header"},
{meta_DEC, "Falcom .DEC RIFF header"},
{meta_VS, "Melbourne House .VS header"},
{meta_DC_STR, "Sega Stream Asset Builder header"},
{meta_DC_STR_V2, "variant of Sega Stream Asset Builder header"},
@ -1093,7 +1088,7 @@ static const meta_info meta_info_list[] = {
{meta_YMF, "Yuke's .YMF Header"},
{meta_FAG, "Radical .FAG Header"},
{meta_PS2_MIHB, "Sony MultiStream MIC header"},
{meta_DSP_WII_MUS, "mus header"},
{meta_MUS_KRONE, "Krone .MUS header"},
{meta_WII_SNG, "SNG DSP Header"},
{meta_RSD, "Radical RSD header"},
{meta_DC_ASD, "ASD Header"},
@ -1112,7 +1107,7 @@ static const meta_info meta_info_list[] = {
{meta_GCA, "GCA DSP Header"},
{meta_SPT_SPD, "SPT+SPD DSP Header"},
{meta_ISH_ISD, "ISH+ISD DSP Header"},
{meta_GSP_GSB, "Tecmo GSP+GSB Header"},
{meta_GSND, "Tecmo GSND Header"},
{meta_YDSP, "Yuke's YDSP Header"},
{meta_NGC_SSM, "SSM DSP Header"},
{meta_PS2_JOE, "Asobo Studio .JOE header"},
@ -1125,7 +1120,7 @@ static const meta_info meta_info_list[] = {
{meta_PS2_P2BT, "Pop'n'Music 7 Header"},
{meta_PS2_GBTS, "Pop'n'Music 9 Header"},
{meta_NGC_DSP_IADP, "IADP Header"},
{meta_RIFF_WAVE_MWV, "RIFF WAVE header with .mwv flavoring"},
{meta_RIFF_WAVE_MWV, "RIFF WAVE header (ctrl looping)"},
{meta_FFCC_STR, "Final Fantasy: Crystal Chronicles STR header"},
{meta_SAT_BAKA, "Konami BAKA header"},
{meta_SWAV, "Nintendo SWAV header"},
@ -1155,7 +1150,7 @@ static const meta_info meta_info_list[] = {
{meta_SAB, "Sensaura SAB header"},
{meta_MAXIS_XA, "Maxis XA Header"},
{meta_EXAKT_SC, "assumed Activision / EXAKT SC by extension"},
{meta_WII_BNS, "Nintendo BNS header"},
{meta_BNS, "Nintendo BNS header"},
{meta_WII_WAS, "Sumo Digital iSWS header"},
{meta_XBOX_HLWAV, "Half-Life 2 .WAV header"},
{meta_MYSPD, "Punchers Impact .MYSPD header"},
@ -1168,7 +1163,7 @@ static const meta_info meta_info_list[] = {
{meta_NGC_DSP_AAAP, "Acclaim Austin AAAp DSP header"},
{meta_NGC_DSP_KONAMI, "Konami DSP header"},
{meta_BNSF, "Namco Bandai BNSF header"},
{meta_PS2_WB, "Shooting Love. ~TRIZEAL~ WB header"},
{meta_WB, "Triangle Service .WB header"},
{meta_S14, "Namco .S14 raw header"},
{meta_SSS, "Namco .SSS raw header"},
{meta_PS2_GCM, "Namco GCM header"},
@ -1183,7 +1178,6 @@ static const meta_info meta_info_list[] = {
{meta_DSP_STR_IG, "Infogrames .DSP header"},
{meta_EA_SWVR, "Electronic Arts SWVR header"},
{meta_PS2_B1S, "B1S header"},
{meta_PS2_WAD, "WAD header"},
{meta_DSP_XIII, "XIII dsp header"},
{meta_DSP_CABELAS, "Cabelas games .DSP header"},
{meta_PS2_ADM, "Dragon Quest V .ADM raw header"},
@ -1416,6 +1410,7 @@ static const meta_info meta_info_list[] = {
{meta_BIGRP, "Inti Creates .BIGRP header"},
{meta_DIC1, "Codemasters DIC1 header"},
{meta_AWD, "RenderWare Audio Wave Dictionary header"},
{meta_RAWI, "Torus SqueakStream RAWI header"},
};
void get_vgmstream_coding_description(VGMSTREAM* vgmstream, char* out, size_t out_size) {

View File

@ -123,9 +123,6 @@ void block_update(off_t block_offset, VGMSTREAM* vgmstream) {
case layout_blocked_ws_aud:
block_update_ws_aud(block_offset,vgmstream);
break;
case layout_blocked_matx:
block_update_matx(block_offset,vgmstream);
break;
case layout_blocked_dec:
block_update_dec(block_offset,vgmstream);
break;

View File

@ -1,18 +0,0 @@
#include "layout.h"
#include "../vgmstream.h"
/* set up for the block at the given offset */
void block_update_matx(off_t block_offset, VGMSTREAM * vgmstream) {
int i;
vgmstream->current_block_offset = block_offset;
vgmstream->current_block_size = read_32bitLE(
vgmstream->current_block_offset,
vgmstream->ch[0].streamfile);
vgmstream->next_block_offset = vgmstream->current_block_offset + vgmstream->current_block_size + 8;
vgmstream->current_block_size/=vgmstream->channels;
for (i=0;i<vgmstream->channels;i++) {
vgmstream->ch[i].offset = vgmstream->current_block_offset + 8;
}
}

View File

@ -20,7 +20,6 @@ void block_update_caf(off_t block_offset, VGMSTREAM* vgmstream);
void block_update_wsi(off_t block_offset, VGMSTREAM* vgmstream);
void block_update_str_snds(off_t block_offset, VGMSTREAM* vgmstream);
void block_update_ws_aud(off_t block_offset, VGMSTREAM* vgmstream);
void block_update_matx(off_t block_offset, VGMSTREAM* vgmstream);
void block_update_dec(off_t block_offset, VGMSTREAM* vgmstream);
void block_update_vs(off_t block_offset, VGMSTREAM* vgmstream);
void block_update_mul(off_t block_offset, VGMSTREAM* vgmstream);

View File

@ -298,7 +298,6 @@
<ClCompile Include="layout\blocked_halpst.c" />
<ClCompile Include="layout\blocked_hwas.c" />
<ClCompile Include="layout\blocked_ivaud.c" />
<ClCompile Include="layout\blocked_matx.c" />
<ClCompile Include="layout\blocked_mul.c" />
<ClCompile Include="layout\blocked_mxch.c" />
<ClCompile Include="layout\blocked_ps2_iab.c" />
@ -370,6 +369,7 @@
<ClCompile Include="meta\bcstm.c" />
<ClCompile Include="meta\bfstm.c" />
<ClCompile Include="meta\bfwav.c" />
<ClCompile Include="meta\bg00.c" />
<ClCompile Include="meta\bgw.c" />
<ClCompile Include="meta\bigrp.c" />
<ClCompile Include="meta\bik.c" />
@ -377,6 +377,7 @@
<ClCompile Include="meta\bmp_konami.c" />
<ClCompile Include="meta\bnk_relic.c" />
<ClCompile Include="meta\bnk_sony.c" />
<ClCompile Include="meta\bns.c" />
<ClCompile Include="meta\bnsf.c" />
<ClCompile Include="meta\brstm.c" />
<ClCompile Include="meta\bsf.c" />
@ -423,6 +424,7 @@
<ClCompile Include="meta\ffdl.c" />
<ClCompile Include="meta\ffmpeg.c" />
<ClCompile Include="meta\ffw.c" />
<ClCompile Include="meta\filp.c" />
<ClCompile Include="meta\flx.c" />
<ClCompile Include="meta\fsb.c" />
<ClCompile Include="meta\fsb5.c" />
@ -436,11 +438,12 @@
<ClCompile Include="meta\genh.c" />
<ClCompile Include="meta\ghs.c" />
<ClCompile Include="meta\gin.c" />
<ClCompile Include="meta\gsp_gsb.c" />
<ClCompile Include="meta\gsnd.c" />
<ClCompile Include="meta\h4m.c" />
<ClCompile Include="meta\halpst.c" />
<ClCompile Include="meta\hca.c" />
<ClCompile Include="meta\hd3_bd3.c" />
<ClCompile Include="meta\hgc1.c" />
<ClCompile Include="meta\his.c" />
<ClCompile Include="meta\hxd.c" />
<ClCompile Include="meta\idsp_ie.c" />
@ -499,6 +502,7 @@
<ClCompile Include="meta\musc.c" />
<ClCompile Include="meta\musx.c" />
<ClCompile Include="meta\mus_acm.c" />
<ClCompile Include="meta\mus_krone.c" />
<ClCompile Include="meta\mus_vc.c" />
<ClCompile Include="meta\myspd.c" />
<ClCompile Include="meta\naac.c" />
@ -549,12 +553,9 @@
<ClCompile Include="meta\ps2_adm.c" />
<ClCompile Include="meta\ps2_ass.c" />
<ClCompile Include="meta\ps2_b1s.c" />
<ClCompile Include="meta\ps2_bg00.c" />
<ClCompile Include="meta\ps2_bmdx.c" />
<ClCompile Include="meta\ps2_filp.c" />
<ClCompile Include="meta\ps2_gbts.c" />
<ClCompile Include="meta\ps2_gcm.c" />
<ClCompile Include="meta\ps2_hgc1.c" />
<ClCompile Include="meta\ps2_hsf.c" />
<ClCompile Include="meta\ps2_iab.c" />
<ClCompile Include="meta\ps2_joe.c" />
@ -565,7 +566,6 @@
<ClCompile Include="meta\ps2_p2bt.c" />
<ClCompile Include="meta\ps2_pcm.c" />
<ClCompile Include="meta\ps2_rnd.c" />
<ClCompile Include="meta\ps2_sl3.c" />
<ClCompile Include="meta\ps2_snd.c" />
<ClCompile Include="meta\ps2_sps.c" />
<ClCompile Include="meta\ps2_va3.c" />
@ -574,8 +574,6 @@
<ClCompile Include="meta\ps2_vds_vdm.c" />
<ClCompile Include="meta\ps2_vgv.c" />
<ClCompile Include="meta\ps2_vms.c" />
<ClCompile Include="meta\ps2_wad.c" />
<ClCompile Include="meta\ps2_wb.c" />
<ClCompile Include="meta\ps2_wmus.c" />
<ClCompile Include="meta\ps2_xa30.c" />
<ClCompile Include="meta\ps3_past.c" />
@ -584,6 +582,7 @@
<ClCompile Include="meta\ps_headerless.c" />
<ClCompile Include="meta\pwb.c" />
<ClCompile Include="meta\rad.c" />
<ClCompile Include="meta\rawi.c" />
<ClCompile Include="meta\raw_int.c" />
<ClCompile Include="meta\raw_pcm.c" />
<ClCompile Include="meta\raw_rsf.c" />
@ -622,6 +621,7 @@
<ClCompile Include="meta\sgxd.c" />
<ClCompile Include="meta\silence.c" />
<ClCompile Include="meta\sk_aud.c" />
<ClCompile Include="meta\sl3.c" />
<ClCompile Include="meta\sli.c" />
<ClCompile Include="meta\smc_smh.c" />
<ClCompile Include="meta\smk.c" />
@ -689,9 +689,8 @@
<ClCompile Include="meta\wave.c" />
<ClCompile Include="meta\wavebatch.c" />
<ClCompile Include="meta\wave_segmented.c" />
<ClCompile Include="meta\wb.c" />
<ClCompile Include="meta\wbk.c" />
<ClCompile Include="meta\wii_bns.c" />
<ClCompile Include="meta\wii_mus.c" />
<ClCompile Include="meta\wii_ras.c" />
<ClCompile Include="meta\wii_sng.c" />
<ClCompile Include="meta\wpd.c" />
@ -709,7 +708,6 @@
<ClCompile Include="meta\xavs.c" />
<ClCompile Include="meta\xa_04sw.c" />
<ClCompile Include="meta\xa_xa30.c" />
<ClCompile Include="meta\xbox_ims.c" />
<ClCompile Include="meta\xma.c" />
<ClCompile Include="meta\xma_ue3.c" />
<ClCompile Include="meta\xmd.c" />

View File

@ -715,9 +715,6 @@
<ClCompile Include="layout\blocked_ivaud.c">
<Filter>layout\Source Files</Filter>
</ClCompile>
<ClCompile Include="layout\blocked_matx.c">
<Filter>layout\Source Files</Filter>
</ClCompile>
<ClCompile Include="layout\blocked_mul.c">
<Filter>layout\Source Files</Filter>
</ClCompile>
@ -931,6 +928,9 @@
<ClCompile Include="meta\bfwav.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\bg00.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\bgw.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
@ -952,6 +952,9 @@
<ClCompile Include="meta\bnk_sony.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\bns.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\bnsf.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
@ -1090,6 +1093,9 @@
<ClCompile Include="meta\ffw.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\filp.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\flx.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
@ -1129,7 +1135,7 @@
<ClCompile Include="meta\gin.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\gsp_gsb.c">
<ClCompile Include="meta\gsnd.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\h4m.c">
@ -1144,6 +1150,9 @@
<ClCompile Include="meta\hd3_bd3.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\hgc1.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\his.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
@ -1318,6 +1327,9 @@
<ClCompile Include="meta\mus_acm.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\mus_krone.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\mus_vc.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
@ -1468,24 +1480,15 @@
<ClCompile Include="meta\ps2_b1s.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\ps2_bg00.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\ps2_bmdx.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\ps2_filp.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\ps2_gbts.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\ps2_gcm.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\ps2_hgc1.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\ps2_hsf.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
@ -1516,9 +1519,6 @@
<ClCompile Include="meta\ps2_rnd.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\ps2_sl3.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\ps2_snd.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
@ -1543,12 +1543,6 @@
<ClCompile Include="meta\ps2_vms.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\ps2_wad.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\ps2_wb.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\ps2_wmus.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
@ -1573,6 +1567,9 @@
<ClCompile Include="meta\rad.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\rawi.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\raw_int.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
@ -1687,6 +1684,9 @@
<ClCompile Include="meta\sk_aud.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\sl3.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\sli.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
@ -1888,15 +1888,12 @@
<ClCompile Include="meta\wave_segmented.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\wb.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\wbk.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\wii_bns.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\wii_mus.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\wii_ras.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
@ -1948,9 +1945,6 @@
<ClCompile Include="meta\xa_xa30.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\xbox_ims.c">
<Filter>meta\Source Files</Filter>
</ClCompile>
<ClCompile Include="meta\xma.c">
<Filter>meta\Source Files</Filter>
</ClCompile>

46
src/meta/bg00.c Normal file
View File

@ -0,0 +1,46 @@
#include "meta.h"
#include "../coding/coding.h"
/* BG00 - from Cave games [Ibara (PS2), Mushihime-sama (PS2)] */
VGMSTREAM* init_vgmstream_bg00(STREAMFILE* sf) {
VGMSTREAM* vgmstream = NULL;
uint32_t start_offset;
int channels, loop_flag = 0;
/* check */
if (!is_id32be(0x00,sf, "BG00"))
return NULL;
/* .bg00: header ID (no filenames or debug strings) */
if (!check_extensions(sf,"bg00"))
return NULL;
if (!is_id32be(0x40,sf, "VAGp"))
return NULL;
if (!is_id32be(0x70,sf, "VAGp"))
return NULL;
loop_flag = 0; /* flag at 0x08? loop points seem external */
channels = 2; /* mono files use regular VAG */
start_offset = 0x800;
/* build the VGMSTREAM */
vgmstream = allocate_vgmstream(channels,loop_flag);
if (!vgmstream) goto fail;
vgmstream->meta_type = meta_BG00;
vgmstream->sample_rate = read_s32be(0x80,sf);
vgmstream->num_samples = ps_bytes_to_samples(read_32bitBE(0x4C,sf), 1);
vgmstream->coding_type = coding_PSX;
vgmstream->layout_type = layout_interleave;
vgmstream->interleave_block_size = read_32bitLE(0x10,sf);
if (!vgmstream_open_stream(vgmstream, sf, start_offset))
goto fail;
return vgmstream;
fail:
close_vgmstream(vgmstream);
return NULL;
}

View File

@ -472,8 +472,9 @@ VGMSTREAM* init_vgmstream_bnk_sony(STREAMFILE* sf) {
/* hack for PS3 files that use dual subsongs as stereo */
if (total_subsongs == 2 && stream_size * 2 == data_size) {
channels = 2;
stream_size = stream_size*channels;
stream_size = stream_size * channels;
total_subsongs = 1;
start_offset -= stream_offset; /* also channels may be inverted [Fat Princess (PS3)] */
}
interleave = stream_size / channels;

View File

@ -3,7 +3,7 @@
#include "../util.h"
/* BNS - Wii "Banner Sound" disc jingle */
VGMSTREAM* init_vgmstream_wii_bns(STREAMFILE* sf) {
VGMSTREAM* init_vgmstream_bns(STREAMFILE* sf) {
VGMSTREAM* vgmstream = NULL;
off_t bns_offset;
uint32_t info_offset = 0, data_offset = 0;
@ -15,7 +15,7 @@ VGMSTREAM* init_vgmstream_wii_bns(STREAMFILE* sf) {
/* .bin: actual extension
* .bns: header id */
if (!check_extensions(sf, "bin,lbin,bns"))
goto fail;
return NULL;
bns_offset = 0;
if (is_id32be(bns_offset + 0x40, sf, "IMET")) {
@ -32,9 +32,9 @@ VGMSTREAM* init_vgmstream_wii_bns(STREAMFILE* sf) {
}
if (!is_id32be(bns_offset + 0x00,sf, "BNS "))
goto fail;
return NULL;
if (read_u32be(bns_offset + 0x04,sf) != 0xFEFF0100u)
goto fail;
return NULL;
/* find chunks */
{
@ -110,7 +110,7 @@ VGMSTREAM* init_vgmstream_wii_bns(STREAMFILE* sf) {
vgmstream = allocate_vgmstream(channels, loop_flag);
if (!vgmstream) goto fail;
vgmstream->meta_type = meta_WII_BNS;
vgmstream->meta_type = meta_BNS;
vgmstream->sample_rate = sample_rate;
vgmstream->num_samples = sample_count;
vgmstream->loop_start_sample = loop_start;

55
src/meta/filp.c Normal file
View File

@ -0,0 +1,55 @@
#include "meta.h"
#include "../layout/layout.h"
#include "../coding/coding.h"
/* FILp - from Resident Evil: Dead Aim (PS2) */
VGMSTREAM* init_vgmstream_filp(STREAMFILE* sf) {
VGMSTREAM* vgmstream = NULL;
uint32_t start_offset;
int channels, loop_flag;
/* checks */
if (!is_id32be(0x00,sf, "FILp"))
return NULL;
/* .fil: extension in bigfile */
if (!check_extensions(sf,"fil"))
return NULL;
channels = read_s32le(0x04,sf); /* stereo only though */
if (read_32bitLE(0x0C,sf) != get_streamfile_size(sf))
goto fail;
loop_flag = (read_u32le(0x34,sf) == 0x00); /* 00/01/02 */
if (!is_id32be(0x100,sf, "VAGp"))
return NULL;
if (!is_id32be(0x130,sf, "VAGp"))
return NULL;
start_offset = 0x00; /* multiple FILp blocks pasted together (each including VAGps, but their sizes refer to the whole thing) */
/* build the VGMSTREAM */
vgmstream = allocate_vgmstream(channels, loop_flag);
if (!vgmstream) goto fail;
vgmstream->meta_type = meta_FILP;
vgmstream->sample_rate = read_s32le(0x110,sf);
vgmstream->num_samples = ps_bytes_to_samples(read_u32le(0x10C,sf), 1); /* channel size for the whole stream */
vgmstream->loop_start_sample = 0;
vgmstream->loop_end_sample = vgmstream->num_samples;
vgmstream->coding_type = coding_PSX;
vgmstream->layout_type = layout_blocked_filp;
if (!vgmstream_open_stream(vgmstream, sf, start_offset))
goto fail;
block_update(start_offset, vgmstream);
return vgmstream;
fail:
close_vgmstream(vgmstream);
return NULL;
}

View File

@ -4,55 +4,55 @@
#include "../util/chunks.h"
/* GSP+GSB - from Tecmo's Super Swing Golf 1 & 2 (Wii), Quantum Theory (PS3/X360) */
VGMSTREAM* init_vgmstream_gsp_gsb(STREAMFILE* sf) {
VGMSTREAM* init_vgmstream_gsnd(STREAMFILE* sf) {
VGMSTREAM* vgmstream = NULL;
STREAMFILE* sf_head = NULL;
STREAMFILE* sb = NULL;
int loop_flag, channel_count, sample_rate, num_samples, loop_start, loop_end;
off_t start_offset, chunk_offset, first_offset;
size_t data_size;
int codec;
/* checks */
if (!check_extensions(sf,"gsb"))
if (!is_id32be(0x00,sf, "GSND"))
goto fail;
sf_head = open_streamfile_by_ext(sf, "gsp");
if (!sf_head) goto fail;
if (!is_id32be(0x00,sf_head, "GSND"))
if (!check_extensions(sf,"gsp"))
goto fail;
sb = open_streamfile_by_ext(sf, "gsb");
if (!sb) goto fail;
/* 0x04: version? */
/* 0x08: 1? */
/* 0x0c: 0? */
first_offset = read_32bitBE(0x10,sf_head); /* usually 0x14 */
first_offset = read_32bitBE(0x10,sf); /* usually 0x14 */
if (!find_chunk_be(sf_head, 0x48454144,first_offset,1, &chunk_offset,NULL)) /* "HEAD" */
if (!find_chunk_be(sf, get_id32be("HEAD"),first_offset,1, &chunk_offset,NULL))
goto fail;
/* 0x00: header size */
/* 0x04: num_chunks */
if (!find_chunk_be(sf_head, 0x44415441,first_offset,1, &chunk_offset,NULL)) /* "DATA" */
if (!find_chunk_be(sf, get_id32be("DATA"),first_offset,1, &chunk_offset,NULL))
goto fail;
data_size = read_32bitBE(chunk_offset + 0x00,sf_head);
codec = read_32bitBE(chunk_offset + 0x04,sf_head);
sample_rate = read_32bitBE(chunk_offset + 0x08,sf_head);
data_size = read_32bitBE(chunk_offset + 0x00,sf);
codec = read_32bitBE(chunk_offset + 0x04,sf);
sample_rate = read_32bitBE(chunk_offset + 0x08,sf);
/* 0x0c: always 16? */
channel_count = read_16bitBE(chunk_offset + 0x0e,sf_head);
channel_count = read_16bitBE(chunk_offset + 0x0e,sf);
/* 0x10: always 0? */
num_samples = read_32bitBE(chunk_offset + 0x14,sf_head);
num_samples = read_32bitBE(chunk_offset + 0x14,sf);
/* 0x18: always 0? */
/* 0x1c: unk (varies with codec_id) */
if (!find_chunk_be(sf_head, 0x42534943,first_offset,1, &chunk_offset,NULL)) /* "BSIC" */
if (!find_chunk_be(sf, get_id32be("BSIC"),first_offset,1, &chunk_offset,NULL))
goto fail;
/* 0x00/0x04: probably volume/pan/etc floats (1.0) */
/* 0x08: null? */
loop_flag = read_8bit(chunk_offset+0x0c,sf_head);
loop_start = read_32bitBE(chunk_offset+0x10,sf_head);
loop_end = read_32bitBE(chunk_offset+0x14,sf_head);
loop_flag = read_8bit(chunk_offset+0x0c,sf);
loop_start = read_32bitBE(chunk_offset+0x10,sf);
loop_end = read_32bitBE(chunk_offset+0x14,sf);
//if (!find_chunk_be(streamHeader, 0x4E414D45,first_offset,1, &chunk_offset,NULL)) /* "NAME" */
//if (!find_chunk_be(streamHeader, get_id32be("NAME"),first_offset,1, &chunk_offset,NULL))
// goto fail;
/* 0x00: name_size */
/* 0x04+: name (same as filename) */
@ -65,7 +65,7 @@ VGMSTREAM* init_vgmstream_gsp_gsb(STREAMFILE* sf) {
vgmstream = allocate_vgmstream(channel_count,loop_flag);
if (!vgmstream) goto fail;
vgmstream->meta_type = meta_GSP_GSB;
vgmstream->meta_type = meta_GSND;
vgmstream->sample_rate = sample_rate;
vgmstream->num_samples = num_samples;
@ -80,16 +80,16 @@ VGMSTREAM* init_vgmstream_gsp_gsb(STREAMFILE* sf) {
vgmstream->coding_type = coding_NGC_DSP;
vgmstream->layout_type = layout_blocked_gsb;
if (!find_chunk_be(sf_head, 0x47434558,first_offset,1, &chunk_offset,NULL)) /* "GCEX" */
if (!find_chunk_be(sf, get_id32be("GCEX"),first_offset,1, &chunk_offset,NULL))
goto fail;
//vgmstream->current_block_size = read_32bitBE(chunk_offset+0x00,streamHeader);
block_header_size = read_32bitBE(chunk_offset+0x04,sf_head);
num_blocks = read_32bitBE(chunk_offset+0x08,sf_head);
block_header_size = read_32bitBE(chunk_offset+0x04,sf);
num_blocks = read_32bitBE(chunk_offset+0x08,sf);
vgmstream->num_samples = (data_size - block_header_size * num_blocks) / 8 / vgmstream->channels * 14;
/* 0x0c+: unk */
dsp_read_coefs_be(vgmstream, sf_head, chunk_offset+0x18, 0x30);
dsp_read_coefs_be(vgmstream, sf, chunk_offset+0x18, 0x30);
break;
}
#ifdef VGM_USE_FFMPEG
@ -101,7 +101,7 @@ VGMSTREAM* init_vgmstream_gsp_gsb(STREAMFILE* sf) {
vgmstream->num_samples = atrac3_bytes_to_samples(data_size, block_align) - encoder_delay;
/* fix num_samples as header samples seem to be modified to match altered (49999/48001) sample rates somehow */
vgmstream->codec_data = init_ffmpeg_atrac3_raw(sf, start_offset,data_size, vgmstream->num_samples,vgmstream->channels,vgmstream->sample_rate, block_align, encoder_delay);
vgmstream->codec_data = init_ffmpeg_atrac3_raw(sb, start_offset,data_size, vgmstream->num_samples,vgmstream->channels,vgmstream->sample_rate, block_align, encoder_delay);
if (!vgmstream->codec_data) goto fail;
vgmstream->coding_type = coding_FFmpeg;
vgmstream->layout_type = layout_none;
@ -112,18 +112,18 @@ VGMSTREAM* init_vgmstream_gsp_gsb(STREAMFILE* sf) {
break;
}
case 0x09: { /* XMA2 [Quantum Theory (PS3)] */
if (!find_chunk_be(sf_head, 0x584D4558,first_offset,1, &chunk_offset,NULL)) /* "XMEX" */
case 0x09: { /* XMA2 [Quantum Theory (X360)] */
if (!find_chunk_be(sf, get_id32be("XMEX"),first_offset,1, &chunk_offset,NULL)) /* "XMEX" */
goto fail;
/* 0x00: fmt0x166 header (BE) */
/* 0x34: seek table */
vgmstream->codec_data = init_ffmpeg_xma_chunk_split(sf_head, sf, start_offset, data_size, chunk_offset, 0x34);
vgmstream->codec_data = init_ffmpeg_xma_chunk_split(sf, sb, start_offset, data_size, chunk_offset, 0x34);
if (!vgmstream->codec_data) goto fail;
vgmstream->coding_type = coding_FFmpeg;
vgmstream->layout_type = layout_none;
xma_fix_raw_samples(vgmstream, sf, start_offset,data_size, 0, 0,0); /* samples are ok */
xma_fix_raw_samples(vgmstream, sb, start_offset,data_size, 0, 0,0); /* samples are ok */
break;
}
#endif
@ -132,13 +132,13 @@ VGMSTREAM* init_vgmstream_gsp_gsb(STREAMFILE* sf) {
}
if (!vgmstream_open_stream(vgmstream, sf, start_offset))
if (!vgmstream_open_stream(vgmstream, sb, start_offset))
goto fail;
close_streamfile(sf_head);
close_streamfile(sb);
return vgmstream;
fail:
close_streamfile(sf_head);
close_streamfile(sb);
close_vgmstream(vgmstream);
return NULL;
}

View File

@ -1187,9 +1187,12 @@ static const hcakey_info hcakey_list[] = {
// Disney Star Smash (Android)
{3941111674189632}, // 000E006B915C3740
// Final Fantasy VII: Ever Crisis (Android)
// Final Fantasy VII: Ever Crisis (beta) (Android)
{19629307353822}, // 000011DA4DE45ADE
// Tower of Sky (Android)
{5893902754391672}, // 0014F0792C042678
};
#endif/*_HCA_KEYS_H_*/

41
src/meta/hgc1.c Normal file
View File

@ -0,0 +1,41 @@
#include "meta.h"
#include "../coding/coding.h"
/* hgC1 - from Knights of the Temple 2 (PS2) */
VGMSTREAM* init_vgmstream_hgc1(STREAMFILE* sf) {
VGMSTREAM* vgmstream = NULL;
uint32_t start_offset;
int channels, loop_flag = 0;
/* checks */
if (!is_id32be(0x00,sf, "hgC1"))
return NULL;
if (!is_id32be(0x04,sf, "strm"))
return NULL;
if (!check_extensions(sf,"str"))
return NULL;
start_offset = 0x20;
loop_flag = 0;
channels = read_s32le(0x08,sf); /* always stereo? */
/* build the VGMSTREAM */
vgmstream = allocate_vgmstream(channels, loop_flag);
if (!vgmstream) goto fail;
vgmstream->meta_type = meta_HGC1;
vgmstream->sample_rate = read_s32le(0x10,sf);
vgmstream->num_samples = ps_bytes_to_samples(read_u32le(0x0C,sf) * 0x10, 1); /* mono frames*/
vgmstream->coding_type = coding_PSX;
vgmstream->layout_type = layout_interleave;
vgmstream->interleave_block_size = 0x10;
if (!vgmstream_open_stream(vgmstream, sf, start_offset))
goto fail;
return vgmstream;
fail:
close_vgmstream(vgmstream);
return NULL;
}

View File

@ -265,8 +265,6 @@ VGMSTREAM* init_vgmstream_wvs_ngc(STREAMFILE* sf);
VGMSTREAM * init_vgmstream_dc_str(STREAMFILE *streamFile);
VGMSTREAM * init_vgmstream_dc_str_v2(STREAMFILE *streamFile);
VGMSTREAM * init_vgmstream_xbox_matx(STREAMFILE *streamFile);
VGMSTREAM * init_vgmstream_dec(STREAMFILE *streamFile);
VGMSTREAM * init_vgmstream_vs(STREAMFILE *streamFile);
@ -300,7 +298,7 @@ VGMSTREAM * init_vgmstream_ps2_mihb(STREAMFILE * streamFile);
VGMSTREAM * init_vgmstream_ngc_pdt_split(STREAMFILE * streamFile);
VGMSTREAM * init_vgmstream_ngc_pdt(STREAMFILE * streamFile);
VGMSTREAM * init_vgmstream_wii_mus(STREAMFILE * streamFile);
VGMSTREAM* init_vgmstream_mus_krone(STREAMFILE* sf);
VGMSTREAM * init_vgmstream_rsd(STREAMFILE * streamFile);
@ -332,7 +330,7 @@ VGMSTREAM * init_vgmstream_ish_isd(STREAMFILE * streamFile);
VGMSTREAM * init_vgmstream_ydsp(STREAMFILE * streamFile);
VGMSTREAM * init_vgmstream_gsp_gsb(STREAMFILE * streamFile);
VGMSTREAM* init_vgmstream_gsnd(STREAMFILE* sf);
VGMSTREAM * init_vgmstream_ngc_ssm(STREAMFILE * streamFile);
@ -412,7 +410,7 @@ VGMSTREAM * init_vgmstream_sab(STREAMFILE* streamFile);
VGMSTREAM * init_vgmstream_exakt_sc(STREAMFILE* streamFile);
VGMSTREAM * init_vgmstream_wii_bns(STREAMFILE* streamFile);
VGMSTREAM* init_vgmstream_bns(STREAMFILE* sf);
VGMSTREAM * init_vgmstream_pona_3do(STREAMFILE* streamFile);
VGMSTREAM * init_vgmstream_pona_psx(STREAMFILE* streamFile);
@ -433,7 +431,7 @@ VGMSTREAM * init_vgmstream_ngc_dsp_konami(STREAMFILE* streamFile);
VGMSTREAM * init_vgmstream_bnsf(STREAMFILE* streamFile);
VGMSTREAM * init_vgmstream_ps2_wb(STREAMFILE* streamFile);
VGMSTREAM* init_vgmstream_wb(STREAMFILE* sf);
VGMSTREAM* init_vgmstream_raw_s14_sss(STREAMFILE* sf);
@ -455,8 +453,6 @@ VGMSTREAM * init_vgmstream_ea_swvr(STREAMFILE* streamFile);
VGMSTREAM * init_vgmstream_ps2_b1s(STREAMFILE* streamFile);
VGMSTREAM * init_vgmstream_ps2_wad(STREAMFILE* streamFile);
VGMSTREAM * init_vgmstream_ps2_adm(STREAMFILE* streamFile);
VGMSTREAM* init_vgmstream_lpcm_shade(STREAMFILE* sf);
@ -982,4 +978,6 @@ VGMSTREAM* init_vgmstream_rws_809(STREAMFILE* sf);
VGMSTREAM* init_vgmstream_pwb(STREAMFILE* sf);
VGMSTREAM* init_vgmstream_rawi(STREAMFILE* sf);
#endif /*_META_H*/

56
src/meta/mus_krone.c Normal file
View File

@ -0,0 +1,56 @@
#include "meta.h"
#include "../layout/layout.h"
#include "../coding/coding.h"
/* .mus - from Star Wars: The Force Unleashed (Wii) */
VGMSTREAM* init_vgmstream_mus_krone(STREAMFILE* sf) {
VGMSTREAM* vgmstream = NULL;
uint32_t start_offset, data_size;
int channels, loop_flag, interleave;
int32_t num_samples;
/* checks */
num_samples = read_s32be(0x00,sf);
interleave = read_s32be(0x04,sf);
start_offset = read_u32be(0x08,sf);
data_size = read_u32be(0x0c,sf);
if (interleave != 0x8000)
return NULL;
if (start_offset != 0x80)
return NULL;
if (data_size + start_offset != get_streamfile_size(sf))
return NULL;
/* could test gain/initial ps at 0x10 + 0x20 too */
if (!check_extensions(sf,"mus"))
return NULL;
channels = 2;
loop_flag = 0;
/* build the VGMSTREAM */
vgmstream = allocate_vgmstream(channels, loop_flag);
if (!vgmstream) goto fail;
vgmstream->meta_type = meta_MUS_KRONE;
vgmstream->num_samples = num_samples;
vgmstream->sample_rate = read_u16be(0x6c,sf);
vgmstream->coding_type = coding_NGC_DSP;
vgmstream->layout_type = layout_interleave;
vgmstream->interleave_block_size = interleave; /* no last block size unlike similar DSPs */
dsp_read_coefs_be(vgmstream, sf, 0x10, 0x2e);
dsp_read_hist_be(vgmstream, sf, 0x10 + 0x24, 0x2e);
if (!vgmstream_open_stream(vgmstream, sf, start_offset))
goto fail;
return vgmstream;
fail:
close_vgmstream(vgmstream);
return NULL;
}

View File

@ -1,65 +0,0 @@
#include "meta.h"
#include "../util.h"
/* BG0 (from Ibara, Mushihimesama)
Note: Seems the Loop Infos are stored external... */
VGMSTREAM * init_vgmstream_bg00(STREAMFILE *streamFile) {
VGMSTREAM * vgmstream = NULL;
char filename[PATH_LIMIT];
off_t start_offset;
int loop_flag = 0;
int channel_count;
/* check extension, case insensitive */
streamFile->get_name(streamFile,filename,sizeof(filename));
if (strcasecmp("bg00",filename_extension(filename))) goto fail;
/* check header */
if (read_32bitBE(0x00,streamFile) != 0x42473030) /* "BG00" */
goto fail;
loop_flag = (read_32bitLE(0x08,streamFile)!=0);
channel_count = 2;
/* build the VGMSTREAM */
vgmstream = allocate_vgmstream(channel_count,loop_flag);
if (!vgmstream) goto fail;
/* fill in the vital statistics */
start_offset = 0x800;
vgmstream->channels = channel_count;
vgmstream->sample_rate = read_32bitBE(0x80,streamFile);
vgmstream->coding_type = coding_PSX;
vgmstream->num_samples = (read_32bitBE(0x4C,streamFile)*2)*28/16/channel_count;
if (loop_flag) {
vgmstream->loop_start_sample = 0;
vgmstream->loop_end_sample = (read_32bitBE(0x4C,streamFile)*2)*28/16/channel_count;
}
vgmstream->layout_type = layout_interleave;
vgmstream->interleave_block_size = read_32bitLE(0x10,streamFile);
vgmstream->meta_type = meta_BG00;
/* open the file for reading */
{
int i;
STREAMFILE * file;
file = streamFile->open(streamFile,filename,STREAMFILE_DEFAULT_BUFFER_SIZE);
if (!file) goto fail;
for (i=0;i<channel_count;i++) {
vgmstream->ch[i].streamfile = file;
vgmstream->ch[i].channel_start_offset=
vgmstream->ch[i].offset=start_offset+
vgmstream->interleave_block_size*i;
}
}
return vgmstream;
/* clean up anything we may have opened */
fail:
if (vgmstream) close_vgmstream(vgmstream);
return NULL;
}

View File

@ -1,67 +0,0 @@
#include "meta.h"
#include "../layout/layout.h"
#include "../util.h"
/* FILp (Resident Evil - Dead Aim) */
VGMSTREAM * init_vgmstream_filp(STREAMFILE *streamFile) {
VGMSTREAM * vgmstream = NULL;
char filename[PATH_LIMIT];
off_t start_offset;
int loop_flag = 0;
int channel_count;
int i;
/* check extension, case insensitive */
streamFile->get_name(streamFile,filename,sizeof(filename));
if (strcasecmp("filp",filename_extension(filename))) goto fail;
/* check header */
if (read_32bitBE(0x0,streamFile) != 0x46494C70) /* "FILp" */
goto fail;
if (read_32bitBE(0x100,streamFile) != 0x56414770) /* "VAGp" */
goto fail;
if (read_32bitBE(0x130,streamFile) != 0x56414770) /* "VAGp" */
goto fail;
if (get_streamfile_size(streamFile) != read_32bitLE(0xC,streamFile))
goto fail;
loop_flag = (read_32bitLE(0x34,streamFile) == 0);
channel_count = read_32bitLE(0x4,streamFile);
/* build the VGMSTREAM */
vgmstream = allocate_vgmstream(channel_count,loop_flag);
if (!vgmstream) goto fail;
/* fill in the vital statistics */
start_offset = 0x0;
vgmstream->channels = channel_count;
vgmstream->sample_rate = read_32bitLE(0x110,streamFile);
vgmstream->coding_type = coding_PSX;
vgmstream->layout_type = layout_blocked_filp;
vgmstream->meta_type = meta_FILP;
/* open the file for reading */
{
STREAMFILE * file;
file = streamFile->open(streamFile,filename,STREAMFILE_DEFAULT_BUFFER_SIZE);
if (!file) goto fail;
for (i=0;i<channel_count;i++) {
vgmstream->ch[i].streamfile = file;
}
}
block_update_filp(start_offset,vgmstream);
vgmstream->num_samples = read_32bitLE(0x10C,streamFile)/16*28;
if (loop_flag) {
vgmstream->loop_start_sample = 0;
vgmstream->loop_end_sample = vgmstream->num_samples;
}
return vgmstream;
/* clean up anything we may have opened */
fail:
if (vgmstream) close_vgmstream(vgmstream);
return NULL;
}

View File

@ -1,64 +0,0 @@
#include "meta.h"
#include "../util.h"
/* hgC1 (from Knights of the Temple 2) */
VGMSTREAM * init_vgmstream_hgc1(STREAMFILE *streamFile) {
VGMSTREAM * vgmstream = NULL;
char filename[PATH_LIMIT];
off_t start_offset;
int loop_flag = 0;
int channel_count;
/* check extension, case insensitive */
streamFile->get_name(streamFile,filename,sizeof(filename));
if (strcasecmp("hgc1",filename_extension(filename))) goto fail;
/* check header */
if (read_32bitBE(0x00,streamFile) != 0x68674331) /* "hgC1" */
goto fail;
loop_flag = 0;
channel_count = read_32bitLE(0x08,streamFile);
/* build the VGMSTREAM */
vgmstream = allocate_vgmstream(channel_count,loop_flag);
if (!vgmstream) goto fail;
/* fill in the vital statistics */
start_offset = 0x40;
vgmstream->channels = channel_count;
vgmstream->sample_rate = read_32bitLE(0x10,streamFile);
vgmstream->coding_type = coding_PSX;
vgmstream->num_samples = (read_32bitLE(0x0C,streamFile)*32)/channel_count/16*28;
if (loop_flag) {
vgmstream->loop_start_sample = 0;
vgmstream->loop_end_sample = (read_32bitLE(0x0C,streamFile)*32)/channel_count/16*28;
}
vgmstream->layout_type = layout_interleave;
vgmstream->interleave_block_size = 0x10;
vgmstream->meta_type = meta_HGC1;
/* open the file for reading */
{
int i;
STREAMFILE * file;
file = streamFile->open(streamFile,filename,STREAMFILE_DEFAULT_BUFFER_SIZE);
if (!file) goto fail;
for (i=0;i<channel_count;i++) {
vgmstream->ch[i].streamfile = file;
vgmstream->ch[i].channel_start_offset=
vgmstream->ch[i].offset=start_offset+
vgmstream->interleave_block_size*i;
}
}
return vgmstream;
/* clean up anything we may have opened */
fail:
if (vgmstream) close_vgmstream(vgmstream);
return NULL;
}

View File

@ -1,45 +0,0 @@
#include "meta.h"
#include "../coding/coding.h"
/* SL3 - Atari Melbourne House games [ Test Drive Unlimited (PS2), Transformers (PS2)] */
VGMSTREAM * init_vgmstream_sl3(STREAMFILE *streamFile) {
VGMSTREAM * vgmstream = NULL;
off_t start_offset;
int loop_flag = 0, channel_count;
/* checks */
/* .ms: actual extension, sl3: header id */
if (!check_extensions(streamFile, "ms,sl3"))
goto fail;
if (read_32bitBE(0x00,streamFile) != 0x534C3300) /* "SL3\0" */
goto fail;
loop_flag = 0;
channel_count = read_32bitLE(0x14,streamFile);
start_offset = 0x8000; /* also at 0x24? */
/* build the VGMSTREAM */
vgmstream = allocate_vgmstream(channel_count,loop_flag);
if (!vgmstream) goto fail;
vgmstream->sample_rate = read_32bitLE(0x18,streamFile);
vgmstream->num_samples = ps_bytes_to_samples(get_streamfile_size(streamFile)-start_offset,channel_count);
if (loop_flag) {
vgmstream->loop_start_sample = 0;
vgmstream->loop_end_sample = read_32bitLE(0x1C,streamFile);
}
vgmstream->coding_type = coding_PSX;
vgmstream->layout_type = layout_interleave;
vgmstream->interleave_block_size = read_32bitLE(0x20,streamFile);
vgmstream->meta_type = meta_SL3;
if (!vgmstream_open_stream(vgmstream,streamFile,start_offset))
goto fail;
return vgmstream;
fail:
close_vgmstream(vgmstream);
return NULL;
}

View File

@ -1,71 +0,0 @@
#include "meta.h"
#include "../util.h"
/* WAD (from The golden Compass) */
VGMSTREAM * init_vgmstream_ps2_wad(STREAMFILE *streamFile) {
VGMSTREAM * vgmstream = NULL;
char filename[PATH_LIMIT];
int loop_flag = 0;
int channel_count;
off_t start_offset;
/* check extension, case insensitive */
streamFile->get_name(streamFile,filename,sizeof(filename));
if (strcasecmp("wad",filename_extension(filename))) goto fail;
/* check header */
if ((read_32bitLE(0x00,streamFile)+0x40) != get_streamfile_size(streamFile))
goto fail;
loop_flag = 0;
channel_count = (uint16_t) read_16bitLE(0x4,streamFile);
/* build the VGMSTREAM */
vgmstream = allocate_vgmstream(channel_count,loop_flag);
if (!vgmstream) goto fail;
/* fill in the vital statistics */
start_offset = 0x40;
vgmstream->channels = channel_count;
vgmstream->sample_rate = (uint16_t) read_16bitLE(0x6,streamFile);;
vgmstream->coding_type = coding_PSX;
vgmstream->num_samples = read_32bitLE(0x0,streamFile)/channel_count/16*28;
if (loop_flag) {
vgmstream->loop_start_sample = 0;
vgmstream->loop_end_sample = read_32bitLE(0x0,streamFile)/channel_count/16*28;
}
if (channel_count == 1)
{
vgmstream->layout_type = layout_none;
}
else
{
goto fail;
}
vgmstream->meta_type = meta_PS2_WAD;
/* open the file for reading */
{
int i;
STREAMFILE * file;
file = streamFile->open(streamFile,filename,STREAMFILE_DEFAULT_BUFFER_SIZE);
if (!file) goto fail;
for (i=0;i<channel_count;i++) {
vgmstream->ch[i].streamfile = file;
vgmstream->ch[i].channel_start_offset=
vgmstream->ch[i].offset=start_offset+
vgmstream->interleave_block_size*i;
}
}
return vgmstream;
/* clean up anything we may have opened */
fail:
if (vgmstream) close_vgmstream(vgmstream);
return NULL;
}

View File

@ -1,64 +0,0 @@
#include "meta.h"
#include "../util.h"
/* WB (from Shooting Love. ~TRIZEAL~) */
VGMSTREAM * init_vgmstream_ps2_wb(STREAMFILE *streamFile) {
VGMSTREAM * vgmstream = NULL;
char filename[PATH_LIMIT];
off_t start_offset;
int loop_flag;
int channel_count;
/* check extension, case insensitive */
streamFile->get_name(streamFile,filename,sizeof(filename));
if (strcasecmp("wb",filename_extension(filename))) goto fail;
/* check header */
if (read_32bitBE(0,streamFile) != 0x00000000)
goto fail;
loop_flag = read_32bitLE(0x4,streamFile);
channel_count = 2;
/* build the VGMSTREAM */
vgmstream = allocate_vgmstream(channel_count,loop_flag);
if (!vgmstream) goto fail;
/* fill in the vital statistics */
start_offset = 0x10;
vgmstream->channels = channel_count;
vgmstream->sample_rate = 48000;
vgmstream->coding_type = coding_PCM16LE;
vgmstream->num_samples = read_32bitLE(0xC,streamFile)/4;
if (loop_flag) {
vgmstream->loop_start_sample = read_32bitLE(0x4,streamFile);
vgmstream->loop_end_sample = read_32bitLE(0x8,streamFile);
}
vgmstream->layout_type = layout_interleave;
vgmstream->interleave_block_size = 2;
vgmstream->meta_type = meta_PS2_WB;
/* open the file for reading */
{
int i;
STREAMFILE * file;
file = streamFile->open(streamFile,filename,STREAMFILE_DEFAULT_BUFFER_SIZE);
if (!file) goto fail;
for (i=0;i<channel_count;i++) {
vgmstream->ch[i].streamfile = file;
vgmstream->ch[i].channel_start_offset=
vgmstream->ch[i].offset=start_offset+
vgmstream->interleave_block_size*i;
}
}
return vgmstream;
fail:
/* clean up anything we may have opened */
if (vgmstream) close_vgmstream(vgmstream);
return NULL;
}

178
src/meta/rawi.c Normal file
View File

@ -0,0 +1,178 @@
#include "meta.h"
#include "../layout/layout.h"
#include "../coding/coding.h"
#include "../util/endianness.h"
/* RAWI - from Torus games "SqueakStream" samples */
VGMSTREAM* init_vgmstream_rawi(STREAMFILE* sf) {
VGMSTREAM* vgmstream = NULL;
STREAMFILE* sb = NULL;
STREAMFILE* sn = NULL;
uint32_t start_offset, name_offset, extn_offset, interleave;
int channels, loop_flag, codec, sample_rate;
int32_t num_samples, loop_start, loop_end;
/* checks */
bool big_endian = false;
if (is_id32be(0x00,sf, "RAWI"))
big_endian = false;
else if (is_id32be(0x00,sf, "IWAR"))
big_endian = true; /* Wii/PS3 */
else
return NULL;
//TODO: handle first version used in Scooby Doo! First Frights (similar but larger fields and no header ID)
/* (extensionless): no known extension */
if (!check_extensions(sf,""))
return NULL;
read_s32_t read_s32 = big_endian ? read_s32be : read_s32le;
read_u32_t read_u32 = big_endian ? read_u32be : read_u32le;
/* mini header with a string to the external asset; on Wii this string is also in a separate file */
if (read_u8(0x04,sf) != 0x01) /* version? */
return NULL;
codec = read_u8(0x05,sf);
channels = read_u8(0x06,sf);
/* 0x07: null */
num_samples = read_s32(0x08, sf);
sample_rate = read_s32(0x0c, sf);
loop_start = read_s32(0x10, sf);
loop_end = read_s32(0x14, sf);
//etbl_offset = read_u32(0x18, sf);
name_offset = read_u32(0x1c, sf);
/* 0x20: null, unknown values (sometimes floats) */
interleave = read_u32(0x38, sf);
/* extra values, then DSP coefs if needed, then asset name (header size is not exact) */
extn_offset = (name_offset >> 24) & 0xFF; /* if name is external, sub-offset inside that file */
name_offset = (name_offset >> 0) & 0xFFFFFF; /* if name is external, default/unused (same with etbl_offset) */
/* simplify as Wii defines both and uses a separate file, PS3 only defines extn and doesn't use separate */
if (extn_offset && !name_offset) {
name_offset = extn_offset;
extn_offset = 0;
}
loop_flag = loop_end > 0;
start_offset = 0x00;
/* open external asset */
{
char asset_name[0x20]; /* "(8-byte crc).raw", "MU(6-byte crc).raw" */
if (extn_offset) {
sn = open_streamfile_by_ext(sf, "asset"); /* unknown real extension, based on debug strings */
if (!sn) {
vgm_logi("RAWI: external name '.asset' not found (put together)\n");
goto fail;
}
read_string(asset_name, sizeof(asset_name), extn_offset, sn);
}
else {
read_string(asset_name, sizeof(asset_name), name_offset, sf);
}
/* try to open external asset in various ways, since this format is a bit hard to use */
/* "(asset name)": plain as found */
if (!sb){
sb = open_streamfile_by_filename(sf, asset_name);
}
/* "sound/(asset name)": most common way to store files */
char path_name[256];
snprintf(path_name, sizeof(path_name), "sound/%s", asset_name);
if (!sb){
sb = open_streamfile_by_filename(sf, path_name);
}
/* "(header name).raw": for renamed files */
if (!sb){
sb = open_streamfile_by_ext(sf, "raw");
}
if (!sb) {
vgm_logi("RAWI: external file '%s' not found (put together)\n", asset_name);
goto fail;
}
}
/* build the VGMSTREAM */
vgmstream = allocate_vgmstream(channels, loop_flag);
if (!vgmstream) goto fail;
vgmstream->meta_type = meta_RAWI;
vgmstream->sample_rate = sample_rate;
vgmstream->num_samples = num_samples;
vgmstream->loop_start_sample = loop_start;
vgmstream->loop_end_sample = loop_end + 1;
switch(codec) {
case 0x00: /* Turbo Super Stunt Squad (Wii/3DS), Penguins of Madagascar (Wii/U/3DS) */
vgmstream->coding_type = coding_NGC_DSP;
vgmstream->layout_type = layout_interleave;
vgmstream->interleave_block_size = interleave;
//vgmstream->interleave_last_block_size = ...; /* apparently padded */
/* etbl_offset defines N coef offset per channel (with external name, etbl_offset is ignored and offsets start at 0x00 in .asset instead)
* but in practice this seem fixed */
dsp_read_coefs(vgmstream, sf, 0x40, 0x30, big_endian);
dsp_read_hist(vgmstream, sf, 0x40 + 0x24, 0x30, big_endian);
break;
case 0x01: /* Falling Skies The Game (PC) */
vgmstream->coding_type = coding_PCM16BE;
vgmstream->layout_type = layout_interleave;
vgmstream->interleave_block_size = interleave; /* not 0x02 */
case 0x02: /* Falling Skies The Game (X360) */
vgmstream->coding_type = coding_PCM16BE;
vgmstream->layout_type = layout_interleave;
vgmstream->interleave_block_size = interleave; /* not 0x02 */
/* etbl_offset may set offsets to RIFF fmts per channel) */
break;
case 0x03: /* How to Train Your Dragon 2 (PS3), Falling Skies The Game (PS3) */
vgmstream->coding_type = coding_PSX;
vgmstream->layout_type = layout_interleave;
vgmstream->interleave_block_size = interleave;
break;
case 0x05: /* Scooby Doo and the Spooky Swamp (DS) */
vgmstream->coding_type = coding_PCM8;
vgmstream->layout_type = layout_interleave;
vgmstream->interleave_block_size = interleave;
break;
case 0x09: /* Turbo Super Stunt Squad (DS) */
vgmstream->coding_type = coding_MS_IMA;
vgmstream->layout_type = layout_none;
//vgmstream->interleave_block_size = interleave; /* unused? (mono) */
vgmstream->frame_size = 0x20;
break;
default:
vgm_logi("RAWI: unknown codec %x (report)\n", codec);
goto fail;
}
if (!vgmstream_open_stream(vgmstream, sb, start_offset))
goto fail;
close_streamfile(sb);
close_streamfile(sn);
return vgmstream;
fail:
close_streamfile(sb);
close_streamfile(sn);
close_vgmstream(vgmstream);
return NULL;
}

41
src/meta/sl3.c Normal file
View File

@ -0,0 +1,41 @@
#include "meta.h"
#include "../coding/coding.h"
/* SL3 - Sirens Sound Library (Winky Soft / Atari Melbourne House) games [Test Drive Unlimited (PS2), Transformers 2003/2004 (PS2)] */
VGMSTREAM* init_vgmstream_sl3(STREAMFILE* sf) {
VGMSTREAM* vgmstream = NULL;
off_t start_offset;
int loop_flag = 0, channels;
/* checks */
if (!is_id32be(0x00,sf, "SL3\0"))
goto fail;
/* .ms: actual extension */
if (!check_extensions(sf, "ms"))
goto fail;
loop_flag = 0;
channels = read_32bitLE(0x14,sf);
start_offset = 0x8000; /* also at 0x24? */
/* build the VGMSTREAM */
vgmstream = allocate_vgmstream(channels, loop_flag);
if (!vgmstream) goto fail;
vgmstream->meta_type = meta_SL3;
vgmstream->sample_rate = read_32bitLE(0x18,sf);
vgmstream->num_samples = ps_bytes_to_samples(get_streamfile_size(sf)-start_offset,channels);
vgmstream->coding_type = coding_PSX;
vgmstream->layout_type = layout_interleave;
vgmstream->interleave_block_size = read_32bitLE(0x20,sf);
if (!vgmstream_open_stream(vgmstream,sf,start_offset))
goto fail;
return vgmstream;
fail:
close_vgmstream(vgmstream);
return NULL;
}

View File

@ -142,6 +142,8 @@ typedef struct {
int chunk_start_set;
int chunk_size_set;
int chunk_count_set;
int chunk_bsize_set;
int chunk_dsize_set;
uint32_t base_offset;
uint32_t is_offset_absolute;
@ -827,7 +829,8 @@ static void set_body_chunk(txth_header* txth) {
//todo maybe should only be done once, or have some count to retrigger to simplify?
if (!txth->chunk_start_set || !txth->chunk_size_set || !txth->chunk_count_set)
return;
if (txth->chunk_size == 0 && !(txth->chunk_bsize_offset || txth->chunk_dsize_offset))
if (txth->chunk_size == 0 && !(txth->chunk_bsize_set || txth->chunk_dsize_set))
return;
if (txth->chunk_start > txth->data_size || txth->chunk_count == 0)
return;
@ -853,6 +856,8 @@ static void set_body_chunk(txth_header* txth) {
cfg.chunk_bsize_offset = txth->chunk_bsize_offset;
cfg.chunk_dsize_offset = txth->chunk_dsize_offset;
cfg.chunk_be = txth->chunk_big_endian;
cfg.chunk_bsize_set = txth->chunk_bsize_set;
cfg.chunk_dsize_set = txth->chunk_dsize_set;
cfg.chunk_start = txth->chunk_start;
cfg.chunk_size = txth->chunk_size;
@ -1473,10 +1478,12 @@ static int parse_keyval(STREAMFILE* sf_, txth_header* txth, const char* key, cha
else if (is_string(key,"chunk_size_offset")) {
if (!parse_num(txth->sf_head,txth,val, &txth->chunk_bsize_offset)) goto fail;
txth->chunk_size_set = 1;
txth->chunk_bsize_set = 1;
}
else if (is_string(key,"chunk_data_size_offset")) {
if (!parse_num(txth->sf_head,txth,val, &txth->chunk_dsize_offset)) goto fail;
txth->chunk_size_set = 1;
txth->chunk_dsize_set = 1;
}
else if (is_string(key,"chunk_endianness")) {
if (!parse_endianness(txth, val, &txth->chunk_big_endian, NULL)) goto fail;

View File

@ -17,6 +17,8 @@ typedef struct {
uint32_t chunk_bsize_offset;
uint32_t chunk_dsize_offset;
int chunk_be;
int chunk_bsize_set;
int chunk_dsize_set;
} txth_io_config_data;
typedef struct {
@ -72,15 +74,15 @@ static size_t txth_io_read(STREAMFILE* sf, uint8_t* dest, off_t offset, size_t l
}
/* chunk size reader (overwrites the above) */
if (data->cfg.chunk_header_size && (data->cfg.chunk_bsize_offset || data->cfg.chunk_dsize_offset)) {
if (data->cfg.chunk_header_size && (data->cfg.chunk_bsize_set || data->cfg.chunk_dsize_set)) {
read_u32_t read_u32 = data->cfg.chunk_be ? read_u32be : read_u32le;
data->block_size = 0;
data->data_size = 0;
if (data->cfg.chunk_bsize_offset)
if (data->cfg.chunk_bsize_set)
data->block_size = read_u32(data->physical_offset + data->cfg.chunk_bsize_offset, sf);
if (data->cfg.chunk_dsize_offset)
if (data->cfg.chunk_dsize_set)
data->data_size = read_u32(data->physical_offset + data->cfg.chunk_dsize_offset, sf);
if (!data->block_size && !data->data_size) { /* bad read? */

45
src/meta/wb.c Normal file
View File

@ -0,0 +1,45 @@
#include "meta.h"
#include "../coding/coding.h"
/* .WB - from Shooting Love. ~TRIZEAL~ */
VGMSTREAM* init_vgmstream_wb(STREAMFILE* sf) {
VGMSTREAM* vgmstream = NULL;
uint32_t start_offset;
int channels, loop_flag;
/* check header */
if (read_u32le(0x00,sf) != 0x00000000)
return NULL;
if (read_u32le(0x0c,sf) + 0x10 != get_streamfile_size(sf))
return NULL;
/* .wb: actual extension */
if (!check_extensions(sf,"wb"))
goto fail;
channels = 2;
start_offset = 0x10;
loop_flag = read_32bitLE(0x04,sf) > 0; /* loop end may be defined */
/* build the VGMSTREAM */
vgmstream = allocate_vgmstream(channels,loop_flag);
if (!vgmstream) goto fail;
vgmstream->meta_type = meta_WB;
vgmstream->sample_rate = 48000;
vgmstream->num_samples = pcm16_bytes_to_samples(read_u32le(0x0C,sf), channels);
vgmstream->loop_start_sample = read_s32le(0x04,sf);
vgmstream->loop_end_sample = read_s32le(0x08,sf);
vgmstream->coding_type = coding_PCM16LE;
vgmstream->layout_type = layout_interleave;
vgmstream->interleave_block_size = 2;
if (!vgmstream_open_stream(vgmstream, sf, start_offset))
goto fail;
return vgmstream;
fail:
close_vgmstream(vgmstream);
return NULL;
}

View File

@ -1,124 +0,0 @@
#include "meta.h"
#include "../layout/layout.h"
#include "../coding/coding.h"
#include "../util.h"
/* .mus, as seen in Star Wars The Force Unleashed for Wii */
/* Doesn't seem to be working quite right yet, coef table looks odd */
VGMSTREAM * init_vgmstream_wii_mus(STREAMFILE *streamFile) {
VGMSTREAM * vgmstream = NULL;
char filename[PATH_LIMIT];
off_t start_offset;
off_t interleave;
int i;
struct {
uint16_t gain;
uint16_t initial_ps;
uint16_t initial_hist1;
uint16_t initial_hist2;
uint16_t loop_ps;
/*
uint16_t loop_hist1;
uint16_t loop_hist2;
*/
} channel[2];
/* check extension, case insensitive */
streamFile->get_name(streamFile,filename,sizeof(filename));
if (strcasecmp("mus",filename_extension(filename))) goto fail;
start_offset = read_32bitBE(0x08,streamFile);
interleave = read_32bitBE(0x04,streamFile);
for (i=0;i<2;i++)
{
channel[i].gain = read_16bitBE(0x30+i*0x2e,streamFile);
channel[i].initial_ps = read_16bitBE(0x32+i*0x2e,streamFile);
channel[i].initial_hist1 = read_16bitBE(0x34+i*0x2e,streamFile);
channel[i].initial_hist2 = read_16bitBE(0x36+i*0x2e,streamFile);
channel[i].loop_ps = read_16bitBE(0x38+i*0x2e,streamFile);
}
/* check initial predictor/scale */
if (channel[0].initial_ps != (uint8_t)read_8bit(start_offset,streamFile))
goto fail;
if (channel[1].initial_ps != (uint8_t)read_8bit(start_offset+interleave,streamFile))
goto fail;
/* check type==0 and gain==0 */
if (channel[0].gain ||
channel[1].gain)
goto fail;
#if 0
if (ch0_header.loop_flag) {
off_t loop_off;
/* check loop predictor/scale */
loop_off = ch0_header.loop_start_offset/16*8;
loop_off = (loop_off/interleave*interleave*2) + (loop_off%interleave);
if (ch0_header.loop_ps != (uint8_t)read_8bit(start_offset+loop_off,streamFile))
goto fail;
if (ch1_header.loop_ps != (uint8_t)read_8bit(start_offset+loop_off+interleave,streamFile))
goto fail;
}
#endif
/* build the VGMSTREAM */
vgmstream = allocate_vgmstream(2,0);
if (!vgmstream) goto fail;
/* fill in the vital statistics */
vgmstream->num_samples = read_32bitBE(0x0,streamFile);
vgmstream->sample_rate = (uint16_t)read_16bitBE(0x6c,streamFile);
/* TODO: adjust for interleave? */
#if 0
vgmstream->loop_start_sample = dsp_nibbles_to_samples(
ch0_header.loop_start_offset);
vgmstream->loop_end_sample = dsp_nibbles_to_samples(
ch0_header.loop_end_offset)+1;
#endif
vgmstream->coding_type = coding_NGC_DSP;
vgmstream->layout_type = layout_interleave;
vgmstream->interleave_block_size = interleave;
vgmstream->meta_type = meta_DSP_WII_MUS;
/* coeffs */
for (i=0;i<16;i++) {
vgmstream->ch[0].adpcm_coef[i] = read_16bitBE(0x10 + i*2,streamFile);
vgmstream->ch[1].adpcm_coef[i] = read_16bitBE(0x3e + i*2,streamFile);
}
/* initial history */
/* always 0 that I've ever seen, but for completeness... */
vgmstream->ch[0].adpcm_history1_16 = channel[0].initial_hist1;
vgmstream->ch[0].adpcm_history2_16 = channel[0].initial_hist2;
vgmstream->ch[1].adpcm_history1_16 = channel[1].initial_hist1;
vgmstream->ch[1].adpcm_history2_16 = channel[1].initial_hist2;
vgmstream->ch[0].streamfile = streamFile->open(streamFile,filename,STREAMFILE_DEFAULT_BUFFER_SIZE);
if (!vgmstream->ch[0].streamfile) goto fail;
vgmstream->ch[1].streamfile = streamFile->open(streamFile,filename,STREAMFILE_DEFAULT_BUFFER_SIZE);
if (!vgmstream->ch[1].streamfile) goto fail;
/* open the file for reading */
for (i=0;i<2;i++) {
vgmstream->ch[i].channel_start_offset=
vgmstream->ch[i].offset=start_offset+i*interleave;
}
return vgmstream;
fail:
/* clean up anything we may have opened */
if (vgmstream) {
if (vgmstream->ch[0].streamfile) close_streamfile(vgmstream->ch[0].streamfile);
close_vgmstream(vgmstream);
}
return NULL;
}

View File

@ -1,61 +0,0 @@
#include "meta.h"
#include "../util.h"
#include "../layout/layout.h"
/* matx
MATX (found in Matrix)
*/
VGMSTREAM * init_vgmstream_xbox_matx(STREAMFILE *streamFile) {
VGMSTREAM * vgmstream = NULL;
char filename[PATH_LIMIT];
int loop_flag=0;
int channel_count;
int i;
/* check extension, case insensitive */
streamFile->get_name(streamFile,filename,sizeof(filename));
if (strcasecmp("matx",filename_extension(filename))) goto fail;
loop_flag = 0;
channel_count=read_16bitLE(0x4,streamFile);
/* build the VGMSTREAM */
vgmstream = allocate_vgmstream(channel_count,loop_flag);
if (!vgmstream) goto fail;
/* fill in the vital statistics */
vgmstream->channels = channel_count;
vgmstream->sample_rate = read_16bitLE(0x06,streamFile) & 0xffff;
vgmstream->coding_type = coding_XBOX_IMA;
vgmstream->layout_type = layout_blocked_matx;
vgmstream->meta_type = meta_XBOX_MATX;
/* open the file for reading by each channel */
{
for (i=0;i<channel_count;i++) {
vgmstream->ch[i].streamfile = streamFile->open(streamFile,filename,STREAMFILE_DEFAULT_BUFFER_SIZE);
if (!vgmstream->ch[i].streamfile) goto fail;
}
}
/* Calc num_samples */
block_update_matx(0,vgmstream);
vgmstream->num_samples=0;
do {
vgmstream->num_samples += vgmstream->current_block_size/36*64;
block_update_matx(vgmstream->next_block_offset,vgmstream);
} while (vgmstream->next_block_offset<get_streamfile_size(streamFile));
block_update_matx(0,vgmstream);
return vgmstream;
/* clean up anything we may have opened */
fail:
if (vgmstream) close_vgmstream(vgmstream);
return NULL;
}

View File

@ -1,72 +1,61 @@
#include "meta.h"
#include "../util.h"
#include "../coding/coding.h"
/* XSS (found in Dino Crisis 3) */
VGMSTREAM * init_vgmstream_xss(STREAMFILE *streamFile) {
VGMSTREAM * vgmstream = NULL;
char filename[PATH_LIMIT];
off_t start_offset;
int loop_flag = 0;
int channel_count;
/* check extension, case insensitive */
streamFile->get_name(streamFile,filename,sizeof(filename));
if (strcasecmp("xss",filename_extension(filename))) goto fail;
/* .XSS - found in Dino Crisis 3 (Xbox) */
VGMSTREAM* init_vgmstream_xss(STREAMFILE* sf) {
VGMSTREAM* vgmstream = NULL;
uint32_t start_offset;
int channels, loop_flag, sample_rate;
/* check header */
if ((uint16_t)read_16bitLE(0x15A,streamFile) != 0x10)
goto fail;
if (read_32bitLE(0x154,streamFile) / read_32bitLE(0x150,streamFile) !=
(uint16_t)read_16bitLE(0x158,streamFile))
goto fail;
/* checks */
/* 00: name + garbage data up to ?
* (due to garbage it's hard which values are from this header, but these seem consistent) */
if (read_u32le(0x0c,sf) != 0x3a)
return NULL;
if (read_u32le(0x10,sf) != 0x00)
return NULL;
loop_flag = (read_32bitLE(0x144,streamFile)!=0);
channel_count = (uint16_t)read_16bitLE(0x14E,streamFile);
if (!check_extensions(sf,"xss"))
return NULL;
/* some floats and stuff up to 0x100, then some sizes, then RIFF fmt-like header */
uint32_t head_offset = 0x140;
if (read_u32le(head_offset+0x00, sf) != 0x40)
return NULL;
loop_flag = (read_u32le(head_offset + 0x04,sf) != 0);
if (read_u16le(head_offset + 0x0c,sf) != 0x01)
return NULL;
channels = read_u16le(head_offset + 0x0E,sf);
sample_rate = read_u32le(head_offset + 0x10,sf);
/* 14: bitrate */
/* 18: block size */
if (read_u16le(head_offset + 0x1A,sf) != 0x10)
return NULL;
start_offset = 0x800;
/* build the VGMSTREAM */
vgmstream = allocate_vgmstream(channel_count,loop_flag);
vgmstream = allocate_vgmstream(channels,loop_flag);
if (!vgmstream) goto fail;
/* fill in the vital statistics */
start_offset = 0x800;
vgmstream->channels = channel_count;
vgmstream->sample_rate = read_32bitLE(0x150,streamFile);
vgmstream->coding_type = coding_PCM16LE;
vgmstream->num_samples = (get_streamfile_size(streamFile)-start_offset)/2/channel_count;
if (loop_flag) {
vgmstream->loop_start_sample = read_32bitLE(0x144,streamFile)/2/channel_count;
vgmstream->loop_end_sample = read_32bitLE(0x148,streamFile)/2/channel_count;
}
if (vgmstream->channels == 1) {
vgmstream->layout_type = layout_none;
} else if (vgmstream->channels > 1) {
vgmstream->layout_type = layout_interleave;
vgmstream->interleave_block_size = 0x2;
}
vgmstream->meta_type = meta_XSS;
vgmstream->sample_rate = sample_rate;
vgmstream->num_samples = pcm16_bytes_to_samples(get_streamfile_size(sf) - start_offset, channels);
vgmstream->loop_start_sample = pcm16_bytes_to_samples(read_u32le(head_offset + 0x04,sf), channels);
vgmstream->loop_end_sample = pcm16_bytes_to_samples(read_u32le(head_offset + 0x08,sf), channels);
/* open the file for reading */
{
int i;
STREAMFILE * file;
file = streamFile->open(streamFile,filename,STREAMFILE_DEFAULT_BUFFER_SIZE);
if (!file) goto fail;
for (i=0;i<channel_count;i++) {
vgmstream->ch[i].streamfile = file;
vgmstream->ch[i].channel_start_offset=
vgmstream->ch[i].offset=start_offset+
vgmstream->interleave_block_size*i;
}
}
vgmstream->coding_type = coding_PCM16LE;
vgmstream->layout_type = layout_interleave;
vgmstream->interleave_block_size = 0x2;
if (!vgmstream_open_stream(vgmstream, sf, start_offset))
goto fail;
return vgmstream;
/* clean up anything we may have opened */
fail:
if (vgmstream) close_vgmstream(vgmstream);
close_vgmstream(vgmstream);
return NULL;
}

View File

@ -108,7 +108,6 @@ init_vgmstream_t init_vgmstream_functions[] = {
init_vgmstream_wvs_ngc,
init_vgmstream_dc_str,
init_vgmstream_dc_str_v2,
init_vgmstream_xbox_matx,
init_vgmstream_dec,
init_vgmstream_vs,
init_vgmstream_dc_str,
@ -130,7 +129,7 @@ init_vgmstream_t init_vgmstream_functions[] = {
init_vgmstream_ps2_mihb,
init_vgmstream_ngc_pdt_split,
init_vgmstream_ngc_pdt,
init_vgmstream_wii_mus,
init_vgmstream_mus_krone,
init_vgmstream_dc_asd,
init_vgmstream_spsd,
init_vgmstream_rsd,
@ -145,7 +144,7 @@ init_vgmstream_t init_vgmstream_functions[] = {
init_vgmstream_gca,
init_vgmstream_spt_spd,
init_vgmstream_ish_isd,
init_vgmstream_gsp_gsb,
init_vgmstream_gsnd,
init_vgmstream_ydsp,
init_vgmstream_ngc_ssm,
init_vgmstream_ps2_joe,
@ -189,7 +188,7 @@ init_vgmstream_t init_vgmstream_functions[] = {
init_vgmstream_apple_caff,
init_vgmstream_pc_mxst,
init_vgmstream_sab,
init_vgmstream_wii_bns,
init_vgmstream_bns,
init_vgmstream_wii_was,
init_vgmstream_pona_3do,
init_vgmstream_pona_psx,
@ -201,7 +200,7 @@ init_vgmstream_t init_vgmstream_functions[] = {
init_vgmstream_dmsg,
init_vgmstream_ngc_dsp_aaap,
init_vgmstream_ngc_dsp_konami,
init_vgmstream_ps2_wb,
init_vgmstream_wb,
init_vgmstream_bnsf,
init_vgmstream_ps2_gcm,
init_vgmstream_smpl,
@ -214,7 +213,6 @@ init_vgmstream_t init_vgmstream_functions[] = {
init_vgmstream_dsp_str_ig,
init_vgmstream_ea_swvr,
init_vgmstream_ps2_b1s,
init_vgmstream_ps2_wad,
init_vgmstream_dsp_xiii,
init_vgmstream_dsp_cabelas,
init_vgmstream_lpcm_shade,
@ -523,6 +521,7 @@ init_vgmstream_t init_vgmstream_functions[] = {
init_vgmstream_awd,
init_vgmstream_rws_809,
init_vgmstream_pwb,
init_vgmstream_rawi,
/* lower priority metas (no clean header identity, somewhat ambiguous, or need extension/companion file to identify) */
init_vgmstream_scd_pcm,

View File

@ -202,7 +202,6 @@ typedef enum {
layout_blocked_wsi,
layout_blocked_str_snds,
layout_blocked_ws_aud,
layout_blocked_matx,
layout_blocked_dec,
layout_blocked_xvas,
layout_blocked_vs,
@ -258,7 +257,7 @@ typedef enum {
meta_DSP_SADB, /* .sad */
meta_DSP_WSI, /* .wsi */
meta_IDSP_TT, /* Traveller's Tales games */
meta_DSP_WII_MUS, /* .mus */
meta_MUS_KRONE,
meta_DSP_WII_WSD, /* Phantom Brave (WII) */
meta_WII_NDP, /* Vertigo (Wii) */
meta_DSP_YGO, /* Konami: Yu-Gi-Oh! The Falsebound Kingdom (NGC), Hikaru no Go 3 (NGC) */
@ -275,7 +274,7 @@ typedef enum {
meta_THP, /* THP movie files */
meta_SWAV,
meta_NDS_RRDS, /* Ridge Racer DS */
meta_WII_BNS, /* Wii BNS Banner Sound (similar to RSTM) */
meta_BNS,
meta_WIIU_BTSND, /* Wii U Boot Sound */
meta_ADX_03, /* CRI ADX "type 03" */
@ -358,7 +357,7 @@ typedef enum {
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) */
meta_GSND,
meta_YDSP, /* WWE Day of Reckoning */
meta_FFCC_STR, /* Final Fantasy: Crystal Chronicles */
meta_UBI_JADE, /* Beyond Good & Evil, Rayman Raving Rabbids */
@ -392,7 +391,6 @@ typedef enum {
meta_UBI_CKD, /* Ubisoft CKD RIFF header (Rayman Origins Wii) */
meta_RAW_WAVM,
meta_WVS,
meta_XBOX_MATX, /* XBOX MATX */
meta_XMU,
meta_XVAS,
meta_EA_SCHL, /* Electronic Arts SCHl with variable header */
@ -455,7 +453,7 @@ typedef enum {
meta_AST_MMV,
meta_DMSG, /* Nightcaster II - Equinox (XBOX) */
meta_NGC_DSP_AAAP, /* Turok: Evolution (NGC), Vexx (NGC) */
meta_PS2_WB, /* Shooting Love. ~TRIZEAL~ */
meta_WB,
meta_S14, /* raw Siren 14, 24kbit mono */
meta_SSS, /* raw Siren 14, 48kbit stereo */
meta_PS2_GCM, /* NamCollection */
@ -469,7 +467,6 @@ typedef enum {
meta_DSP_STR_IG, /* Micro Machines, Superman Superman: Shadow of Apokolis */
meta_EA_SWVR, /* Future Cop L.A.P.D., Freekstyle */
meta_PS2_B1S, /* 7 Wonders of the ancient world */
meta_PS2_WAD, /* The golden Compass */
meta_DSP_XIII, /* XIII, possibly more (Ubisoft header???) */
meta_DSP_CABELAS, /* Cabelas games */
meta_PS2_ADM, /* Dragon Quest V (PS2) */
@ -581,11 +578,11 @@ typedef enum {
meta_DSP_MCADPCM, /* Skyrim (Switch) */
meta_UBI_LYN, /* Ubisoft LyN engine [The Adventures of Tintin (multi)] */
meta_MSB_MSH, /* sfx companion of MIH+MIB */
meta_TXTP, /* generic text playlist */
meta_TXTP,
meta_SMC_SMH, /* Wangan Midnight (System 246) */
meta_PPST, /* PPST [Parappa the Rapper (PSP)] */
meta_SPS_N1,
meta_UBI_BAO, /* Ubisoft BAO */
meta_UBI_BAO,
meta_DSP_SWITCH_AUDIO, /* Gal Gun 2 (Switch) */
meta_H4M, /* Hudson HVQM4 video [Resident Evil 0 (GC), Tales of Symphonia (GC)] */
meta_ASF, /* Argonaut ASF [Croc 2 (PC)] */
@ -701,6 +698,7 @@ typedef enum {
meta_BIGRP,
meta_DIC1,
meta_AWD,
meta_RAWI,
} meta_t;