1 // Copyright (C) 2007-2022 CEA/DEN, EDF R&D, OPEN CASCADE
3 // Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
4 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
6 // This library is free software; you can redistribute it and/or
7 // modify it under the terms of the GNU Lesser General Public
8 // License as published by the Free Software Foundation; either
9 // version 2.1 of the License, or (at your option) any later version.
11 // This library is distributed in the hope that it will be useful,
12 // but WITHOUT ANY WARRANTY; without even the implied warranty of
13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 // Lesser General Public License for more details.
16 // You should have received a copy of the GNU Lesser General Public
17 // License along with this library; if not, write to the Free Software
18 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
20 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
23 // GEOM OBJECT : interactive object for Geometry entities visualization
24 // File : GEOM_OCCReader.h
25 // Author : Christophe ATTANASIO
28 #include "GEOM_OCCReader.h"
30 #include <GEOMUtils_Hatcher.hxx>
32 #include <Basics_OCCTVersion.hxx>
35 #include <vtkPoints.h>
36 #include <vtkCellArray.h>
38 #include <vtkObjectFactory.h>
39 #include <vtkPolyData.h>
40 #include <vtkInformation.h>
41 #include <vtkInformationVector.h>
43 // OpenCASCADE Includes
44 #if OCC_VERSION_LARGE < 0x07070000
45 #include <Adaptor3d_HCurve.hxx>
47 #include <Adaptor3d_Curve.hxx>
49 #include <Poly_Triangulation.hxx>
50 #include <Poly_Polygon3D.hxx>
51 #include <Poly_PolygonOnTriangulation.hxx>
53 #include <TopoDS_Face.hxx>
54 #include <TopoDS_Edge.hxx>
55 #include <Precision.hxx>
56 #include <BRep_Tool.hxx>
57 #include <TColStd_Array1OfInteger.hxx>
58 #include <TColStd_Array1OfReal.hxx>
60 #include "utilities.h"
63 static Standard_Integer lastVTKpoint = 0;
64 static Standard_Integer PlotCount = 0;
65 static Standard_Real IsoRatio = 1.001;
66 static Standard_Integer MaxPlotCount = 5;
68 //=======================================================================
71 //=======================================================================
73 GEOM_OCCReader* GEOM_OCCReader::New()
75 vtkObject* ret = vtkObjectFactory::CreateInstance("GEOM_OCCReader");
77 return (GEOM_OCCReader*)ret;
79 return new GEOM_OCCReader;
82 //=======================================================================
83 // Function : GEOM_OCCReader
85 //=======================================================================
87 GEOM_OCCReader::GEOM_OCCReader()
89 //this->myShape = NULL;
91 this->forced = Standard_False;
92 this->discretiso = 15;
95 //=======================================================================
96 // Function : ~GEOM_OCCReader
98 //=======================================================================
100 GEOM_OCCReader::~GEOM_OCCReader()
105 //=======================================================================
106 // Function : RequestData
108 //=======================================================================
110 int GEOM_OCCReader::RequestData(vtkInformation *vtkNotUsed(request),
111 vtkInformationVector **/*inputVector*/,
112 vtkInformationVector *outputVector)
114 vtkInformation *outInfo = outputVector->GetInformationObject(0);
115 vtkPolyData *output = vtkPolyData::SafeDownCast(
116 outInfo->Get(vtkDataObject::DATA_OBJECT()));
118 vtkPoints* Pts = NULL;
119 vtkCellArray* Cells = NULL;
120 TopLoc_Location aLoc;
123 Pts = vtkPoints::New();
124 Cells = vtkCellArray::New();
126 //Compute number of triangles and points
127 Standard_Integer nbpoly=0,nbpts=0;
132 if(myShape.ShapeType() == TopAbs_FACE) {
134 const TopoDS_Face& aFace = TopoDS::Face(myShape);
135 Handle(Poly_Triangulation) aPoly = BRep_Tool::Triangulation(aFace,aLoc);
142 nbpts = aPoly->NbNodes();
143 nbpoly = aPoly->NbTriangles();
145 Pts->SetNumberOfPoints(nbpts);
146 Cells->Allocate(Cells->EstimateSize(nbpoly,3));
157 ComputeWireframe(Pts,Cells);
158 output->SetPoints(Pts);
159 output->SetLines(Cells);
163 if(myShape.ShapeType() == TopAbs_FACE) {
164 ComputeShading(Pts,Cells);
166 output->SetPoints(Pts);
167 output->SetPolys(Cells);
176 //=======================================================================
177 // Function : ComputeWireframe
178 // Purpose : Compute the shape in CAD wireframe mode
179 //=======================================================================
181 void GEOM_OCCReader::ComputeWireframe(vtkPoints* Pts,vtkCellArray* Cells){
183 // Check the type of the shape:
184 if(myShape.ShapeType() == TopAbs_FACE) {
186 TransferFaceWData(TopoDS::Face(myShape),Pts,Cells);
187 } else if(myShape.ShapeType() == TopAbs_EDGE) {
189 TransferEdgeWData(TopoDS::Edge(myShape),Pts,Cells);
191 if(myShape.ShapeType() == TopAbs_VERTEX) {
193 TransferVertexWData(TopoDS::Vertex(myShape),Pts,Cells);
198 //=======================================================================
199 // Function : TransferFaceWData
200 // Purpose : Transfer wireframe data for FACE
201 //=======================================================================
203 void GEOM_OCCReader::TransferFaceWData(const TopoDS_Face& aFace,
207 TopoDS_Face aCopyFace = aFace;
208 aCopyFace.Orientation (TopAbs_FORWARD);
209 createISO(aCopyFace,1,Pts,Cells);
212 //=======================================================================
213 // Function : createISO
214 // Purpose : Create ISO for Face Wireframe representation
215 //=======================================================================
217 void GEOM_OCCReader::createISO (const TopoDS_Face &TopologicalFace,
218 const Standard_Integer NbIsos,
222 GEOMUtils::Hatcher aHatcher(TopologicalFace);
224 aHatcher.Init(NbIsos);
227 if (aHatcher.IsDone()) {
228 // Push iso lines in vtk kernel
229 Standard_Integer pt_start_idx = 0;
231 createIsos(aHatcher, Standard_True, pt_start_idx, Pts, Cell);
232 createIsos(aHatcher, Standard_False, pt_start_idx, Pts, Cell);
236 //=======================================================================
237 // Function : createIsos
238 // Purpose : Create isolines obtained from hatcher.
239 //=======================================================================
240 void GEOM_OCCReader::createIsos(const GEOMUtils::Hatcher &theHatcher,
241 const Standard_Boolean IsUIso,
242 Standard_Integer &pt_start_idx,
246 // Push iso lines in vtk kernel
247 Handle(TColStd_HArray1OfInteger) anIndices;
248 Handle(TColStd_HArray1OfReal) aParams;
252 anIndices = theHatcher.GetUIndices();
253 aParams = theHatcher.GetUParams();
256 anIndices = theHatcher.GetVIndices();
257 aParams = theHatcher.GetVParams();
260 if (anIndices.IsNull() || aParams.IsNull()) {
262 MESSAGE("GEOMUtils_Hatcher: null U-isoline indices");
264 MESSAGE("GEOMUtils_Hatcher: null V-isoline indices");
267 const GeomAbs_IsoType aType = (IsUIso ? GeomAbs_IsoU : GeomAbs_IsoV);
268 Standard_Integer anIsoInd = anIndices->Lower();
270 for (; anIsoInd <= anIndices->Upper(); anIsoInd++) {
271 const Standard_Integer aHatchingIndex = anIndices->Value(anIsoInd);
273 if (aHatchingIndex != 0) {
274 const Standard_Real aParam = aParams->Value(anIsoInd);
275 const Standard_Integer aNbDomains =
276 theHatcher.GetNbDomains(aHatchingIndex);
278 if (aNbDomains < 0) {
280 MESSAGE("GEOMUtils_Hatcher: U iso of parameter: "<<aParam);
282 MESSAGE("GEOMUtils_Hatcher: V iso of parameter: "<<aParam);
285 switch (theHatcher.GetHatcher().Status (aHatchingIndex)) {
286 case HatchGen_NoProblem :
287 MESSAGE("No Problem") ; break ;
288 case HatchGen_TrimFailure :
289 MESSAGE("Trim Failure") ; break ;
290 case HatchGen_TransitionFailure :
291 MESSAGE("Transition Failure") ; break ;
292 case HatchGen_IncoherentParity :
293 MESSAGE("Incoherent Parity") ; break ;
294 case HatchGen_IncompatibleStates :
295 MESSAGE("Incompatible States") ; break ;
298 Standard_Integer anIDom = 1;
302 for (; anIDom <= aNbDomains; anIDom++) {
303 if (theHatcher.GetDomain(aHatchingIndex, anIDom, aV1, aV2)) {
304 DrawIso(aType, aParam, aV1, aV2, Pts, Cell,pt_start_idx);
313 //=======================================================================
315 // Purpose : Init VTK ISO PLOT
316 //=======================================================================
317 void GEOM_OCCReader::MoveTo(gp_Pnt P,
322 coord[0] = P.X(); coord[1] = P.Y(); coord[2] = P.Z();
323 lastVTKpoint = Pts->InsertNextPoint(coord);
327 //=======================================================================
329 // Purpose : Plot point in VTK
330 //=======================================================================
331 void GEOM_OCCReader::DrawTo(gp_Pnt P,
336 coord[0] = P.X(); coord[1] = P.Y(); coord[2] = P.Z();
337 Standard_Integer NewVTKpoint = Pts->InsertNextPoint(coord);
340 pts[0] = lastVTKpoint;
341 pts[1] = NewVTKpoint;
343 Cells->InsertNextCell(2,pts);
345 lastVTKpoint = NewVTKpoint;
349 //=======================================================================
350 // Function : DrawIso
351 // Purpose : Draw an iso on vtk
352 //=======================================================================
353 void GEOM_OCCReader::DrawIso(GeomAbs_IsoType T,
359 Standard_Integer& /*startidx*/)
362 Standard_Boolean halt = Standard_False;
363 Standard_Integer j,myDiscret = discretiso;
364 Standard_Real U1,U2,V1,V2,stepU=0.,stepV=0.;
368 const Handle(Geom_Surface)& S = BRep_Tool::Surface(TopoDS::Face(myShape),l);
370 BRepAdaptor_Surface S(TopoDS::Face(myShape),Standard_False);
372 GeomAbs_SurfaceType SurfType = S.GetType();
374 GeomAbs_CurveType CurvType = GeomAbs_OtherCurve;
376 Standard_Integer Intrv, nbIntv;
377 Standard_Integer nbUIntv = S.NbUIntervals(GeomAbs_CN);
378 Standard_Integer nbVIntv = S.NbVIntervals(GeomAbs_CN);
379 TColStd_Array1OfReal TI(1,Max(nbUIntv, nbVIntv)+1);
382 if (T == GeomAbs_IsoU) {
383 S.VIntervals(TI, GeomAbs_CN);
392 S.UIntervals(TI, GeomAbs_CN);
404 for (Intrv = 1; Intrv <= nbIntv; Intrv++) {
406 if (TI(Intrv) <= T1 && TI(Intrv + 1) <= T1)
408 if (TI(Intrv) >= T2 && TI(Intrv + 1) >= T2)
410 if (T == GeomAbs_IsoU) {
411 V1 = Max(T1, TI(Intrv));
412 V2 = Min(T2, TI(Intrv + 1));
413 stepV = (V2 - V1) / myDiscret;
416 U1 = Max(T1, TI(Intrv));
417 U2 = Min(T2, TI(Intrv + 1));
418 stepU = (U2 - U1) / myDiscret;
422 //-------------GeomAbs_Plane---------------
425 //----GeomAbs_Cylinder GeomAbs_Cone------
426 case GeomAbs_Cylinder :
428 if (T == GeomAbs_IsoV) {
429 for (j = 1; j < myDiscret; j++) {
437 //---GeomAbs_Sphere GeomAbs_Torus--------
438 //GeomAbs_BezierSurface GeomAbs_BezierSurface
439 case GeomAbs_Sphere :
441 case GeomAbs_OffsetSurface :
442 case GeomAbs_OtherSurface :
443 for (j = 1; j < myDiscret; j++) {
450 //-------------GeomAbs_BSplineSurface------
451 case GeomAbs_BezierSurface :
452 case GeomAbs_BSplineSurface :
453 for (j = 1; j <= myDiscret/2; j++) {
457 PlotIso ( S, T, U1, V1, (T == GeomAbs_IsoV) ? stepU*2. : stepV*2., halt, Pts, Cells);
462 //-------------GeomAbs_SurfaceOfExtrusion--
463 //-------------GeomAbs_SurfaceOfRevolution-
464 case GeomAbs_SurfaceOfExtrusion :
465 case GeomAbs_SurfaceOfRevolution :
466 if ((T == GeomAbs_IsoV && SurfType == GeomAbs_SurfaceOfRevolution) ||
467 (T == GeomAbs_IsoU && SurfType == GeomAbs_SurfaceOfExtrusion)) {
468 if (SurfType == GeomAbs_SurfaceOfExtrusion) break;
469 for (j = 1; j < myDiscret; j++) {
476 CurvType = (S.BasisCurve())->GetType();
480 case GeomAbs_Circle :
481 case GeomAbs_Ellipse :
482 for (j = 1; j < myDiscret; j++) {
489 case GeomAbs_Parabola :
490 case GeomAbs_Hyperbola :
491 case GeomAbs_BezierCurve :
492 case GeomAbs_BSplineCurve :
493 case GeomAbs_OffsetCurve:
494 case GeomAbs_OtherCurve :
495 for (j = 1; j <= myDiscret/2; j++) {
499 PlotIso ( S, T, U1, V1,(T == GeomAbs_IsoV) ? stepU*2. : stepV*2., halt, Pts, Cells);
513 //=======================================================================
514 // Function : PlotIso
515 // Purpose : Plot iso for other surface
516 //=======================================================================
518 void GEOM_OCCReader::PlotIso (BRepAdaptor_Surface& S,
523 Standard_Boolean& halt,
532 if (T == GeomAbs_IsoU) {
534 S.D0(U, V + Step/2., Pm);
535 S.D0(U, V + Step, Pr);
538 S.D0(U + Step/2., V, Pm);
539 S.D0(U + Step, V, Pr);
542 if (PlotCount > MaxPlotCount) {
543 DrawTo(Pr,Pts,Cells);
547 if (Pm.Distance(Pl) + Pm.Distance(Pr) <= IsoRatio*Pl.Distance(Pr)) {
548 DrawTo(Pr,Pts,Cells);
550 if (T == GeomAbs_IsoU) {
551 PlotIso ( S, T, U, V, Step/2, halt, Pts, Cells);
552 Standard_Real aLocalV = V + Step/2 ;
553 PlotIso ( S, T, U, aLocalV , Step/2, halt, Pts, Cells);
555 PlotIso ( S, T, U, V, Step/2, halt, Pts, Cells);
556 Standard_Real aLocalU = U + Step/2 ;
557 PlotIso ( S, T, aLocalU , V, Step/2, halt, Pts, Cells);
561 //=======================================================================
562 // Function : TransferEdgeWData
563 // Purpose : Transfer wireframe data for EDGE
564 //=======================================================================
566 void GEOM_OCCReader::TransferEdgeWData(const TopoDS_Edge& aEdge,
570 Handle(Poly_PolygonOnTriangulation) aEdgePoly;
571 Standard_Integer i = 1;
572 Handle(Poly_Triangulation) T;
573 TopLoc_Location aEdgeLoc;
574 BRep_Tool::PolygonOnTriangulation(aEdge, aEdgePoly, T, aEdgeLoc, i);
576 Handle(Poly_Polygon3D) P;
577 if(aEdgePoly.IsNull()) {
578 P = BRep_Tool::Polygon3D(aEdge, aEdgeLoc);
581 if(P.IsNull() && aEdgePoly.IsNull())
588 Standard_Boolean isidtrsf = true;
589 if(!aEdgeLoc.IsIdentity()) {
591 edgeTransf = aEdgeLoc.Transformation();
596 Standard_Integer nbnodes;
597 if (aEdgePoly.IsNull()) {
598 nbnodes = P->NbNodes();
599 const TColgp_Array1OfPnt& theNodesP = P->Nodes();
602 aP2 = theNodesP(nbnodes);
607 for(int j=1;j<nbnodes;j++) {
608 gp_Pnt pt1 = theNodesP(j);
609 gp_Pnt pt2 = theNodesP(j+1);
612 // apply edge transformation
613 pt1.Transform(edgeTransf);
614 pt2.Transform(edgeTransf);
618 coord[0] = pt1.X(); coord[1] = pt1.Y(); coord[2] = pt1.Z();
619 pts[0] = Pts->InsertNextPoint(coord);
622 coord[0] = pt2.X(); coord[1] = pt2.Y(); coord[2] = pt2.Z();
623 pts[1] = Pts->InsertNextPoint(coord);
625 // insert line (pt1,pt2)
626 Cells->InsertNextCell(2,pts);
629 nbnodes = aEdgePoly->NbNodes();
630 const TColStd_Array1OfInteger& Nodesidx = aEdgePoly->Nodes();
633 aP2 = T->Node(nbnodes);
638 for(int j=1;j<nbnodes;j++) {
639 Standard_Integer id1 = Nodesidx(j);
640 Standard_Integer id2 = Nodesidx(j+1);
642 gp_Pnt pt1 = T->Node(id1);
643 gp_Pnt pt2 = T->Node(id2);
646 // apply edge transformation
647 pt1.Transform(edgeTransf);
648 pt2.Transform(edgeTransf);
652 coord[0] = pt1.X(); coord[1] = pt1.Y(); coord[2] = pt1.Z();
653 pts[0] = Pts->InsertNextPoint(coord);
656 coord[0] = pt2.X(); coord[1] = pt2.Y(); coord[2] = pt2.Z();
657 pts[1] = Pts->InsertNextPoint(coord);
659 // insert line (pt1,pt2)
660 Cells->InsertNextCell(2,pts);
664 // vector representation has an arrow on its end
668 // apply edge transformation
669 aP1.Transform(edgeTransf);
670 aP2.Transform(edgeTransf);
674 gp_Vec aDirVec (aP1, aP2);
675 Standard_Real aDist = aDirVec.Magnitude();
676 if (aDist < gp::Resolution()) return;
677 gp_Dir aDirection (aDirVec);
679 Standard_Real anAngle = M_PI/180. * 5.;
680 Standard_Real aLength = aDist/10.;
682 Standard_Real dx,dy,dz;
683 aDirection.Coord(dx,dy,dz);
685 // Pointe de la fleche
686 Standard_Real xo,yo,zo;
689 // Centre du cercle base de la fleche
690 gp_XYZ aPc = aP2.XYZ() - aDirection.XYZ() * aLength;
692 // Construction d'un repere i,j pour le cercle
694 if (Abs(dx) <= Abs(dy) && Abs(dx) <= Abs(dz)) aDirN = gp::DX();
695 else if (Abs(dy) <= Abs(dz) && Abs(dy) <= Abs(dx)) aDirN = gp::DY();
696 else aDirN = gp::DZ();
698 gp_Dir aDirI = aDirection ^ aDirN;
699 gp_Dir aDirJ = aDirection ^ aDirI;
701 // Add points and segments, composing the arrow
702 Standard_Real cosinus, sinus, Tg = tan(anAngle);
705 coord[0] = xo; coord[1] = yo; coord[2] = zo;
707 int ptLoc = Pts->InsertNextPoint(coord);
715 for (int i = 1; i <= NbPoints; i++, ptPrev = ptCur)
717 cosinus = cos(2. * M_PI / NbPoints * (i-1));
718 sinus = sin(2. * M_PI / NbPoints * (i-1));
720 gp_XYZ aP = aPc + (aDirI.XYZ() * cosinus + aDirJ.XYZ() * sinus) * aLength * Tg;
726 ptCur = Pts->InsertNextPoint(coord);
733 // insert line (ptCur,ptPrev)
735 Cells->InsertNextCell(2,pts);
738 // insert line (ptCur,ptLoc)
740 Cells->InsertNextCell(2,pts);
743 // insert line (ptCur,ptFirst)
746 Cells->InsertNextCell(2,pts);
750 /* Standard_Integer nbnodes = aEdgePoly->NbNodes();
751 const TColStd_Array1OfInteger& Nodesidx = aEdgePoly->Nodes();
752 const TColgp_Array1OfPnt& theNodes = T->Nodes();
759 for(i=1;i<=nbnodes;i++) {
760 Standard_Integer id = Nodesidx(i);
761 gp_Pnt pt = theNodes(id);
764 if(!isidtrsf) pt.Transform(edgeTransf);
766 coord[0] = pt.X(); coord[1] = pt.Y(); coord[2] = pt.Z();
768 Pts->SetPoint(id-1,coord);
773 for(i=1;i<nbnodes;i++) {
775 Standard_Integer id1 = Nodesidx(i);
776 Standard_Integer id2 = Nodesidx(i+1);
779 pts[0] = id1-1; pts[1] = id2-1;
781 // insert line (pt1,pt2)
782 Cells->InsertNextCell(2,pts);
788 //=======================================================================
789 // Function : TransferVertexWData
790 // Purpose : Transfer wireframe data for VERTEX
791 //=======================================================================
793 void GEOM_OCCReader::TransferVertexWData(const TopoDS_Vertex& /*aVertex*/,
797 #define ZERO_COORD coord[0] = coord[1] = coord[2] = 0.0
799 // gp_Pnt P = BRep_Tool::Pnt( aVertex ); ??????????????????????????
800 float delta = 1, coord[3];
803 ZERO_COORD; coord[0] = +delta;
804 pts[0] = Pts->InsertNextPoint(coord);
806 pts[1] = Pts->InsertNextPoint(coord);
807 // insert line (pt1,pt2)
808 Cells->InsertNextCell(2,pts);
810 ZERO_COORD; coord[1] = +delta;
811 pts[0] = Pts->InsertNextPoint(coord);
813 pts[1] = Pts->InsertNextPoint(coord);
814 // insert line (pt1,pt2)
815 Cells->InsertNextCell(2,pts);
817 ZERO_COORD; coord[2] = +delta;
818 pts[0] = Pts->InsertNextPoint(coord);
820 pts[1] = Pts->InsertNextPoint(coord);
821 // insert line (pt1,pt2)
822 Cells->InsertNextCell(2,pts);
827 //=======================================================================
828 // Function : TransferEdgeSData(
829 // Purpose : Transfer shading data for EDGE
830 //=======================================================================
832 void GEOM_OCCReader::TransferEdgeSData(const TopoDS_Edge& /*aFace*/,
834 vtkCellArray* /*Cells*/)
839 //=======================================================================
840 // Function : TransferFaceSData
841 // Purpose : Transfer shading data for FACE
842 //=======================================================================
843 void GEOM_OCCReader::TransferFaceSData(const TopoDS_Face& aFace,
845 vtkCellArray* Cells) {
847 TopLoc_Location aLoc;
848 Handle(Poly_Triangulation) aPoly = BRep_Tool::Triangulation(aFace,aLoc);
849 if(aPoly.IsNull()) return;
853 Standard_Boolean identity = true;
854 if(!aLoc.IsIdentity()) {
856 myTransf = aLoc.Transformation();
859 Standard_Integer nbNodesInFace = aPoly->NbNodes();
860 Standard_Integer nbTriInFace = aPoly->NbTriangles();
863 for(i=1;i<=nbNodesInFace;i++) {
864 gp_Pnt P = aPoly->Node(i);
866 if(!identity) P.Transform(myTransf);
867 coord[0] = P.X(); coord[1] = P.Y(); coord[2] = P.Z();
868 Pts->SetPoint(i-1,coord);
871 for(i=1;i<=nbTriInFace;i++) {
874 Standard_Integer N1,N2,N3;
875 aPoly->Triangle(i).Get(N1,N2,N3);
878 pts[0] = N1-1; pts[1] = N2-1; pts[2] = N3-1;
879 Cells->InsertNextCell(3,pts);
885 //=======================================================================
886 // Function : ComputeShading
887 // Purpose : Compute the shape in shading mode
888 //=======================================================================
889 void GEOM_OCCReader::ComputeShading(vtkPoints* Pts,vtkCellArray* Cells){
891 // Check the type of the shape:
892 if(myShape.ShapeType() == TopAbs_FACE) {
894 TransferFaceSData(TopoDS::Face(myShape),Pts,Cells);
897 if(myShape.ShapeType() == TopAbs_EDGE) {
899 TransferEdgeSData(TopoDS::Edge(myShape),Pts,Cells);
908 //=======================================================================
910 // Purpose : Set parameters
911 //=======================================================================
912 void GEOM_OCCReader::setDisplayMode(int thenewmode) {
916 void GEOM_OCCReader::setTopo(const TopoDS_Shape& aShape, bool isVector) {
918 myIsVector = isVector;
921 void GEOM_OCCReader::setForceUpdate(Standard_Boolean bol) {
925 //=======================================================================
927 // Purpose : Get parameters
928 //=======================================================================
929 const TopoDS_Shape& GEOM_OCCReader::getTopo() {
933 int GEOM_OCCReader::getDisplayMode() {