diff options
author | Víctor Manuel Jáquez Leal <victorx.jaquez@intel.com> | 2017-03-29 19:16:50 +0200 |
---|---|---|
committer | Víctor Manuel Jáquez Leal <victorx.jaquez@intel.com> | 2017-04-06 22:00:05 +0200 |
commit | 48e21d6ba88496d0ffb9fa578778c949393225f4 (patch) | |
tree | e76a32176f5945098505103720b989321a0f4e4a | |
parent | e534ff56097d0ec7ccba1c3cb760163933cc98e7 (diff) |
libs: encoder: h265: ensures profile given format
Set the VA profile as GST_VAAPI_PROFILE_H265_MAIN10 if the
configured color format is P010_10LE.
Otherwise, keep GST_VAAPI_PROFILE_H265_MAIN
https://bugzilla.gnome.org/show_bug.cgi?id=771291
-rw-r--r-- | gst-libs/gst/vaapi/gstvaapiencoder_h265.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/gst-libs/gst/vaapi/gstvaapiencoder_h265.c b/gst-libs/gst/vaapi/gstvaapiencoder_h265.c index 7170bcff..8993e14d 100644 --- a/gst-libs/gst/vaapi/gstvaapiencoder_h265.c +++ b/gst-libs/gst/vaapi/gstvaapiencoder_h265.c @@ -936,11 +936,16 @@ static gboolean ensure_profile (GstVaapiEncoderH265 * encoder) { GstVaapiProfile profile; + const GstVideoFormat format = + GST_VIDEO_INFO_FORMAT (GST_VAAPI_ENCODER_VIDEO_INFO (encoder)); /* Always start from "Main" profile for maximum compatibility */ profile = GST_VAAPI_PROFILE_H265_MAIN; + if (format == GST_VIDEO_FORMAT_P010_10LE) + profile = GST_VAAPI_PROFILE_H265_MAIN10; + encoder->profile = profile; encoder->profile_idc = gst_vaapi_utils_h265_get_profile_idc (profile); return TRUE; |