mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-01-13 21:28:01 +02:00
warn user if max=bitrate && max > min
Originally committed as revision 9829 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
parent
611e7bc41b
commit
3dd2a1c53f
@ -342,6 +342,10 @@ int MPV_encode_init(AVCodecContext *avctx)
|
|||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(avctx->rc_max_rate && avctx->rc_max_rate == avctx->bit_rate && avctx->rc_max_rate != avctx->rc_min_rate){
|
||||||
|
av_log(avctx, AV_LOG_INFO, "impossible bitrate constraints, this will fail\n");
|
||||||
|
}
|
||||||
|
|
||||||
if(avctx->rc_buffer_size && avctx->bit_rate*av_q2d(avctx->time_base) > avctx->rc_buffer_size){
|
if(avctx->rc_buffer_size && avctx->bit_rate*av_q2d(avctx->time_base) > avctx->rc_buffer_size){
|
||||||
av_log(avctx, AV_LOG_ERROR, "VBV buffer too small for bitrate\n");
|
av_log(avctx, AV_LOG_ERROR, "VBV buffer too small for bitrate\n");
|
||||||
return -1;
|
return -1;
|
||||||
|
Loading…
Reference in New Issue
Block a user