Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Dinges <blender@dingto.org>2014-01-13 23:40:13 +0400
committerThomas Dinges <blender@dingto.org>2014-01-14 00:17:55 +0400
commit6b61f7f755011c0ceea89a31be218e1ed4940414 (patch)
tree3bd475deb2184546cd44aae02bd917fc14f5aaae /intern/cycles/kernel/svm/svm_brick.h
parentef67b9eec4edbeec8d21fa6db798cd6ef68ab344 (diff)
Code cleanup / Cycles: Don't pass scale to texture functions, do the multiplication in the function call already.
Diffstat (limited to 'intern/cycles/kernel/svm/svm_brick.h')
-rw-r--r--intern/cycles/kernel/svm/svm_brick.h8
1 files changed, 3 insertions, 5 deletions
diff --git a/intern/cycles/kernel/svm/svm_brick.h b/intern/cycles/kernel/svm/svm_brick.h
index 7cac922d8a6..97c2b545c5f 100644
--- a/intern/cycles/kernel/svm/svm_brick.h
+++ b/intern/cycles/kernel/svm/svm_brick.h
@@ -26,12 +26,10 @@ ccl_device_noinline float brick_noise(int n) /* fast integer noise */
return 0.5f * ((float)nn / 1073741824.0f);
}
-ccl_device_noinline float2 svm_brick(float3 p, float scale, float mortar_size, float bias,
+ccl_device_noinline float2 svm_brick(float3 p, float mortar_size, float bias,
float brick_width, float row_height, float offset_amount, int offset_frequency,
float squash_amount, int squash_frequency)
-{
- p *= scale;
-
+{
int bricknum, rownum;
float offset = 0.0f;
float x, y;
@@ -89,7 +87,7 @@ ccl_device void svm_node_tex_brick(KernelGlobals *kg, ShaderData *sd, float *sta
float offset_amount = __int_as_float(node3.z);
float squash_amount = __int_as_float(node3.w);
- float2 f2 = svm_brick(co, scale, mortar_size, bias, brick_width, row_height,
+ float2 f2 = svm_brick(co*scale, mortar_size, bias, brick_width, row_height,
offset_amount, offset_frequency, squash_amount, squash_frequency);
float tint = f2.x;