[Libav-user] Write raw RGB frames to file

Max Göttner - d.stream max.goettner at dstream.de
Wed Nov 23 11:54:20 CET 2011


So this means, I shall simply set the encoders AVCodecCtx.pix_fmt to e.g.
PIX_FMT_BGR24? Unfortunately I don’t have any clue how to set codec relevant
parameters and I only get 5kbyte files with no videodata. I could find
examples for encoding to various mpeg codecs and h264 but nothing about
rawvideo.

Is there any reference or example that tells me, which attributes of the
AVCodecCtx have to be set in order to get the rawvideo-encoding work?
Maybe this seems too obvious for any advanced libav coder, but I have been
searching quite a long time, and a trial-and-error approach seems very
unconvenient for the dozens of parameters.


>Why do you think so?
>I believe that for the sake of your question it supports "all" pix_fmts.
>(It does not support all but all relevant ones.)





More information about the Libav-user mailing list