From owner-freebsd-multimedia@FreeBSD.ORG Tue Dec 8 15:14:20 2009 Return-Path: Delivered-To: freebsd-multimedia@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E18D0106566C for ; Tue, 8 Dec 2009 15:14:20 +0000 (UTC) (envelope-from rnoland@FreeBSD.org) Received: from gizmo.2hip.net (gizmo.2hip.net [64.74.207.195]) by mx1.freebsd.org (Postfix) with ESMTP id BA64D8FC3D for ; Tue, 8 Dec 2009 15:14:20 +0000 (UTC) Received: from [192.168.1.4] (adsl-154-218-170.ard.bellsouth.net [72.154.218.170]) (authenticated bits=0) by gizmo.2hip.net (8.14.3/8.14.3) with ESMTP id nB8FEIjV002229 (version=TLSv1/SSLv3 cipher=DHE-RSA-CAMELLIA256-SHA bits=256 verify=NO); Tue, 8 Dec 2009 10:14:18 -0500 (EST) (envelope-from rnoland@FreeBSD.org) From: Robert Noland To: Tom Evans In-Reply-To: <2e027be00912071114t6a69b0a5vfdefea06e6ea9273@mail.gmail.com> References: <2e027be00912070613y5b3c4841tcd4d9ff58e1db330@mail.gmail.com> <2e027be00912071114t6a69b0a5vfdefea06e6ea9273@mail.gmail.com> Content-Type: text/plain Organization: FreeBSD Date: Tue, 08 Dec 2009 09:14:12 -0600 Message-Id: <1260285252.2315.280.camel@balrog.2hip.net> Mime-Version: 1.0 X-Mailer: Evolution 2.26.3 FreeBSD GNOME Team Port Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-1.4 required=5.0 tests=AWL,BAYES_00,RCVD_IN_PBL, RCVD_IN_SORBS_DUL, RDNS_DYNAMIC, SPF_SOFTFAIL autolearn=no version=3.2.5 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on gizmo.2hip.net Cc: freebsd-multimedia@freebsd.org Subject: Re: mplayer SVN plays video too fast on FreeBSD X-BeenThere: freebsd-multimedia@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Multimedia discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 08 Dec 2009 15:14:21 -0000 On Mon, 2009-12-07 at 19:14 +0000, Tom Evans wrote: > Hi all > > I sent this to the mplayer mailing list earlier today, without > thinking that probably someone on multimedia@ has tried to compile > mplayer from svn. Has anyone succesfully managed to do it? - and get a > working player out of it! I haven't tried mplayer from SVN, but the video playing too fast issue is your audio codec. mplayer (and gstreamer, iirc) seem to set the frame rate based on the audio. Generally, what I have seen is that people with ATI/AMD (radeon) video cards with HDMI ports end up with the HDMI port as dsp0. If you aren't running the radeonhd driver with the AUDIO option set, the codec isn't initialized properly and so the video plays too fast. To correct this issue, usually all you need to do is set the sysctl hw.snd.default_unit to the correct pcm device. Basically, if you have the following: balrog% cat /dev/sndstat FreeBSD Audio Driver (newpcm: 64bit 2009061500/amd64) Installed devices: pcm0: at cad 0 nid 1 on hdac0 kld snd_hda [MPSAFE] (1p:1v/0r:0v channels simplex) pcm1: at cad 0 nid 1 on hdac1 kld snd_hda [MPSAFE] (1p:4v/1r:2v channels duplex default) pcm2: at cad 0 nid 1 on hdac1 kld snd_hda [MPSAFE] (1p:1v/0r:0v channels simplex) pcm3: at cad 0 nid 1 on hdac1 kld snd_hda [MPSAFE] (1p:1v/0r:0v channels simplex) pcm4: at cad 0 nid 1 on hdac1 kld snd_hda [MPSAFE] (1p:1v/0r:0v channels simplex) Setting "sysctl hw.snd.default_unit=1" will choose the primary analog pcm for audio output and mplayer will work fine. robert. > Cheers > > Tom > > ---------- Forwarded message ---------- > From: Tom Evans > Date: Mon, Dec 7, 2009 at 2:13 PM > Subject: mplayer SVN plays video too fast on FreeBSD > To: mplayer-users@mplayerhq.hu > > > Hi all > > Nvidia recently released a video driver for FreeBSD 8/amd64 (which was > previously unsupported by nvidia). With this, amd64 users finally got > access to libvdpau. > > As such, I wanted to recompile mplayer with support for vdpau. > Unfortunately, the packaged version of mplayer in freebsd is > 'mplayer-0.99.11_14' (which comes from MPlayer-1.0rc2.tar.bz2), which > doesn't know about vdpau, so I set about to compile from tip of svn. > > So, I checked out mplayer trunk, r29977, and made a few changes to > support compilation on FreeBSD (see attached diff). The program built > and compiled successfully, but every file I play through it has the > video processed way too fast. > > It almost looks as though it is trying to benchmark the video by > playing it as fast as possible. A 40 minute TV episode only takes > about 3 minutes to play through! The audio playback was correct, no > distortions. > > My configure line for mplayer was: > > --enable-png --enable-menu --disable-tv-v4l1 --disable-tv-v4l2 \ > --disable-dvdnav --disable-ssse3 --disable-directfb --disable-faac \ > --disable-twolame --disable-mencoder --disable-mad --disable-libdv \ > --disable-theora --disable-musepack --enable-libdca --enable-speex \ > --disable-xanim --disable-live --disable-xmms --disable-jack --disable-nas \ > --disable-openal --disable-smb --disable-fribidi --disable-cdparanoia \ > --disable-libcdio --disable-ladspa --disable-liblzo > --enable-runtime-cpudetection \ > --disable-win32dll --disable-qtx --enable-real > --realcodecsdir=/usr/local/lib/win32 \ > --enable-gui --extra-cflags="-I/usr/local/include/freetype2 > -I/usr/local/include" \ > --enable-freetype --disable-rtc --disable-arts --disable-caca --disable-lirc \ > --disable-sdl --disable-svga --disable-aa --disable-esd \ > --disable-joystick --extra-libs="-L/usr/local/lib -ldca" \ > --prefix=/usr/local --mandir=/usr/local/man --target=amd64-srcbld-freebsd8.0 \ > --enable-vdpau > > My ~/.mplayer/config looks like: > > vo=vdpau,xv > #vo=xv > vc=ffh264vdpau,ffvc1vdpau,ffmpeg12vdpau,ffwmv3vdpau, > cache=65536 > fs=1 > afm=hwac3 > > The effect is noticed with vo=vdpau,xv or with vo=xv and vc commented > out. It didn't appear to matter what video was being played, I tried > mkv/x264, avi/xvid and mpeg2/mpeg2ts. > > Any ideas? > > Cheers > > Tom > _______________________________________________ > freebsd-multimedia@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-multimedia > To unsubscribe, send any mail to "freebsd-multimedia-unsubscribe@freebsd.org" -- Robert Noland FreeBSD