[Mplayer-cvslog] CVS: main/libmpcodecs ad_alaw.c,1.2,1.3

Arpi of Ize arpi at mplayerhq.hu
Wed Oct 16 18:50:18 CEST 2002


Update of /cvsroot/mplayer/main/libmpcodecs
In directory mail:/var/tmp.root/cvs-serv31030

Modified Files:
	ad_alaw.c 
Log Message:
set up ss_div/ss_mul properly, accept 'alaw' fourcc too


Index: ad_alaw.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpcodecs/ad_alaw.c,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- ad_alaw.c	30 Aug 2002 21:44:20 -0000	1.2
+++ ad_alaw.c	16 Oct 2002 16:49:58 -0000	1.3
@@ -31,6 +31,8 @@
 static int preinit(sh_audio_t *sh)
 {
   sh->audio_out_minsize=2048;
+  sh->ds->ss_div = 1; // 1 samples/packet
+  sh->ds->ss_mul = 1; // 1 bytes/packet
   return 1;
 }
 
@@ -61,7 +63,7 @@
  unsigned short *d=(unsigned short *) buf;
  unsigned char *s=buf;
  len=2*l;
- if(sh_audio->format==6){
+ if(sh_audio->format==6 || sh_audio->format==0x77616C61){
  /* aLaw */
    while(l>0){ --l; d[l]=alaw2short[s[l]]; }
  } else {




More information about the MPlayer-cvslog mailing list