From dd38dce7f0ae604396d1e96bc49500369fdedf29 Mon Sep 17 00:00:00 2001 From: Antony Riakiotakis Date: Tue, 17 Mar 2015 15:20:33 +0100 Subject: Part 2 of D1082 by Troy Sobotka, remove our functions that do luma calculations and use the OCIO one instead. --- source/blender/nodes/shader/nodes/node_shader_valToRgb.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'source/blender/nodes/shader/nodes/node_shader_valToRgb.c') diff --git a/source/blender/nodes/shader/nodes/node_shader_valToRgb.c b/source/blender/nodes/shader/nodes/node_shader_valToRgb.c index fa5d9b43ee7..72942cce9c5 100644 --- a/source/blender/nodes/shader/nodes/node_shader_valToRgb.c +++ b/source/blender/nodes/shader/nodes/node_shader_valToRgb.c @@ -31,6 +31,7 @@ #include "node_shader_util.h" +#include "IMB_colormanagement.h" /* **************** VALTORGB ******************** */ static bNodeSocketTemplate sh_node_valtorgb_in[] = { @@ -106,7 +107,7 @@ static void node_shader_exec_rgbtobw(void *UNUSED(data), int UNUSED(thread), bNo float col[3]; nodestack_get_vec(col, SOCK_VECTOR, in[0]); - out[0]->vec[0] = rgb_to_bw(col); + out[0]->vec[0] = IMB_colormanagement_get_luminance(col); } static int gpu_shader_rgbtobw(GPUMaterial *mat, bNode *UNUSED(node), bNodeExecData *UNUSED(execdata), GPUNodeStack *in, GPUNodeStack *out) -- cgit v1.2.3