mirror of https://git.ffmpeg.org/ffmpeg.git
avcodec/nvenc: Handle minqp-only case in set_vbr
This commit is contained in:
parent
eae4eba9cb
commit
971351b664
|
@ -531,6 +531,14 @@ static av_cold void set_vbr(AVCodecContext *avctx)
|
||||||
rc->maxQP.qpIntra = avctx->qmax;
|
rc->maxQP.qpIntra = avctx->qmax;
|
||||||
|
|
||||||
qp_inter_p = (avctx->qmax + 3 * avctx->qmin) / 4; // biased towards Qmin
|
qp_inter_p = (avctx->qmax + 3 * avctx->qmin) / 4; // biased towards Qmin
|
||||||
|
} else if (avctx->qmin >= 0) {
|
||||||
|
rc->enableMinQP = 1;
|
||||||
|
|
||||||
|
rc->minQP.qpInterB = avctx->qmin;
|
||||||
|
rc->minQP.qpInterP = avctx->qmin;
|
||||||
|
rc->minQP.qpIntra = avctx->qmin;
|
||||||
|
|
||||||
|
qp_inter_p = avctx->qmin;
|
||||||
} else {
|
} else {
|
||||||
qp_inter_p = 26; // default to 26
|
qp_inter_p = 26; // default to 26
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue