mirror of
https://github.com/vgmstream/vgmstream.git
synced 2025-02-21 12:51:57 +01:00
Remove fake format .wmus (use .txth)
This commit is contained in:
parent
0915bb0056
commit
824c55e718
@ -1868,10 +1868,6 @@ different internally (encrypted, different versions, etc) and not always can be
|
||||
- *vas_kceo_container*: `.vas`
|
||||
- Subfiles: *vas_kceo*
|
||||
- Codecs: PCM16LE XBOX_IMA PSX NGC_DSP
|
||||
- **ps2_wmus.c**
|
||||
- assumed The Warriors Sony ADPCM by .wmus extension [*PS2_WMUS*]
|
||||
- *ps2_wmus*: `.wmus`
|
||||
- Codecs: PSX
|
||||
- **mjb_mjh.c**
|
||||
- Sony MultiStream MJH+MJB header [*MJB_MJH*]
|
||||
- *mjb_mjh*: `.mjb + .mjh .mjb`
|
||||
|
@ -667,7 +667,6 @@ static const char* extension_list[] = {
|
||||
"wic", //txth/reserved [Road Rash (SAT)-videos]
|
||||
"wip", //txth/reserved [Colin McRae DiRT (PC)]
|
||||
"wlv", //txth/reserved [ToeJam & Earl III: Mission to Earth (DC)]
|
||||
"wmus", //fake extension (to be removed)
|
||||
"wp2",
|
||||
"wpd",
|
||||
"wsd",
|
||||
@ -1250,7 +1249,6 @@ static const meta_info meta_info_list[] = {
|
||||
{meta_LSF_N1NJ4N, "Gizmondo Studios Helsingborg LSF header"},
|
||||
{meta_XWAV, "feelplus XWAV header"},
|
||||
{meta_RAW_SNDS, "PC .snds raw header"},
|
||||
{meta_PS2_WMUS, "assumed The Warriors Sony ADPCM by .wmus extension"},
|
||||
{meta_HYPERSCAN_KVAG, "Mattel Hyperscan KVAG"},
|
||||
{meta_PSND, "Polarbit PSND header"},
|
||||
{meta_ADP_WILDFIRE, "Wildfire ADP! header"},
|
||||
|
@ -638,7 +638,6 @@
|
||||
<ClCompile Include="meta\ps2_vbk.c" />
|
||||
<ClCompile Include="meta\ps2_vgv.c" />
|
||||
<ClCompile Include="meta\ps2_vms.c" />
|
||||
<ClCompile Include="meta\ps2_wmus.c" />
|
||||
<ClCompile Include="meta\psb.c" />
|
||||
<ClCompile Include="meta\psf.c" />
|
||||
<ClCompile Include="meta\psnd.c" />
|
||||
|
@ -1744,9 +1744,6 @@
|
||||
<ClCompile Include="meta\ps2_vms.c">
|
||||
<Filter>meta\Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="meta\ps2_wmus.c">
|
||||
<Filter>meta\Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="meta\psb.c">
|
||||
<Filter>meta\Source Files</Filter>
|
||||
</ClCompile>
|
||||
|
@ -490,8 +490,6 @@ VGMSTREAM * init_vgmstream_xwav_old(STREAMFILE* sf);
|
||||
|
||||
VGMSTREAM * init_vgmstream_raw_snds(STREAMFILE* streamFile);
|
||||
|
||||
VGMSTREAM * init_vgmstream_ps2_wmus(STREAMFILE* streamFile);
|
||||
|
||||
VGMSTREAM * init_vgmstream_hyperscan_kvag(STREAMFILE* streamFile);
|
||||
|
||||
VGMSTREAM* init_vgmstream_psnd(STREAMFILE* sf);
|
||||
|
@ -1,102 +0,0 @@
|
||||
#include "meta.h"
|
||||
#include "../util.h"
|
||||
|
||||
//#include <windows.h>
|
||||
//#include <tchar.h>
|
||||
|
||||
/* WMUS - Arbitrary extension chosen for The Warriors (PS2) */
|
||||
|
||||
VGMSTREAM * init_vgmstream_ps2_wmus(STREAMFILE *streamFile)
|
||||
{
|
||||
VGMSTREAM * vgmstream = NULL;
|
||||
char filename[PATH_LIMIT];
|
||||
|
||||
int loop_flag = 1;
|
||||
int channel_count;
|
||||
off_t start_offset;
|
||||
int i;
|
||||
|
||||
int blockCount;
|
||||
int shortBlockSize;
|
||||
int lastBlockLocation;
|
||||
|
||||
char filenameWHED[PATH_LIMIT];
|
||||
STREAMFILE * streamFileWHED = NULL;
|
||||
|
||||
//_TCHAR szBuffer[100];
|
||||
|
||||
/* check extension, case insensitive */
|
||||
streamFile->get_name(streamFile,filename,sizeof(filename));
|
||||
|
||||
if (strcasecmp("wmus",filename_extension(filename)))
|
||||
{
|
||||
goto fail;
|
||||
}
|
||||
|
||||
/* check for .WHED file */
|
||||
strcpy(filenameWHED, filename);
|
||||
strcpy(filenameWHED + strlen(filenameWHED) - 4, "WHED");
|
||||
|
||||
streamFileWHED = streamFile->open(streamFile, filenameWHED, STREAMFILE_DEFAULT_BUFFER_SIZE);
|
||||
if (!streamFileWHED)
|
||||
{
|
||||
goto fail;
|
||||
}
|
||||
|
||||
/* check loopand channel */
|
||||
loop_flag = 1;
|
||||
channel_count = read_32bitLE(0x14, streamFileWHED);
|
||||
|
||||
/* 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_32bitLE(0x04, streamFileWHED);
|
||||
|
||||
vgmstream->coding_type = coding_PSX;
|
||||
|
||||
vgmstream->interleave_block_size = read_32bitLE(0x18, streamFileWHED);
|
||||
blockCount = read_32bitLE(0x1C, streamFileWHED) * channel_count;
|
||||
shortBlockSize = read_32bitLE(0x20, streamFileWHED);
|
||||
|
||||
vgmstream->num_samples = (vgmstream->interleave_block_size * blockCount) / 16 / channel_count * 28;
|
||||
vgmstream->loop_start_sample = 0;
|
||||
|
||||
lastBlockLocation = (vgmstream->interleave_block_size * blockCount) - (vgmstream->interleave_block_size - shortBlockSize);
|
||||
vgmstream->loop_end_sample = lastBlockLocation / 16 / channel_count * 28;
|
||||
|
||||
//_stprintf(szBuffer, _T("%x"), lastBlockLocation);
|
||||
//MessageBox(NULL, szBuffer, _T("Foo"), MB_OK);
|
||||
|
||||
|
||||
vgmstream->layout_type = layout_interleave;
|
||||
vgmstream->meta_type = meta_PS2_WMUS;
|
||||
|
||||
start_offset = 0;
|
||||
|
||||
/* 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;
|
||||
|
||||
vgmstream->ch[i].channel_start_offset=
|
||||
vgmstream->ch[i].offset=
|
||||
(off_t)(start_offset+vgmstream->interleave_block_size*i);
|
||||
}
|
||||
}
|
||||
|
||||
return vgmstream;
|
||||
|
||||
/* clean up anything we may have opened */
|
||||
fail:
|
||||
if (streamFileWHED) close_streamfile(streamFileWHED);
|
||||
if (vgmstream) close_vgmstream(vgmstream);
|
||||
return NULL;
|
||||
}
|
@ -524,7 +524,6 @@ init_vgmstream_t init_vgmstream_functions[] = {
|
||||
init_vgmstream_scd_pcm,
|
||||
init_vgmstream_vas_kceo,
|
||||
init_vgmstream_vas_kceo_container,
|
||||
init_vgmstream_ps2_wmus,
|
||||
init_vgmstream_mib_mih,
|
||||
init_vgmstream_mjb_mjh,
|
||||
init_vgmstream_mic_koei,
|
||||
|
@ -495,7 +495,6 @@ typedef enum {
|
||||
meta_LSF_N1NJ4N, /* .lsf n1nj4n Fastlane Street Racing (iPhone) */
|
||||
meta_XWAV,
|
||||
meta_RAW_SNDS,
|
||||
meta_PS2_WMUS, /* The Warriors (PS2) */
|
||||
meta_HYPERSCAN_KVAG, /* Hyperscan KVAG/BVG */
|
||||
meta_PSND,
|
||||
meta_ADP_WILDFIRE,
|
||||
|
Loading…
x
Reference in New Issue
Block a user