[MPlayer-cvslog] CVS: main/libmpcodecs ad_pcm.c,1.16,1.17

Ivo van Poorten CVS syncmail at mplayerhq.hu
Sun Feb 27 00:02:11 CET 2005


CVS change done by Ivo van Poorten CVS

Update of /cvsroot/mplayer/main/libmpcodecs
In directory mail:/var2/tmp/cvs-serv9486/libmpcodecs

Modified Files:
	ad_pcm.c 
Log Message:

Add support for 32-bit float WAV files and support for extended WAV files
with 4, 6, 8, ... channels of audio.



Index: ad_pcm.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpcodecs/ad_pcm.c,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -r1.16 -r1.17
--- ad_pcm.c	27 Dec 2004 17:30:14 -0000	1.16
+++ ad_pcm.c	26 Feb 2005 23:02:09 -0000	1.17
@@ -28,6 +28,7 @@
   switch(sh_audio->format){ /* hardware formats: */
     case 0x0:
     case 0x1: // Microsoft PCM
+    case 0xfffe: // Extended
        switch (sh_audio->samplesize) {
          case 1: sh_audio->sample_format=AF_FORMAT_U8; break;
          case 2: sh_audio->sample_format=AF_FORMAT_S16_LE; break;
@@ -35,6 +36,9 @@
          case 4: sh_audio->sample_format=AF_FORMAT_S32_LE; break;
        }
        break;
+    case 0x3: // IEEE float
+       sh_audio->sample_format=AF_FORMAT_FLOAT_LE;
+       break;
     case 0x6:  sh_audio->sample_format=AF_FORMAT_A_LAW;break;
     case 0x7:  sh_audio->sample_format=AF_FORMAT_MU_LAW;break;
     case 0x11: sh_audio->sample_format=AF_FORMAT_IMA_ADPCM;break;




More information about the MPlayer-cvslog mailing list