Go to: Related nodes. Attributes.

Luminance is a utility node that takes in a color, and outputs a luminance value.

Luminance simply means the apparent brightness of a color, as seen by the human eye. The human eye is not equally sensitive across the whole spectrum; greens appear brighter than reds, and reds brighter than blue. For this reason, luminance is calculated by this equation:
   Luminance = 0.3 * red + 0.59 * green + 0.11 * blue
 
You can use the Luminance node to convert a color image or texture into a monochrome (black-and-white) image. To do this, connect the texture's Out Color into the Luminance node's Value attribute, then connect the Luminance node's Out Value attribute to all three color channels (R, G, and B) of a shader. In the table below, imporant attributes have their names listed in bold in the description column.

This node is MP safe

Node name Parents Classification MFn type Compatible function sets
luminance node utility/color:drawdb/shader/operation/luminance kLuminance kBase
kNamedObject
kDependencyNode
kLuminance

Related nodes

blendColors, clamp, lightInfo, gammaCorrect, surfaceLuminance, contrast, rgbToHsv, hsvToRgb, samplerInfo, setRange, resolution, renderQuality, renderGlobals, renderGlobalsList, baseShadingSwitch, singleShadingSwitch, doubleShadingSwitch, tripleShadingSwitch

Attributes (6)

outValue, renderPassMode, value, valueB, valueG, valueR

Long name (short name) Type Default Flags
value (v) float3 0.0, 0.0, 0.0 outputinputconnectablestorable
Value is the input color or texture.
valueR (vr) float 0.0 outputinputconnectablestorablekeyable
The first component of Value
valueG (vg) float 0.0 outputinputconnectablestorablekeyable
The second component of Value
valueB (vb) float 0.0 outputinputconnectablestorablekeyable
The third component of Value
renderPassMode (arp) enum 1 outputinputconnectablestorablekeyable
renderPassMode controls how the node affects material render passes.
outValue (o) float 0.0 outputconnectable
Out Value is the luminance of the Value input.