CVS: main/libmpdemux demux_audio.c,1.2,1.3
Update of /cvsroot/mplayer/main/libmpdemux In directory mplayer:/var/tmp.root/cvs-serv10406 Modified Files: demux_audio.c Log Message: mp3 position fixed Index: demux_audio.c =================================================================== RCS file: /cvsroot/mplayer/main/libmpdemux/demux_audio.c,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- demux_audio.c 14 Feb 2002 18:37:33 -0000 1.2 +++ demux_audio.c 15 Feb 2002 00:16:21 -0000 1.3 @@ -1,5 +1,6 @@ #include "config.h" +#include "../mp_msg.h" #include <stdlib.h> #include <stdio.h> @@ -83,7 +84,7 @@ switch(frmt) { case MP3: sh_audio->format = 0x55; - demuxer->movi_start = st_pos; + demuxer->movi_start = st_pos-3; for(n = 0; n < 5 ; n++) { pos = mp_decode_mp3_header(hdr); if(pos < 0) @@ -159,13 +160,15 @@ priv = (da_priv_t*)malloc(sizeof(da_priv_t)); priv->frmt = frmt; demuxer->priv = priv; - demuxer->movi_start = st_pos; +// demuxer->movi_start = st_pos; demuxer->audio->id = 0; demuxer->audio->sh = sh_audio; sh_audio->ds = demuxer->audio; if(stream_tell(s) != demuxer->movi_start) stream_seek(s,demuxer->movi_start); + + mp_msg(MSGT_DEMUX,MSGL_V,"demux_audio: audio data 0x%X - 0x%X \n",demuxer->movi_start,demuxer->movi_end); return 1; }
Hi Arpi of Ize, on Fri, 15 Feb 2002 01:16:23 +0100 you wrote:
Update of /cvsroot/mplayer/main/libmpdemux In directory mplayer:/var/tmp.root/cvs-serv10406
Modified Files: demux_audio.c Log Message: mp3 position fixed It's not fix it's bug ;) . Please reverse or fix ASP. The last version work not this one. Albeu
Hi,
Update of /cvsroot/mplayer/main/libmpdemux In directory mplayer:/var/tmp.root/cvs-serv10406
Modified Files: demux_audio.c Log Message: mp3 position fixed It's not fix it's bug ;) . Please reverse or fix ASP. The last version work not this one. Albeu
nope. run mplayer with -v -v, it will print demuxer->movi_start you set. then check the mp3 file with biew. you'll see that position you set to movi_start is 3 byte later than where the first mp3 audio frame starts. it results in skipping first mp3 frame, lots of head_check_failed at dec_audio, ugly noise tick and sometimes bad detection. A'rpi / Astral & ESP-team -- Developer of MPlayer, the Movie Player for Linux - http://www.MPlayerHQ.hu
Hi Arpi, on Fri, 15 Feb 2002 16:23:15 +0100 you wrote:
Hi,
Update of /cvsroot/mplayer/main/libmpdemux In directory mplayer:/var/tmp.root/cvs-serv10406
Modified Files: demux_audio.c Log Message: mp3 position fixed It's not fix it's bug ;) . Please reverse or fix ASP. The last version work not this one. Albeu
nope. run mplayer with -v -v, it will print demuxer->movi_start you set. then check the mp3 file with biew. you'll see that position you set to movi_start is 3 byte later than where the first mp3 audio frame starts. it results in skipping first mp3 frame, lots of head_check_failed at dec_audio, ugly noise tick and sometimes bad detection. None of us was right. We should skip the first frame exactly. I done a test with my oldest mp3 CD (and a few more) and the only way to have all of them played correctly is to skip the first frame. Otherwise many are badly detected, make the decoder aboard or worse crash :( Albeu
Hi,
then check the mp3 file with biew. you'll see that position you set to movi_start is 3 byte later than where the first mp3 audio frame starts. it results in skipping first mp3 frame, lots of head_check_failed at dec_audio, ugly noise tick and sometimes bad detection. None of us was right. We should skip the first frame exactly. heh?????????????????? do NOT skip any frame.
the only special case exception: there are few files using fake mp3 frame to contain some text data at the beginning.
I done a test with my oldest mp3 CD (and a few more) and the only way to have all of them played correctly is to skip the first frame. Otherwise many are badly detected, make the decoder aboard or worse crash :( Albeu
A'rpi / Astral & ESP-team -- Developer of MPlayer, the Movie Player for Linux - http://www.MPlayerHQ.hu
participants (3)
-
Alban Bedel -
Arpi -
Arpi of Ize