Hide menu
Loading...
Searching...
No Matches
Part representations

Table of Contents

Representations are associated with a ModelData::Part and define its ModelData::Shape .

The following representations are supported:

  • Boundary Representation (B-Rep) – exact geometrical representation.

Each part may have zero or one Boundary Representation.

Boundary Representation

B-Rep includes a topological model that describes hierarchy and connectivity information between elements in the 3D model (from vertices to solid), as well as reference to underlying geometries (points, curves and surfaces):

Topology and Geometry

Topological entities subsclass the base class ModelData::Shape , curves subclass the class Geom::Curve and surfaces inherit from the base class Geom::Surface .

Manufacturing Toolkit supports next types of bodies: ModelData::SolidBody , ModelData::SheetBody and ModelData::WireframeBody . Body belongs to B-Rep itself.

B-Rep bodies

Supported geometries include:

  • Analytical representations (lines, circles, ellipses, planar, spherical, cylindrical and other elementary surfaces);
  • Extrusion and rotation surfaces;
  • Offset curves and surfaces;
  • Bezier and NURBS curves and surfaces.

Each topological entity can be explored for its children. Vertices, edges, faces can be interrogated for associated geometries.

ModelData::Wire aWire = ...;
ModelData::ShapeIterator anIt (aWire);
while (anIt.HasNext()) {
const ModelData::Shape& anEdgeShape = anIt.Next();
const ModelData::Edge& anEdge = Edge::Cast (anEdgeShape);
double aFirst, aLast; //edge's curve range
Geom::Curve aCurve = anEdge.Curve (aFirst, aLast);
}
static const Edge & Cast(const Shape &theShape)
Casts a base class object to Edge.
Definition Edge.cxx:705

Curves and surfaces can be interrogated for their defining parameters (e.g. axis for a circle, or control points for a NURBS curve):

Geon::Circle aCircle = ...;
const Geom::Axis3d& anAxis = aCircle.Position();
Geom::Point aPoint = aCircle.Value (M_PI_2);