2 #pragma warning(disable : 4251) 26 class TopologicalItem;
28 class LazyFacetedBrepShape;
40 class ShapeAttributes;
43 class IndexedDrawable;
44 struct GeometricInformation;
75 typedef std::shared_ptr<Topo::Shape>
pShape;
77 typedef std::shared_ptr<Topo::MeshShape>
pMesh;
79 typedef std::shared_ptr<Topo::Solid>
pSolid;
80 typedef std::shared_ptr<Topo::Shell>
pShell;
81 typedef std::shared_ptr<Topo::Face>
pFace;
82 typedef std::shared_ptr<Topo::Wire>
pWire;
83 typedef std::shared_ptr<Topo::Edge>
pEdge;
84 typedef std::shared_ptr<Topo::Coedge>
pCoedge;
85 typedef std::shared_ptr<Topo::Vertex>
pVertex;
92 typedef std::shared_ptr<Topo::MeshShape const>
pConstMesh;
125 class AcisElementTool;
129 class AcisVertexTool;
144 class ShapeVariantHandler;
159 static std::map<std::string, ShapeFactory*>
registry;
160 static pShape read(
const std::string& format,
const std::string& data,
int version);
161 static pShape read(
const std::string& format, std::istream& reader);
165 virtual pShape read(
const std::string& data,
int version) = 0;
166 virtual pShape read(std::istream& reader) = 0;
231 public std::enable_shared_from_this<Topo::Shape>
240 virtual ~
Shape(
void);
266 bool hasShapeAttributes()
const;
272 void releaseShapesAttributes();
283 virtual std::shared_ptr<Core::DbgInfo> getDbgInfo()
const;
284 virtual Topo::Shape* clone(
bool deepcopy)
const = 0;
297 virtual void copyFrom(
pConstShape rhs,
bool deepCopy =
true) = 0;
298 virtual bool isSingleFace()
const;
299 virtual bool isSingleWire()
const;
300 virtual bool isSingleEdge()
const;
301 virtual bool isSingleVertex()
const;
302 virtual bool isSolid()
const;
303 virtual bool isClosedSolid()
const;
304 virtual bool isWire()
const;
305 virtual bool isCompound()
const;
306 virtual bool isMesh()
const {
return false; }
308 bool _copy(
const Topo::Shape* rhs,
bool deepCopy =
true);
362 virtual void copyFrom(
pConstMesh rhs,
bool deepCopy =
true) = 0;
370 virtual void getTextureCoordinates(std::vector<Geom::Pnt2d>& textureCoordinates, std::vector<int>& textureIndices)
const = 0;
371 virtual bool calculateDetail(CA_Detail& detail,
const CA_Snap& theSnap) = 0;
372 virtual void getEdges(std::vector<std::pair<Geom::Pnt, Geom::Pnt> >& lines)
const = 0;
373 virtual void getPoints(std::vector<Geom::Pnt>& points)
const = 0;
375 virtual std::vector<Geom::Pnt> getNormals()
const = 0;
376 virtual void getOuterBoundaries(std::vector<Geom::Pnt>& points, std::vector<int>& edges)
const = 0;
377 virtual void getFacePoints(
int index, std::vector<Geom::Pnt>& points)
const = 0;
384 void copyFrom(
pConstShape rhs,
bool deepCopy =
true);
403 virtual void copyFrom(
pConstCompound rhs,
bool deepCopy =
true) = 0;
427 virtual ~
Solid(
void);
430 virtual void copyFrom(
pConstSolid rhs,
bool deepCopy =
true) = 0;
448 public std::enable_shared_from_this<Topo::Shell>
457 virtual ~
Shell(
void);
460 virtual void copyFrom(
pConstShell rhs,
bool deepCopy =
true) = 0;
482 public std::enable_shared_from_this<Topo::Face>
518 public std::enable_shared_from_this<Topo::Wire>
530 friend class Acis::AcisWireTool;
532 virtual void copyFrom(
pConstWire rhs,
bool deepCopy =
true) = 0;
533 virtual int getEdgeCount()
const = 0;
534 virtual pConstEdge getEdgeByIndex(
int idx)
const = 0;
536 virtual bool isLoop()
const;
556 public std::enable_shared_from_this<Topo::Edge>
569 virtual void copyFrom(
pConstEdge rhs,
bool deepCopy =
true) = 0;
580 double _passagePntParam;
581 bool _hasPassagePntParam;
594 public std::enable_shared_from_this<Topo::Coedge>
607 virtual void copyFrom(
pConstCoedge rhs,
bool deepCopy =
true) = 0;
619 double _passagePntParam;
620 bool _hasPassagePntParam;
633 public std::enable_shared_from_this<Topo::Vertex>
646 virtual void copyFrom(
pConstVertex rhs,
bool deepCopy =
true) = 0;
701 void setOkay(
bool ok);
739 std::shared_ptr<Topo::SpecialFaceInfo>
info;
775 #define REGISTER_SHAPE_FACTORY(_factoryName_, _shapeFormat_) Topo::ShapeFactory::registry[_shapeFormat_] = (Topo::ShapeFactory*)new _factoryName_(); std::shared_ptr< Topo::Wire const > pConstWire
Definition: Shape.h:97
virtual bool wasCreatedWithProblems() const
Definition: Shape.h:288
LX_GEOM_EXPORT Point getPoint(const Geom::Pnt &p)
std::shared_ptr< Topo::LazyFacetedBrepShape > pLazyFacetedBrepShape
Definition: Shape.h:76
virtual void setWasCreatedWithProblems(bool)
Definition: Shape.h:289
std::shared_ptr< Topo::Solid const > pConstSolid
Definition: Shape.h:94
std::shared_ptr< Topo::Shape > pShape
Definition: Shape.h:75
std::vector< Geom::Pnt > vertices
Definition: Shape.h:735
std::shared_ptr< Topo::Solid > pSolid
Definition: Shape.h:79
std::shared_ptr< Topo::Compound > pCompound
Definition: Shape.h:78
std::vector< long > wire_coordinateIndices
Definition: Shape.h:340
virtual bool getGeometricInformation(Topo::GeometricInformation &) const
Definition: Shape.h:405
std::vector< int > MeshModel
Definition: Shape.h:354
Wire(ENTITY *ent)
Definition: Shape.h:540
std::shared_ptr< Base::BaseClass > pBaseClass
Definition: Shape.h:73
TopologicalItem(ENTITY *)
Definition: Shape.h:214
Defines a non-persistent 3D Cartesian point.
Definition: Pnt.h:43
ModellingKernel
Definition: Shape.h:195
std::shared_ptr< Topo::Shape const > pConstShape
Definition: Shape.h:90
std::shared_ptr< Topo::Vertex > pVertex
Definition: Shape.h:85
ShapeTessellationMode
Definition: Settings.h:93
CheckShape
Definition: Shape.h:245
std::shared_ptr< Topo::Edge const > pConstEdge
Definition: Shape.h:98
Face(ENTITY *ent)
Definition: Shape.h:502
Edge(ENTITY *ent)
Definition: Shape.h:576
std::unique_ptr< Topo::FacetedShape > uniqueFacetedShape
Definition: Shape.h:115
bool isEqual(const Core::Variant &v1, const Core::Variant &v2, double=1E-06) const
Definition: Shape.h:679
std::unique_ptr< Base::BaseClass > uniqueBaseClass
Definition: Shape.h:102
virtual bool getGeometricInformation(Topo::GeometricInformation &) const
Definition: Shape.h:537
virtual ~TopologicalItem(void)
Definition: Shape.h:186
virtual bool getGeometricInformation(Topo::GeometricInformation &) const
Definition: Shape.h:431
std::shared_ptr< Topo::TopologicalItem const > pConstTopologicalItem
Definition: Shape.h:89
double radius
Definition: Shape.h:727
std::vector< Geom::Pnt > vertices
Definition: Shape.h:748
std::unique_ptr< Topo::Face > uniqueFace
Definition: Shape.h:110
Core::Settings::ShapeTessellationMode mode
Definition: Shape.h:150
virtual void transform(const Geom::Trsf &)
Definition: Shape.h:648
int index
Definition: Shape.h:750
virtual bool getGeometricInformation(Topo::GeometricInformation &) const
Definition: Shape.h:499
std::shared_ptr< Topo::Face const > pConstFace
Definition: Shape.h:96
std::shared_ptr< Topo::LazyFacetedBrepShape const > pConstLazyFacetedBrepShape
Definition: Shape.h:91
pConstTopologicalItem source
Definition: Shape.h:216
std::vector< int > edge_coordinateIndices
Definition: Shape.h:749
std::shared_ptr< Topo::Face > pFace
Definition: Shape.h:81
Geom::Ax2 position
Definition: Shape.h:717
Vertex(ENTITY *ent)
Definition: Shape.h:652
bool isEqual(const Core::Variant &v1, const Core::Variant &v2, double=1E-06) const
Definition: Shape.h:663
Core::Settings::ShapeTessellationQuality quality
Definition: Shape.h:149
A Utf-16 (windows) or ucs4 (unix) encoded string class.
Definition: String.h:23
virtual void transform(const Geom::Trsf &)
Definition: Shape.h:572
virtual void transform(const Geom::Trsf &)
Definition: Shape.h:498
std::shared_ptr< Topo::IndexedDrawable > pIndexedDrawable
Definition: Shape.h:86
double radius
Definition: Shape.h:718
LX_CORE_EXPORT Version & version
std::shared_ptr< Topo::Coedge > pCoedge
Definition: Shape.h:84
std::unique_ptr< Topo::Shape > uniqueShape
Definition: Shape.h:104
void transform(Container container, OutputIt out, BinaryFunction function)
Definition: Algorithms.h:29
std::shared_ptr< Topo::Shell > pShell
Definition: Shape.h:80
std::unique_ptr< Topo::Solid > uniqueSolid
Definition: Shape.h:108
T getValue(bool *ok) const
Definition: Variant.h:325
ShapeType
Definition: Shape.h:46
Definition: ShapeAttributes.h:13
virtual Geom::SurfaceType getSurfaceType() const =0
virtual bool getGeometricInformation(Topo::GeometricInformation &) const
Definition: Shape.h:649
Geom::SurfaceType getSurfaceType() const
Definition: Shape.h:716
std::shared_ptr< Topo::Shell const > pConstShell
Definition: Shape.h:95
std::unique_ptr< Topo::Shell > uniqueShell
Definition: Shape.h:109
std::vector< IndexedFace > faces
Definition: Shape.h:761
std::unique_ptr< Topo::Coedge > uniqueCoedge
Definition: Shape.h:113
std::shared_ptr< Topo::TopologicalItem > pTopologicalItem
Definition: Shape.h:74
BaseClass class and root of the type system.
Definition: Base.h:85
std::shared_ptr< const Geom::BrepData > pConstBrepData
Definition: BrepData.h:31
int getType()
Definition: Shape.h:687
virtual ENTITY * getEntity() const
Definition: Shape.h:209
std::shared_ptr< Geom::IndexedMesh > pIndexedMesh
Definition: IndexedMesh.h:55
std::shared_ptr< Base::BaseClass const > pConstBaseClass
Definition: Shape.h:88
virtual bool getGeometricInformation(Topo::GeometricInformation &) const
Definition: Shape.h:286
OrientationType
Definition: Shape.h:62
std::unique_ptr< Topo::Compound > uniqueCompound
Definition: Shape.h:106
std::shared_ptr< Topo::MeshShape > pMesh
Definition: Shape.h:77
std::vector< int > coordinateIndices
Definition: Shape.h:737
Shell(ENTITY *ent)
Definition: Shape.h:464
MesherType
Definition: Shape.h:188
Definition: Variant.h:151
std::shared_ptr< Topo::Coedge const > pConstCoedge
Definition: Shape.h:99
bool globalMeshMode
Definition: Shape.h:151
std::vector< Geom::Dir > verticesNormals
Definition: Shape.h:736
std::unique_ptr< Topo::Wire > uniqueWire
Definition: Shape.h:111
std::unique_ptr< Topo::Edge > uniqueEdge
Definition: Shape.h:112
std::shared_ptr< Topo::Vertex const > pConstVertex
Definition: Shape.h:100
std::vector< MeshModel > SubMeshModels
Definition: Shape.h:355
Coedge(ENTITY *ent)
Definition: Shape.h:615
Definition: Variant.h:152
std::shared_ptr< Topo::Compound const > pConstCompound
Definition: Shape.h:93
std::vector< Geom::Pnt > face_vertices
Definition: Shape.h:335
SurfaceType
Definition: GeomEnums.h:23
virtual bool getGeometricInformation(Topo::GeometricInformation &) const
Definition: Shape.h:461
std::unique_ptr< Topo::Vertex > uniqueVertex
Definition: Shape.h:114
std::shared_ptr< Topo::Wire > pWire
Definition: Shape.h:82
ShapeTessellationQuality
Definition: Settings.h:84
TopologicalItem()
Definition: Shape.h:185
Definition: IndexedMesh.h:10
MD5 LX_BASE_EXPORT createMD5(const std::string &filename)
virtual void transform(const Geom::Trsf &)
Definition: Shape.h:404
std::shared_ptr< Topo::SpecialFaceInfo > info
Definition: Shape.h:739
int index
Definition: Shape.h:738
std::unique_ptr< Topo::TopologicalItem > uniqueTopologicalItem
Definition: Shape.h:103
double angle
Definition: Shape.h:726
std::shared_ptr< Topo::Shape const > pConstShape
Definition: Variant.h:77
std::vector< Geom::Dir > face_per_vertex_normals
Definition: Shape.h:337
virtual void transform(const Geom::Trsf &)
Definition: Shape.h:535
Solid(ENTITY *ent)
Definition: Shape.h:434
std::shared_ptr< Topo::MeshShape const > pConstMesh
Definition: Shape.h:92
std::vector< long > face_coordinateIndices
Definition: Shape.h:336
Geom::Ax2 position
Definition: Shape.h:725
std::vector< Geom::Pnt > wire_vertices
Definition: Shape.h:339
virtual bool getGeometricInformation(Topo::GeometricInformation &) const
Definition: Shape.h:612
std::unique_ptr< Topo::ShapeSet > uniqueShapeSet
Definition: Shape.h:107
std::set< Core::DocObject * > m_appGeometryBackLinks
Definition: Shape.h:252
int getType()
Definition: Shape.h:671
Base::String fileName
Definition: CoreDocument.h:186
static std::map< std::string, ShapeFactory * > registry
Definition: Shape.h:159
virtual void transform(const Geom::Trsf &)
Definition: Shape.h:610
virtual bool getGeometricInformation(Topo::GeometricInformation &) const
Definition: Shape.h:573
std::unique_ptr< Topo::MeshShape > uniqueMesh
Definition: Shape.h:105
virtual bool getGeometricInformation(Topo::GeometricInformation &) const
Definition: Shape.h:378
Compound(ENTITY *ent)
Definition: Shape.h:408
std::vector< IndexedEdge > edges
Definition: Shape.h:762
Definition: DocObject.h:51
std::shared_ptr< Topo::Shape > pShape
Definition: Variant.h:76
virtual bool isMesh() const
Definition: Shape.h:306
std::shared_ptr< Topo::Edge > pEdge
Definition: Shape.h:83
Geom::SurfaceType getSurfaceType() const
Definition: Shape.h:724