mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-27 04:01:08 +00:00
vp8enc/vp8enc: set 1 for the default value of VP8E_SET_STATIC_THRESHOLD
In Google webrtc, the setting VP8E_SET_STATIC_THRESHOLD is set to 1
(except when the content is known to be static very often in which
case it is set to 100, i.e. when sharing screen with Google Hangouts).
The cpu usage drops a lot when using 1 for above setting because it
allows the encoder to skip static/low content blocks. The current
0 default value uses too much cpu and confuses the user regarding
the cpu usage expectations. User expects vp8enc to use low cpu by
default.
Documentation of VP8E_SET_STATIC_THRESHOLD:
https://github.com/webmproject/libvpx/blob/master/vpx/vp8cx.h#L188
chromium/webrtc:
b484ec0082/modules/video_coding/codecs/vp8/libvpx_vp8_encoder.cc (822)
Closes #58
This commit is contained in:
parent
83e9d4f70d
commit
88ce7397fc
1 changed files with 6 additions and 3 deletions
|
@ -88,7 +88,10 @@ GST_DEBUG_CATEGORY_STATIC (gst_vpxenc_debug);
|
|||
#define DEFAULT_DEADLINE VPX_DL_BEST_QUALITY
|
||||
#define DEFAULT_NOISE_SENSITIVITY 0
|
||||
#define DEFAULT_SHARPNESS 0
|
||||
#define DEFAULT_STATIC_THRESHOLD 0
|
||||
|
||||
/* Use same default value as Chromium/webrtc. */
|
||||
#define DEFAULT_STATIC_THRESHOLD 1
|
||||
|
||||
#define DEFAULT_TOKEN_PARTITIONS 0
|
||||
#define DEFAULT_ARNR_MAXFRAMES 0
|
||||
#define DEFAULT_ARNR_STRENGTH 3
|
||||
|
@ -582,8 +585,8 @@ gst_vpx_enc_class_init (GstVPXEncClass * klass)
|
|||
|
||||
g_object_class_install_property (gobject_class, PROP_STATIC_THRESHOLD,
|
||||
g_param_spec_int ("static-threshold", "Static Threshold",
|
||||
"Motion detection threshold",
|
||||
0, G_MAXINT, DEFAULT_STATIC_THRESHOLD,
|
||||
"Motion detection threshold. Recommendation is to set 100 for "
|
||||
"screen/window sharing", 0, G_MAXINT, DEFAULT_STATIC_THRESHOLD,
|
||||
(GParamFlags) (G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS)));
|
||||
|
||||
g_object_class_install_property (gobject_class, PROP_TOKEN_PARTITIONS,
|
||||
|
|
Loading…
Reference in a new issue