some fixes to play kRAW as dual file stereo

git-svn-id: https://vgmstream.svn.sourceforge.net/svnroot/vgmstream@434 51a99a44-fe44-0410-b1ba-c3e57ba2b86b
This commit is contained in:
halleyscometsw 2008-09-20 22:16:57 +00:00
parent 77874c70cf
commit 80eba7a0e7
2 changed files with 11 additions and 4 deletions

View File

@ -152,7 +152,12 @@ VGMSTREAM * init_vgmstream_internal(STREAMFILE *streamFile, int do_dfs) {
}
/* dual file stereo */
if (do_dfs && ((vgmstream->meta_type == meta_DSP_STD) || (vgmstream->meta_type == meta_PS2_VAGp) || (vgmstream->meta_type == meta_GENH)) && vgmstream->channels == 1) {
if (do_dfs && (
(vgmstream->meta_type == meta_DSP_STD) ||
(vgmstream->meta_type == meta_PS2_VAGp) ||
(vgmstream->meta_type == meta_GENH) ||
(vgmstream->meta_type == meta_KRAW)
) && vgmstream->channels == 1) {
try_dual_file_stereo(vgmstream, streamFile);
}
@ -1680,13 +1685,14 @@ void describe_vgmstream(VGMSTREAM * vgmstream, char * desc, int length) {
}
/* */
#define DFS_PAIR_COUNT 4
const char * const dfs_pairs[DFS_PAIR_COUNT][2] = {
const char * const dfs_pairs[][2] = {
{"L","R"},
{"l","r"},
{"_0","_1"},
{"left","right"},
{"Left","Right"},
};
#define DFS_PAIR_COUNT (sizeof(dfs_pairs)/sizeof(dfs_pairs[0]))
void try_dual_file_stereo(VGMSTREAM * opened_stream, STREAMFILE *streamFile) {
char filename[260];
@ -1830,4 +1836,4 @@ void try_dual_file_stereo(VGMSTREAM * opened_stream, STREAMFILE *streamFile) {
}
fail:
return;
}
}

View File

@ -121,6 +121,7 @@ gchar *vgmstream_exts [] = {
"idvi",
"omu",
"xa2",
"kraw",
/* terminator */
NULL
};