gmsh-TingyuanDoc  0.1
An Open-Source Timing-driven Analytical Mixed-size FPGA Placer
OCCRegion.h
Go to the documentation of this file.
1 // Gmsh - Copyright (C) 1997-2022 C. Geuzaine, J.-F. Remacle
2 //
3 // See the LICENSE.txt file in the Gmsh root directory for license information.
4 // Please report all issues on https://gitlab.onelab.info/gmsh/gmsh/issues.
5 
6 #ifndef OCC_REGION_H
7 #define OCC_REGION_H
8 
9 #include "GmshConfig.h"
10 #include "GRegion.h"
11 
12 #if defined(HAVE_OCC)
13 
14 #include <TopoDS_Solid.hxx>
15 
16 class OCCRegion : public GRegion {
17 private:
18  TopoDS_Solid _s;
19  void _setup();
20 
21 public:
22  OCCRegion(GModel *m, TopoDS_Solid s, int num);
23  virtual ~OCCRegion() {}
24  virtual SBoundingBox3d bounds(bool fast = false);
25  virtual GeomType geomType() const;
26  virtual ModelType getNativeType() const { return OpenCascadeModel; }
27  virtual void *getNativePtr() const { return (void *)&_s; }
28  virtual bool containsPoint(const SPoint3 &pt) const;
29  void writeBREP(const char *filename);
30 };
31 
32 #endif
33 
34 #endif
GEntity::OpenCascadeModel
@ OpenCascadeModel
Definition: GEntity.h:82
SPoint3
Definition: SPoint3.h:14
GEntity::getNativeType
virtual ModelType getNativeType() const
Definition: GEntity.h:268
GEntity::containsPoint
virtual bool containsPoint(const SPoint3 &pt) const
Definition: GEntity.h:265
GEntity::getNativePtr
virtual void * getNativePtr() const
Definition: GEntity.h:271
GRegion.h
GModel
Definition: GModel.h:44
GEntity::geomType
virtual GeomType geomType() const
Definition: GEntity.h:238
GRegion
Definition: GRegion.h:28
SBoundingBox3d
Definition: SBoundingBox3d.h:21
GRegion::bounds
virtual SBoundingBox3d bounds(bool fast=false)
Definition: GRegion.cpp:179