[MPlayer-users] Re: audio video sync

Yan Seiner yan at cardinalengineering.com
Sun Mar 30 08:22:37 CEST 2003


> 
> Huh? autosync and framedrop are mplayer options and have nothing to do
> with capturing with mencoder. Also bps/nobps and ni (non-INTERLEAVED,
> not non-interlaced) are options for avi demuxing and have nothing to
> do with your situation.

Well, I was testing the assumption than mencoder works, mplayer is
broken - in which case from the docs the above options should address
out-of sync audio.  From the docs:

Q: Audio goes out of sync playing an AVI file.
A: Try the -bps or -nobps option. If it does not improve, read this and
upload the file to FTP.

> 
> > (25) or NTSC rates (29.97) as appropriate.  No joy.  My CPU loads are
> > pretty small - 30 - 50% during capture, less during playback.
> > 
> > I'm stumped.  xawtv plays fine for both PAL and NTSC; no sound sync
> > problems there.
> 
> Of course playing in realtime can't have sync problems since there's
> nothing to sync!!! It's just showing what's currently in the buffer!

Again, I was looking at the possibility of some sort of weird
interaction between my digital tape deck and video capture.  Just
eliminating all possibilities - make sure it's not the source that's the
problem.

> 
> > Any ideas, help, etc. are greatly appreciated.
> > 
> > I will be uploading the appropriate 5 MB clip to the ftp server along
> > with all of the info soon.  The full clip (30MB) is (or will be shortly)
> > at ftp://portia.cardinalengineering.com/outgoing/yan.tar.bz2
> 
> You MUST at least tell us what command line you are using; otherwise
> we have no idea what's going wrong (or what you're doing wrong). My
> guess is that it's the -oac pcm bug which was just fixed in cvs.

OK, here's the command lines:

for capture:

/usr/local/bin/mencoder -tv
on:norm=NTSC:input=1:driver=v4l:width=320:height=240:fps=29.97 -ofps
29.97 -ovc lavc -lavcopts vcodec=mjpeg -oac copy -o output.avi

(BTW, I can't capture at 640x480; my CPU can't keep up....)

for playback:

mplayer -v -fps 29.97 output.avi

I've uploaded a 5MB clip to the mplayer website
ftp://mplayerhq.hu/MPlayer/incoming/yan.tar.bz2 and a full 30 mb clip to
ftp://portia.cardinalengineering.com/outgoing/yan.tar.bz2 .  The
tarballs include all of the system info and mplayer logs requested.

I've tested this with both the latest (as of yesterday) CVS and the rc5
rpms; same thing.

I've done some playing around; I can get close to normal sync if I play
back the video at somewhere between 40 and 45 fps.  It appears to vary
slightly, so the sync is never perfect.

--Yan


-- 
        o
     /\ /_       o__
   o*  ~(_)      ,>/'_      o__
Yan Seiner, PE  (_)\(_)     ,>/'_   o__     o__
Cardinal Engineering, Inc. (_)\(_)  ,>/'_   ,>/'_
http://www.cardinalengineering.com (_)\(_) (_)\(_)
spam killer code kpwq1jkcsEzdx39gnkVvgycd15ayqq




More information about the MPlayer-users mailing list