| 1 | -- Created on: 1998-01-17 |
| 2 | -- Created by: Julia GERASIMOVA |
| 3 | -- Copyright (c) 1998-1999 Matra Datavision |
| 4 | -- Copyright (c) 1999-2014 OPEN CASCADE SAS |
| 5 | -- |
| 6 | -- This file is part of Open CASCADE Technology software library. |
| 7 | -- |
| 8 | -- This library is free software; you can redistribute it and/or modify it under |
| 9 | -- the terms of the GNU Lesser General Public License version 2.1 as published |
| 10 | -- by the Free Software Foundation, with special exception defined in the file |
| 11 | -- OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT |
| 12 | -- distribution for complete text of the license and disclaimer of any warranty. |
| 13 | -- |
| 14 | -- Alternatively, this file may be used under the terms of Open CASCADE |
| 15 | -- commercial license or contractual agreement. |
| 16 | |
| 17 | class EqualRadiusRelation from AIS inherits Relation from AIS |
| 18 | |
| 19 | ---Purpose: |
| 20 | |
| 21 | uses |
| 22 | Edge from TopoDS, |
| 23 | Plane from Geom, |
| 24 | PresentationManager3d from PrsMgr, |
| 25 | Presentation from Prs3d, |
| 26 | Projector from Prs3d, |
| 27 | Transformation from Geom, |
| 28 | Selection from SelectMgr, |
| 29 | Pnt from gp |
| 30 | |
| 31 | is |
| 32 | Create( aFirstEdge : Edge from TopoDS; |
| 33 | aSecondEdge : Edge from TopoDS; |
| 34 | aPlane : Plane from Geom ) |
| 35 | ---Purpose: Creates equal relation of two arc's radiuses. |
| 36 | -- If one of edges is not in the given plane, |
| 37 | -- the presentation method projects it onto the plane. |
| 38 | returns EqualRadiusRelation from AIS; |
| 39 | |
| 40 | -- Methods from PresentableObject |
| 41 | |
| 42 | Compute( me : mutable; |
| 43 | aPresentationManager: PresentationManager3d from PrsMgr; |
| 44 | aPresentation : Presentation from Prs3d; |
| 45 | aMode : Integer from Standard= 0 ) |
| 46 | is redefined static private; |
| 47 | |
| 48 | Compute( me : mutable; |
| 49 | aProjector : Projector from Prs3d; |
| 50 | aPresentation : Presentation from Prs3d ) |
| 51 | is redefined static private; |
| 52 | |
| 53 | Compute(me : mutable; |
| 54 | aProjector : Projector from Prs3d; |
| 55 | aTrsf : Transformation from Geom; |
| 56 | aPresentation : Presentation from Prs3d) |
| 57 | is redefined; |
| 58 | ---Purpose: computes the presentation according to a point of view |
| 59 | -- given by <aProjector>. |
| 60 | -- To be Used when the associated degenerated Presentations |
| 61 | -- have been transformed by <aTrsf> which is not a Pure |
| 62 | -- Translation. The HLR Prs can't be deducted automatically |
| 63 | -- WARNING :<aTrsf> must be applied |
| 64 | -- to the object to display before computation !!! |
| 65 | |
| 66 | -- Methods from SelectableObject |
| 67 | |
| 68 | ComputeSelection( me : mutable; |
| 69 | aSelection : Selection from SelectMgr; |
| 70 | aMode : Integer from Standard) |
| 71 | is private; |
| 72 | |
| 73 | ComputeRadiusPosition(me: mutable) is private; |
| 74 | |
| 75 | fields |
| 76 | |
| 77 | myFirstCenter : Pnt from gp; |
| 78 | mySecondCenter : Pnt from gp; |
| 79 | myFirstPoint : Pnt from gp; |
| 80 | mySecondPoint : Pnt from gp; |
| 81 | |
| 82 | end EqualRadiusRelation; |