[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [43660] trunk/blender/source/blender/ editors/space_view3d/view3d_select.c: Bugfix: Circle-select in Pose Mode disregarded layer visibility, selecting

Joshua Leung aligorith at gmail.com
Tue Jan 24 09:43:41 CET 2012


Revision: 43660
          http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=43660
Author:   aligorith
Date:     2012-01-24 08:43:39 +0000 (Tue, 24 Jan 2012)
Log Message:
-----------
Bugfix: Circle-select in Pose Mode disregarded layer visibility, selecting
invisible bones too

Modified Paths:
--------------
    trunk/blender/source/blender/editors/space_view3d/view3d_select.c

Modified: trunk/blender/source/blender/editors/space_view3d/view3d_select.c
===================================================================
--- trunk/blender/source/blender/editors/space_view3d/view3d_select.c	2012-01-24 08:43:17 UTC (rev 43659)
+++ trunk/blender/source/blender/editors/space_view3d/view3d_select.c	2012-01-24 08:43:39 UTC (rev 43660)
@@ -2452,6 +2452,7 @@
 static void pose_circle_select(ViewContext *vc, int select, const int mval[2], float rad)
 {
 	struct {ViewContext *vc; short select; int mval[2]; float radius; } data;
+	bArmature *arm = vc->obact->data;
 	bPose *pose = vc->obact->pose;
 	bPoseChannel *pchan;
 	int change= FALSE;
@@ -2470,6 +2471,10 @@
 		short sco1[2], sco2[2], didpoint=0;
 		float vec[3];
 		
+		/* skip invisible bones */
+		if (PBONE_VISIBLE(arm, pchan->bone) == 0)
+			continue;
+		
 		/* project head location to screenspace */
 		mul_v3_m4v3(vec, vc->obact->obmat, pchan->pose_head);
 		project_short(vc->ar, vec, sco1);



More information about the Bf-blender-cvs mailing list