From 80eba7a0e7471bd1119841a9ecc4981dd14b27c7 Mon Sep 17 00:00:00 2001 From: halleyscometsw Date: Sat, 20 Sep 2008 22:16:57 +0000 Subject: [PATCH] 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 --- src/vgmstream.c | 14 ++++++++++---- unix/data.c | 1 + 2 files changed, 11 insertions(+), 4 deletions(-) diff --git a/src/vgmstream.c b/src/vgmstream.c index 065f6cab..a1591d43 100644 --- a/src/vgmstream.c +++ b/src/vgmstream.c @@ -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; -} \ No newline at end of file +} diff --git a/unix/data.c b/unix/data.c index 2834657a..8fd52e7d 100644 --- a/unix/data.c +++ b/unix/data.c @@ -121,6 +121,7 @@ gchar *vgmstream_exts [] = { "idvi", "omu", "xa2", + "kraw", /* terminator */ NULL };