[Bf-committers] Updating Colour Configurations

Sergey Sharybin sergey.vfx at gmail.com
Wed Nov 11 10:21:18 CET 2015


For the majority of Blender it's already possible to use whatever linear
space you want. It should work rather fine in areas like compositor.

For the rendering i don't know if it really makes sense to make core
working in XYZ space. I had a WIP patch which witched Cycles to a wider
gamut RGB space which solved issues caused by color saturation. Some other
render engines aren't using XYZ either because difference between XYZ and
wider gamut RGB is quite negotiable. So using wider gamut internally and
converting to whatever-scene-linear is after rendering should work rather
fine i think.

As for OCIO conversion on GPU -- it's possible to use same baking API as
for GLSL and then interpolate baked LUTs from the CUDA/OpenCL kernels.



On Wed, Nov 11, 2015 at 7:42 AM, Brecht Van Lommel <
brechtvanlommel at pandora.be> wrote:

> After talking to Troy I now understand the idea better. So basically
> we want the scene_linear color space (the working space for rendering)
> to be fully defined and configurable. Currently it is hardcoded to
> Rec.709 RGB, but we want to support color spaces with a wider gamut
> covering more colors of the visible spectrum. We can do that by
> ensuring the OCIO configuration has an XYZ color space and a
> transformation from the XYZ color space to the scene_linear color
> space.
>
> Then for example if we do XYZ to scene linear RGB conversion in the
> Cycles Sky texture, we use that OCIO transformation instead of the
> hardcoded XYZ to Rec.709 RGB conversion that we have now.
>
> However, OCIO can't be called from the GPU, so we need to implement
> that transformation ourselves in the Cycles kernel. Luckily, if the
> scene_linear color space is indeed radiometrically linear, then the
> transformation to/from XYZ must be a linear transformation, which is
> just a 3x3 matrix. The columns of that matrix can be extracted from
> OCIO by transforming the colors (1, 0, 0), (0, 1, 0), (0, 0, 1). This
> 3x3 matrix can be easily copied to and used on the GPU.
>
> On Wed, Nov 11, 2015 at 12:16 AM, Troy Sobotka <troy.sobotka at gmail.com>
> wrote:
> > On Nov 10, 2015 2:47 PM, "Brecht Van Lommel" <brechtvanlommel at pandora.be
> >
> > wrote:
> >>
> >> I doubt GPU rendering is a problem, but I have no idea what the word
> >> "role" means in this context and what "implementing an XYZ role"
> >> means.
> >
> > A role is simply a known alias that software can hunt for via OCIO. So
> for
> > example, if you have to convert colour temperature via a Bradford etc.
> > transform and require the space's XYZ primaries and white point, you
> could
> > request the “XYZ” role. It is provided for grabbing “Grading” or “UI”
> > transforms etc.
> >
> > With respect,
> > TJS
> > _______________________________________________
> > Bf-committers mailing list
> > Bf-committers at blender.org
> > http://lists.blender.org/mailman/listinfo/bf-committers
> _______________________________________________
> Bf-committers mailing list
> Bf-committers at blender.org
> http://lists.blender.org/mailman/listinfo/bf-committers
>



-- 
With best regards, Sergey Sharybin


More information about the Bf-committers mailing list