v4l2object: use S_SELECTION instead of S_CROP in gst_v4l2_object_set_crop
authorPhilipp Zabel <p.zabel@pengutronix.de>
Mon, 25 Jun 2018 14:03:17 +0000 (16:03 +0200)
committerNicolas Dufresne <nicolas.dufresne@collabora.com>
Wed, 27 Jun 2018 20:31:39 +0000 (16:31 -0400)
commit32fa1e7a65711b9d2b7468e682ce9fe0bc97b66b
tree89f35279b97f33a1d94f837847cb34f9f6be87e2
parent58e9341384faa01073c8b3c1899f0f50defc124d
v4l2object: use S_SELECTION instead of S_CROP in gst_v4l2_object_set_crop

The S_CROP call doesn't work on mem2mem output queues. Use the
S_SELECTION call to set the crop rectangle and only fall back to
S_CROP for ancient kernels.
This will allow v4l2videoenc to set the coded size on the output
queue via S_FMT and then set the visible size via the crop rectangle,
as required by the V4L2 codec API.

https://bugzilla.gnome.org/show_bug.cgi?id=796672
sys/v4l2/gstv4l2object.c