From: Gwenole Beauchesne Date: Mon, 28 Jul 2014 14:43:47 +0000 (+0200) Subject: vaapidecode: fix auto-plugging of vaapisink element. X-Git-Tag: 0.5.9~6 X-Git-Url: http://review.tizen.org/git/?p=platform%2Fupstream%2Fgstreamer-vaapi.git;a=commitdiff_plain;h=c5102c72af9df7f508fe278054c45409c15ead24 vaapidecode: fix auto-plugging of vaapisink element. Make sure to propagate memory:VASurface capsfeature to srcpad caps only for GStreamer >= 1.5 as the plug-in elements in GStreamer 1.4 core currently miss additional patches available in 1.5-git (1.6). This is a temporary workaround. --- diff --git a/gst/vaapi/gstvaapidecode.c b/gst/vaapi/gstvaapidecode.c index b5f7a40..cc934e4 100644 --- a/gst/vaapi/gstvaapidecode.c +++ b/gst/vaapi/gstvaapidecode.c @@ -196,12 +196,12 @@ gst_vaapidecode_update_src_caps(GstVaapiDecode *decode, default: if (format == GST_VIDEO_FORMAT_ENCODED) { /* XXX: this is a workaround until auto-plugging is fixed when - format=ENCODED + memory:VASurface caps feature are provided. - Meanwhile, providing a random format here works but this is - a terribly wrong thing per se. */ + format=ENCODED + memory:VASurface caps feature are provided. + Meanwhile, providing a random format here works but this is + a terribly wrong thing per se. */ gst_vaapidecode_video_info_change_format(&vis, out_format, GST_VIDEO_INFO_WIDTH(vi), GST_VIDEO_INFO_HEIGHT(vi)); -#if GST_CHECK_VERSION(1,3,0) +#if GST_CHECK_VERSION(1,5,0) if (feature == GST_VAAPI_CAPS_FEATURE_VAAPI_SURFACE) features = gst_caps_features_new( GST_CAPS_FEATURE_MEMORY_VAAPI_SURFACE, NULL);