]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
FS-9106 #resolve [vpx performance tweaks]
authorAnthony Minessale <anthm@freeswitch.org>
Wed, 27 Apr 2016 04:05:08 +0000 (23:05 -0500)
committerAnthony Minessale <anthm@freeswitch.org>
Wed, 27 Apr 2016 04:05:14 +0000 (23:05 -0500)
src/mod/applications/mod_conference/conference_video.c
src/switch_vpx.c

index 998486400e252bda7f81dd76b1b39c15d246b736..01f87a8ac7573be03676994e5fc11eaf8ec1e3fd 100644 (file)
@@ -1514,7 +1514,7 @@ void *SWITCH_THREAD_FUNC conference_video_muxing_write_thread_run(switch_thread_
                return NULL;
        }
 
-       switch_core_autobind_cpu();
+       //switch_core_autobind_cpu();
 
        while(conference_utils_member_test_flag(member, MFLAG_RUNNING)) {
                if (switch_queue_pop(member->mux_out_queue, &pop) == SWITCH_STATUS_SUCCESS) {
index f195eab30089dcde3639497fc55cf71a290fc722..6ad449f14ecaffc30253140ffcefb7e616662482 100644 (file)
@@ -403,8 +403,8 @@ static switch_status_t init_encoder(switch_codec_t *codec)
        config->g_h = context->codec_settings.video.height;     
        config->rc_target_bitrate = context->bandwidth;
        config->g_lag_in_frames = 0;
-       config->kf_max_dist = 2000;
-       config->g_threads = 1;//(cpus > 1) ? 2 : 1;
+       config->kf_max_dist = 360;//2000;
+       config->g_threads = cpus - 1;//(cpus > 1) ? 2 : 1;
        
        if (context->is_vp9) {
                //config->rc_dropframe_thresh = 2;
@@ -435,7 +435,7 @@ static switch_status_t init_encoder(switch_codec_t *codec)
                config->rc_end_usage = VPX_CBR;
                //config->g_pass = VPX_RC_ONE_PASS;
                config->kf_mode = VPX_KF_AUTO;
-               config->kf_max_dist = 1000;
+               config->kf_max_dist = 360;//1000;
 
                //config->kf_mode = VPX_KF_DISABLED;
                config->rc_resize_allowed = 1;
@@ -545,7 +545,7 @@ static switch_status_t init_encoder(switch_codec_t *codec)
                                vpx_codec_control(&context->encoder, VP8E_SET_CPUUSED, -8);
                        }
 
-                       vpx_codec_control(&context->encoder, VP8E_SET_STATIC_THRESHOLD, 100);
+                       vpx_codec_control(&context->encoder, VP8E_SET_STATIC_THRESHOLD, 1000);
                        vpx_codec_control(&context->encoder, VP8E_SET_TOKEN_PARTITIONS, token_parts);
                        vpx_codec_control(&context->encoder, VP9E_SET_TUNE_CONTENT, VP9E_CONTENT_SCREEN);