diff options
author | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2012-05-02 13:33:45 +0400 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2012-05-02 13:33:45 +0400 |
commit | 1e2afcddd3f1fd7b82fc0ea78fec2d80021fe844 (patch) | |
tree | 8bec6696a9a624affbb56ae9531fc6598f631d81 /intern/cycles/util/util_math.h | |
parent | 5d4fd04f05fc20d1a15817e5de4f1e2b776ab2b6 (diff) |
Fix #31168: cycles mask layer should only affect objects for camera rays.
Fix: texture coordinate normal output was not correct, still changed under
object transform.
Diffstat (limited to 'intern/cycles/util/util_math.h')
-rw-r--r-- | intern/cycles/util/util_math.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/intern/cycles/util/util_math.h b/intern/cycles/util/util_math.h index f09803d8b09..7b527241847 100644 --- a/intern/cycles/util/util_math.h +++ b/intern/cycles/util/util_math.h @@ -436,6 +436,11 @@ __device_inline float len(const float3 a) return sqrtf(dot(a, a)); } +__device_inline float len_squared(const float3 a) +{ + return dot(a, a); +} + #ifndef __KERNEL_OPENCL__ __device_inline float3 normalize(const float3 a) |