From bb3efe61276346f7ee12d24308d95d447941b0ec Mon Sep 17 00:00:00 2001 From: Sergey Sharybin Date: Wed, 14 Feb 2018 14:29:37 +0100 Subject: [PATCH] Blenlib: Assert when attempting to rotate point around vector and store result in the point This isn't supported since there are subsequent reads to all point coordinates after modification started. Probably we need to create a temp copy of point, but that's like extra CPU ticks. --- source/blender/blenlib/intern/math_vector.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/source/blender/blenlib/intern/math_vector.c b/source/blender/blenlib/intern/math_vector.c index 05562502278..d6e48fa59e7 100644 --- a/source/blender/blenlib/intern/math_vector.c +++ b/source/blender/blenlib/intern/math_vector.c @@ -890,6 +890,8 @@ void rotate_normalized_v3_v3v3fl(float out[3], const float p[3], const float axi void rotate_v3_v3v3fl(float r[3], const float p[3], const float axis[3], const float angle) { + BLI_assert(r != p); + float axis_n[3]; normalize_v3_v3(axis_n, axis);