[FFmpeg-devel] The quantization parameter QP (s-> qscale) in FFmpeg-"mpeg4videodec.c"-

Michael Niedermayer michaelni at gmx.at
Fri Aug 3 16:50:32 CEST 2012

On Wed, Aug 01, 2012 at 03:51:22PM +0100, Moad Toutou wrote:
> Hello,
> I'm still looking for my quantization parameter QP. I located a set of files that manipulates this variable QP:
> 1-/ffmpeg/libavcodec/cavsdec.c
> 2-/ffmpeg/libavcodec/bink.c
> 3-/ffmpeg/libavcodec/libx264.c
> 4-/libavcodec/proresenc_anatoliy.c
> 5-/ffmpeg/libavcodec/mpeg4videodec.c
> The file that interests me most is "mpeg4videodec.c" because I'm more interested in MPEG video decoding.
> For me, the value of qp in the file "mpeg4videodec.c" equal to "s-> qscale".

> My first question: is "qp" equals "s-> qscale"?

mostly yes

> I brought a  modéfications to the file "mpeg4videodec.c" and my second question is:  what is the ffmpeg command for which, the execution of this command, the program will go through by the file instructions "mpeg4 video dec.c"?

it will when decoding a mpeg4 video

> This is the kind of instructions that i added in the file "mpeg4videodec.c" :
> -av_log(s->avctx, AV_LOG_DEBUG, "the value of qp is %d", s->qscale);
> -av_log(s->avctx, AV_LOG_ERROR, "the value of qp is %d", s->qscale);
> -av_log(s->avctx, AV_LOG_INFO, "the value of qp is %d", s->qscale);
> -av_log(s->avctx, AV_LOG_INFO, "the value of qp is %d", s->qscale);

> Finally, in what place, i'm going to get the results ? (in the consol or in the log files?

this depends on the used log callback, see how av_log() is implemented
if it interrests you. see the header where av_log is declared for a
documentation of its API


Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

While the State exists there can be no freedom; when there is freedom there
will be no State. -- Vladimir Lenin
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20120803/04fa3ccd/attachment.asc>

More information about the ffmpeg-devel mailing list