Brightness/Contrast Node for Cycles
authorDalai Felinto <dfelinto@gmail.com>
Tue, 24 Jan 2012 16:32:31 +0000 (16:32 +0000)
committerDalai Felinto <dfelinto@gmail.com>
Tue, 24 Jan 2012 16:32:31 +0000 (16:32 +0000)
commit335ffb0ff3df6ee52f525448d09ae6448b75e158
tree460fc93c618d05f0585405c61dcc5152ee906798
parent1f9e25ac1a7851ab2503b88564c0d480b9e125cf
Brightness/Contrast Node for Cycles

Contrast helps to adjust IBL (HDR images used for background lighting).
Note: In the UI we are caling it Bright instead of Brightness. This copy what Blender composite is doing.
Note2: the algorithm we are using produces pure black when contrast is 100. I'm not a fan of that, but it's a division by zero. I would like to look at other algorithms (what gimp does for example). But that would be only after 2.62.
17 files changed:
intern/cycles/app/cycles_xml.cpp
intern/cycles/blender/blender_shader.cpp
intern/cycles/kernel/CMakeLists.txt
intern/cycles/kernel/osl/nodes/CMakeLists.txt
intern/cycles/kernel/osl/nodes/node_brightness.osl [new file with mode: 0644]
intern/cycles/kernel/svm/svm.h
intern/cycles/kernel/svm/svm_brightness.h [new file with mode: 0644]
intern/cycles/kernel/svm/svm_types.h
intern/cycles/render/nodes.cpp
intern/cycles/render/nodes.h
source/blender/blenkernel/BKE_node.h
source/blender/blenkernel/intern/node.c
source/blender/makesrna/intern/rna_nodetree_types.h
source/blender/nodes/CMakeLists.txt
source/blender/nodes/NOD_shader.h
source/blender/nodes/shader/nodes/node_shader_brightness.c [new file with mode: 0644]
source/blender/nodes/shader/nodes/node_shader_gamma.c