mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-20 07:16:55 +00:00
openh264: Detect 1.4 API change
As mentionned in release notes : Added new Sps/Pps strategies for real-time video (replace the old setting variable 'bEnableSpsPpsIdAddition' with 'eSpsPpsIdStrategy')
This commit is contained in:
parent
25561db099
commit
29387e85c7
1 changed files with 5 additions and 0 deletions
|
@ -38,6 +38,7 @@
|
|||
#include <wels/codec_api.h>
|
||||
#include <wels/codec_app_def.h>
|
||||
#include <wels/codec_def.h>
|
||||
#include <wels/codec_ver.h>
|
||||
|
||||
#define GST_OPENH264ENC_GET_PRIVATE(obj) \
|
||||
(G_TYPE_INSTANCE_GET_PRIVATE((obj), GST_TYPE_OPENH264ENC, GstOpenh264EncPrivate))
|
||||
|
@ -682,7 +683,11 @@ gst_openh264enc_set_format (GstVideoEncoder * encoder,
|
|||
openh264enc->priv->scene_change_detection;
|
||||
enc_params.bEnableFrameSkip = openh264enc->priv->enable_frame_skip;
|
||||
enc_params.bEnableLongTermReference = 0;
|
||||
#if OPENH264_MINOR >= 4
|
||||
enc_params.eSpsPpsIdStrategy = CONSTANT_ID;
|
||||
#else
|
||||
enc_params.bEnableSpsPpsIdAddition = 1;
|
||||
#endif
|
||||
enc_params.bPrefixNalAddingCtrl = 0;
|
||||
enc_params.fMaxFrameRate = fps_n * 1.0 / fps_d;
|
||||
enc_params.iLoopFilterDisableIdc = openh264enc->priv->deblocking_mode;
|
||||
|
|
Loading…
Reference in a new issue