Add ability to select 3 faces
parent
105a350ccd
commit
7d5eaffa89
|
@ -428,6 +428,26 @@ void TextWindow::DescribeSelection() {
|
|||
double d = (p1.Minus(p0)).Dot(n0);
|
||||
Printf(true, " distance = %Fi%s", SS.MmToString(d).c_str());
|
||||
}
|
||||
} else if(gs.n == 3 && gs.faces == 3) {
|
||||
Printf(false, "%FtTHREE PLANE FACES");
|
||||
|
||||
Vector n0 = SK.GetEntity(gs.face[0])->FaceGetNormalNum();
|
||||
Printf(true, " planeA normal = " PT_AS_NUM, CO(n0));
|
||||
Vector p0 = SK.GetEntity(gs.face[0])->FaceGetPointNum();
|
||||
Printf(false, " planeA thru = " PT_AS_STR, COSTR(SK.GetEntity(gs.face[0]), p0));
|
||||
|
||||
Vector n1 = SK.GetEntity(gs.face[1])->FaceGetNormalNum();
|
||||
Printf(true, " planeB normal = " PT_AS_NUM, CO(n1));
|
||||
Vector p1 = SK.GetEntity(gs.face[1])->FaceGetPointNum();
|
||||
Printf(false, " planeB thru = " PT_AS_STR, COSTR(SK.GetEntity(gs.face[1]), p1));
|
||||
|
||||
Vector n2 = SK.GetEntity(gs.face[2])->FaceGetNormalNum();
|
||||
Printf(true, " planeC normal = " PT_AS_NUM, CO(n2));
|
||||
Vector p2 = SK.GetEntity(gs.face[2])->FaceGetPointNum();
|
||||
Printf(false, " planeB thru = " PT_AS_STR, COSTR(SK.GetEntity(gs.face[2]), p2));
|
||||
|
||||
// We should probably compute and show the intersection point if there is onw.
|
||||
|
||||
} else if(gs.n == 0 && gs.constraints == 1) {
|
||||
Constraint *c = SK.GetConstraint(gs.constraint[0]);
|
||||
const std::string &desc = c->DescriptionString().c_str();
|
||||
|
|
|
@ -185,7 +185,7 @@ void GraphicsWindow::MakeSelected(Selection *stog) {
|
|||
|
||||
if(stog->entity.v != 0 && SK.GetEntity(stog->entity)->IsFace()) {
|
||||
// In the interest of speed for the triangle drawing code,
|
||||
// only two faces may be selected at a time.
|
||||
// only three faces may be selected at a time.
|
||||
int c = 0;
|
||||
Selection *s;
|
||||
selection.ClearTags();
|
||||
|
@ -193,7 +193,7 @@ void GraphicsWindow::MakeSelected(Selection *stog) {
|
|||
hEntity he = s->entity;
|
||||
if(he.v != 0 && SK.GetEntity(he)->IsFace()) {
|
||||
c++;
|
||||
if(c >= 2) s->tag = 1;
|
||||
if(c >= 3) s->tag = 1;
|
||||
}
|
||||
}
|
||||
selection.RemoveTagged();
|
||||
|
|
Loading…
Reference in New Issue