[MPlayer-dev-eng] [PATCH] CQMs in x264

Guillaume POIRIER poirierg at gmail.com
Wed Jul 27 11:05:24 CEST 2005


Hi,

On 7/27/05, Robert Swain <robert.swain at gmail.com> wrote:

> > You're not forcing a linebreak here, you need to pad one more character.
> >
> > > +.B cqm4iy=<list>
> > > +Custom 4x4 intra luminance matrix. A list of 16 comma separated values.
> >
> > Capitalization is funky here, try
> >
> >   custom 4x4 intra luminance matrix (list of 16 comma separated values)
> 
> Guillaume helped with these issues already, so please see what you
> think of the docs in this patch.
> 
> > What those values are is still a mystery.
> 
> They are values between 1 and 255. The coefficients of these matrices
> are used for the quantisation stage of h.264 encoding. I guess if you
> don't know what that is or don't use h.264 codecs then it won't really
> matter if you don't know. :) They're exactly the same concept as
> custom quantisation matrices for MPEG-4 ASP (XviD, etc) codecs.

Maybe it'd be great to tell what is the expected range of the values.
Would that be okay?

Custom 4x4 intra luminance matrix, given as a list of 16 comma separated
values ranging from 1 to 255.

That could be added later anyhow.


> > Whoever came up with these cleverly inconsistent option names (i vs y vs
> > p) should enter some sort of obfuscation contest...
> 
> It's perfectly consistent. Breaking it down into sections:
> 1) cqm - means custom quantisation matrix
> 2) 4 or 8 - mean the matrix is either 4x4 or 8x8 respectively, hence
> 16 or 64 values are required
> 3) i or p - mean the matrix is intended for intra or inter blocks respectively.
> 4) y or c - mean the matrix is intended for luminance or chrominance
> blocks respectively. That is Y, or U/V. x264 uses the same matrix for
> both U and V as far as I can see but it is possible in the
> specification to use two different matrices. Also note that for the
> 8x8 matrix size there are no chrominance matrices. This is because of
> the h.264 high profile specification.
> 
> > > +.RE
> > > +.I NOTES:
> >
> > .RE ends, not starts, first level suboptions.
> 
> Well this is what I read:
> 
> ".RE [nnn]
>         This macro moves the left margin back to level nnn; if no argument
> is given, it moves one level back. The first level (i.e., no call to
> RS yet) has number 1, and each call to RS increases the level by 1."
> 
> I wanted it to move back one level such that the notes apply to the
> lists and the cqm=blah stuff.

I did not test it, but I think that you should replace the ".RE"
pointed out by Diego by ".RSs". I just had a look at how it was done
in other paragraphs of the man page.


> To everyone: I'm sure revision 9 was working on all fronts
> implementation-wise, with valid arguments given. However, I haven't
> changed anything significant between then and now with regard to the
> cqm=blah code and yet it no longer works. Can you see anything in
> lines 131-157 of the attached patch to suggest why cqm=flat / cqm=jvt
> / cqm=matrix.cfg should cause mencoder to crash?

no idea :-(

Guillaume
-- 
I feel sorry for people who don't drink.
When they wake up in the morning, that's
as good as they're going to feel all day.
 -- Frank Sinatra




More information about the MPlayer-dev-eng mailing list