[Bf-blender-cvs] [493a8d5] temp-cycles-microdisplacement: Merge remote-tracking branch 'origin/master' into temp-cycles-microdisplacement
Lukas Stockner
noreply at git.blender.org
Sun May 8 00:39:53 CEST 2016
Commit: 493a8d572d795c95a75398990bb0a9588f48efae
Author: Lukas Stockner
Date: Sun May 8 00:19:32 2016 +0200
Branches: temp-cycles-microdisplacement
https://developer.blender.org/rB493a8d572d795c95a75398990bb0a9588f48efae
Merge remote-tracking branch 'origin/master' into temp-cycles-microdisplacement
Conflicts:
intern/cycles/render/nodes.cpp
===================================================================
===================================================================
diff --cc intern/cycles/bvh/bvh_build.cpp
index 58da1d0,63edbc9..0ebf620
--- a/intern/cycles/bvh/bvh_build.cpp
+++ b/intern/cycles/bvh/bvh_build.cpp
@@@ -635,11 -615,9 +635,11 @@@ BVHNode* BVHBuild::create_leaf_node(con
BoundBox bounds[PRIMITIVE_NUM_TOTAL] = {BoundBox::empty,
BoundBox::empty,
BoundBox::empty,
+ BoundBox::empty,
+ BoundBox::empty,
BoundBox::empty};
int ob_num = 0;
-
+ int num_new_prims = 0;
/* Fill in per-type type/index array. */
for(int i = 0; i < range.size(); i++) {
const BVHReference& ref = references[range.start() + i];
diff --cc intern/cycles/kernel/kernel_globals.h
index 5dc0e91,3291239..10e53b1
--- a/intern/cycles/kernel/kernel_globals.h
+++ b/intern/cycles/kernel/kernel_globals.h
@@@ -31,11 -31,8 +31,11 @@@ struct OSLThreadData
struct OSLShadingSystem;
# endif
+struct GeomCache;
+struct GeomCacheThreadData;
+
# define MAX_BYTE_IMAGES 1024
- # define MAX_FLOAT_IMAGES 1024
+ # define MAX_FLOAT4_IMAGES 1024
typedef struct KernelGlobals {
texture_image_uchar4 texture_byte_images[MAX_BYTE_IMAGES];
diff --cc intern/cycles/render/nodes.cpp
index e3b5f72,c1841f3..1c2f1b4
--- a/intern/cycles/render/nodes.cpp
+++ b/intern/cycles/render/nodes.cpp
@@@ -4386,23 -4251,18 +4252,19 @@@ void BumpNode::compile(SVMCompiler& com
ShaderInput *distance_in = input("Distance");
ShaderOutput *normal_out = output("Normal");
- compiler.stack_assign(center_in);
- compiler.stack_assign(dx_in);
- compiler.stack_assign(dy_in);
- compiler.stack_assign(strength_in);
- compiler.stack_assign(distance_in);
- compiler.stack_assign(normal_out);
-
- if(normal_in->link)
- compiler.stack_assign(normal_in);
-
/* pack all parameters in the node */
+ int flags = (NODE_BUMP_INVERT * invert) | (NODE_BUMP_OVERRIDE * displacement_override);
compiler.add_node(NODE_SET_BUMP,
- compiler.encode_uchar4(normal_in->stack_offset, distance_in->stack_offset, flags),
- compiler.encode_uchar4(center_in->stack_offset, dx_in->stack_offset,
- dy_in->stack_offset, strength_in->stack_offset),
- normal_out->stack_offset);
+ compiler.encode_uchar4(
+ compiler.stack_assign_if_linked(normal_in),
+ compiler.stack_assign(distance_in),
- invert),
++ flags),
+ compiler.encode_uchar4(
+ compiler.stack_assign(center_in),
+ compiler.stack_assign(dx_in),
+ compiler.stack_assign(dy_in),
+ compiler.stack_assign(strength_in)),
+ compiler.stack_assign(normal_out));
}
void BumpNode::compile(OSLCompiler& compiler)
More information about the Bf-blender-cvs
mailing list