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:
authorSergey Sharybin <sergey.vfx@gmail.com>2017-01-17 16:23:29 +0300
committerSergey Sharybin <sergey.vfx@gmail.com>2017-01-20 14:46:18 +0300
commitd50d370755beba0d23356acc301a180afa87e676 (patch)
tree7e51fd4f7fef2325004fe2a2c46ba6a9bb54a117 /intern/cycles/render/mesh.h
parent6f900c383a4f8415331eb56a3e2b69c0cec30702 (diff)
Cycles: Add utility function to calculate curve boundbox from given 4 keys
Also fixed some issues with motion keys calculation: - Clamp lower and upper limits of curves so we can safely call those functions for the very first and very last curve segment. - Fixed wrong indexing for the curve radius array. - Fixed wrong motion attribute offset calculation.
Diffstat (limited to 'intern/cycles/render/mesh.h')
-rw-r--r--intern/cycles/render/mesh.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/intern/cycles/render/mesh.h b/intern/cycles/render/mesh.h
index b29a2561a0e..5f33e30eac2 100644
--- a/intern/cycles/render/mesh.h
+++ b/intern/cycles/render/mesh.h
@@ -95,6 +95,7 @@ public:
const float3 *curve_keys,
const float *curve_radius,
BoundBox& bounds) const;
+ void bounds_grow(float4 keys[4], BoundBox& bounds) const;
void bounds_grow(const int k,
const float3 *curve_keys,
const float *curve_radius,
@@ -104,6 +105,7 @@ public:
void motion_keys(const float3 *curve_keys,
const float *curve_radius,
const float3 *key_steps,
+ size_t num_curve_keys,
size_t num_steps,
float time,
size_t k0, size_t k1,
@@ -111,6 +113,7 @@ public:
void cardinal_motion_keys(const float3 *curve_keys,
const float *curve_radius,
const float3 *key_steps,
+ size_t num_curve_keys,
size_t num_steps,
float time,
size_t k0, size_t k1,
@@ -120,6 +123,7 @@ public:
void keys_for_step(const float3 *curve_keys,
const float *curve_radius,
const float3 *key_steps,
+ size_t num_curve_keys,
size_t num_steps,
size_t step,
size_t k0, size_t k1,
@@ -127,6 +131,7 @@ public:
void cardinal_keys_for_step(const float3 *curve_keys,
const float *curve_radius,
const float3 *key_steps,
+ size_t num_curve_keys,
size_t num_steps,
size_t step,
size_t k0, size_t k1,