[Ffmpeg-devel] moving non-SIMD parts of libswscale to LGPL

Luca Abeni lucabe72
Tue Dec 5 10:23:32 CET 2006


Hi Michael,

On Mon, 2006-12-04 at 13:31 +0100, Michael Niedermayer wrote:
[...]
> 117579*255/76309        = 392.91... = /2 = 196.455...
> 138453*255/76309        = 462.665...= /2 = 231.33...
> (25675+53279)*255/76309 = 263.83... = /2 = 131.91...
> 
> 256 + 2 *232 = y range + max chroma table range
> 
> 393+463+264+256*3 = 1888
> 197 + 2*682 + 256 + 132 = 1949
> so it seems this table is larger then needed ...
> 
> i suggest that you simply check which index in the table the max/min yuv
> values would reach and then use that to allocate the table and set the index
> of each "subtable"
Ok; thanks for the explaination. I'll perform this check, changing the
values to the correct ones and adding comments about them.

[...]
> > Ok. So, if I get it right such tables are either written by you or taken
> > >from a paper by Bayer... Can they be reused in LGPLed code? (I would say
> > yes, because they are by you or from a previous - non GPLed - work. But
> > IANAL, so I am asking :)
> 
> the ones i wrote yes, if there are any i did not write then it depends on
> the tables and their source, use svn-log
>From a quick look at svn history, you added all of these tables. I'll
double check the commit messages later, but it looks like we can use
them as LGPLed

> [...]
> > 3) The values in Inverse_Table_6_9 have been quickly computed based on
> > the tables sent by Michael - I inverted the rgb ---> yuv matrix with
> > octave. I do not know if octave somehow truncated / approximated some
> > results. If needed, I can redo the computation with a higher accuracy
> 
> i suggest you calculate the exact matrix (iam assuming that the values in
> the spec are exact), if octave cant then use pencil and paper or write a
> 1 page program which uses AVRational to do the calculation
> (this of course can be done later after swscale is default ...)
No problem, I'll redo the computation using a better accuracy (but I
suspect the MPEG2 specs provided truncated values).


			Thanks,
				Luca
-- 
_____________________________________________________________________________
Copy this in your signature, if you think it is important:
                               N O    W A R ! ! !





More information about the ffmpeg-devel mailing list