[FFmpeg-user] Where is the Stream's Bitrate on some formats?

Aurélio A. Heckert aurium at gmail.com
Sat Jul 2 04:57:19 CEST 2011


Hi all,

I need to convert videos to the web in OGV, respecting the
original bitrate (quality) and may writing lightweight versions
with minor dimension and lower bitrate (for video and audio).

Well with "ffmpeg -i file" i can get some important information,
the video dimension, the frame rate, but not the bitrate for all
formats. Only the global file bitrate is always shown.

There is some examples:

$ ffmpeg -i firebus.3gp
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'firebus.3gp':
  Duration: 00:02:29.80, start: 0.000000, bitrate: 279 kb/s
    Stream #0.0(eng): Video: mpeg4, yuv420p, 128x96 [PAR 1:1 DAR 4:3],
265 kb/s, 15.01 fps, 15 tbr, 15 tbn, 15 tbc
    Stream #0.1(eng): Audio: amrnb, 8000 Hz, 1 channels, flt, 12 kb/s

$ ffmpeg -i atropelamento.ogv
Input #0, ogg, from 'atropelamento.ogv':
  Duration: 00:00:05.00, start: 0.000000, bitrate: 334 kb/s
    Stream #0.0: Video: theora, yuv420p, 208x130 [PAR 1:1 DAR 8:5], 24
fps, 24 tbr, 24 tbn, 24 tbc
    Stream #0.1: Audio: flac, 44100 Hz, 2 channels, s16

$ ffmpeg -i Animals.AVI
Input #0, avi, from 'Animals.AVI':
  Duration: 01:27:51.00, start: 0.000000, bitrate: 924 kb/s
    Stream #0.0: Video: mpeg4, yuv420p, 608x352 [PAR 1:1 DAR 19:11],
25 tbr, 25 tbn, 25 tbc
    Stream #0.1: Audio: mp3, 48000 Hz, 2 channels, s16, 128 kb/s

I'm using FFmpeg version 0.6.2 from this package:
http://packages.debian.org/wheezy/ffmpeg

I also try to use the FFruby, based on the libav, but this also fails
to response the bitrate
for the "atropelamento.ogv" streams and for the "Animals.AVI" video stream.

That is a FFmpeg bug or there is some way to get the stream bitrate always?

Bonus question: I also have no FPS for the Animals.AVI's video stream.
Reading this http://forums.creativecow.net/thread/291/140 i believe i can
trust my life to the TBR, but that is true? If yes, FFmpeg does not asume
the admit the TBR value to the FPS and stop the confusion?

Thanks,
 Aurium

-- 
Aurélio A. Heckert  http://SoftwareLivre.org/aurium
Coop. de Tecnologias Livres: http://Colivre.coop.br
     - - - - - - - - - - - - - - - - - - - - - - - - -
GNU/Linux User #312507  http://counter.li.org
Ilustração Vetorial Livre: http://InkscapeBrasil.org
     - - - - - - - - - - - - - - - - - - - - - - - - -
  "Windows 7: a new era of restrictions."
   http://windows7sins.org

   Antes de imprimir esta mensagem reflita
   sobre a sua responsabilidade com a
   preservação do Meio Ambiente.


More information about the ffmpeg-user mailing list