utils: only enable VP8 profiles for newer VA-API versions.
authorGwenole Beauchesne <gwenole.beauchesne@intel.com>
Mon, 2 Jun 2014 14:25:03 +0000 (16:25 +0200)
committerGwenole Beauchesne <gwenole.beauchesne@intel.com>
Mon, 2 Jun 2014 16:25:12 +0000 (18:25 +0200)
VP8 decoding API appeared in VA-API >= 0.35.0. So, disable mappings
involving VP8 codec on earlier versions of the API.

gst-libs/gst/vaapi/gstvaapiprofile.c
gst-libs/gst/vaapi/gstvaapiutils.c

index 76e5d0e..5b3640c 100644 (file)
@@ -126,8 +126,10 @@ static const GstVaapiProfileMap gst_vaapi_profiles[] = {
       "image/jpeg", "baseline"
     },
 #endif
+#if VA_CHECK_VERSION(0,35,0)
     {GST_VAAPI_PROFILE_VP8, VAProfileVP8Version0_3,
       "video/x-vp8", "Version0_3"},
+#endif
     { 0, }
 };
 
index 63e4691..d7f1d85 100644 (file)
@@ -145,6 +145,9 @@ string_of_VAProfile (VAProfile profile)
       MAP (VC1Simple);
       MAP (VC1Main);
       MAP (VC1Advanced);
+#if VA_CHECK_VERSION(0,35,0)
+      MAP (VP8Version0_3);
+#endif
 #undef MAP
     default:
       break;