Linear workflow was a biggie for many years and for many people nothing much has changed. Color management generally was a biggie for every post-house I've worked for. I'll try to reveal little bit of how things works in CG rendering using Maya & V-Ray.
Let's look at some good and bad examples and set up basic terminology. Then we will talk little bit about why we use gamma corrected space. I'll try to keep it simple, so we'll talk just about simple gamma correction. This should give you solid grounding how to make technically correct renders, which are looking nice and compositors should be happy with :-)
CORRECT
This is the only correct solution for 99 percent of tasks for vfx and animation projects.
sRGB look-up turned on
- this does make it look correct on computer screen
sRGB textures linearized
-this make textures mimic real world value, which renderer expects to get
WRONG !!
Textures looks washed out, but if you dont use textures, or they are in linear space already, this is correct solution.
sRGB look-up turned on
- this does make the light look correct on computer screen, this is what we need
sRGB textures are not linearized
- so if you compare with original textures, they look somehow washed out
WRONG !!
This is usual scenario, change anything, just press the render button :o))
no sRGB look-up
- lighting looks wrong, shadows are darker then they should be
sRGB textures are not linearized
- because there is no lookup, textures look correct, just lighting is wrong
WRONG !!
Wrong example of trying to make it correct :o))
no sRGB look-up
- lighting looks wrong, shadows are darker then they should be
sRGB textures are not linearized
- they look much darker .. this is the worst combination!
BASIC TERMS
Scene referred space or Linear light space
corresponds to real physical units, and it is not perceptually uniform, thus if something is physically twice as bright, it's not looking twice as bright for human eye ... in photographic and cinema world twice as bright means +1EV or +1 f-stop on your camera. You can imagine this as a white line on the picture above.
What is linear workflow
Gamma
is in fact some sort of curve, described by mathematical function. For us let's make it simple and assume it's power function of 2.2 , which should should match with most of the PC monitors quite well, unless you have unusual setup.
Display referred space
is working space of our display, often called gamma corrected space. In case of PC monitor, we have to do correction against it's gamma function and this is where all the problems start.
Let's assume that white line on the diagram is the picture we need to display, and red curve is characteristics of our display. In order to display it right, we need to do inverse correction - green line. Most of the 8 and 16 bit image formats have this gamma correction baked in, that's why you see them correctly when you display them on your monitor.
HOW TO PUT THIS IN PRACTICE
Well, now we know that real world units works in linear space (white line) and our display doesn't. Thus it needs to be fed with data which are corrected. But our renderer mimics the real world behaviour, so we need to fed it with "real world" data. This means we have to get rid off baked-in gamma correction and then put this correction back on the final rendering to be able display it right. There is couple of things we have to do, ...
Linearize input textures
Generally, textures should be linear. There is few kind of texture maps you can be using
- Image maps - like color, specular, glossy, .... if you have used tools like Photoshop or Mari, they are most likely in display referred space, so you need to conform them into the linear colorspace.
- Data maps and baked textures - like displacement or normal map, or. any texture bakes are usually in linear colorspace, so you need to leave them as they are.
Don't use "Linear workflow" checkbox in V-Ray Color Mapping tab!
"It's simple and it works, why I shouldn't use it?"
Well, answer is quite straighforward, there is couple of reasons. First Chaos Group no longer support this feature and encourage users not to use it. Second reason is because you cant produce linear image for compositing and also you dont have explicit control over what is being corrected, so this makes you hard time, if you want to use normal/displacement maps or do texture baking.
Use V-Ray attribute instead. Each filenode has ability to add Extra V-Ray Attribute - Texture Input Gamma.
There is nothing more you need to do, input gamma is already set for you!
Set-up your buffer gamma look-up
Images are rendered in linear colorspace, thus you need to compensate for that.
Convert image to sRGB for RenderView ensures, that image looks correct in RenderView.
Anyway I encourage you to use VFB, just tick that checkbox and you should be ready to go!
On the bottom shelf is little icon sRGB, just activate that and you're done with your linear workflow setup!
There is some more settings to go
Well, here is couple of things how to optimize render speed based on what human eye can see.
If you want to speedup your renders, set gamma to 2.2 and tick "Dont affect colors (adaptation only)"
This will just weight sampling based on 2.2 gamma, so it will favor places which are more visible to human eye, and sample less, where noise is not that apparent.
If you intend to send your rendering to compositor for more complex task, you should have color mapping type set to Linear Multiply!
Linear workflow check box must be turned off!
That's it for now, if you have any questions, please post them into comments.