Curve Technologies
There are different technologies for representing curves. All curves implement ICurve_DG.
Standard curves
Straight lines, circles, ellipses can be created either using methods of IStdShape_DG to direcly using calls similar to:
ICircle_DG circle = IObjectGenerator_DGCreate<ICircle_DG>();
BSpline Curves
BSpline Curves are accessed via IBSplineCurve_DG interface. Use IObjectGenerator_DG >
Create("IBSplineCurve_DG") >
IBSplineCurve_DG to create a standalone curve.
Curves, defining geometry of BRep edges, can be accessed via IBRepEdge_DG.GetCurve() > IBSplineCurve_DG.
To add a new BSpline Curve to the scene the curve has to be wrapped into a BRepEdge first (one of methods):
IObjectGenerator_DG >
Create1("IBRepEdge_DG", iCurve) >
IBRepShape_DG
> IModel_DG.AddBRepShape();
See CreateSpline() in Curves sample for an example.
See also: Curves sample, BSpline Curves, Free-form Curves,
Arc Spline Curves.
|