tags:

views:

85

answers:

1

I've been trying to code a framegrabber for a firewire camera, using libdc1394. The initialization of the camera is done properly, the video mode is set to the supported DC1394_VIDEO_MODE_640x480_YUV422 and the frame is grabbed without any errors.

The problem is, however, that the frame that is returned consists of 640x480x1.5 bytes, which is actually YUV411 packaging. The video frame struct also states the video mode used was YUV411.

But the data actually does not decode with YUV411. Instead YUV422 decoding produces a valid image, but the lower region of the image is missing, obviously due to the frame data missing the last bytes (YUV422 is 16bits per pixel, YUV411 is 12bits per pixel).

Now the camera is IIDC v1.30 compliant and libdc1394 supports that. The only video mode supported (as stated by libdc1394) is being used and that's the one that the camera manual states the camera is using.

I haven't found my way around this problem by googling. Any clues?

A: 

The problem is with the firmware of the device failing to return the correct value of the video mode. It can be resolved by patching libdc1394 to return the desired value.

alkar