9 #include <TGeoMedium.h>
14 #ifndef _EIC_CAD_FILE_
15 #define _EIC_CAD_FILE_
25 class EicOpenCascadeShape {
28 friend bool EicCadShapeEqual(
const std::pair<unsigned, EicOpenCascadeShape> &lh,
29 const std::pair<unsigned, EicOpenCascadeShape> &rh);
32 EicOpenCascadeShape(): object(0), dimension(0),
solid(0) {};
33 ~EicOpenCascadeShape() {};
35 enum ShapeType {_OCC_PLANE_, _OCC_CYLINDER_, _OCC_CONE_, _OCC_SPHERE_, _OCC_TORUS_};
50 #define _COLOR_DEFAULT_ (kBlue)
119 gp_Pnt *boundarySphereCenter;
120 double boundarySphereRadius;
122 void ConstructDummyStepGeometry();
123 void ConstructStepGeometry();
124 void ConstructIgesGeometry();
126 enum FaceType {FaceTypeAny, FaceTypeFlat, FaceTypeCurved};
128 void HandleThisSolid(
const TopoDS_Shape &
solid, TGeoMedium *medium,
double *
color);
129 void HandleThisSolidWrapper(
const TopoDS_Shape &
solid, TGeoMedium *medium,
double *
color);
131 void DumpAsStlSolid(
const TopoDS_Shape &
solid, TGeoMedium *medium);
134 void DumpAsRootSolid(
const TopoDS_Shape &
solid,
135 std::vector< std::pair<unsigned, EicOpenCascadeShape> > &facets,
136 TGeoMedium *medium,
double *
color);
137 Bool_t elementaryFaceType(TopoDS_Face &face, FaceType fType = FaceTypeAny);
138 Bool_t splitSolidByInfiniteFace(
const TopoDS_Shape &
solid,
const TopoDS_Face &face,
139 EicOpenCascadeShape &cuttingShape,
140 std::vector<TopoDS_Shape> &commonSolids,
141 std::vector<TopoDS_Shape> &cutSolids);
152 void ConstructElmerGeometry();