...
 
Commits (19)
include: "https://gitlab.freedesktop.org/gstreamer/gst-ci/raw/master/gitlab/ci_template.yml"
include: "https://gitlab.freedesktop.org/gstreamer/gst-ci/raw/1.16/gitlab/ci_template.yml"
This diff is collapsed.
This diff is collapsed.
This is GStreamer gstreamer-vaapi 1.16.0.
This is GStreamer gstreamer-vaapi 1.16.1.
The GStreamer team is thrilled to announce a new major feature release in the
stable 1.0 API series of your favourite cross-platform multimedia framework!
As always, this release is again packed with new features, bug fixes and
other improvements.
The GStreamer team is pleased to announce another bug-fix release in the
stable 1.x API series of your favourite cross-platform multimedia framework!
The 1.16 release series adds new features on top of the 1.14 series and is
part of the API and ABI-stable 1.x release series of the GStreamer multimedia
......@@ -60,7 +57,7 @@ You can find source releases of gstreamer in the download
directory: https://gstreamer.freedesktop.org/src/gstreamer/
The git repository and details how to clone it can be found at
https://cgit.freedesktop.org/gstreamer/gstreamer/
https://gitlab.freedesktop.org/gstreamer/
==== Homepage ====
......
# gstreamer-vaapi package version number
m4_define([gst_vaapi_major_version], [1])
m4_define([gst_vaapi_minor_version], [16])
m4_define([gst_vaapi_micro_version], [0])
m4_define([gst_vaapi_micro_version], [1])
m4_define([gst_vaapi_nano_version], [0])
m4_define([gst_vaapi_version],
[gst_vaapi_major_version.gst_vaapi_minor_version.gst_vaapi_micro_version])
......@@ -16,17 +16,17 @@ dnl - interfaces added/removed/changed -> increment CURRENT, REVISION = 0
dnl - interfaces added -> increment AGE
dnl - interfaces removed -> AGE = 0
# gstreamer-vaapi library (libtool) version number
m4_define([gst_vaapi_lt_current], [1600])
m4_define([gst_vaapi_lt_current], [1601])
m4_define([gst_vaapi_lt_revision], [0])
m4_define([gst_vaapi_lt_age], [1600])
m4_define([gst_vaapi_lt_age], [1601])
# glib version number
m4_define([glib_version], [2.40])
# gstreamer version number
m4_define([gst_version], [1.16.0])
m4_define([gst_plugins_base_version], [1.16.0])
m4_define([gst_plugins_bad_version], [1.16.0])
m4_define([gst_version], [1.16.1])
m4_define([gst_plugins_base_version], [1.16.1])
m4_define([gst_plugins_bad_version], [1.16.1])
# Wayland minimum version number
m4_define([wayland_api_version], [1.11.0])
......
......@@ -3,7 +3,7 @@
<description>VA-API based elements</description>
<filename>../../gst/vaapi/.libs/libgstvaapi.so</filename>
<basename>libgstvaapi.so</basename>
<version>1.16.0</version>
<version>1.16.1</version>
<license>LGPL</license>
<source>gstreamer-vaapi</source>
<package>gstreamer-vaapi</package>
......@@ -12,7 +12,7 @@
<element>
<name>vaapidecodebin</name>
<longname>VA-API Decode Bin</longname>
<class>Codec/Decoder/Video</class>
<class>Codec/Decoder/Video/Hardware</class>
<description>A VA-API based bin with a decoder and a postprocessor</description>
<author>Sreerenj Balachandran &lt;sreerenj.balachandran@intel.com&gt;, Victor Jaquez &lt;victorx.jaquez@intel.com&gt;</author>
<pads>
......
......@@ -118,8 +118,7 @@ gst_vaapi_decoder_vp9_close (GstVaapiDecoderVp9 * decoder)
for (i = 0; i < GST_VP9_REF_FRAMES; i++)
gst_vaapi_picture_replace (&priv->ref_frames[i], NULL);
if (priv->parser)
gst_vp9_parser_free (priv->parser);
g_clear_pointer (&priv->parser, gst_vp9_parser_free);
}
static gboolean
......@@ -220,7 +219,16 @@ ensure_context (GstVaapiDecoderVp9 * decoder)
info.profile = priv->profile;
info.entrypoint = entrypoint;
info.chroma_type = GST_VAAPI_CHROMA_TYPE_YUV420;
if (priv->parser->bit_depth == GST_VP9_BIT_DEPTH_8) {
info.chroma_type = GST_VAAPI_CHROMA_TYPE_YUV420;
} else if (priv->parser->bit_depth == GST_VP9_BIT_DEPTH_10) {
info.chroma_type = GST_VAAPI_CHROMA_TYPE_YUV420_10BPP;
} else {
GST_WARNING ("VP9 with depth %d, bigger than 10BPP not supported now",
priv->parser->bit_depth);
return GST_VAAPI_DECODER_STATUS_ERROR_UNSUPPORTED_CHROMA_FORMAT;
}
info.width = priv->width;
info.height = priv->height;
info.ref_frames = 8;
......
......@@ -329,6 +329,8 @@ gst_vaapi_encoder_ensure_param_roi_regions (GstVaapiEncoder * encoder,
roi = (GstVideoRegionOfInterestMeta *)
gst_buffer_iterate_meta_filtered (input, &state,
GST_VIDEO_REGION_OF_INTEREST_META_API_TYPE);
if (!roi)
continue;
/* ignore roi if overflow */
if ((roi->x > G_MAXINT16) || (roi->y > G_MAXINT16)
......
......@@ -2745,6 +2745,7 @@ reset_properties (GstVaapiEncoderH264 * encoder)
{
GstVaapiEncoder *const base_encoder = GST_VAAPI_ENCODER_CAST (encoder);
guint mb_size, i;
gboolean ret;
if (encoder->idr_period < base_encoder->keyframe_period)
encoder->idr_period = base_encoder->keyframe_period;
......@@ -2754,8 +2755,9 @@ reset_properties (GstVaapiEncoderH264 * encoder)
encoder->qp_i = encoder->init_qp;
mb_size = encoder->mb_width * encoder->mb_height;
g_assert (gst_vaapi_encoder_ensure_num_slices (base_encoder, encoder->profile,
encoder->entrypoint, (mb_size + 1) / 2, &encoder->num_slices));
ret = gst_vaapi_encoder_ensure_num_slices (base_encoder, encoder->profile,
encoder->entrypoint, (mb_size + 1) / 2, &encoder->num_slices);
g_assert (ret);
if (encoder->num_bframes > (base_encoder->keyframe_period + 1) / 2)
encoder->num_bframes = (base_encoder->keyframe_period + 1) / 2;
......
......@@ -1721,6 +1721,9 @@ add_slice_headers (GstVaapiEncoderH265 * encoder, GstVaapiEncPicture * picture,
slice_param->num_ref_idx_l1_active_minus1 = reflist_1_count - 1;
else
slice_param->num_ref_idx_l1_active_minus1 = 0;
if (picture->type == GST_VAAPI_PICTURE_TYPE_P && encoder->low_delay_b)
slice_param->num_ref_idx_l1_active_minus1 =
slice_param->num_ref_idx_l0_active_minus1;
i_ref = 0;
if (picture->type != GST_VAAPI_PICTURE_TYPE_I) {
......@@ -2058,6 +2061,7 @@ reset_properties (GstVaapiEncoderH265 * encoder)
GstVaapiH265ReorderPool *reorder_pool;
GstVaapiH265RefPool *ref_pool;
guint ctu_size;
gboolean ret;
if (encoder->idr_period < base_encoder->keyframe_period)
encoder->idr_period = base_encoder->keyframe_period;
......@@ -2067,8 +2071,9 @@ reset_properties (GstVaapiEncoderH265 * encoder)
encoder->qp_i = encoder->init_qp;
ctu_size = encoder->ctu_width * encoder->ctu_height;
g_assert (gst_vaapi_encoder_ensure_num_slices (base_encoder, encoder->profile,
encoder->entrypoint, (ctu_size + 1) / 2, &encoder->num_slices));
ret = gst_vaapi_encoder_ensure_num_slices (base_encoder, encoder->profile,
encoder->entrypoint, (ctu_size + 1) / 2, &encoder->num_slices);
g_assert (ret);
gst_vaapi_encoder_ensure_max_num_ref_frames (base_encoder, encoder->profile,
encoder->entrypoint);
......
......@@ -417,8 +417,10 @@ ensure_sequence (GstVaapiEncoderMpeg2 * encoder, GstVaapiEncPicture * picture)
if (!fill_sequence (encoder, sequence))
goto error;
if (picture->type == GST_VAAPI_PICTURE_TYPE_I &&
!set_sequence_packed_header (encoder, picture, sequence))
if ((GST_VAAPI_ENCODER_PACKED_HEADERS (encoder) &
VA_ENC_PACKED_HEADER_SEQUENCE)
&& picture->type == GST_VAAPI_PICTURE_TYPE_I
&& !set_sequence_packed_header (encoder, picture, sequence))
goto error;
gst_vaapi_enc_picture_set_sequence (picture, sequence);
gst_vaapi_codec_object_replace (&sequence, NULL);
......@@ -442,7 +444,9 @@ ensure_picture (GstVaapiEncoderMpeg2 * encoder, GstVaapiEncPicture * picture,
if (!fill_picture (encoder, picture, codedbuf, surface))
return FALSE;
if (!set_picture_packed_header (encoder, picture)) {
if ((GST_VAAPI_ENCODER_PACKED_HEADERS (encoder) &
VA_ENC_PACKED_HEADER_PICTURE)
&& !set_picture_packed_header (encoder, picture)) {
GST_ERROR ("set picture packed header failed");
return FALSE;
}
......
......@@ -445,6 +445,11 @@ error:
static GstVaapiEncoderStatus
gst_vaapi_encoder_vp8_flush (GstVaapiEncoder * base_encoder)
{
GstVaapiEncoderVP8 *const encoder = GST_VAAPI_ENCODER_VP8 (base_encoder);
encoder->frame_num = 0;
clear_references (encoder);
return GST_VAAPI_ENCODER_STATUS_SUCCESS;
}
......
......@@ -462,6 +462,10 @@ error:
static GstVaapiEncoderStatus
gst_vaapi_encoder_vp9_flush (GstVaapiEncoder * base_encoder)
{
GstVaapiEncoderVP9 *const encoder = GST_VAAPI_ENCODER_VP9 (base_encoder);
encoder->frame_num = 0;
return GST_VAAPI_ENCODER_STATUS_SUCCESS;
}
......
......@@ -36,6 +36,7 @@ gst_vaapi_surface_get_drm_buf_handle (GstVaapiSurface * surface, guint type)
if (!image)
goto error_derive_image;
/* The proxy takes ownership if the image, even creation failure. */
proxy =
gst_vaapi_buffer_proxy_new_from_object (GST_VAAPI_OBJECT (surface),
image->internal_image.buf, type, gst_vaapi_object_unref, image);
......@@ -52,7 +53,6 @@ error_derive_image:
error_alloc_export_buffer:
{
GST_ERROR ("failed to allocate export buffer proxy");
gst_vaapi_object_unref (image);
return NULL;
}
}
......
......@@ -573,6 +573,7 @@ egl_display_thread (gpointer data)
EGLint major_version, minor_version;
gchar **gl_apis, **gl_api;
g_mutex_lock (&display->mutex);
if (!display->base.is_wrapped) {
gl_display = display->base.handle.p =
egl_get_display_from_native (display->base.handle.u,
......@@ -609,7 +610,9 @@ egl_display_thread (gpointer data)
goto error;
display->base.is_valid = TRUE;
display->created = TRUE;
g_cond_broadcast (&display->gl_thread_ready);
g_mutex_unlock (&display->mutex);
while (!display->gl_thread_cancel) {
EglMessage *const msg =
......@@ -624,17 +627,20 @@ egl_display_thread (gpointer data)
egl_object_unref (msg);
}
}
g_mutex_lock (&display->mutex);
done:
if (gl_display != EGL_NO_DISPLAY && !display->base.is_wrapped)
eglTerminate (gl_display);
display->base.handle.p = NULL;
g_cond_broadcast (&display->gl_thread_ready);
g_mutex_unlock (&display->mutex);
return NULL;
/* ERRORS */
error:
{
display->created = TRUE;
display->base.is_valid = FALSE;
goto done;
}
......@@ -656,7 +662,8 @@ egl_display_init (EglDisplay * display)
return FALSE;
g_mutex_lock (&display->mutex);
g_cond_wait (&display->gl_thread_ready, &display->mutex);
while (!display->created)
g_cond_wait (&display->gl_thread_ready, &display->mutex);
g_mutex_unlock (&display->mutex);
return display->base.is_valid;
}
......@@ -1124,8 +1131,6 @@ egl_context_new_wrapped (EglDisplay * display, EGLContext gl_context)
if (!success)
return NULL;
if (args.context)
args.context->base.is_wrapped = TRUE;
return args.context;
}
......
......@@ -122,6 +122,7 @@ struct egl_display_s
GCond gl_thread_ready;
volatile gboolean gl_thread_cancel;
GAsyncQueue *gl_queue;
gboolean created;
};
struct egl_config_s
......
......@@ -246,7 +246,7 @@ gst_vaapi_decode_bin_class_init (GstVaapiDecodeBinClass * klass)
element_class->change_state = gst_vaapi_decode_bin_change_state;
gst_element_class_set_static_metadata (element_class,
"VA-API Decode Bin",
"Codec/Decoder/Video",
"Codec/Decoder/Video/Hardware",
GST_PLUGIN_DESC,
"Sreerenj Balachandran <sreerenj.balachandran@intel.com>, "
"Victor Jaquez <victorx.jaquez@intel.com>");
......
......@@ -769,6 +769,9 @@ gst_vaapiencode_change_state (GstElement * element, GstStateChange transition)
switch (transition) {
case GST_STATE_CHANGE_PAUSED_TO_READY:
gst_pad_stop_task (GST_VAAPI_PLUGIN_BASE_SRC_PAD (encode));
if (!gst_vaapiencode_drain (encode))
goto drain_error;
break;
default:
break;
......@@ -776,6 +779,12 @@ gst_vaapiencode_change_state (GstElement * element, GstStateChange transition)
return
GST_ELEMENT_CLASS (gst_vaapiencode_parent_class)->change_state (element,
transition);
drain_error:
{
GST_ERROR ("failed to drain pending encoded frames");
return GST_STATE_CHANGE_FAILURE;
}
}
static gboolean
......
......@@ -954,7 +954,6 @@ gst_vaapi_driver_is_whitelisted (GstVaapiDisplay * display)
guint i;
static const gchar *whitelist[] = {
"Intel i965 driver",
"mesa gallium",
NULL
};
......
......@@ -244,13 +244,17 @@ gst_vaapipostproc_ensure_filter_caps (GstVaapiPostproc * postproc)
if (!gst_vaapipostproc_ensure_filter (postproc))
return FALSE;
postproc->filter_ops = gst_vaapi_filter_get_operations (postproc->filter);
if (!postproc->filter_ops)
return FALSE;
if (!postproc->filter_ops) {
postproc->filter_ops = gst_vaapi_filter_get_operations (postproc->filter);
if (!postproc->filter_ops)
return FALSE;
}
postproc->filter_formats = gst_vaapi_filter_get_formats (postproc->filter);
if (!postproc->filter_formats)
return FALSE;
if (!postproc->filter_formats) {
postproc->filter_formats = gst_vaapi_filter_get_formats (postproc->filter);
if (!postproc->filter_formats)
return FALSE;
}
return TRUE;
}
......
......@@ -709,9 +709,11 @@ _get_preferred_caps (GstVaapiPostproc * postproc, GstVideoInfo * vinfo,
/* we don't need to do format conversion if GL_TEXTURE_UPLOAD_META
* is negotiated */
if (f != GST_VAAPI_CAPS_FEATURE_GL_TEXTURE_UPLOAD_META
&& postproc->format != format)
if (f == GST_VAAPI_CAPS_FEATURE_GL_TEXTURE_UPLOAD_META) {
postproc->format = DEFAULT_FORMAT;
} else if (postproc->format != format) {
postproc->format = format;
}
return outcaps;
......
......@@ -709,7 +709,7 @@ bail:
/* ERRORS */
error_no_derive_image:
{
GST_ERROR ("Cannot create a VA derived image from surface %p", surface);
GST_INFO ("Cannot create a VA derived image from surface %p", surface);
return FALSE;
}
error_cannot_map:
......
......@@ -25,6 +25,16 @@
</GitRepository>
</repository>
<release>
<Version>
<revision>1.16.1</revision>
<branch>1.16</branch>
<name></name>
<created>2019-09-23</created>
<file-release rdf:resource="https://gstreamer.freedesktop.org/src/gstreamer-vaapi/gstreamer-vaapi-1.16.1.tar.xz" />
</Version>
</release>
<release>
<Version>
<revision>1.16.0</revision>
......
project('gstreamer-vaapi', 'c',
version : '1.16.0',
version : '1.16.1',
meson_version : '>= 0.47.0',
default_options : [ 'warning_level=1',
'buildtype=debugoptimized' ])
......