diff --git a/gst/vaapi/gstvaapipostproc.c b/gst/vaapi/gstvaapipostproc.c index 60b6960d45..dab15bea37 100644 --- a/gst/vaapi/gstvaapipostproc.c +++ b/gst/vaapi/gstvaapipostproc.c @@ -982,10 +982,12 @@ gst_vaapipostproc_update_src_caps (GstVaapiPostproc * postproc, GstCaps * caps, postproc->format != DEFAULT_FORMAT) postproc->flags |= GST_VAAPI_POSTPROC_FLAG_FORMAT; - if ((postproc->width || postproc->height) && - postproc->width != GST_VIDEO_INFO_WIDTH (&postproc->sinkpad_info) && - postproc->height != GST_VIDEO_INFO_HEIGHT (&postproc->sinkpad_info)) + if (GST_VIDEO_INFO_WIDTH (&postproc->srcpad_info) != + GST_VIDEO_INFO_WIDTH (&postproc->sinkpad_info) + && GST_VIDEO_INFO_HEIGHT (&postproc->srcpad_info) != + GST_VIDEO_INFO_HEIGHT (&postproc->sinkpad_info)) postproc->flags |= GST_VAAPI_POSTPROC_FLAG_SIZE; + return TRUE; }