From: gb Date: Thu, 29 Apr 2010 21:12:30 +0000 (+0000) Subject: Fix gst_vaapi_profile_get_caps() to include the "profile" field. X-Git-Tag: accepted/trunk/20120822.173359~492 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=8c17e2f99d46ec7d3377ec28d0a1eb06afd06610;p=profile%2Fivi%2Fgstreamer-vaapi.git Fix gst_vaapi_profile_get_caps() to include the "profile" field. --- diff --git a/gst-libs/gst/vaapi/gstvaapiprofile.c b/gst-libs/gst/vaapi/gstvaapiprofile.c index c832a2b..11c67ad 100644 --- a/gst-libs/gst/vaapi/gstvaapiprofile.c +++ b/gst-libs/gst/vaapi/gstvaapiprofile.c @@ -279,8 +279,17 @@ GstCaps * gst_vaapi_profile_get_caps(GstVaapiProfile profile) { const GstVaapiProfileMap * const m = get_profiles_map(profile); + GstCaps *caps; - return m ? gst_caps_from_string(m->caps_str) : NULL; + if (!m) + return NULL; + + caps = gst_caps_from_string(m->caps_str); + if (!caps) + return NULL; + + gst_caps_set_simple(caps, "profile", G_TYPE_STRING, m->profile_str, NULL); + return caps; } /**