From owner-freebsd-multimedia@FreeBSD.ORG Mon Jan 5 20:48:57 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 E50E71065746 for ; Mon, 5 Jan 2009 20:48:56 +0000 (UTC) (envelope-from jason.harmening@gmail.com) Received: from wf-out-1314.google.com (wf-out-1314.google.com [209.85.200.173]) by mx1.freebsd.org (Postfix) with ESMTP id B838D8FC18 for ; Mon, 5 Jan 2009 20:48:56 +0000 (UTC) (envelope-from jason.harmening@gmail.com) Received: by wf-out-1314.google.com with SMTP id 24so10029415wfg.7 for ; Mon, 05 Jan 2009 12:48:56 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to :subject:mime-version:content-type:content-transfer-encoding :content-disposition; bh=L8Iff2I93I0CgEz9XF8vRcrLalOo49l++wxkh+kaS8s=; b=oWBiXDx5mLXEJ7sNlVS+5r9UfF74UxIYBgzUtAstDCt5Fhf1WmlNQ4lfkIP3suCAyY LlLgk/jA70RIHul/8HiCs9Yq5TaN5SJzEjeYK9lfIOTuCFsEIaZfyr5ib3hIYfA896tf U7dF0StPjn/2wCEPi0JXyDOFBsisi+r6extbQ= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:mime-version:content-type :content-transfer-encoding:content-disposition; b=KS/cvCEHeUXynlQEARz9fwq3ReM0yBiQkWzcjunLpsVXb8qUnoiYq49c/9OZZjZ4P3 LkbmHjcobFbH6PoLwjYIenPyC1ZXtHqTkdA5CC3jsjIeQLPlv1gl1W8TtZHza3y5UWRw T/kSphnSVHCt+AePrYkwz4fJlbZr7zppIQxzc= Received: by 10.142.58.2 with SMTP id g2mr8810827wfa.313.1231187315522; Mon, 05 Jan 2009 12:28:35 -0800 (PST) Received: by 10.142.125.6 with HTTP; Mon, 5 Jan 2009 12:28:35 -0800 (PST) Message-ID: <2d1264630901051228q7c526b80of3def7f6028599e3@mail.gmail.com> Date: Mon, 5 Jan 2009 14:28:35 -0600 From: "Jason Harmening" To: freebsd@sopwith.solgatos.com, freebsd-multimedia@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline Cc: Subject: Re: sound for cx88 analog capture 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: Mon, 05 Jan 2009 20:48:59 -0000 > I updated to the latest cx88 and am trying to get analog > working as described in "Capturing Raw Video" on the wiki. > > I have the video working, but no audio. > > Wiki says: "The ffmpeg command above uses the OSS-compatible cx88 audio > interface, and assumes that /dev/dsp1 is the OSS audio device that > corresponds to cx88audio0. > > How do we determine if /dev/dsp1 corresponds to cx88audio0? > > pcm0: port 0xf000-0xf0ff,0xec00-0xecff mem 0xfebfd000-0xfebfdfff irq 12 at device 4.0 on pci0 > pcm0: [ITHREAD] > pcm0: > cx88audio0: mem 0xfc000000-0xfcffffff irq 10 at device 7.1 on pci1 > iicbus6: on cx88audio0 > cx88audio0: [FILTER] > pcm1: on cx88audio0 > cx88audio0: [FILTER+ITHREAD] The node number of the dsp* entry will correspond to the number for the pcm* entry, so /dev/dsp1 should be it. Can you try capturing just the audio: cx88 -d /dev/cx88audio0 -x /usr/local/share/examples/cx88/cx88.xml.sample -c USA:42 while simultaneously doing a 'cat /dev/dsp1 > /dev/dsp0'? That will be basically the same thing that's happening for the audio part of the combined video/audio capture. > > The /dev entries seem kinda screwy: > > crw-rw-rw- 1 root wheel 0, 202 Dec 29 13:10 /dev/dsp0.0 > crw-rw-rw- 1 root wheel 0, 207 Dec 29 13:10 /dev/dsp0.1 > crw-rw-rw- 1 root wheel 0, 203 Dec 29 13:10 /dev/dsp1.0 > crw-rw-rw- 1 root wheel 0, 209 Dec 29 13:10 /dev/dsp1 > crw-rw-rw- 1 root wheel 0, 210 Dec 29 13:10 /dev/dsp0 > > ls: /dev/pcm0: No such file or directory > ls: /dev/pcm1: No such file or directory > > crw-rw-rw- 1 root wheel 0, 205 Dec 29 13:10 /dev/cx88audio0 > > I changed the script to output dv format: > > mkfifo /tmp/vpipe > /usr/local/bin/ffmpeg -v 2 \ > -f oss -ar 48000 -ac 2 -i /dev/dsp1 \ > -pix_fmt yuv422p -r 30000/1001 -s 640x480 -f rawvideo -i /tmp/vpipe \ > -pix_fmt yuv411p -r 30000/1001 -padleft 40 -padright 40 \ > /var/tmp/analog.dv > > ffmpeg says: > > Input #0, oss, from '/dev/dsp1': > Duration: N/A, start: 1230593138.586555, bitrate: N/A > Stream #0.0, 1/1000000: Audio: pcm_s16le, 48000 Hz, stereo, 1536 kb/s > Input #1, rawvideo, from '/tmp/vpipe': > Duration: N/A, bitrate: N/A > Stream #1.0, 1001/30000: Video: rawvideo, yuv422p, 640x480, 1001/30000, 29.97 fps(r) > Output #0, dv, to '/var/tmp/analog.dv': > Stream #0.0, 1/90000: Video: dvvideo, yuv411p, 720x480, 1001/30000, q=2-31, 200 kb/s, 29.97 fps(c) > Stream #0.1, 1/90000: Audio: pcm_s16le, 48000 Hz, stereo, 1536 kb/s > Stream mapping: > Stream #1.0 -> #0.0 > Stream #0.0 -> #0.1 > Press [q] to stop encoding > frame= 494 fps= 30 q=0.0 size= 57773kB time=16.5 bitrate=28755.7kbits/s dup=0 drop=0 ffmpeg seems to think it captured the audio--could it have something to do with the dv format? Can you try using the MPEG format like the example on the wiki?