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:
authorCampbell Barton <ideasman42@gmail.com>2012-05-07 19:45:41 +0400
committerCampbell Barton <ideasman42@gmail.com>2012-05-07 19:45:41 +0400
commit6291b36d4c14949dfe3cd6b02b321f8bde705db0 (patch)
tree1ef7f101af82d088e02af444312341988ae4a2aa /source/blender/modifiers
parentb613879f348e870d3b0fb6a68bbcf91e85579280 (diff)
fix for solidify modifier angle calculation (was incorrectly using normalized angle function)
Diffstat (limited to 'source/blender/modifiers')
-rw-r--r--source/blender/modifiers/intern/MOD_solidify.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/source/blender/modifiers/intern/MOD_solidify.c b/source/blender/modifiers/intern/MOD_solidify.c
index 96c84f5abbe..163c3979bfe 100644
--- a/source/blender/modifiers/intern/MOD_solidify.c
+++ b/source/blender/modifiers/intern/MOD_solidify.c
@@ -474,16 +474,16 @@ static DerivedMesh *applyModifier(ModifierData *md, Object *ob,
/* just added, calc the normal */
BLI_array_empty(face_angles);
+ BLI_array_reserve(face_angles, mp->totloop);
for (j = 0, ml = mloop + mp->loopstart; j < mp->totloop; j++, ml++) {
MLoop *ml_prev = ME_POLY_LOOP_PREV(mloop, mp, j);
MLoop *ml_next = ME_POLY_LOOP_NEXT(mloop, mp, j);
- float e1[3], e2[3], angle;
-
+ float e1[3], e2[3];
+
sub_v3_v3v3(e1, mvert[ml_next->v].co, mvert[ml->v].co);
sub_v3_v3v3(e2, mvert[ml_prev->v].co, mvert[ml->v].co);
- angle = (float)M_PI - angle_normalized_v3v3(e1, e2);
- BLI_array_append(face_angles, angle);
+ face_angles[j] = (float)M_PI - angle_v3v3(e1, e2);
}
for (j = 0, ml = mloop + mp->loopstart; j < mp->totloop; j++, ml++) {