Skip to content

Commit

Permalink
Use ull/cbr profile for nvenc in low latency mode.
Browse files Browse the repository at this point in the history
  • Loading branch information
Themaister committed Nov 6, 2023
1 parent 492563c commit bcb9e5a
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions video/ffmpeg_encode.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1023,7 +1023,11 @@ bool VideoEncoder::Impl::init_video_codec()
// Codec delay. We want blocking realtime.
av_dict_set_int(&opts, "delay", 0, 0);
if (options.low_latency)
{
av_dict_set_int(&opts, "zerolatency", 1, 0);
av_dict_set(&opts, "tune", "ull", 0);
av_dict_set(&opts, "rc", "cbr", 0);
}
}

if ((is_x264 || is_nvenc) && options.low_latency)
Expand Down

0 comments on commit bcb9e5a

Please sign in to comment.