v4l2codecs: h265dec: Fail when frame cropping is needed while using DMABuf
It is not possible to do frame cropping when DMABuf caps feature is negotiated. The VideoInfo size is zero, resulting in empty destination buffers, and video convert library may not understand what the format actually is. Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9305>
This commit is contained in:
parent
e7be87b3de
commit
5e2a4a6d13
@ -501,10 +501,18 @@ gst_v4l2_codec_h265_dec_decide_allocation (GstVideoDecoder * decoder,
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
if (gst_video_is_dma_drm_caps (caps) && !has_videometa) {
|
||||
GST_ERROR_OBJECT (self,
|
||||
"DMABuf caps negotiated without the mandatory support of VideoMeta");
|
||||
return FALSE;
|
||||
if (gst_video_is_dma_drm_caps (caps)) {
|
||||
if (!has_videometa) {
|
||||
GST_ERROR_OBJECT (self,
|
||||
"DMABuf caps negotiated without the mandatory support of VideoMeta");
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
if (self->need_crop) {
|
||||
GST_ERROR_OBJECT (self,
|
||||
"Frame cropping is not supported when DMABuf caps is negotiated.");
|
||||
return FALSE;
|
||||
}
|
||||
}
|
||||
|
||||
/* Check if we can zero-copy buffers */
|
||||
|
Loading…
x
Reference in New Issue
Block a user