Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 25 Apr 1999 18:53:12 -0700
From:      John-Mark Gurney <gurney_j@efn.org>
To:        multimedia@freebsd.org
Cc:        Amancio Hasty <hasty@rah.star-gate.com>, Steve Passe <fsmp@freebsd.org>
Subject:   brooktree driver problems??
Message-ID:  <19990425185312.25505@hydrogen.nike.efn.org>

next in thread | raw e-mail | index | archive | help

--LboLdkugWU4S2B/J
Content-Type: text/plain; charset=us-ascii

well, I'm writing a util that will allow you to specify multiple files
and capture video distributed over the files... this allows you to not
have to strip your drives to get the performance necessary to capture
640x480@30fps...

the first problem I came across was the driver sending my program around
280-380 signals per sec...  this is definately NOT 30fps...  I set the
geometry using the METEORSETGEO ioctl to width 160, height 120, frame 1,
and fmt METEOR_GEO_YUV_12...  and similar things happen when I set the
geo to 320x240...  as I read the driver, this shouldn't happen, but it
is...

the second problem I have is that then I set the format to 640x480, it
captures only at 24fps and it doesn't wake my program up until I deliver
the intended signal myself...  I know I am not missing signals as I have
a VERY simple signal handler that will count if it gets called and I
haven't processed the last one...

I have attached the code that I am using to set up the brooktree driver..
I should note that this is on a 3.0-R system with v1.56 of brooktree.c
(the one that came with 3.0-R)...  I read the commit logs for brooktree.c
and didn't see anything that would address the issues I have stated
above...

-- 
  John-Mark Gurney                              Voice: +1 541 684 8449
  Cu Networking					  P.O. Box 5693, 97405

  "The soul contains in itself the event that shall presently befall it.
  The event is only the actualizing of its thought." -- Ralph Waldo Emerson

--LboLdkugWU4S2B/J
Content-Type: text/plain; charset=us-ascii
Content-Disposition: attachment; filename="bktr.init"

	ccp.height = 160;
	ccp.width = 120;
	ccp.heightoff = 0;
	ccp.widthoff = 0;
						/* 12bpp / 8bits for YUV_12 */
	ccp.framesize = ccp.height * ccp.width * 12 / 8;
	ccp.brightness = 0;
	ccp.contrast = 0;
	ccp.fmt = METEOR_GEO_YUV_12;
	ccp.dev = 0;
	ccp.devname = "/dev/bktr0";

	if ((ccfd = open(ccp->devname, O_RDONLY, 0)) == -1)
		return "open capture card";

	i = ccp->contrast;
	if (ioctl(ccfd, METEORSCONT, &i) == -1)
		return "METEORSCONT";

	i = ccp->brightness;
	if (ioctl(ccfd, METEORSBRIG, &i) == -1)
		return "METEORSBRIG";

	i = METEOR_FMT_NTSC;
	if (ioctl(ccfd, METEORSFMT, &i) == -1)
		return "METEORSFMT";

	geo.rows = ccp->height;
	geo.columns = ccp->width;
	geo.oformat = ccp->fmt;
	geo.frames = 1;
	if (ioctl(ccfd, METEORSETGEO, &geo) == -1)
		return "METEORSETGEO";

	i = ccp->dev;
	if (ioctl(ccfd, METEORSINPUT, &i) == -1)
		return "METEORSINPUT";

	i = SIGUSR1;
	if (ioctl(ccfd, METEORSSIGNAL, &i) == -1)
		return "METEORSSIGNAL";

	if ((mem = mmap(0, ccp->framesize, PROT_READ, MAP_SHARED, ccfd, 0))
	    == MAP_FAILED)
		return "mmap";


--LboLdkugWU4S2B/J--


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-multimedia" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?19990425185312.25505>