From c85622f5e41979de81278f75ac628f086c57be45 Mon Sep 17 00:00:00 2001 From: morkt Date: Mon, 11 May 2015 20:22:14 +0400 Subject: [PATCH] (WaveAudio.Write): fixed RIFF size calculation. --- GameRes/AudioWAV.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/GameRes/AudioWAV.cs b/GameRes/AudioWAV.cs index 61a566c3..3b7dd306 100644 --- a/GameRes/AudioWAV.cs +++ b/GameRes/AudioWAV.cs @@ -103,7 +103,7 @@ namespace GameRes { using (var buffer = new BinaryWriter (output, Encoding.ASCII, true)) { - uint total_size = (uint)(0x2e + source.PcmSize); + uint total_size = (uint)(0x2e - 8 + source.PcmSize); buffer.Write (Signature); buffer.Write (total_size); buffer.Write (0x45564157); // 'WAVE'