diff options
author | Campbell Barton <ideasman42@gmail.com> | 2019-04-17 07:17:24 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2019-04-17 07:21:24 +0300 |
commit | e12c08e8d170b7ca40f204a5b0423c23a9fbc2c1 (patch) | |
tree | 8cf3453d12edb177a218ef8009357518ec6cab6a /source/blender/nodes/texture/nodes/node_texture_decompose.c | |
parent | b3dabc200a4b0399ec6b81f2ff2730d07b44fcaa (diff) |
ClangFormat: apply to source, most of intern
Apply clang format as proposed in T53211.
For details on usage and instructions for migrating branches
without conflicts, see:
https://wiki.blender.org/wiki/Tools/ClangFormat
Diffstat (limited to 'source/blender/nodes/texture/nodes/node_texture_decompose.c')
-rw-r--r-- | source/blender/nodes/texture/nodes/node_texture_decompose.c | 56 |
1 files changed, 30 insertions, 26 deletions
diff --git a/source/blender/nodes/texture/nodes/node_texture_decompose.c b/source/blender/nodes/texture/nodes/node_texture_decompose.c index e531eb6c816..999b2c30448 100644 --- a/source/blender/nodes/texture/nodes/node_texture_decompose.c +++ b/source/blender/nodes/texture/nodes/node_texture_decompose.c @@ -21,62 +21,66 @@ * \ingroup texnodes */ - #include "node_texture_util.h" #include "NOD_texture.h" #include <math.h> static bNodeSocketTemplate inputs[] = { - { SOCK_RGBA, 1, N_("Color"), 0.0f, 0.0f, 0.0f, 1.0f }, - { -1, 0, "" }, + {SOCK_RGBA, 1, N_("Color"), 0.0f, 0.0f, 0.0f, 1.0f}, + {-1, 0, ""}, }; static bNodeSocketTemplate outputs[] = { - { SOCK_FLOAT, 0, N_("Red") }, - { SOCK_FLOAT, 0, N_("Green") }, - { SOCK_FLOAT, 0, N_("Blue") }, - { SOCK_FLOAT, 0, N_("Alpha") }, - { -1, 0, "" }, + {SOCK_FLOAT, 0, N_("Red")}, + {SOCK_FLOAT, 0, N_("Green")}, + {SOCK_FLOAT, 0, N_("Blue")}, + {SOCK_FLOAT, 0, N_("Alpha")}, + {-1, 0, ""}, }; static void valuefn_r(float *out, TexParams *p, bNode *UNUSED(node), bNodeStack **in, short thread) { - tex_input_rgba(out, in[0], p, thread); - *out = out[0]; + tex_input_rgba(out, in[0], p, thread); + *out = out[0]; } static void valuefn_g(float *out, TexParams *p, bNode *UNUSED(node), bNodeStack **in, short thread) { - tex_input_rgba(out, in[0], p, thread); - *out = out[1]; + tex_input_rgba(out, in[0], p, thread); + *out = out[1]; } static void valuefn_b(float *out, TexParams *p, bNode *UNUSED(node), bNodeStack **in, short thread) { - tex_input_rgba(out, in[0], p, thread); - *out = out[2]; + tex_input_rgba(out, in[0], p, thread); + *out = out[2]; } static void valuefn_a(float *out, TexParams *p, bNode *UNUSED(node), bNodeStack **in, short thread) { - tex_input_rgba(out, in[0], p, thread); - *out = out[3]; + tex_input_rgba(out, in[0], p, thread); + *out = out[3]; } -static void exec(void *data, int UNUSED(thread), bNode *node, bNodeExecData *execdata, bNodeStack **in, bNodeStack **out) +static void exec(void *data, + int UNUSED(thread), + bNode *node, + bNodeExecData *execdata, + bNodeStack **in, + bNodeStack **out) { - tex_output(node, execdata, in, out[0], &valuefn_r, data); - tex_output(node, execdata, in, out[1], &valuefn_g, data); - tex_output(node, execdata, in, out[2], &valuefn_b, data); - tex_output(node, execdata, in, out[3], &valuefn_a, data); + tex_output(node, execdata, in, out[0], &valuefn_r, data); + tex_output(node, execdata, in, out[1], &valuefn_g, data); + tex_output(node, execdata, in, out[2], &valuefn_b, data); + tex_output(node, execdata, in, out[3], &valuefn_a, data); } void register_node_type_tex_decompose(void) { - static bNodeType ntype; + static bNodeType ntype; - tex_node_type_base(&ntype, TEX_NODE_DECOMPOSE, "Separate RGBA", NODE_CLASS_OP_COLOR, 0); - node_type_socket_templates(&ntype, inputs, outputs); - node_type_exec(&ntype, NULL, NULL, exec); + tex_node_type_base(&ntype, TEX_NODE_DECOMPOSE, "Separate RGBA", NODE_CLASS_OP_COLOR, 0); + node_type_socket_templates(&ntype, inputs, outputs); + node_type_exec(&ntype, NULL, NULL, exec); - nodeRegisterType(&ntype); + nodeRegisterType(&ntype); } |