[MPlayer-users] copying AC3 audio into DivX confuse all windo ws players

Green, Shaun Shaun.Green at msfc.nasa.gov
Wed Sep 11 19:57:01 CEST 2002


Jose,

Here's my entire 10 step process (in a nut shell), but I don't know if it
will help you. :o)

1) Insert DVD and run dvd::rip.
2) Click the Read DVD button to load the DVD tracks, etc. Choose the audio
track.
3) Click Play Movie button to authenticate the DVD and mine plays it using
gmplayer (MPlayer w/ GUI). Skip around and make sure there's not any
interlacing in the video. If there is you need to add -I 3, antialias, and
change frame rate to 29.97 if it's full video in step 7.
4) Click rip it to the hard drive. This will rip and get the preview image.
5) Choose the next tab to setup all the resize, crop and correct aspect
ratio (dvd::rip makes this step very easy).
6) Open up a console window and edit the transcode shell script (I have one
I always use) to match the step 5 params.
7) Run the script; this encodes to DivX5 using special params I give it (-w
1500,999999,100 --divx_quant 2,3 --a52_drc_off, etc) and passes the AC3
through unchanged. It also uses MPlayer to rip the audio AC3 file to a
separate file on the HD and the subtitles to vobsub using Mencode.
8) Use AVIdemux to playback and check for AV sync, which it always fails
here. It always loses a little AV sync at every VOB change :o( for some
reason. So I then import the AC3 file I wrote out in step 7 and it syncs up
perfectly throughout sometimes needing a little adjustment.
9) Write out the split files and edit the movie shell script file to reflect
the delays.
10) Test the AVIs and burn them using Gnome Toaster (Under MC, you just have
to hit enter on the shell script to play the movie).

Note - I don't use psumode, that has never produced good AV sync for me @
23.976 fps encoded files. When I tried it, still only the first part syncs
up then VOB changes kill it. Also, I never have had better results with 2
pass, that's just for cramming onto 1 CD and it's not worth the time. 2-4
CD's are the norm for every movie at high quality, but this depends on
duration mostly since I never resize down the movie width unless it's 4:3
aspect.

