mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-04-26 06:54:49 +00:00
nvenc: Remove unused member variables
Supported interlace-mode and codec profiles are checked during plugin init and those values are never used.
This commit is contained in:
parent
eba4e7e989
commit
b43d0f785c
5 changed files with 0 additions and 64 deletions
|
@ -97,10 +97,6 @@ typedef struct {
|
||||||
* while we wait */
|
* while we wait */
|
||||||
GThread *bitstream_thread;
|
GThread *bitstream_thread;
|
||||||
|
|
||||||
/* supported interlacing input modes.
|
|
||||||
* 0 = none, 1 = fields, 2 = interleaved */
|
|
||||||
gint interlace_modes;
|
|
||||||
|
|
||||||
void *display; /* GstGLDisplay */
|
void *display; /* GstGLDisplay */
|
||||||
void *other_context; /* GstGLContext */
|
void *other_context; /* GstGLContext */
|
||||||
|
|
||||||
|
|
|
@ -93,7 +93,6 @@ gst_nv_h264_enc_finalize (GObject * obj)
|
||||||
static gboolean
|
static gboolean
|
||||||
gst_nv_h264_enc_open (GstVideoEncoder * enc)
|
gst_nv_h264_enc_open (GstVideoEncoder * enc)
|
||||||
{
|
{
|
||||||
GstNvH264Enc *nvenc = GST_NV_H264_ENC (enc);
|
|
||||||
GstNvBaseEnc *base = GST_NV_BASE_ENC (enc);
|
GstNvBaseEnc *base = GST_NV_BASE_ENC (enc);
|
||||||
|
|
||||||
if (!GST_VIDEO_ENCODER_CLASS (gst_nv_h264_enc_parent_class)->open (enc))
|
if (!GST_VIDEO_ENCODER_CLASS (gst_nv_h264_enc_parent_class)->open (enc))
|
||||||
|
@ -117,31 +116,12 @@ gst_nv_h264_enc_open (GstVideoEncoder * enc)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* query supported input formats */
|
|
||||||
nvenc->supported_profiles =
|
|
||||||
gst_nv_enc_get_supported_codec_profiles (base->encoder,
|
|
||||||
NV_ENC_CODEC_H264_GUID);
|
|
||||||
if (!nvenc->supported_profiles) {
|
|
||||||
GST_WARNING_OBJECT (nvenc, "No supported encoding profiles");
|
|
||||||
gst_nv_h264_enc_close (enc);
|
|
||||||
return FALSE;
|
|
||||||
}
|
|
||||||
|
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
static gboolean
|
static gboolean
|
||||||
gst_nv_h264_enc_close (GstVideoEncoder * enc)
|
gst_nv_h264_enc_close (GstVideoEncoder * enc)
|
||||||
{
|
{
|
||||||
GstNvH264Enc *nvenc = GST_NV_H264_ENC (enc);
|
|
||||||
|
|
||||||
GST_OBJECT_LOCK (nvenc);
|
|
||||||
if (nvenc->supported_profiles)
|
|
||||||
g_value_unset (nvenc->supported_profiles);
|
|
||||||
g_free (nvenc->supported_profiles);
|
|
||||||
nvenc->supported_profiles = NULL;
|
|
||||||
GST_OBJECT_UNLOCK (nvenc);
|
|
||||||
|
|
||||||
return GST_VIDEO_ENCODER_CLASS (gst_nv_h264_enc_parent_class)->close (enc);
|
return GST_VIDEO_ENCODER_CLASS (gst_nv_h264_enc_parent_class)->close (enc);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -37,16 +37,6 @@
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
GstNvBaseEnc base_nvenc;
|
GstNvBaseEnc base_nvenc;
|
||||||
|
|
||||||
/* the supported input formats */
|
|
||||||
GValue * supported_profiles; /* OBJECT LOCK */
|
|
||||||
|
|
||||||
GstVideoCodecState *input_state;
|
|
||||||
gboolean gl_input;
|
|
||||||
|
|
||||||
/* supported interlacing input modes.
|
|
||||||
* 0 = none, 1 = fields, 2 = interleaved */
|
|
||||||
gint interlace_modes;
|
|
||||||
} GstNvH264Enc;
|
} GstNvH264Enc;
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
|
|
|
@ -94,7 +94,6 @@ gst_nv_h265_enc_finalize (GObject * obj)
|
||||||
static gboolean
|
static gboolean
|
||||||
gst_nv_h265_enc_open (GstVideoEncoder * enc)
|
gst_nv_h265_enc_open (GstVideoEncoder * enc)
|
||||||
{
|
{
|
||||||
GstNvH265Enc *nvenc = GST_NV_H265_ENC (enc);
|
|
||||||
GstNvBaseEnc *base = GST_NV_BASE_ENC (enc);
|
GstNvBaseEnc *base = GST_NV_BASE_ENC (enc);
|
||||||
|
|
||||||
if (!GST_VIDEO_ENCODER_CLASS (gst_nv_h265_enc_parent_class)->open (enc))
|
if (!GST_VIDEO_ENCODER_CLASS (gst_nv_h265_enc_parent_class)->open (enc))
|
||||||
|
@ -118,31 +117,12 @@ gst_nv_h265_enc_open (GstVideoEncoder * enc)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* query supported input formats */
|
|
||||||
nvenc->supported_profiles =
|
|
||||||
gst_nv_enc_get_supported_codec_profiles (base->encoder,
|
|
||||||
NV_ENC_CODEC_HEVC_GUID);
|
|
||||||
if (!nvenc->supported_profiles) {
|
|
||||||
GST_WARNING_OBJECT (nvenc, "No supported encoding profiles");
|
|
||||||
gst_nv_h265_enc_close (enc);
|
|
||||||
return FALSE;
|
|
||||||
}
|
|
||||||
|
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
static gboolean
|
static gboolean
|
||||||
gst_nv_h265_enc_close (GstVideoEncoder * enc)
|
gst_nv_h265_enc_close (GstVideoEncoder * enc)
|
||||||
{
|
{
|
||||||
GstNvH265Enc *nvenc = GST_NV_H265_ENC (enc);
|
|
||||||
|
|
||||||
GST_OBJECT_LOCK (nvenc);
|
|
||||||
if (nvenc->supported_profiles)
|
|
||||||
g_value_unset (nvenc->supported_profiles);
|
|
||||||
g_free (nvenc->supported_profiles);
|
|
||||||
nvenc->supported_profiles = NULL;
|
|
||||||
GST_OBJECT_UNLOCK (nvenc);
|
|
||||||
|
|
||||||
return GST_VIDEO_ENCODER_CLASS (gst_nv_h265_enc_parent_class)->close (enc);
|
return GST_VIDEO_ENCODER_CLASS (gst_nv_h265_enc_parent_class)->close (enc);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -38,16 +38,6 @@
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
GstNvBaseEnc base_nvenc;
|
GstNvBaseEnc base_nvenc;
|
||||||
|
|
||||||
/* the supported input formats */
|
|
||||||
GValue * supported_profiles; /* OBJECT LOCK */
|
|
||||||
|
|
||||||
GstVideoCodecState *input_state;
|
|
||||||
gboolean gl_input;
|
|
||||||
|
|
||||||
/* supported interlacing input modes.
|
|
||||||
* 0 = none, 1 = fields, 2 = interleaved */
|
|
||||||
gint interlace_modes;
|
|
||||||
} GstNvH265Enc;
|
} GstNvH265Enc;
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
|
|
Loading…
Reference in a new issue