HM_ExtAPI::CreateCurveSegment()
Straight line geometry object.
Syntax
bool CreateCurveSegment(
HM_EntityGeometryCurve & new_segment,
const HM_Point& start_point,
const HM_Point& end_point
);
Type
HyperMesh Ext API Function
Description
The function creates the curve object of the type HM_ExtAPI::SEGMENT.
The points on the segment can be calculated parametrically as linear interpolation between start and end points
C(t) = S (1 - t) + E t
where segment parameters correspond to the parameters used by the CreateCurveSegment function as summarized in the table below.
Parameters used by CreateCurveSegment | Segment parameters |
---|---|
start_point | S |
end_point | E |
If the function succeeds, the return value is true. If the function fails, the return value is false. To get extended value information, call HM_ExtAPI::GetLastErrorCode().
Requires including hm_extapi.h.
Inputs
- new_segment
- [out] - Handle to new curve object.
- start_point
- [in] - The point corresponding to curve parameter value 0.
- end_point
- [in] - The point corresponding to curve parameter value 1.
Errors
None.