[theora] YCbCr <-> RGB conversion question

Ralph Giles giles at xiph.org
Tue Jun 16 16:26:17 PDT 2009

On Tue, Jun 16, 2009 at 6:43 AM, Ondrej Certik<ondrej at certik.cz> wrote:

> Right, I also think it's impossible, because when you have an image in
> RGB and convert to YCbCr, one gets floating point numbers, and once I
> round it, I am already loosing precision.

Yes. 8-bit to 8-bit colour space conversions always lose some
significant precision, unless the transform is specifically designed
to be reversible. And if it is, generally it doesn't do as good a job
separating energy. JPEG 2000 has such a transform for lossless
support, but in practice people seem to just compress such images
directly in RGB.

Even more exciting, I don't believe the transforms to and from
theora's defined colour spaces can be completely described by ICC
profiles. So all the work being done to get colour correction
implemented by the GPU through the compositing manager *still* won't
give us perfectly calibrated video. (It will be better than what we
have now though!)


More information about the theora mailing list