From 7e2c02efc8d0f6edf15186d3d3ee3b2192dba020 Mon Sep 17 00:00:00 2001 From: bxaimc Date: Wed, 1 Jun 2011 22:53:29 +0000 Subject: [PATCH] Adjusted chan count and freq. to ignore the muted left channel. Sounds like crap but maybe it's how it shows up in-game. Might also sound crappy due to the usage of 8-bit PCM. git-svn-id: https://vgmstream.svn.sourceforge.net/svnroot/vgmstream@958 51a99a44-fe44-0410-b1ba-c3e57ba2b86b --- src/meta/pcm.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/meta/pcm.c b/src/meta/pcm.c index fb21c042..a905a01c 100644 --- a/src/meta/pcm.c +++ b/src/meta/pcm.c @@ -20,7 +20,7 @@ VGMSTREAM * init_vgmstream_pcm_scd(STREAMFILE *streamFile) { goto fail; loop_flag = (read_32bitLE(0x02,streamFile)!=0); - channel_count = 2; + channel_count = 1; /* build the VGMSTREAM */ vgmstream = allocate_vgmstream(channel_count,loop_flag); @@ -29,12 +29,12 @@ VGMSTREAM * init_vgmstream_pcm_scd(STREAMFILE *streamFile) { /* fill in the vital statistics */ start_offset = 0x200; vgmstream->channels = channel_count; - vgmstream->sample_rate = 16000; + vgmstream->sample_rate = 32000; vgmstream->coding_type = coding_PCM8_SB_int; vgmstream->num_samples = read_32bitBE(0x06,streamFile)*2; if(loop_flag) { - vgmstream->loop_start_sample = read_32bitBE(0x02,streamFile)*0x400; - vgmstream->loop_end_sample = read_32bitBE(0x06,streamFile); + vgmstream->loop_start_sample = read_32bitBE(0x02,streamFile)*0x400*2; + vgmstream->loop_end_sample = read_32bitBE(0x06,streamFile)*2; } vgmstream->layout_type = layout_interleave; vgmstream->interleave_block_size = 0x1;