mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-02-20 21:16:24 +00:00
libs: remove crumbs of libva < 0.39
All these guarded code seem like leftovers of commit 920b1ec7a
. This
patch completes that missing clean up.
This commit is contained in:
parent
0f1b1f40e5
commit
96cdebf185
3 changed files with 0 additions and 49 deletions
|
@ -822,9 +822,7 @@ fill_picture (GstVaapiDecoderVC1 * decoder, GstVaapiPicture * picture)
|
|||
pic_param->backward_reference_picture = VA_INVALID_ID;
|
||||
pic_param->inloop_decoded_picture = VA_INVALID_ID;
|
||||
pic_param->sequence_fields.value = 0;
|
||||
#if VA_CHECK_VERSION(0,32,0)
|
||||
pic_param->sequence_fields.bits.profile = seq_hdr->profile;
|
||||
#endif
|
||||
pic_param->coded_width = priv->width;
|
||||
pic_param->coded_height = priv->height;
|
||||
pic_param->entrypoint_fields.value = 0;
|
||||
|
|
|
@ -501,11 +501,8 @@ ensure_profiles (GstVaapiDisplay * display)
|
|||
|
||||
GST_DEBUG ("%d profiles", n);
|
||||
for (i = 0; i < n; i++) {
|
||||
#if VA_CHECK_VERSION(0,34,0)
|
||||
/* Introduced in VA/VPP API */
|
||||
if (profiles[i] == VAProfileNone)
|
||||
continue;
|
||||
#endif
|
||||
GST_DEBUG (" %s", string_of_VAProfile (profiles[i]));
|
||||
}
|
||||
|
||||
|
@ -602,11 +599,6 @@ ensure_properties (GstVaapiDisplay * display)
|
|||
GST_DEBUG (" %s", string_of_VADisplayAttributeType (attr->type));
|
||||
|
||||
switch (attr->type) {
|
||||
#if !VA_CHECK_VERSION(0,34,0)
|
||||
case VADisplayAttribDirectSurface:
|
||||
prop.name = GST_VAAPI_DISPLAY_PROP_RENDER_MODE;
|
||||
break;
|
||||
#endif
|
||||
case VADisplayAttribRenderMode:
|
||||
prop.name = GST_VAAPI_DISPLAY_PROP_RENDER_MODE;
|
||||
break;
|
||||
|
@ -1848,26 +1840,6 @@ get_render_mode_VADisplayAttribRenderMode (GstVaapiDisplay * display,
|
|||
return TRUE;
|
||||
}
|
||||
|
||||
static gboolean
|
||||
get_render_mode_VADisplayAttribDirectSurface (GstVaapiDisplay * display,
|
||||
GstVaapiRenderMode * pmode)
|
||||
{
|
||||
#if VA_CHECK_VERSION(0,34,0)
|
||||
/* VADisplayAttribDirectsurface was removed in VA-API >= 0.34.0 */
|
||||
return FALSE;
|
||||
#else
|
||||
gint direct_surface;
|
||||
|
||||
if (!get_attribute (display, VADisplayAttribDirectSurface, &direct_surface))
|
||||
return FALSE;
|
||||
if (direct_surface)
|
||||
*pmode = GST_VAAPI_RENDER_MODE_OVERLAY;
|
||||
else
|
||||
*pmode = GST_VAAPI_RENDER_MODE_TEXTURE;
|
||||
return TRUE;
|
||||
#endif
|
||||
}
|
||||
|
||||
static gboolean
|
||||
get_render_mode_default (GstVaapiDisplay * display, GstVaapiRenderMode * pmode)
|
||||
{
|
||||
|
@ -1911,10 +1883,6 @@ gst_vaapi_display_get_render_mode (GstVaapiDisplay * display,
|
|||
if (get_render_mode_VADisplayAttribRenderMode (display, pmode))
|
||||
return TRUE;
|
||||
|
||||
/* Try with direct-surface attribute */
|
||||
if (get_render_mode_VADisplayAttribDirectSurface (display, pmode))
|
||||
return TRUE;
|
||||
|
||||
/* Default: determine from the display type */
|
||||
return get_render_mode_default (display, pmode);
|
||||
}
|
||||
|
|
|
@ -38,7 +38,6 @@ gboolean
|
|||
gst_vaapi_encoder_ensure_param_quality_level (GstVaapiEncoder * encoder,
|
||||
GstVaapiEncPicture * picture)
|
||||
{
|
||||
#if VA_CHECK_VERSION(0,36,0)
|
||||
GstVaapiEncMiscParam *misc;
|
||||
|
||||
/* quality level param is not supported */
|
||||
|
@ -52,7 +51,6 @@ gst_vaapi_encoder_ensure_param_quality_level (GstVaapiEncoder * encoder,
|
|||
sizeof (encoder->va_quality_level));
|
||||
gst_vaapi_enc_picture_add_misc_param (picture, misc);
|
||||
gst_vaapi_codec_object_replace (&misc, NULL);
|
||||
#endif
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
|
@ -621,15 +619,6 @@ get_packed_headers (GstVaapiEncoder * encoder)
|
|||
encoder->got_packed_headers = TRUE;
|
||||
encoder->packed_headers = cdata->packed_headers & value;
|
||||
|
||||
if (cdata->codec == GST_VAAPI_CODEC_JPEG) {
|
||||
#if !VA_CHECK_VERSION(0,37,1)
|
||||
encoder->packed_headers = VA_ENC_PACKED_HEADER_RAW_DATA;
|
||||
GST_DEBUG ("Hard coding the packed header flag value to "
|
||||
"VA_ENC_PACKED_HEADER_RAW_DATA. This is a work around for the driver "
|
||||
"bug");
|
||||
#endif
|
||||
}
|
||||
|
||||
return encoder->packed_headers;
|
||||
}
|
||||
|
||||
|
@ -791,9 +780,7 @@ gst_vaapi_encoder_reconfigure_internal (GstVaapiEncoder * encoder)
|
|||
GstVaapiVideoPool *pool;
|
||||
guint codedbuf_size, target_percentage;
|
||||
guint fps_d, fps_n;
|
||||
#if VA_CHECK_VERSION(0,36,0)
|
||||
guint quality_level_max = 0;
|
||||
#endif
|
||||
|
||||
fps_d = GST_VIDEO_INFO_FPS_D (vip);
|
||||
fps_n = GST_VIDEO_INFO_FPS_N (vip);
|
||||
|
@ -826,7 +813,6 @@ gst_vaapi_encoder_reconfigure_internal (GstVaapiEncoder * encoder)
|
|||
if (!gst_vaapi_encoder_ensure_context (encoder))
|
||||
goto error_reset_context;
|
||||
|
||||
#if VA_CHECK_VERSION(0,36,0)
|
||||
if (get_config_attribute (encoder, VAConfigAttribEncQualityRange,
|
||||
&quality_level_max) && quality_level_max > 0) {
|
||||
GST_VAAPI_ENCODER_QUALITY_LEVEL (encoder) =
|
||||
|
@ -836,7 +822,6 @@ gst_vaapi_encoder_reconfigure_internal (GstVaapiEncoder * encoder)
|
|||
}
|
||||
GST_INFO ("Quality level is fixed to %d",
|
||||
GST_VAAPI_ENCODER_QUALITY_LEVEL (encoder));
|
||||
#endif
|
||||
|
||||
if (encoder->trellis) {
|
||||
#if VA_CHECK_VERSION(1,0,0)
|
||||
|
|
Loading…
Reference in a new issue