Vertex colors loose color data

Vertex color data seems to be distorted when used in material nodes, does anybody has similar issues? Looks like Blender modifies them for Cycles somehow. I am using VC not for coloring but for hinting shader about material properties at specific faces and need exact RGB values from Attribute node. This happens with “shade” colors only.

Exact case:

  • When i am using pure colors in vertex color editor ( full red/green/blue/white) and read them via Attribute node in material - everything is fine, i get the same RGB values. So in case of (1, 1, 1), (0, 0, 0) color data is not lost.
  • But when i assign colors like (0.5, 0.5, 0.5) - “Attribute node” returns halved values, (0.21, 0.21, 0.21) for pure gray, for example.

In other words colors in Vertex color editor and “Attribute node” are not the same, there is a nonlinear mismatch. How this can be fixed? How real RGB, unaltered values of vertex color data can be read in material node?

Any help really appreciated.

More info about this issue: https://blender.stackexchange.com/questions/87576/vertex-colors-loose-color-data/87583#87583

Whenever I have problems with vertex colors in blender I just use UVs. If you need 3 value channels just use 2 UV layers. Use the 4th value for something down the road. If the UVs went through color management, we would have one hell of a problem. Too bad they are not UVW.

As an example I usually use 2 UVs when I need to store a backup copy of custom normals, since custom normals only allow a single “layer” or set. This is normally not for materials though, but because most of Blenders tools and modifiers do not play nice with custom normals and end up wrecking them. UVs are treated better.

I remember seeing someone correcting color space problems with the curve node once. Would be nice if they had a built in color space conversion node though.