Category Archives: tutorial

Wax Crayons – alLayerColor and Utility shaders


I wanted to tint the color of the paper covering of some wax crayons. So, how to do this without having multiple colored paper textures for each wax crayon? The alLayerColor shader from the very cool alshaders by Anders Langland in combination with the Ai Utility shader is perfect for this kind of thing.

By setting the Color Mode of the Ai Utility to ‘Object’ each of the crayons will be randomly tinted because Object mode uses the name of the shapes to compute the color. Ensure that the ‘Shade Mode’ is set to flat as we don’t want any shading effect from the Ai Utility shader as the alSurface shader is being used for the wax and paper.

‘Shade Mode’ set to ‘flat’ and ‘Color Mode’ set to ‘Object’.

The Ai Utility and the grey paper.jpg texture are combined using the alLayerColor shader:

Paper.jpg layered with Utility shader using alLayerColor connected to Color of alSurface ‘Paper’ shader
alLayerColor connected to Diffuse Color of paper. Mode set to ‘Color Dodge’.
Grey paper texture without alLayerColor
Grey paper texture layered with Ai Utility using alLayerColor shader

The same Ai Utility shader is also used to alter the Diffuse Color and SSS of the wax alSurface shader.

Ai Utility driving the ‘Diffuse Color’ and ‘SSS’ color of the wax shader.