23 #if !defined(OPENNURBS_POLYCURVE_INC_) 24 #define OPENNURBS_POLYCURVE_INC_ 46 #if defined(ON_HAS_RVALUEREF) 73 unsigned int SizeOf()
const override;
76 ON__UINT32
DataCRC(ON__UINT32 current_remainder)
const override;
121 bool GetBBox(
double* boxmin,
double* boxmax,
bool bGrowBox =
false )
const override;
166 int desired_dimension
197 double = ON_ZERO_TOLERANCE
226 double = ON_ZERO_TOLERANCE
232 double = ON_ZERO_TOLERANCE
237 double = ON_ZERO_TOLERANCE
292 double cos_angle_tolerance=ON_DEFAULT_ANGLE_TOLERANCE_COSINE,
293 double curvature_tolerance=ON_SQRT_EPSILON
333 double point_tolerance=ON_ZERO_TOLERANCE,
334 double d1_tolerance=ON_ZERO_TOLERANCE,
335 double d2_tolerance=ON_ZERO_TOLERANCE,
336 double cos_angle_tolerance=ON_DEFAULT_ANGLE_TOLERANCE_COSINE,
337 double curvature_tolerance=ON_SQRT_EPSILON
520 double SegmentCurveParameter(
521 double polycurve_parameter
536 double PolyCurveParameter(
538 double segmentcurve_parameter
566 double polycurve_parameter
587 ON_Curve* FirstSegmentCurve()
const;
606 int FindNextGap(
int segment_index0 )
const;
621 bool HasGapAt(
int segment_index )
const;
623 ON_DEPRECATED_MSG(
"Replace calls to HasGap() with FindNextGap(0)")
653 bool CloseGap(
int gap_index,
int segments_to_modify );
694 bool IsNested()
const;
705 bool RemoveNesting();
707 ON_DEPRECATED_MSG(
"Use RemoveNesting(). RemoveNestingEx() will be removed in the next release.")
708 bool RemoveNestingEx();
717 bool HasSynchronizedSegmentDomains()
const;
728 bool SynchronizeSegmentDomains();
736 void SetSegment(
int index,
ON_Curve* crv);
747 bool SetParameterization(
const double* t );
virtual bool IsClosed() const
Test a curve to see if it is closed.
Definition: opennurbs_curve.h:1168
virtual int SpanCount() const =0
Get number of nonempty smooth (c-infinity) spans in curve
virtual bool IsContinuous(ON::continuity c, double t, int *hint=nullptr, double point_tolerance=ON_ZERO_TOLERANCE, double d1_tolerance=ON_ZERO_TOLERANCE, double d2_tolerance=ON_ZERO_TOLERANCE, double cos_angle_tolerance=ON_DEFAULT_ANGLE_TOLERANCE_COSINE, double curvature_tolerance=ON_SQRT_EPSILON) const
Test continuity at a curve parameter value.
virtual bool GetNextDiscontinuity(ON::continuity c, double t0, double t1, double *t, int *hint=nullptr, int *dtype=nullptr, double cos_angle_tolerance=ON_DEFAULT_ANGLE_TOLERANCE_COSINE, double curvature_tolerance=ON_SQRT_EPSILON) const
Search for a derivatitive, tangent, or curvature discontinuity.
virtual int Dimension() const
Dimension of the object.
An ON_Arc is a subcurve of 3d circle.
Definition: opennurbs_arc.h:33
virtual bool GetBBox(double *boxmin, double *boxmax, bool bGrowBox=false) const
This is the virtual function that actually calculates axis aligned bounding boxes.
bool ParameterSearch(double t, int &index, bool bEnableSnap, const ON_SimpleArray< double > &m_t, double RelTol=ON_SQRT_EPSILON) const
Lookup a parameter in the m_t array, optionally using a built in snap tolerance to snap a parameter v...
virtual bool IsArc(const ON_Plane *plane=nullptr, ON_Arc *arc=nullptr, double tolerance=ON_ZERO_TOLERANCE) const
Test a curve to see if the locus if its points is an arc or circle.
virtual bool SetStartPoint(ON_3dPoint start_point)
Force the curve to start at a specified point.
virtual int HasNurbForm() const
Does a NURBS curve representation of this curve.
virtual bool GetSpanVector(double *knots) const =0
Get number of parameters of "knots".
virtual bool MakeDeformable()
If possible, converts the object into a form that can be accuratly modified with "squishy" transforma...
virtual bool Reverse()=0
Reverse the direction of the curve.
virtual bool Extend(const ON_Interval &domain)
Pure virtual function. Default returns false. Where possible, analytically extends curve to include d...
ON_Curve is a pure virtual class for curve objects
Definition: opennurbs_curve.h:93
virtual int GetNurbForm(ON_NurbsCurve &nurbs_curve, double tolerance=0.0, const ON_Interval *subdomain=nullptr) const
Get a NURBS curve representation of this curve.
virtual int Degree() const =0
Returns maximum algebraic degree of any span or a good estimate if curve spans are not algebraic...
virtual bool IsPlanar(ON_Plane *plane=nullptr, double tolerance=ON_ZERO_TOLERANCE) const
Test a curve to see if it is planar.
virtual bool SwapCoordinates(int i, int j)
Swaps object coordinate values with indices i and j.
virtual bool GetNurbFormParameterFromCurveParameter(double curve_t, double *nurbs_t) const
Convert a curve parameter to a NURBS curve parameter.
virtual ON_Curve * DuplicateCurve() const
Get a duplicate of the curve.
virtual bool ChangeDimension(int desired_dimension)
Change the dimension of a curve.
bool EvaluatePoint(const class ON_ObjRef &objref, ON_3dPoint &P) const override
virtual ON_Geometry override
virtual bool IsInPlane(const ON_Plane &test_plane, double tolerance=ON_ZERO_TOLERANCE) const =0
Test a curve to see if it lies in a specific plane.
bool Transform(const ON_Xform &xform) override
overrides virtual ON_Geometry::Transform(). ON_Curve::Transform() calls ON_Geometry::Transform(xform)...
virtual int IsPolyline(ON_SimpleArray< ON_3dPoint > *pline_points=nullptr, ON_SimpleArray< double > *pline_t=nullptr) const
Several types of ON_Curve can have the form of a polyline including a degree 1 ON_NurbsCurve, an ON_PolylineCurve, and an ON_PolyCurve all of whose segments are some form of polyline. IsPolyline tests a curve to see if it can be represented as a polyline.
virtual bool ChangeClosedCurveSeam(double t)
If this curve is closed, then modify it so that the start/end point is at curve parameter t...
Definition: opennurbs_bounding_box.h:25
An ON_PolyCurve is an ON_Curve represented by a sequence of contiguous ON_Curve segments. A valid polycurve is represented by an array m_segment of Count()>=1 curve objects and a strictly increasing array m_t of Count()+1 parameter values. The i-th curve segment, when considered as part of the polycurve, is affinely reparamaterized from m_t[i] to m_t[i+1], i.e., m_segment[i].Domain()[0] is mapped to m_t[i] and m_segment[i].Domain()[1] is mapped to m_t[i+1].
Definition: opennurbs_polycurve.h:35
bool GetTightBoundingBox(class ON_BoundingBox &tight_bbox, bool bGrowBox=false, const class ON_Xform *xform=nullptr) const override
virtual ON_Geometry GetTightBoundingBox override
virtual void Dump(ON_TextLog &) const
Creates a text dump of the object.
void EmergencyDestroy()
Sets m_user_data_list = 0.
virtual bool IsDeformable() const
ON_Curve & operator=(const ON_Curve &)
virtual bool IsPeriodic() const
Test a curve to see if it is periodic.
bool SetDomain(ON_Interval domain)
Set the domain of the curve.
virtual bool GetCurveParameterFromNurbFormParameter(double nurbs_t, double *curve_t) const
Convert a NURBS curve parameter to a curve parameter
virtual bool Trim(const ON_Interval &domain)
Removes portions of the curve outside the specified interval.
virtual bool SetEndPoint(ON_3dPoint end_point)
Force the curve to end at a specified point.
virtual bool Evaluate(double t, int der_count, int v_stride, double *v, int side=0, int *hint=0) const =0
This evaluator actually does all the work. The other ON_Curve evaluation tools call this virtual func...
Definition: opennurbs_nurbscurve.h:26
Definition: opennurbs_textlog.h:20
Definition: opennurbs_archive.h:1783
virtual bool Read(ON_BinaryArchive &binary_archive)
Low level archive writing tool used by ON_BinaryArchive::ReadObject().
Definition: opennurbs_objref.h:163
Definition: opennurbs_point.h:460
bool IsValid(class ON_TextLog *text_log=nullptr) const override
Tests an object to see if its data members are correctly initialized.
virtual bool Write(ON_BinaryArchive &binary_archive) const
Low level archive writing tool used by ON_BinaryArchive::WriteObject().
virtual ON__UINT32 DataCRC(ON__UINT32 current_remainder) const
Returns a CRC calculated from the information that defines the object. This CRC can be used as a quic...
Definition: opennurbs_plane.h:20
void DestroyRuntimeCache(bool bDelete=true) override
virtual ON_Object::DestroyRuntimeCache override
unsigned int SizeOf() const override
virtual ON_Object::SizeOf override
virtual bool IsLinear(double tolerance=ON_ZERO_TOLERANCE) const
Test a curve to see if the locus if its points is a line segment.
Definition: opennurbs_point.h:46
virtual ON_Interval Domain() const =0
virtual bool Split(double t, ON_Curve *&left_side, ON_Curve *&right_side) const
Splits (divides) the curve at the specified parameter. The parameter must be in the interior of the c...