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>2011-03-06 20:03:25 +0300
committerSergey Sharybin <sergey.vfx@gmail.com>2011-03-06 20:03:25 +0300
commitd49bafe9572d33ac05a949f78e468267f4d9ecea (patch)
treeac5add5ec4763d9346ebddf187fddd484cfe9105 /source/blender/editors/transform/transform_conversions.c
parent8a312979ef02fbcd382329d9287021acebf213f3 (diff)
Fix #26324: proportional editing and armature applied to editing cage during edit mode works strangely
Not sure why proportional editing used to disable crazyspace corrections, but from that time hwn it was done transform stuff was changed a lot. I've made several tests (with file from report and sintel from durian data files) and it worked nice.
Diffstat (limited to 'source/blender/editors/transform/transform_conversions.c')
-rw-r--r--source/blender/editors/transform/transform_conversions.c38
1 files changed, 18 insertions, 20 deletions
diff --git a/source/blender/editors/transform/transform_conversions.c b/source/blender/editors/transform/transform_conversions.c
index 9a70ec2f3be..84392b1c3cc 100644
--- a/source/blender/editors/transform/transform_conversions.c
+++ b/source/blender/editors/transform/transform_conversions.c
@@ -2056,27 +2056,25 @@ static void createTransEditVerts(bContext *C, TransInfo *t)
if(propmode) editmesh_set_connectivity_distance(em, mtx);
/* detect CrazySpace [tm] */
- if(propmode==0) {
- if(modifiers_getCageIndex(t->scene, t->obedit, NULL, 1)>=0) {
- if(modifiers_isCorrectableDeformed(t->obedit)) {
- /* check if we can use deform matrices for modifier from the
- start up to stack, they are more accurate than quats */
- totleft= editmesh_get_first_deform_matrices(t->scene, t->obedit, em, &defmats, &defcos);
-
- /* if we still have more modifiers, also do crazyspace
- correction with quats, relative to the coordinates after
- the modifiers that support deform matrices (defcos) */
- if(totleft > 0) {
- mappedcos= crazyspace_get_mapped_editverts(t->scene, t->obedit);
- quats= MEM_mallocN( (t->total)*sizeof(float)*4, "crazy quats");
- crazyspace_set_quats_editmesh(em, (float*)defcos, mappedcos, quats);
- if(mappedcos)
- MEM_freeN(mappedcos);
- }
-
- if(defcos)
- MEM_freeN(defcos);
+ if(modifiers_getCageIndex(t->scene, t->obedit, NULL, 1)>=0) {
+ if(modifiers_isCorrectableDeformed(t->obedit)) {
+ /* check if we can use deform matrices for modifier from the
+ start up to stack, they are more accurate than quats */
+ totleft= editmesh_get_first_deform_matrices(t->scene, t->obedit, em, &defmats, &defcos);
+
+ /* if we still have more modifiers, also do crazyspace
+ correction with quats, relative to the coordinates after
+ the modifiers that support deform matrices (defcos) */
+ if(totleft > 0) {
+ mappedcos= crazyspace_get_mapped_editverts(t->scene, t->obedit);
+ quats= MEM_mallocN( (t->total)*sizeof(float)*4, "crazy quats");
+ crazyspace_set_quats_editmesh(em, (float*)defcos, mappedcos, quats);
+ if(mappedcos)
+ MEM_freeN(mappedcos);
}
+
+ if(defcos)
+ MEM_freeN(defcos);
}
}