diff options
author | Campbell Barton <ideasman42@gmail.com> | 2012-06-22 11:49:44 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2012-06-22 11:49:44 +0400 |
commit | 226c86ae58cdf292fd415db05c05fba46375738d (patch) | |
tree | 3f002f89da94cc0428529f469175c311d0341561 /source/blender/nodes/texture | |
parent | ec3399efa6882ea5a8fe023092c0918ee7b135d9 (diff) |
use an inline function for rgb -> bw conversion.
Diffstat (limited to 'source/blender/nodes/texture')
-rw-r--r-- | source/blender/nodes/texture/nodes/node_texture_valToRgb.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/source/blender/nodes/texture/nodes/node_texture_valToRgb.c b/source/blender/nodes/texture/nodes/node_texture_valToRgb.c index d1a02210038..10db0debd5b 100644 --- a/source/blender/nodes/texture/nodes/node_texture_valToRgb.c +++ b/source/blender/nodes/texture/nodes/node_texture_valToRgb.c @@ -91,8 +91,7 @@ static void rgbtobw_valuefn(float *out, TexParams *p, bNode *UNUSED(node), bNode { float cin[4]; tex_input_rgba(cin, in[0], p, thread); - - *out = cin[0] * 0.35f + cin[1] * 0.45f + cin[2] * 0.2f; + *out = rgb_to_bw(cin); } static void rgbtobw_exec(void *data, bNode *node, bNodeStack **in, bNodeStack **out) |