[MPlayer-cvslog] CVS: main/libmpdemux demux_audio.c,1.42,1.43

Reimar Döffinger CVS syncmail at mplayerhq.hu
Tue Feb 7 23:12:37 CET 2006


CVS change done by Reimar Döffinger CVS

Update of /cvsroot/mplayer/main/libmpdemux
In directory mail:/var2/tmp/cvs-serv13693

Modified Files:
	demux_audio.c 
Log Message:
read data in nBlockAlign aligned chunks


Index: demux_audio.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpdemux/demux_audio.c,v
retrieving revision 1.42
retrieving revision 1.43
diff -u -r1.42 -r1.43
--- demux_audio.c	18 Nov 2005 14:39:18 -0000	1.42
+++ demux_audio.c	7 Feb 2006 22:12:34 -0000	1.43
@@ -428,7 +428,10 @@
       }
     } break;
   case WAV : {
+    unsigned align = sh_audio->wf->nBlockAlign;
     l = sh_audio->wf->nAvgBytesPerSec;
+    if (align)
+      l = (l + align - 1) / align * align;
     dp = new_demux_packet(l);
     l = stream_read(s,dp->buffer,l);
     priv->last_pts = priv->last_pts < 0 ? 0 : priv->last_pts + l/(float)sh_audio->i_bps;




More information about the MPlayer-cvslog mailing list