mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-02-23 06:26:23 +00:00
x265enc: Fix tune parameter mismatch
There was a mismatch between the tune parameter in x265 and the enum used in this element. The value in the enum is the x265 tune parameter + 1.
This commit is contained in:
parent
8bacecfb08
commit
db766de135
1 changed files with 2 additions and 2 deletions
|
@ -616,7 +616,7 @@ gst_x265_enc_init_encoder (GstX265Enc * encoder)
|
|||
|
||||
if (x265_param_default_preset (&encoder->x265param,
|
||||
x265_preset_names[encoder->speed_preset - 1],
|
||||
x265_tune_names[encoder->tune]) < 0) {
|
||||
x265_tune_names[encoder->tune - 1]) < 0) {
|
||||
GST_DEBUG_OBJECT (encoder, "preset or tune unrecognized");
|
||||
GST_OBJECT_UNLOCK (encoder);
|
||||
return FALSE;
|
||||
|
@ -858,7 +858,7 @@ gst_x265_enc_set_latency (GstX265Enc * encoder)
|
|||
|
||||
/* FIXME get a real value from the encoder, this is currently not exposed */
|
||||
if (encoder->tune > 0 && encoder->tune <= G_N_ELEMENTS (x265_tune_names) &&
|
||||
strcmp (x265_tune_names[encoder->tune + 1], "zerolatency") == 0)
|
||||
strcmp (x265_tune_names[encoder->tune - 1], "zerolatency") == 0)
|
||||
max_delayed_frames = 0;
|
||||
else
|
||||
max_delayed_frames = 5;
|
||||
|
|
Loading…
Reference in a new issue