C3D Toolkit  Kernel - 118069, Vision - 2.16.7.1844
action_wireframe.h File Reference

Functions for wire frame creation. More...

#include <wire_frame.h>
#include <wireframe_point.h>

Functions

MbResultType CreateWireFrameFillets (c3d::WireFrameSPtr &wireframe, MbeCopyMode sameEdges, const MbWireFrameFilletsParams &params, c3d::WireFrameSPtr &result)
 Create a filleted wire frame. More...
 
MbResultType CreateNurbsWireFrame (c3d::WireFrameSPtr &wireFrame, MbeCopyMode sameWire, const MbNurbsWireFrameParams &params, c3d::WireFrameSPtr &result)
 Construct a NURBS copy of a wire frame. More...
 
MbResultType CreateTrimmedWireFrame (c3d::WireFrameSPtr &wireframe, MbeCopyMode sameEdges, const MbTrimmedWireFrameParams &params, c3d::WireFrameSPtr &result)
 Create trimmed wire frame. More...
 
MbResultType NearPointProjection (const MbWireFrame &wireFrame, const MbWireFrameProjParams &params, MbWireFrameProjResult &result)
 Find the point projection to the wire frame. More...
 
MbResultType WireFramesIntersect (const MbWireFrame &wireFrame1, const MbWireFrame &wireFrame2, double eps, c3d::WireFramePointsPairsVector &result)
 Calculate intersection points of two wire frames. More...
 
size_t EdgesIntersect (const MbEdge &edge1, const MbEdge &edge2, double eps, c3d::EdgePointsPairsVector &result)
 Calculate intersection points of two edges, taking into account the tolerance of the vertices. More...
 
MbResultType ExtendWireFrame (c3d::WireFrameSPtr &wireframe, MbeCopyMode sameEdges, const MbCurveExtensionParameters3D &params, c3d::WireFrameSPtr &result)
 Extend the wire frame. More...
 
MbResultType CreateOffsetWireFrame (c3d::WireFrameSPtr &wireFrame, MbeCopyMode sameWire, const MbOffsetWireFrameParams &params, c3d::WireFrameSPtr &result)
 Create an offset wire frame. More...
 
MbResultType ProjectionWireFrame (const MbProjectionWireFrameParams &params, MbProjectionWireFrameResults &results)
 Create a projection wireframe. More...
 

Detailed Description

Functions for wire frame creation.

Function Documentation

◆ CreateWireFrameFillets()

MbResultType CreateWireFrameFillets ( c3d::WireFrameSPtr &  wireframe,
MbeCopyMode  sameEdges,
const MbWireFrameFilletsParams &  params,
c3d::WireFrameSPtr &  result 
)

Create a filleted wire frame.

Create a wire frame as fillet of all the edges of a wire frame.
If two edges in wire frame are smoothly connected, the fillet is not created at this joint, the radius is ignored.

Parameters
[in]wireframe- The initial wire frame.
[in]sameEdges- Whether to copy the input wire frame.
[in]params- A fillet parameters.
[out]result- The filleted wire frame.
Returns
Returns operation result code.
Warning
Under development.

◆ CreateNurbsWireFrame()

MbResultType CreateNurbsWireFrame ( c3d::WireFrameSPtr &  wireFrame,
MbeCopyMode  sameWire,
const MbNurbsWireFrameParams &  params,
c3d::WireFrameSPtr &  result 
)

Construct a NURBS copy of a wire frame.

Constructs a wire frame contains NURBS curves which approximates a given wire frame. If it is possible, constructs the accurate curves, perhaps with multiple knots. The number of knots for NURBS is defined depending on the curve.

Parameters
[in]wireFrame- The initial wire frame.
[in]sameWire- Whether to copy the input wire frame.
[in]params- A fillet parameters.
[out]result- he constructed wire frame with NURBS curve or nullptr in a case of failure.
Returns
Returns operation result code.
Warning
Under development.

◆ CreateTrimmedWireFrame()

MbResultType CreateTrimmedWireFrame ( c3d::WireFrameSPtr &  wireframe,
MbeCopyMode  sameEdges,
const MbTrimmedWireFrameParams &  params,
c3d::WireFrameSPtr &  result 
)

Create trimmed wire frame.

Create a wire frame in the form of a connected chain of edges of the original wire frame enclosed between truncation points.
Init wire frame should be normalized.

Parameters
[in]wireframe- The initial wire frame.
[in]sameEdges- Whether to copy the input wire frame.
[in]params- Trimmed parameters.
[out]result- The trimmed wire frame.
Returns
Returns operation result code.
Warning
Under development.

◆ NearPointProjection()

MbResultType NearPointProjection ( const MbWireFrame &  wireFrame,
const MbWireFrameProjParams &  params,
MbWireFrameProjResult &  result 
)

Find the point projection to the wire frame.

Find the nearest projection of a point to the wire frame within the parameter range or its extension. Analogue of MbContour3D::NearPointProjection(). The wire frame must be normalized.

Parameters
[in]wireFrame- Wire frame for searching projection.
[in]params- Operation parameters.
[in]result- Results of the operation.
Returns
Operation result code.

◆ WireFramesIntersect()

MbResultType WireFramesIntersect ( const MbWireFrame &  wireFrame1,
const MbWireFrame &  wireFrame2,
double  eps,
c3d::WireFramePointsPairsVector &  result 
)

Calculate intersection points of two wire frames.

Calculate the parameters of intersection points of two wireframes.

Parameters
[in]wireFrame1- The first wireframe.
[in]wireFrame2- The second wireframe.
[in]eps- The intersection tolerance.
[out]result- The intersection pairs of wire frames.
Returns
Returns the code of the operation result.

◆ EdgesIntersect()

size_t EdgesIntersect ( const MbEdge &  edge1,
const MbEdge &  edge2,
double  eps,
c3d::EdgePointsPairsVector &  result 
)

Calculate intersection points of two edges, taking into account the tolerance of the vertices.

Calculate intersection points of two edges, taking into account the tolerance of the vertices.

Parameters
[in]edge1- The first edge.
[in]edge2- The second edge.
[in]eps- The intersection tolerance of edge's curves.
[out]result- The intersection points of two edges, taking into account the tolerance of the vertices.
Returns
Returns the number of intersection points.

◆ CreateOffsetWireFrame()

MbResultType CreateOffsetWireFrame ( c3d::WireFrameSPtr &  wireFrame,
MbeCopyMode  sameWire,
const MbOffsetWireFrameParams &  params,
c3d::WireFrameSPtr &  result 
)

Create an offset wire frame.

Create an offset wire frame by shifting the base wire frame. When the MbSNameMaker::addParentNamesAttributes = true option is set, the attribute (MbNameAttribute) with the names of parent edges and the corresponding hint (promt) are added to the equidistant edges.

Parameters
[in]wireFrame- The initial wire frame.
[in]sameWire- Whether to copy the input wire frame.
[in]params- Operation parameters.
[out]result- The offset wire frame.
Returns
Returns operation result code.

◆ ProjectionWireFrame()

MbResultType ProjectionWireFrame ( const MbProjectionWireFrameParams &  params,
MbProjectionWireFrameResults &  results 
)

Create a projection wireframe.

Create a normal or vector projection of a set of curves to a solid, set of faces or a surface.

Parameters
[in]params- Operation parameters.
[out]results- Operation results.
Returns
Returns operation result code. Non empty result is returned if at least one of the source curves has been projected successfully. If at least one source curve has not been projected successfully error status (not rt_Success) will be returned.
Warning
Under development.