Now I'd like to use Mencoder if it could properly resize and crop the black
bars like transcode can (I haven't tried this). you should be able to just
take the settings you get in dvd::rip step 5 and use them with Mencode. But
it would also need to handle adding in the special params in step 7 for
DivX5.

So how do you do it all?

Shaun

-----Original Message-----
From: José M. Fandiño
To: Green, Shaun
Sent: 9/11/2002 11:53 AM
Subject: Re: [MPlayer-users] copying AC3 audio into DivX confuse all windows
players

"Green, Shaun" wrote:
> 
> I've tested all my DivX5 AVIs w/ AC3 audio created with MPlayer under
> Windows and they don't stutter. I use Zoom Player under Windows.


Hello Shaun,

I don't know of the player called Zoom, but I used players like 
windows media player 6.x, powerDVD and the playa (I think that this
is the 90% of the windows players) in several computers of friends 
with identical results.

Perhaps, you can provide me the command line that you used 
for generate those avi files. (or use the windows media player)

regards.

> shaun
> 
> -----Original Message-----
> From: José M. Fandiño
> To: mplayer-users at mplayerhq.hu
> Sent: 9/11/2002 11:33 AM
> Subject: [MPlayer-users] copying AC3 audio into DivX confuse all
windows
> players
> 
> [Automatic answer: RTFM (read DOCS, FAQ), also read
> DOCS/bugreports.html]
> hello friens,
> 
> I have a strange problem copying AC3 with mencoder. I simply want copy
> the AC3 stream (AC3: 2.0 (stereo)  48000 Hz  192.0 kbit/s) into the
> file mr.avi with this script:
> 
> #!/bin/sh
> set -e
> mencoder -ss 3 -endpos 20 -v -ovc frameno -o frameno.avi -oac copy
> ./mr.vob
> mencoder -ss 3 -endpos 20 -v -oac copy -o /dev/null -ovc lavc \
> -lavcopts vcodec=mpeg4:vbitrate=1000:vhq:vpass=1:vqmin=2:vqmax=31  \
> -vop pp=6,scale=512:384 -npp lb ./mr.vob
> mencoder -ss 3 -endpos 20 -v -oac copy -o mr.avi -ovc lavc \
> -lavcopts vcodec=mpeg4:vbitrate=1000:vhq:vpass=2:vqmin=2:vqmax=31 \
> -vop pp=6,scale=512:384 -npp lb ./mr.vob
> 
> and it plays perfectly with mplayer, but with windows players (like
> media player 6.x, the playa, powerdvd, etc) the sound stutter.
> 
> I think that I need specify an interleave of 80ms according to
> the Virtual_dub+ac3 page:
> 
> ( http://www.xs4all.nl/~merlinx/ac3guideeng.html )
> [snip]
> .
> .
> 
> 3. There are 2 methods to get the audio and video synch.
> 
> Some people have excellent results with these settings :
> 
> 192 kb preload : 80 ms interleave every 80 ms
> 384 kb preload : 160 ms interleave every 160 ms
> 448 kb preload : 128ms interleave every 128 ms
> 
> .
> .
> 
> [snip]
> 
> but mencoder seems haven't any parameter for specify this,
> Can I anyway encode ac3 audio with a determined interleave???
> 
> thanks
> 
> I'm uploading a sample file to
> ftp://ftp.mplayerhq.hu/MPlayer/incoming/mr/mr.{avi,txt}
> 
>         /------/
> 
> MPlayer 0.90pre7-2.95.3 (C) 2000-2002 Arpad Gereoffy (see DOCS!)
> 
> CPU: Advanced Micro Devices Athlon TB Thunderbird (Family: 6,
Stepping:
> 4)
> CPUflags:  MMX: 1 MMX2: 1 3DNow: 1 3DNow2: 1 SSE: 0 SSE2: 0
> Compiled for x86 CPU with extensions: MMX MMX2 3DNow 3DNowEx
> 
> Reading /home/users/fan/.mplayer/codecs.conf: 38 audio & 107 video
> codecs
> Font /home/users/fan/.mplayer/font/font.desc loaded successfully! (206
> chars)
> Using usleep() timing
> Input config file /home/users/fan/.mplayer/input.conf parsed : 50
binds
> 
> Playing mr.avi
> Cache fill:  0.00% (0 bytes)    Detected AVI file format!
> VIDEO:  [DIVX]  512x384  24bpp  25.00 fps  998.8 kbps (121.9 kbyte/s)
> Clip info:
>  Software: MEncoder 0.90pre7-2.95.3
>
========================================================================
> ==
> Detected audio codec: [a52] afm:liba52 (AC3-liba52)
> Opening audio decoder: [liba52] AC3 decoding with liba52
> AC3: 2.0 (stereo)  48000 Hz  192.0 kbit/s
> AUDIO: 48000 Hz, 2 ch, sfmt: 0x10 (2 bps), ratio: 24000->192000 (192.0
> kbit)
> vo: X11 running at 1024x768 with depth 16 and 16 bpp (":0.0" => local
> display)
> Opening video filter: [pp]
>
========================================================================
> ==
> Opening video decoder: [ffmpeg] FFmpeg's libavcodec codec family
> Detected video codec: [ffodivx] vfm:ffmpeg (FFmpeg MPEG-4)
>
========================================================================
> ==
> Video attribute 'brightness' isn't supported by selected vo & vd!
> AO: [oss] 48000Hz 2ch Signed 16-bit (Little-Endian)
> Start playing...
> VDec: vo config request - 512 x 384 (preferred csp: Planar YV12)
> [PP] Using external postprocessing filter, max q = 6
> VDec: using Planar YV12 as output csp (no 0)
> Movie-Aspect is undefined - no prescaling applied.
> VO: [xv] 512x384 => 512x384 Planar YV12  [fs]
> 
> System info:
> ============
> 
> FreeBSD damocles.olimpus 4.6-RC2 FreeBSD 4.6-RC2 #0: Wed May 22
21:01:00
> CEST 2002
> root at damocles.olimpus:/usr/obj/usr/src/sys/NUCLEO  i386
> 
>         /----/
> 
> -r--r--r--  1 root  wheel  1222232 22 may 22:13 /usr/lib/libc.a
> lrwxr-xr-x  1 root  wheel        9 22 may 22:13 /usr/lib/libc.so ->
> libc.so.4
> -r--r--r--  1 root  wheel   579412 22 may 22:13 /usr/lib/libc.so.4
> 
>         /----/
> 
> XFree86 Version 4.2.0 / X Window System
> (protocol Version 11, revision 0, vendor release 6600)
> Release Date: 18 January 2002
>         If the server is older than 6-12 months, or if your card is
>         newer than the above date, look for a newer version before
>         reporting problems.  (See http://www.XFree86.Org/)
> Build Operating System: FreeBSD 4.4-RELEASE-p1 i386 [ELF]
> Module Loader present
> Note: (I'm using the last gatos driver)
> 
>         /----/
> 
> gcc --version
> 2.95.3
> 
>         /----/
> 
> GNU ld version 2.11.2 20010719 [FreeBSD] (with BFD 2.11.2 20010719
> [FreeBSD])
> 
>         /----/
> 
> GNU assembler 2.11.2 20010719 [FreeBSD]
> Copyright 2001 Free Software Foundation, Inc.
> This program is free software; you may redistribute it under the terms
> of
> the GNU General Public License.  This program has absolutely no
> warranty.
> This assembler was configured for a target of `i386-unknown-freebsd4'.
> 
>         /----/
> 
> Linux proc emulation (K7 T-bird 1,4):
> cat /linprocfs/cpuinfo
> processor       : 0
> vendor_id       : AuthenticAMD
> cpu family      : 6
> model           : 7
> stepping        : 4
> flags           : fpu vme de pse tsc msr pae mce cx8 sep mtrr pge mca
> cmov pat pse36 mmx fxsr
> cpu MHz         : 1410.21
> bogomips        : 1410.21
> 
>         /----/
> 
> Video Chipset ATI Rage 128 Pro PF (AGP)
> 
>         /----/
> 
> FreeBSD Audio Driver (newpcm)
> Installed devices:
> pcm0: <VIA VT82C686A> at io 0xa800 irq 5 (1p/1r/0v channels duplex)
> 
> --
> -----BEGIN GEEK CODE BLOCK-----
> Version: 3.1
> GCS/IT d- s+:+() a- C+++ UBL+++$ P+ L+++ E--- W++ N+ o++ K- w---
> O+ M+ V- PS+ PE+ Y++ PGP+>+++ t+ 5 X+$ R- tv-- b+++ DI D++>+++
> G++ e- h+(++) !r !z
> ------END GEEK CODE BLOCK------
> 
> _______________________________________________
> RTFM!!!  http://www.MPlayerHQ.hu/DOCS
> Search:  http://www.MPlayerHQ.hu/cgi-bin/htsearch
> http://mplayerhq.hu/mailman/listinfo/mplayer-users

-- 
-----BEGIN GEEK CODE BLOCK-----
Version: 3.1
GCS/IT d- s+:+() a- C+++ UBL+++$ P+ L+++ E--- W++ N+ o++ K- w---
O+ M+ V- PS+ PE+ Y++ PGP+>+++ t+ 5 X+$ R- tv-- b+++ DI D++>+++
G++ e- h+(++) !r !z
------END GEEK CODE BLOCK------




More information about the MPlayer-users mailing list