/// <summary> /// takes a single set of vertices and transforms it into a set of faces describing the face joining the 2wires contained inside the set /// </summary> /// <param name="face1">first face</param> /// <param name="face2">second face</param> /// <param name="orientation">orientation of the face</param> /// <returns>a set of faces</returns> public List <Face> ComputeFaces(Face face1, Face face2, TopAbs_Orientation orientation) { // let's compose the face between those 2 faces List <Face> subFaces = new List <Face>(); int limit = Math.Min(face1.pts.Count - 1, face2.pts.Count - 1); for (int i = 0; i < limit; i++) { Face tempFace = new Face(); tempFace.Add(face1.pts[i]); tempFace.Add(face1.pts[i + 1]); tempFace.Add(face2.pts[i + 1]); tempFace.Add(face2.pts[i]); tempFace.orientation = orientation; subFaces.Add(tempFace); } Face temp = new Face(); temp.Add(face1.pts[limit]); temp.Add(face1.pts[0]); temp.Add(face2.pts[0]); temp.Add(face2.pts[limit]); temp.orientation = orientation; subFaces.Add(temp); return(subFaces); }
public Surface(List <gp_Pnt> faces, TopAbs_Orientation orientation) { // note that if u don't have at least 3 points in a row coming from the first face, this gonna be a total mess List <Face> twoFaces = GetFaces(faces); f1 = twoFaces[0]; f2 = twoFaces[1]; this.orientation = orientation; }
/// <summary> /// Initializes this iterator with shape S. /// Note: /// - If cumOri is true, the function composes all sub-shapes with the orientation of S. /// - If cumLoc is true, the function multiplies all sub-shapes by the location of S, i.e. it applies to /// each sub-shape the transformation that is associated with S. /// </summary> /// <param name="S"></param> /// <param name="cumOri"></param> /// <param name="cumLoc"></param> public void Initialize(TopoDS_Shape S, bool cumOri, bool cumLoc) { if (cumLoc) { myLocation = S.Location; } else { myLocation.Identity(); } if (cumOri) { myOrientation = S.Orientation; } else { myOrientation = TopAbs_Orientation.TopAbs_FORWARD; } if (S.IsNull()) { myShapes = new TopoDS_ListIteratorOfListOfShape(); } else { myShapes.Initialize(S.TShape().myShapes); } if (More()) { myShape = myShapes.Value(); myShape.Orientation = TopAbs.Compose(myOrientation, myShape.Orientation); if (!myLocation.IsIdentity()) { myShape.Move(myLocation); } } }
public double ComputeCos(double Tole, gp_Dir Norm, TopAbs_Orientation O, ref bool _isleft) { throw new NotImplementedException(); }
public bool VertexConnectsEdges(TopoDS_Shape V, TopoDS_Shape E1, TopoDS_Shape E2, ref TopAbs_Orientation O1, ref TopAbs_Orientation O2) { throw new NotImplementedException(); }
public TopoDS_Solid Tool(TopoDS_Shape SRef, TopoDS_Face Fac, TopAbs_Orientation Orf) { throw new NotImplementedException(); }
public void SetOrientation(TopoDS_Shape aShape, TopAbs_Orientation Or) { throw new NotImplementedException(); }
public TCollection_AsciiString SPrint(TopAbs_Orientation O) { throw new NotImplementedException(); }
public Face(Face f) { pts = f.pts; orientation = f.orientation; }
public void CurrentEdge(BRepClass_Edge E, ref TopAbs_Orientation Or) { throw new NotImplementedException(); }
public void SetInterference(int LineIndex, TopAbs_Orientation Trans, Geom2d_Curve PCurv1, Geom2d_Curve PCurv2) { throw new NotImplementedException(); }
public void OrientationOnFace2(TopAbs_Orientation Or2) { throw new NotImplementedException(); }
public TopOpeBRepDS_Transition ProcessEdgeTransition(TopOpeBRep_VPointInter P, int Index, TopAbs_Orientation LineOrientation) { throw new NotImplementedException(); }
public void SetOrientation(TopAbs_Orientation Or, bool First) { throw new NotImplementedException(); }
public void LastPCurveOrientation(TopAbs_Orientation O) { throw new NotImplementedException(); }
public Geom_Surface NewSurface(Geom_Surface S, TopAbs_Orientation OriS, gp_Dir Direction, double Angle, gp_Pln NeutralPlane) { throw new NotImplementedException(); }
public Geom_Curve NewCurve(Geom_Curve C, Geom_Surface S, TopAbs_Orientation OriS, gp_Dir Direction, double Angle, gp_Pln NeutralPlane, bool Flag) { throw new NotImplementedException(); }
public void SetTransition(TopAbs_Orientation Trans) { throw new NotImplementedException(); }
public TopOpeBRepDS_Transition ProcessFaceTransition(TopOpeBRep_LineInter L, int Index, TopAbs_Orientation FaceOrientation) { throw new NotImplementedException(); }
public GeomInt_ParameterAndOrientation(double P, TopAbs_Orientation Or1, TopAbs_Orientation Or2) : base() { throw new NotImplementedException(); }
public void Compare(Geom2dAdaptor_Curve E, TopAbs_Orientation Or) { throw new NotImplementedException(); }
public void SetOrientation2(TopAbs_Orientation Or) { throw new NotImplementedException(); }
public void SetDirectingPCurve(TopoDS_Shape aNewFace, TopoDS_Shape aNewEdge, TopoDS_Shape aGenE, TopoDS_Shape aGenV, Sweep_NumShape aDirE, TopAbs_Orientation orien) { throw new NotImplementedException(); }
public void Compare(double Tole, gp_Dir Norm, gp_Dir MaxD, gp_Dir MinD, double MaxCurv, double MinCurv, TopAbs_Orientation S, TopAbs_Orientation O) { throw new NotImplementedException(); }
public Face(List <Pnt> pts, TopAbs_Orientation orientation) { this.pts = pts; this.orientation = orientation; }
public void Compare(double Tole, gp_Dir Norm, TopAbs_Orientation S, TopAbs_Orientation O) { throw new NotImplementedException(); }
public void CurrentEdge(Geom2dAdaptor_Curve E, ref TopAbs_Orientation Or) { throw new NotImplementedException(); }
public TopAbs_State GetAfter(TopAbs_Orientation Tran) { throw new NotImplementedException(); }
public void Compare(BRepClass_Edge E, TopAbs_Orientation Or) { throw new NotImplementedException(); }
public void UpdateReference(double Tole, bool _isInfRef, ref double CosInf, ref double CosSup, TopAbs_Orientation Tran, ref TopAbs_Orientation TranRef) { throw new NotImplementedException(); }