[Bf-blender-cvs] [584f439] master: imp: show alert color if mesh has weight groups but no active group is selected

Gaia Clary noreply at git.blender.org
Tue Nov 3 20:19:31 CET 2015


Commit: 584f439112a705e03edf8724e0c8596380a1e976
Author: Gaia Clary
Date:   Tue Nov 3 20:19:03 2015 +0100
Branches: master
https://developer.blender.org/rB584f439112a705e03edf8724e0c8596380a1e976

imp: show alert color if mesh has weight groups but no active group is selected

===================================================================

M	source/blender/blenkernel/intern/DerivedMesh.c

===================================================================

diff --git a/source/blender/blenkernel/intern/DerivedMesh.c b/source/blender/blenkernel/intern/DerivedMesh.c
index 744a154..a5a29f6 100644
--- a/source/blender/blenkernel/intern/DerivedMesh.c
+++ b/source/blender/blenkernel/intern/DerivedMesh.c
@@ -1468,7 +1468,10 @@ static void calc_weightpaint_vert_array(
 	}
 	else {
 		unsigned char col[4];
-		if (draw_flag & (CALC_WP_GROUP_USER_ACTIVE | CALC_WP_GROUP_USER_ALL)) {
+		if ((ob->actdef == 0) && !BLI_listbase_is_empty(&ob->defbase)) {
+			ARRAY_SET_ITEMS(col, 0xff, 0, 0xff, 0xff);
+		}
+		else if (draw_flag & (CALC_WP_GROUP_USER_ACTIVE | CALC_WP_GROUP_USER_ALL)) {
 			copy_v3_v3_char((char *)col, dm_wcinfo->alert_color);
 			col[3] = 255;
 		}




More information about the Bf-blender-cvs mailing list