Category Archives: tutorial

Wax Crayons – alLayerColor and Utility shaders

crayons-2k

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.

utility
‘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
Paper.jpg layered with Utility shader using alLayerColor connected to Color of alSurface ‘Paper’ shader
alLayerColor
alLayerColor connected to Diffuse Color of paper. Mode set to ‘Color Dodge’.
grey-crayon
Grey paper texture without alLayerColor
pink-crayon
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.

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

9624b657a165427e3e342793bd310603