video format and inversion

Mike Travisano mtravisano at Saba.com
Mon May 7 15:50:44 GMT 2007


Thanks Steve.

It appears that the driver only wants to return 2yuv, as confirmed
through both the VDGetDigitizerInfo call (looking at VDIG
outputcapabilities flags) and the VDGetImageDescription() call.

The VDGetCompressionTypes() function only returns one item in a list
"Component Video CCIR - 601 uyuv"

I've tried to set all of the following using the VDSetCompression(...)
function, but they all get rejected.

k16LE555PixelFormat = 16 bit LE rgb 555 
k16LE5551PixelFormat = 16 bit LE rgb 5551
k16BE565PixelFormat = 16 bit BE rgb 565
k16LE565PixelFormat = 16 bit LE rgb 565
k24BGRPixelFormat = 24 bit bgr 
k32BGRAPixelFormat = 32 bit bgra (Matrox)
k32ABGRPixelFormat = 32 bit abgr    
k32RGBAPixelFormat = 32 bit rgba   


I'll look into the using a Decompression Sequence/GWorld solution.

-Mike




-----Original Message-----
From: Steve Sisak [mailto:steve.sisak at ioxperts.com] 
Sent: Monday, May 07, 2007 1:49 PM
To: IOXperts Video Developers Discussion List
Cc: Mike Travisano
Subject: Re: video format and inversion

At 1:02 PM -0400 5/7/07, Mike Travisano wrote:
>I'm trying to integrate this code into a cross-platform (Mac, Win) 
>implementation, which uses Trolltech's QT libraries (these have 
>support for RGB only).

Which RGB format(s)?

>The problems I am seeing are:
>
>1)       It appears as though I cannot get image data in the RGB 
>format from the input device. It looks like YUV is the only color 
>space available. I've used other stand-alone applications as well, 
>including some of the QuickTime examples, and I'm observing the same 
>issue.

I'm pretty sure 24-bit RGB is supported and we generate 32-bit from 
that in the driver (although the hardware only supports 15fps RGB at 
VGA)

>2)       The frames appear to be inverted. Rendering of the frames 
>is done through my use of TrollTech's QT, so the image is flipped 
>180 degrees.

Not sure I can help much there -- sounds like they use a non-standard 
coordinate system.

>I'm tempted to write a color space converter (YUV to RGB) and flip 
>the image at the same time, but I'm hoping that there is a quicker 
>solution. Are there functions on the Mac to do this? Is there a way 
>to get RGB data from video capture devices on the Mac?

(These are typed from memory, but s/b close)

Assuming you're talking to the Video Digitizer (which you can get 
from the video channel of the sequence grabber):

VDGetCompressTypes()  returns the lost of supported compression types
VDSetCompression() lets you set which of those (and the depth) to use
VDGetImageDescription() returns an image description for what you're
getting

I don't know anything about Qt, but might be able to provide more 
info with more details.

Since you can't guarantee what pixel format you're going to get, you 
might want to feed the output of the VDig/SG to a 
DecompressionSession to an RGB GWorld which can also do flip/mirror 
in the process.

QuickTime and CoreVideo are the video architectures on the Mac and 
both provide very deep control over video and video formats.

HTH,

-Steve

-- 
________________________________________________________________________
_
Steve Sisak, CTO
steve.sisak at ioxperts.com
IOXperts, Inc.                                     voice: +1 617
876-2572
87 Bristol St #3A                                    fax: +1 617
876-2337
Cambridge, MA 02139                               mobile: +1 617
388-6476



More information about the Video-Developers mailing list