From e83983d7ca318535379c7bfd2281a8cd5d736981 Mon Sep 17 00:00:00 2001 From: =?utf8?q?V=C3=ADctor=20Manuel=20J=C3=A1quez=20Leal?= Date: Fri, 27 May 2022 14:45:51 +0200 Subject: [PATCH] va: encoder: Fix regression since commit 2042c2d4f0. There's no need to compare with the open entrypoint to query the encoder. This commit removes the checks to the configured entrypoint with the parameter. Part-of: --- subprojects/gst-plugins-bad/sys/va/gstvaencoder.c | 21 --------------------- 1 file changed, 21 deletions(-) diff --git a/subprojects/gst-plugins-bad/sys/va/gstvaencoder.c b/subprojects/gst-plugins-bad/sys/va/gstvaencoder.c index 8062c6f..fa08754 100644 --- a/subprojects/gst-plugins-bad/sys/va/gstvaencoder.c +++ b/subprojects/gst-plugins-bad/sys/va/gstvaencoder.c @@ -586,9 +586,6 @@ gst_va_encoder_get_max_slice_num (GstVaEncoder * self, if (profile == VAProfileNone) return -1; - if (entrypoint != self->entrypoint) - return -1; - dpy = gst_va_display_get_va_dpy (self->display); status = vaGetConfigAttributes (dpy, profile, entrypoint, &attrib, 1); if (status != VA_STATUS_SUCCESS) { @@ -620,9 +617,6 @@ gst_va_encoder_get_max_num_reference (GstVaEncoder * self, if (profile == VAProfileNone) return FALSE; - if (entrypoint != self->entrypoint) - return FALSE; - dpy = gst_va_display_get_va_dpy (self->display); status = vaGetConfigAttributes (dpy, profile, entrypoint, &attrib, 1); if (status != VA_STATUS_SUCCESS) { @@ -661,9 +655,6 @@ gst_va_encoder_get_rate_control_mode (GstVaEncoder * self, if (profile == VAProfileNone) return 0; - if (entrypoint != self->entrypoint) - return 0; - dpy = gst_va_display_get_va_dpy (self->display); status = vaGetConfigAttributes (dpy, profile, entrypoint, &attrib, 1); if (status != VA_STATUS_SUCCESS) { @@ -693,9 +684,6 @@ gst_va_encoder_get_quality_level (GstVaEncoder * self, if (profile == VAProfileNone) return 0; - if (entrypoint != self->entrypoint) - return 0; - dpy = gst_va_display_get_va_dpy (self->display); status = vaGetConfigAttributes (dpy, profile, entrypoint, &attrib, 1); if (status != VA_STATUS_SUCCESS) { @@ -725,9 +713,6 @@ gst_va_encoder_has_trellis (GstVaEncoder * self, if (profile == VAProfileNone) return FALSE; - if (entrypoint != self->entrypoint) - return FALSE; - dpy = gst_va_display_get_va_dpy (self->display); status = vaGetConfigAttributes (dpy, profile, entrypoint, &attrib, 1); if (status != VA_STATUS_SUCCESS) { @@ -755,9 +740,6 @@ gst_va_encoder_get_rtformat (GstVaEncoder * self, if (profile == VAProfileNone) return 0; - if (entrypoint != self->entrypoint) - return 0; - dpy = gst_va_display_get_va_dpy (self->display); status = vaGetConfigAttributes (dpy, profile, entrypoint, &attrib, 1); if (status != VA_STATUS_SUCCESS) { @@ -785,9 +767,6 @@ gst_va_encoder_get_packed_headers (GstVaEncoder * self, VAProfile profile, if (profile == VAProfileNone) return 0; - if (entrypoint != self->entrypoint) - return 0; - dpy = gst_va_display_get_va_dpy (self->display); status = vaGetConfigAttributes (dpy, profile, entrypoint, &attrib, 1); if (status != VA_STATUS_SUCCESS) { -- 2.7.4