Jump to content
Wout

.rat files, linear and color spaces

Recommended Posts

Hey guys,

 

so what I want to do is render to a .rat file with several image planes. I'd like to process those planes and then save them to a sRgb color space format, png. The thing is I can't find how to do that. When I import the .rat file, colors look weird , like looking at a linear file with no correction, and that's how the ROP saves them as well. What do I need to know/do to render out, for example, normal maps so that it has the correct, (sRgb) color space ? Checking the ' Convert to Image Format's Colorspace' box doesn't work.

Thank You ! 

 

Wout

Share this post


Link to post
Share on other sites

Hey,

 

can you help us with a bit more information. What is exactly your workflow, where do you import the rats (houdini or mplay), where/how were those rats generated would be helpful.

Share this post


Link to post
Share on other sites

The RAT file format specifies that all color values stored in it are in linear space, so rendering to them will write the values as-is (no sRGB conversion). Rendering to a PNG, on the other hand, will convert the rendered linear color values to sRGB because it's a sRGB format. If you're writing a normal map to PNG, you do not want any colorspace conversion to take place on export or import - the value should be stored linearly (otherwise normal values are unevenly distributed across[-1,1]). 

So if you are reading the RAT into COPs, extracting the normals into a separate plane and writing them to PNG, disable the "Convert to Image Format's Colorspace" toggle in the Composite tab of the Composite ROP. This will write the linear values into the PNG as-is, without sRGB encoding.

  • Like 1

Share this post


Link to post
Share on other sites

Thank you for your replies; , I'll check it later maybe, bit crazy at work right now.. :)

 

 

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×