Revision: 17796
          
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=17796
Author:   aligorith
Date:     2008-12-12 06:32:15 +0100 (Fri, 12 Dec 2008)

Log Message:
-----------
AnimSys2: Bone Heating in WeightPaint mode only creates necessary Vertex Groups

I've added a check for selected bones in the function which assigns/creates the 
Vertex Groups.

Modified Paths:
--------------
    branches/animsys2/source/blender/src/editarmature.c

Modified: branches/animsys2/source/blender/src/editarmature.c
===================================================================
--- branches/animsys2/source/blender/src/editarmature.c 2008-12-11 23:05:18 UTC 
(rev 17795)
+++ branches/animsys2/source/blender/src/editarmature.c 2008-12-12 05:32:15 UTC 
(rev 17796)
@@ -3863,8 +3863,15 @@
                        else
                                segments = 1;
                        
-                       if (!(defgroup = get_named_vertexgroup(ob, bone->name)))
-                               defgroup = add_defgroup_name(ob, bone->name);
+                       /* only create new group if not in weightpainting mode 
or bone is selected, 
+                        * so that we don't create extra groups.
+                        */
+                       if (!(G.f & G_WEIGHTPAINT) || (bone->flag & 
BONE_SELECTED)) {
+                               if (!(defgroup = get_named_vertexgroup(ob, 
bone->name)))
+                                       defgroup = add_defgroup_name(ob, 
bone->name);
+                       }
+                       else
+                               defgroup= NULL;
                        
                        if (data->list != NULL) {
                                hgroup = (bDeformGroup ***) &data->list;


_______________________________________________
Bf-blender-cvs mailing list
[email protected]
http://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to