[MPlayer-cvslog] CVS: main/libmpdemux muxer_mpeg.c,1.14,1.15
Nico Sabbi CVS
syncmail at mplayerhq.hu
Mon Mar 7 08:36:29 CET 2005
CVS change done by Nico Sabbi CVS
Update of /cvsroot/mplayer/main/libmpdemux
In directory mail:/var2/tmp/cvs-serv29474
Modified Files:
muxer_mpeg.c
Log Message:
fixed support for mp3 at <32000 sample_rate
Index: muxer_mpeg.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpdemux/muxer_mpeg.c,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -r1.14 -r1.15
--- muxer_mpeg.c 4 Mar 2005 07:43:00 -0000 1.14
+++ muxer_mpeg.c 7 Mar 2005 07:36:27 -0000 1.15
@@ -999,7 +999,7 @@
static uint32_t get_audio_frame_size(muxer_headers_t *spriv, uint8_t *buf, int format, int samples_ps)
{
- uint32_t sz, tmp;
+ uint32_t sz, tmp, spf;
#ifdef USE_LIBA52
#include "../liba52/a52.h"
@@ -1011,7 +1011,14 @@
return sz;
}
#endif
- tmp = spriv->bitrate * (format == 0x2000 ? 1536 : 1152);
+ if(format == 0x2000)
+ spf = 1536;
+ else if((format == 0x55) && (samples_ps < 32000))
+ spf = 576;
+ else
+ spf = 1152;
+
+ tmp = spriv->bitrate * spf;
sz = tmp / samples_ps;
if(sz % 2)
sz++;
More information about the MPlayer-cvslog
mailing list