forked from blender/blender
main sync #3
@ -8,7 +8,7 @@ void node_composite_luminance_matte(vec4 color,
|
|||||||
out float matte)
|
out float matte)
|
||||||
{
|
{
|
||||||
float luminance = get_luminance(color.rgb, luminance_coefficients);
|
float luminance = get_luminance(color.rgb, luminance_coefficients);
|
||||||
float alpha = clamp(0.0, 1.0, (luminance - low) / (high - low));
|
float alpha = clamp((luminance - low) / (high - low), 0.0, 1.0);
|
||||||
matte = min(alpha, color.a);
|
matte = min(alpha, color.a);
|
||||||
result = color * matte;
|
result = color * matte;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user