v4l2sink: v4l2-gfx driver cropping workaround
authorAlessandro Decina <alessandro.decina@collabora.co.uk>
Tue, 6 Sep 2011 15:15:28 +0000 (17:15 +0200)
committerAlessandro Decina <alessandro.decina@collabora.co.uk>
Tue, 6 Sep 2011 15:15:28 +0000 (17:15 +0200)
commitaa2dd29211788f2d4b6a6588f8fd05b8518a9bc2
treeb7725f6d2e9c35396ae1593baa1ad651e6247093
parentd40b86211cebe863ac0de6f82867a4fc14c584ee
v4l2sink: v4l2-gfx driver cropping workaround

When using the v4l2-gfx driver, the rendering side usually
gets frame width and height looking at the
v4l2_gfx_buf_params structure passed to the V4L2_GFX_IOC_ACQ
ioctl. The structure is populated with the values set by the
last VIDIOC_S_CROP ioctl, or zero filled if VIDIOC_S_CROP
was never called.

So we make sure to call VIDIOC_S_CROP at least once, and
always with crop_width and crop_height set to meaningful
values.
sys/v4l2/gstv4l2sink.c