MEncoder

„MEncoder is a free command line video decoding, encoding and filtering tool released under the GNU General Public License. It is a close sibling to MPlayer and can convert all the formats that MPlayer understands into a variety of compressed and uncompressed formats using different codecs.“

MEncoder. (2008, February 23). In Wikipedia, The Free Encyclopedia. Retrieved 18:57, April 5, 2008, from
http://en.wikipedia.org/w/index.php?title=MEncoder&oldid=193447614


My Blog List

Monday, April 14, 2008

Re: [MEncoder-users] B Frames and mp4

Alex Samad wrote:
> There has been a lot of talk about Bframes (and one other type that
> escapes me right now), how can I tell from a .mp4 file weather there are
> B Frames being used, something like mplayer -v <file> ?

As far as I understand, it's possible for a video stream to have
B-frames enabled (low_delay=0) but not actually have any B-frames
present. The only sure way is to scan the entire file; however, in most
sane cases, B-frames will be present near the beginning or not at all,
so feel free to add '-frames 100' or something to the following command:

mplayer <some_file> -nosound -vo null -benchmark -v -lavdopts debug=1 \
2>/dev/null

This will print out lines beginning with:
[h264 @ 0x101c480]slice:1 F mb:0 B pps:0 frame:6 poc:18/18 ref:5/1...
^ so, this is a B-frame


You can pipe the lines to something to count frames for you. The
following quick-n-dirty perl should work for mplayer's output when
playing MPEG-4 and H.264. Try piping the above command into this:

perl -e 'while(<>) { ++$f{$2} if /\[(h264|mpeg4).*?([PIB])/ }'\
' print "I-frames: $f{I}\nP-frames: $f{P}\nB-frames: $f{B}\n"'


-Corey
_______________________________________________
MEncoder-users mailing list
MEncoder-users@mplayerhq.hu
https://lists.mplayerhq.hu/mailman/listinfo/mencoder-users

No comments:

PCBs

Links

Forex brokers, Forex online


Privacy Policy