Commit a58118b8 authored by John Stebbins's avatar John Stebbins

encavcodec: fix chapter mark postion for nvenc encodes

"forced-idr" was only getting set for constant quality encodes.

fixes https://github.com/HandBrake/HandBrake/issues/2269
parent 744cab1a
......@@ -372,10 +372,6 @@ int encavcodecInit( hb_work_object_t * w, hb_job_t * job )
av_dict_set( &av_opts, "init_qpB", qualityB, 0 );
av_dict_set( &av_opts, "init_qpI", qualityI, 0 );
hb_log( "encavcodec: encoding at rc=vbr %.2f", job->vquality );
// Force IDR frames when we force a new keyframe for chapters
av_dict_set( &av_opts, "forced-idr", "1", 0 );
}
else if ( job->vcodec == HB_VCODEC_FFMPEG_VCE_H264 || job->vcodec == HB_VCODEC_FFMPEG_VCE_H265 )
{
......@@ -537,8 +533,12 @@ int encavcodecInit( hb_work_object_t * w, hb_job_t * job )
//context->tier = FF_TIER_UNKNOWN;
}
if ( job->vcodec == HB_VCODEC_FFMPEG_NVENC_H264 || job->vcodec == HB_VCODEC_FFMPEG_NVENC_H265 )
if (job->vcodec == HB_VCODEC_FFMPEG_NVENC_H264 ||
job->vcodec == HB_VCODEC_FFMPEG_NVENC_H265)
{
// Force IDR frames when we force a new keyframe for chapters
av_dict_set( &av_opts, "forced-idr", "1", 0 );
// Set profile and level
if (job->encoder_profile != NULL && *job->encoder_profile)
{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment