1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-08-09 13:22:24 +03:00

0027756: Visualization - add Draw() method taking Graphic3d_Group to tools Prs3d_Arrow, Prs3d_Text

and deprecate Draw() methods taking Prs3d_Presentation.
This commit is contained in:
kgv
2016-08-10 10:55:07 +03:00
committed by bugmaster
parent 521b0d7f81
commit 4ad142d9cb
40 changed files with 228 additions and 329 deletions

View File

@@ -232,7 +232,7 @@ void StdPrs_Curve::Add (const Handle (Prs3d_Presentation)& aPresentation,
gp_Pnt Location;
gp_Vec Direction;
aCurve.D1(aCurve.LastParameter(),Location,Direction);
Prs3d_Arrow::Draw (aPresentation,Location,gp_Dir(Direction),
Prs3d_Arrow::Draw (Prs3d_Root::CurrentGroup (aPresentation), Location, gp_Dir(Direction),
aDrawer->ArrowAspect()->Angle(),
aDrawer->ArrowAspect()->Length());
}
@@ -298,7 +298,7 @@ void StdPrs_Curve::Add (const Handle (Prs3d_Presentation)& aPresentation,
gp_Pnt Location;
gp_Vec Direction;
aCurve.D1(aCurve.LastParameter(),Location,Direction);
Prs3d_Arrow::Draw (aPresentation,Location,gp_Dir(Direction),
Prs3d_Arrow::Draw (Prs3d_Root::CurrentGroup (aPresentation), Location, gp_Dir(Direction),
aDrawer->ArrowAspect()->Angle(),
aDrawer->ArrowAspect()->Length());
}

View File

@@ -308,7 +308,7 @@ void StdPrs_DeflectionCurve::Add (const Handle (Prs3d_Presentation)& aPresentati
gp_Pnt Location;
gp_Vec Direction;
aCurve.D1(V2, Location,Direction);
Prs3d_Arrow::Draw (aPresentation,
Prs3d_Arrow::Draw (aGroup,
Location,
gp_Dir(Direction),
aDrawer->ArrowAspect()->Angle(),
@@ -355,7 +355,7 @@ void StdPrs_DeflectionCurve::Add (const Handle (Prs3d_Presentation)& aPresentati
gp_Pnt Location;
gp_Vec Direction;
aCurve.D1(V2, Location,Direction);
Prs3d_Arrow::Draw (aPresentation,
Prs3d_Arrow::Draw (aGroup,
Location,
gp_Dir(Direction),
aDrawer->ArrowAspect()->Angle(),

View File

@@ -96,7 +96,7 @@ void StdPrs_Plane::Add (const Handle (Prs3d_Presentation)& aPresentation,
aPrims->AddVertex(loc);
aPrims->AddVertex(p1);
TheGroup->AddPrimitiveArray(aPrims);
Prs3d_Arrow::Draw(aPresentation,p1,norm,ang,len);
Prs3d_Arrow::Draw (Prs3d_Root::CurrentGroup (aPresentation), p1, norm, ang, len);
}
if (theaspect->DisplayEdgesArrows()) {
Handle(Graphic3d_ArrayOfSegments) aPrims = new Graphic3d_ArrayOfSegments(8);
@@ -105,25 +105,25 @@ void StdPrs_Plane::Add (const Handle (Prs3d_Presentation)& aPresentation,
p1 = loc.Translated(trans);
aPrims->AddVertex(loc);
aPrims->AddVertex(p1);
Prs3d_Arrow::Draw(aPresentation,p1,norm,ang,len);
Prs3d_Arrow::Draw (Prs3d_Root::CurrentGroup (aPresentation), p1, norm, ang, len);
//
thegeom->D0(-Xmax,Ymax,loc);
p1 = loc.Translated(trans);
aPrims->AddVertex(loc);
aPrims->AddVertex(p1);
Prs3d_Arrow::Draw(aPresentation,p1,norm,ang,len);
Prs3d_Arrow::Draw (Prs3d_Root::CurrentGroup (aPresentation), p1, norm, ang, len);
//
thegeom->D0(Xmax,Ymax,loc);
p1 = loc.Translated(trans);
aPrims->AddVertex(loc);
aPrims->AddVertex(p1);
Prs3d_Arrow::Draw(aPresentation,p1,norm,ang,len);
Prs3d_Arrow::Draw (Prs3d_Root::CurrentGroup (aPresentation), p1, norm, ang, len);
//
thegeom->D0(Xmax,-Ymax,loc);
p1 = loc.Translated(trans);
aPrims->AddVertex(loc);
aPrims->AddVertex(p1);
Prs3d_Arrow::Draw(aPresentation,p1,norm,ang,len);
Prs3d_Arrow::Draw (Prs3d_Root::CurrentGroup (aPresentation), p1, norm, ang, len);
//
TheGroup->AddPrimitiveArray(aPrims);
}

View File

@@ -65,7 +65,7 @@ void StdPrs_PoleCurve::Add (const Handle (Prs3d_Presentation)& aPresentation,
gp_Pnt Location;
gp_Vec Direction;
aCurve.D1(aCurve.LastParameter(),Location,Direction);
Prs3d_Arrow::Draw (aPresentation,
Prs3d_Arrow::Draw (Prs3d_Root::CurrentGroup (aPresentation),
Location,
gp_Dir(Direction),
aDrawer->ArrowAspect()->Angle(),