video-converter: Add checks for configuration sanity.
authorJan Schmidt <jan@centricular.com>
Fri, 5 Jun 2020 15:22:21 +0000 (01:22 +1000)
committerGStreamer Merge Bot <gitlab-merge-bot@gstreamer-foundation.org>
Fri, 12 Jun 2020 06:49:56 +0000 (06:49 +0000)
commit205bb066edb6b87fdb3546eb9cdfb04640c93310
tree7c3539379bf5e542a57de1688309136743d10bf8
parentbf5d51c5da78b84c203d61369b640de0042dd0bf
video-converter: Add checks for configuration sanity.

If the cropping or scaling input or output rects put us completely
outside the input/output frame respectively, we can't draw anything
except black safely. Check for those conditions and don't set up a
configuration that attempts to access out of bounds memory outside
the input/output framebuffers.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/696>
gst-libs/gst/video/video-converter.c
tests/check/libs/video.c