> From: Andrew Rowley [mailto:[email protected]] 
> Sent: 21 June 2010 09:32
> To: 'FFmpeg Users (libav)'
> Subject: Video Bitrate settings
>
> Hi,
>
> I have been playing about with the video bit rate settings both using the 
> command line ffmpeg and through the > bit_rate field in the AVCodecContext.  
> When  using the command line, I can change the bit rate, and the file > size 
> seems to change (although the overall output bit rate seems to be much less 
> than I specify).  When I use > AVCodecContext, the bit_rate seems to be 
> ignored completely. 
>
>I am using the msmpeg4 codec, although even with the mpeg4, the results are 
>similar - the bit rate specified >on the command line works, although with 
>less bits than expected, and the AVCodecContext bit_rate is ignored.
>
> So my questions are:
>
>1) Why doesn't the final file bit rate come close to the video bit rate 
>specified (i.e. out by 1000 at least)?
>
>2) What do I need to do to make Libav take account of the AVCodecContext 
>bit_rate parameter (i.e. are there >any flags I need to add)?
>
>Thanks,
>
>Andrew :)

To answer my own question 2, you need to make sure that the AVCodecContext 
time_rate is set to the right value i.e. the correct frame rate for your 
stream.  Otherwise I guess the codec doesn't really know how long each frame is 
and so can't work out the correct bit rate.

Andrew :)

_______________________________________________
libav-user mailing list
[email protected]
https://lists.mplayerhq.hu/mailman/listinfo/libav-user

Reply via email to