]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
FS-11189 set default cpu string to cpu/2/4 if not configured
authorSeven Du <dujinfang@x-y-t.cn>
Fri, 24 Aug 2018 03:25:26 +0000 (11:25 +0800)
committerSeven Du <dujinfang@x-y-t.cn>
Fri, 24 Aug 2018 03:25:26 +0000 (11:25 +0800)
src/mod/applications/mod_av/avcodec.c

index cd0ec1c51267ec7b0686c74f988d517b2eb37e62..9f45982781b3308c1a2053de6bd78c413bebc305 100644 (file)
@@ -1858,6 +1858,8 @@ static void load_config()
                profile->ctx.qmin = -1;
                profile->ctx.qmax = -1;
                profile->ctx.max_qdiff = -1;
+               profile->ctx.thread_count = switch_parse_cpu_string("cpu/2/4");
+               profile->decoder_thread_count = switch_parse_cpu_string("cpu/2/4");
 
                if (!strcasecmp(CODEC_MAPS[i], "H264")) {
                        profile->ctx.profile = FF_PROFILE_H264_BASELINE;