From owner-freebsd-multimedia@FreeBSD.ORG Mon May 1 05:36:08 2006 Return-Path: X-Original-To: freebsd-multimedia@freebsd.org 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 0C63116A818 for ; Mon, 1 May 2006 05:34:48 +0000 (UTC) (envelope-from jakemsr@jakemsr.com) Received: from mail231.csoft.net (mail231.csoft.net [205.205.221.4]) by mx1.FreeBSD.org (Postfix) with SMTP id 0CE2343D68 for ; Mon, 1 May 2006 05:34:40 +0000 (GMT) (envelope-from jakemsr@jakemsr.com) Received: (qmail 6220 invoked from network); 1 May 2006 05:34:39 -0000 Received: from unknown (HELO puff.jakemsr.gom) (jakemsr@67.168.202.159) by mail231.csoft.net with SMTP; 1 May 2006 05:34:39 -0000 Received: from puff.jakemsr.gom (jakemsr@localhost.jakemsr.gom [127.0.0.1]) by puff.jakemsr.gom (8.13.6/8.13.4) with ESMTP id k415Ybfq010371; Sun, 30 Apr 2006 22:34:38 -0700 (PDT) Received: (from jakemsr@localhost) by puff.jakemsr.gom (8.13.6/8.13.3/Submit) id k415Ybrb030143; Sun, 30 Apr 2006 22:34:37 -0700 (PDT) Date: Sun, 30 Apr 2006 22:34:37 -0700 From: Jacob Meuser To: freebsd-multimedia@freebsd.org Message-ID: <20060501053437.GA20289@puff.jakemsr.gom> Mail-Followup-To: freebsd-multimedia@freebsd.org, Torfinn Ingolfsen References: <20060427182528.35070.qmail@exxodus.fedaykin.here> <20060427205905.9ab1500f.torfinn.ingolfsen@broadpark.no> <20060427201316.GJ728@funkthat.com> <20060430213424.GA19859@puff.jakemsr.gom> <20060501044835.GQ728@funkthat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20060501044835.GQ728@funkthat.com> User-Agent: Mutt/1.4.2i Cc: Subject: Re: FreeBSD Multimedia API and Google SOC2006 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, 01 May 2006 05:36:08 -0000 On Sun, Apr 30, 2006 at 09:48:35PM -0700, John-Mark Gurney wrote: > Jacob Meuser wrote this message on Sun, Apr 30, 2006 at 14:34 -0700: > > On Thu, Apr 27, 2006 at 01:13:16PM -0700, John-Mark Gurney wrote: > > > Torfinn Ingolfsen wrote this message on Thu, Apr 27, 2006 at 20:59 +0200: > > > > On Thu, 27 Apr 2006 15:25:05 -0300 > > > > Mario Sergio Fujikawa Ferreira wrote: > > > > > > > > > I was wondering if someone could propose a > > > > > project for a basic multimedia API for FreeBSD. > > > > > > > > Video4bsd (V4B) perhaps? > > > > Here is one candidate: http://people.freebsd.org/~jmg/videobsd.html > > > > > > Yeh, I think I'll mentor someone if someone is interested.... > > > > > > > Also, the USB Video class (example at http://linux-uvc.berlios.de/) > > > > looks interesting, I think it should be included in a multimedia API > > > > for BSD. > > > > > > > > > I am not proposing V4Linux but some sort of common > > > > > API abstraction. > > > > > > > > IMHO, if we create our own multimedia API, it should have V4L2 > > > > and V4L1 "faces" or "shims" that allows devices to be operated through > > > > these APIs. At least V4L2, only V4L1 if it is really needed. > > > > The reason for this is that it will ease porting of programs that uses > > > > the V4L API's. And there are a lot of those. > > > > Note: I am very much out of my waters here, I can't really tell if this > > > > is feasible / practical at all. > > > > > > Personally the V4Lx API's are at the wrong level for how far computers > > > have advanaced... Any video api should be a userland library, that > > > provides access to it... and not a kernel interface that is of > > > limited use... This has the advantage that updates for new tuners and > > > other stuff can happen easier and quicker... and more people are willing > > > to touch the code... > > > > > > My bktrau driver for the DViCO FusionHDTV5 Lite has a minimal kernel > > > presence... the userland capture program uses the GPIO defines in bktr, > > > the iic device driver for controlling the tuner and demodulator to > > > control the capture.. This means my driver is under 1k lines of code.. > > > > is the bktrau code available? > > It's in perforce: > http://perforce.freebsd.org/depotTreeBrowser.cgi?FSPC=//depot/user/jmg/bktrau thanks > > > > If there is need for a mechanism (sp?) to distinguish which API a > > > > certain device can be operated with, an easy way would be to use a > > > > naming convention. Example: /dev/video0 - use the V4L > > > > API, /dev/bsdvideo0 - use the V4B API. Most likely, somebody else has a > > > > better suggestion. > > > > > > I'd suggest NOT to use a kernel interface.. they are expensive to > > > maintain, and harder to shoehorn things like USB web cams into... > > > > I tried making a userland A/V library ... > > > > http://www.jakemsr.com/bsdav/ > > > > not the greatest, only supports bktr video, but maybe some kind of > > starting point? > > Hmmm... This seems to be more of a stream format than a AV device > library... There are a few things to interact w/ bktr, but my goal > for a library, is that you'd never know what the frame (or stream) > grabber underneath is.. that you'd just say, give me a frame in x > format.. and the userland would find the best common format and handle > the translation... yeah, it was just a "first go". I would like to make it more usable. I think I see what you're saying though ... something like: bsdav.vid->init(YV12, 640, 480, 30); while (...) { buf = bsdav.vid->get_frame(); (modify/write/display buf) } bsdav.vid->stop(); --