From owner-freebsd-multimedia Sun Oct 27 14:51:18 2002 Delivered-To: freebsd-multimedia@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 70CF837B401 for ; Sun, 27 Oct 2002 14:51:16 -0800 (PST) Received: from smtp.web.de (smtp02.web.de [217.72.192.151]) by mx1.FreeBSD.org (Postfix) with ESMTP id F0B7E43E75 for ; Sun, 27 Oct 2002 14:51:15 -0800 (PST) (envelope-from g.w.k@web.de) Received: from [217.232.189.13] (helo=pD9E8BD0D.dip.t-dialin.net) by smtp.web.de with asmtp (WEB.DE(Exim) 4.75 #2) id 185wFU-0002Kk-00; Sun, 27 Oct 2002 23:51:12 +0100 Subject: Re: FreeBSD 4.7R: no sound when recording with ffmpeg? From: "Georg-W. Koltermann" To: Steve O'Hara-Smith Cc: freebsd-multimedia@freebsd.org In-Reply-To: <20021027071908.1ac2e5d1.steve@sohara.org> References: <1035673653.3373.8.camel@bat.localnet> <20021027071908.1ac2e5d1.steve@sohara.org> Content-Type: text/plain Content-Transfer-Encoding: 7bit X-Mailer: Ximian Evolution 1.0.8 Date: 27 Oct 2002 23:51:57 +0100 Message-Id: <1035759136.1944.97.camel@bat.localnet> Mime-Version: 1.0 Sender: owner-freebsd-multimedia@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org On Sun, 2002-10-27 at 07:19, Steve O'Hara-Smith wrote: > On 27 Oct 2002 01:07:22 +0200 > "Georg-W. Koltermann" wrote: > > [...] > GWK> Since I upgraded to 4.7R, I don't capture sound any more. > > Urk! > > GWK> Ffmpeg does record sound (if I turn up the recording volume, I get > GWK> audible static), it just doesn't seem to activate the audio output of > GWK> the tuner any more. > > Strange, this is achieved by simply opening /dev/tuner0 (it > still works for me on 4.7-STABLE about two weeks old). The only other > thing it depends on is proper mixer settings (record level and device > are classic gotchas). Is /dev/tuner0 still there and writeable to > whichever user runs ffmpeg ? Thanks Steve, that was it. /dev/tuner0 was 0444, which oddly didn't cause any error message from ffmpeg, but it didn't activate the sound. Now after a chown $USER and chmod 644 sound works. > GWK> Mencoder does not have this problem, it still records audio. But > GWK> with Mencoder I can only grab 6 to 7 fps :-( > > Double urk! Mencoder and ffmpeg do this in exactly the same > way. Hmm, the mplayer/mencoder from ports didn't want to grab at all when I tried it in 4.6-R. It said something about no matching colorspace. I applied the patch of pb@ludd.luth.se (http://www.freebsd.org/cgi/getmsg.cgi?fetch=8374+0+/usr/local/www/db/text/2002/freebsd-multimedia/20021006.freebsd-multimedia). Now that you say it should work I searched the mail archives again and found that a frame rate of 16 was hardcoded in that patch. Yikes! When I remove that hardcoding I get 19-20 fps mpeg4 at full PAL resolution. This is with a Pentium 4A 2 GHz. With ffmpeg, encoding as mjpeg and no audio compression, I can capture full resolution with just occasional jerkyness. All this is with your recent one-line bktr patch for sync generation. -- Regards, Georg. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-multimedia" in the body of the message From owner-freebsd-multimedia Sun Oct 27 21:33:39 2002 Delivered-To: freebsd-multimedia@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 9806D37B406 for ; Sun, 27 Oct 2002 21:33:36 -0800 (PST) Received: from smtp4.wanadoo.nl (smtp4.wanadoo.nl [194.134.35.175]) by mx1.FreeBSD.org (Postfix) with ESMTP id C3B4243E42 for ; Sun, 27 Oct 2002 21:33:32 -0800 (PST) (envelope-from steve@sohara.org) Received: from ams-gw.sohara.org (p2856.vwr.wanadoo.nl [194.134.219.49]) by smtp4.wanadoo.nl (Postfix) with SMTP id 01C863E307; Mon, 28 Oct 2002 06:33:30 +0100 (CET) Date: Mon, 28 Oct 2002 06:33:25 +0100 From: Steve O'Hara-Smith To: "Georg-W. Koltermann" Cc: freebsd-multimedia@freebsd.org Subject: Re: FreeBSD 4.7R: no sound when recording with ffmpeg? Message-Id: <20021028063325.224adec5.steve@sohara.org> In-Reply-To: <1035759136.1944.97.camel@bat.localnet> References: <1035673653.3373.8.camel@bat.localnet> <20021027071908.1ac2e5d1.steve@sohara.org> <1035759136.1944.97.camel@bat.localnet> X-Mailer: Sylpheed version 0.8.5 (GTK+ 1.2.10; i386-portbld-freebsd4.7) X-Face: %]+HVL}K`P8>+8ZcY-WGHP6j@&mxMo9JH6_WdgIgUGH)JX/usO0%jy7T~IVgqjumD^OBqX,Kv^-GM6mlw(fI^$"QRKyZ$?xx/ Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-freebsd-multimedia@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org On 27 Oct 2002 23:51:57 +0100 "Georg-W. Koltermann" wrote: GWK> Thanks Steve, that was it. /dev/tuner0 was 0444, which oddly didn't GWK> cause any error message from ffmpeg, but it didn't activate the GWK> sound. I wasn't test for that error on the grounds that there may not be a tuner or any audio (camera input for example) so it isn't a failure if opening the tuner doesn't work. I've added a warning message for the next update. GWK> Hmm, the mplayer/mencoder from ports didn't want to grab at all when GWK> I tried it in 4.6-R. It said something about no matching colorspace. There are very few codecs (ie. divx only I think) in mencoder that can handle the capture format used and there is (at the moment) no support for switching capture format. That's the itch that got me writing capture for ffmpeg in the first place :) GWK> With ffmpeg, encoding as mjpeg and no audio compression, I can GWK> capture full resolution with just occasional jerkyness. Nice, I have been getting great results (low CPU and no jerkiness) with "-vcodec mpeg1video -me zero -intra -b 7200" on my AMD2000. Turning on motion estimation pushes average CPU usage to 65% and at the peaks I lose frames. GWK> All this is with your recent one-line bktr patch for sync generation. Now that's the news I've been waiting to hear. That makes two thumbs up and no complaints. I guess it's send_pr and hunt a committer time :) -- C:>WIN | Directable Mirrors The computer obeys and wins. |A Better Way To Focus The Sun You lose and Bill collects. | licenses available - see: | http://www.sohara.org/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-multimedia" in the body of the message From owner-freebsd-multimedia Mon Oct 28 4:21:53 2002 Delivered-To: freebsd-multimedia@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id CC1C437B401 for ; Mon, 28 Oct 2002 04:21:52 -0800 (PST) Received: from brain.stagecraft.cx (CPE-203-51-27-200.nsw.bigpond.net.au [203.51.27.200]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9279A43E3B for ; Mon, 28 Oct 2002 04:21:46 -0800 (PST) (envelope-from carl@stagecraft.cx) Received: from stagecraft.cx (26.stagecraft.cx [203.37.99.26]) by brain.stagecraft.cx (8.12.6/8.12.6) with ESMTP id g9SCLSIB003970; Mon, 28 Oct 2002 23:21:29 +1100 (EST) (envelope-from carl@stagecraft.cx) Date: Mon, 28 Oct 2002 23:21:32 +1100 Subject: Re: FreeBSD 4.7R: no sound when recording with ffmpeg? Content-Type: text/plain; charset=US-ASCII; format=flowed Mime-Version: 1.0 (Apple Message framework v546) Cc: freebsd-multimedia@FreeBSD.ORG To: "Steve O'Hara-Smith" From: Carl Makin In-Reply-To: <20021028063325.224adec5.steve@sohara.org> Message-Id: Content-Transfer-Encoding: 7bit X-Mailer: Apple Mail (2.546) Sender: owner-freebsd-multimedia@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org Hi Steve, On Monday, October 28, 2002, at 04:33 PM, Steve O'Hara-Smith wrote: > Nice, I have been getting great results (low CPU and no jerkiness) > with "-vcodec mpeg1video -me zero -intra -b 7200" on my AMD2000. I have a Celeron 600 and the above ffmpeg parms give me excellent video with only the occasional jerkyness, however the audio goes out of sync *very* quickly. After 120 seconds of recording the sound is obviously wrong. How do you keep the audio in sync? Mencoder keeps the audio in sync, but I can only get, at best, 19fps. Any hints? Thanks! Carl. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-multimedia" in the body of the message From owner-freebsd-multimedia Mon Oct 28 5: 7:19 2002 Delivered-To: freebsd-multimedia@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1E5B337B401 for ; Mon, 28 Oct 2002 05:07:18 -0800 (PST) Received: from srv2.resnet.ohio-state.edu (srv2.resnet.ohio-state.edu [164.107.3.56]) by mx1.FreeBSD.org (Postfix) with SMTP id ED74D43E75 for ; Mon, 28 Oct 2002 05:07:16 -0800 (PST) (envelope-from mistry.7@osu.edu) Received: (qmail 16164 invoked by uid 506); 28 Oct 2002 13:14:53 -0000 Received: from mistry.7@osu.edu by srv2.resnet.ohio-state.edu by uid 503 with qmail-scanner-1.14 ( Clear:. Processed in 0.019913 secs); 28 Oct 2002 13:14:53 -0000 Received: from rdrt-164-107-204-107.resnet.ohio-state.edu (HELO bigguy.am-productions.biz) (164.107.204.107) by srv2.resnet.ohio-state.edu with SMTP; 28 Oct 2002 13:14:53 -0000 Content-Type: text/plain; charset="iso-8859-1" From: Anish Mistry To: Carl Makin Subject: Re: FreeBSD 4.7R: no sound when recording with ffmpeg? Date: Mon, 28 Oct 2002 08:06:59 -0500 User-Agent: KMail/1.4.3 References: In-Reply-To: Cc: freebsd-multimedia@FreeBSD.ORG MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Message-Id: <200210280806.59688.mistry.7@osu.edu> Sender: owner-freebsd-multimedia@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org On Monday 28 October 2002 07:21 am, Carl Makin wrote: > Hi Steve, >=20 > On Monday, October 28, 2002, at 04:33 PM, Steve O'Hara-Smith wrote: >=20 > > =09Nice, I have been getting great results (low CPU and no jerkiness) > > with "-vcodec mpeg1video -me zero -intra -b 7200" on my AMD2000. >=20 > I have a Celeron 600 and the above ffmpeg parms give me excellent video= =20 > with only the occasional jerkyness, however the audio goes out of sync=20 > *very* quickly. After 120 seconds of recording the sound is obviously=20 > wrong. How do you keep the audio in sync? >=20 > Mencoder keeps the audio in sync, but I can only get, at best, 19fps. >=20 For mencoder try the options: -lameopts cbr:br=3D64:q=3D9 > Any hints? >=20 >=20 > Thanks! >=20 >=20 > Carl. >=20 >=20 > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-multimedia" in the body of the message >=20 >=20 --=20 Anish Mistry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-multimedia" in the body of the message From owner-freebsd-multimedia Mon Oct 28 11:22:43 2002 Delivered-To: freebsd-multimedia@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E4D4537B401 for ; Mon, 28 Oct 2002 11:22:41 -0800 (PST) Received: from smtp4.wanadoo.nl (smtp4.wanadoo.nl [194.134.35.175]) by mx1.FreeBSD.org (Postfix) with ESMTP id 939E343E4A for ; Mon, 28 Oct 2002 11:22:39 -0800 (PST) (envelope-from steve@sohara.org) Received: from ams-gw.sohara.org (i0851.vwr.wanadoo.nl [194.134.211.87]) by smtp4.wanadoo.nl (Postfix) with SMTP id D0AA43E69E; Mon, 28 Oct 2002 20:22:35 +0100 (CET) Date: Mon, 28 Oct 2002 20:22:30 +0100 From: Steve O'Hara-Smith To: Carl Makin Cc: freebsd-multimedia@FreeBSD.ORG Subject: Re: FreeBSD 4.7R: no sound when recording with ffmpeg? Message-Id: <20021028202230.1283e8cd.steve@sohara.org> In-Reply-To: References: <20021028063325.224adec5.steve@sohara.org> X-Mailer: Sylpheed version 0.8.5 (GTK+ 1.2.10; i386-portbld-freebsd4.7) X-Face: %]+HVL}K`P8>+8ZcY-WGHP6j@&mxMo9JH6_WdgIgUGH)JX/usO0%jy7T~IVgqjumD^OBqX,Kv^-GM6mlw(fI^$"QRKyZ$?xx/ Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-freebsd-multimedia@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org On Mon, 28 Oct 2002 23:21:32 +1100 Carl Makin wrote: CM> I have a Celeron 600 and the above ffmpeg parms give me excellent CM> video with only the occasional jerkyness, At what resolution ? I'm impressed if a Celeron 600 can keep up with full resolution (720x576 for PAL). CM> however the audio goes out CM> of sync *very* quickly. After 120 seconds of recording the sound is CM> obviously wrong. How do you keep the audio in sync? Erm, well, erm, it just stays in sync for me. Is the sound slippage related to the jerkiness (I'm thinking that the video is skipping occasional frames but the audio is complete which is what I'd expect to happen if frame encoding overuns from time to time). CM> Any hints? Not unless I can figure out a way to detect a missed frame sync interrupt (that bit is easy enough) and sort out the resultant mess, which would be a neat trick.