[Bf-blender-cvs] [48053ad] PSketch: PSculpt: Show help text showing key methods of operation in the header

Joshua Leung noreply at git.blender.org
Sun Jan 31 14:29:34 CET 2016


Commit: 48053adbc2c1dd949efd669c1f3f6d25ed247d74
Author: Joshua Leung
Date:   Sun Jan 31 13:01:58 2016 +1300
Branches: PSketch
https://developer.blender.org/rB48053adbc2c1dd949efd669c1f3f6d25ed247d74

PSculpt: Show help text showing key methods of operation in the header

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

M	source/blender/editors/armature/pose_sculpt.c

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

diff --git a/source/blender/editors/armature/pose_sculpt.c b/source/blender/editors/armature/pose_sculpt.c
index 305d8ec..a47d416 100644
--- a/source/blender/editors/armature/pose_sculpt.c
+++ b/source/blender/editors/armature/pose_sculpt.c
@@ -1181,6 +1181,9 @@ static int psculpt_brush_init(bContext *C, wmOperator *op)
 {
 	Scene *scene = CTX_data_scene(C);
 	Object *ob = CTX_data_active_object(C);
+	ScrArea *sa = CTX_wm_area(C);
+	
+	PSculptSettings *pset = psculpt_settings(scene);
 	tPoseSculptingOp *pso;
 	tPSculptContext *data;
 	PSculptBrushData *brush;
@@ -1218,7 +1221,48 @@ static int psculpt_brush_init(bContext *C, wmOperator *op)
 	}
 	
 	/* setup cursor and header drawing */
-	ED_area_headerprint(CTX_wm_area(C), IFACE_("Pose Sculpting in progress..."));
+	switch (pset->brushtype) {
+		case PSCULPT_BRUSH_DRAW:
+			ED_area_headerprint(sa, IFACE_("Draw Pose"));
+			break;
+			
+		case PSCULPT_BRUSH_ADJUST:
+			ED_area_headerprint(sa, IFACE_("Adjust Pose: Move to rotate bones   |  Pressure controls strength"));
+			break;
+			
+		case PSCULPT_BRUSH_SMOOTH:
+			ED_area_headerprint(sa, IFACE_("Smooth Pose"));
+			break;
+		
+		case PSCULPT_BRUSH_GRAB:
+			ED_area_headerprint(sa, IFACE_("Grab Bones: Move to translate bones"));
+			break;
+		
+		case PSCULPT_BRUSH_CURL:
+			if (brush->xzMode == PSCULPT_BRUSH_DO_X)
+				ED_area_headerprint(sa, IFACE_("Curl Bones: Move to paint curling effects on X axis |  Shift to Invert direction  | Pressure controls strength"));
+			else if (brush->xzMode == PSCULPT_BRUSH_DO_Z)
+				ED_area_headerprint(sa, IFACE_("Curl Bones: Move to paint curling effects on Z axis  |  Shift to Invert direction  | Pressure controls strength"));
+			else
+				ED_area_headerprint(sa, IFACE_("Curl Bones: Move to paint curling effects on X and Z axes  |  Shift to Invert direction  | Pressure controls strength"));
+			break;
+			
+		case PSCULPT_BRUSH_TWIST:
+			ED_area_headerprint(sa, IFACE_("Twist Bones: Move to paint y-rotation effects on bones  |  Shift to Invert direction"));
+			break;
+			
+		case PSCULPT_BRUSH_STRETCH:
+			ED_area_headerprint(sa, IFACE_("Stretch Bones: Move to paint stretching effects on bones  |  Shift to Invert direction"));
+			break;
+			
+		case PSCULPT_BRUSH_RESET:
+			ED_area_headerprint(sa, IFACE_("Reset Pose: Paint to blend pose back to rest pose  |  Shift to Invert (blend pose back to pre-sculpt condition)"));
+			break;
+		
+		default:
+			ED_area_headerprint(CTX_wm_area(C), IFACE_("Pose Sculpting in progress..."));
+			break;
+	}
 	
 	WM_cursor_modal_set(CTX_wm_window(C), BC_CROSSCURSOR);
 	psculpt_toggle_cursor(C, true);




More information about the Bf-blender-cvs mailing list