Rhino C++ API  8.14
Public Member Functions | Public Attributes | List of all members
ON_PolynomialCurve Class Reference

#include <opennurbs_bezier.h>

Public Member Functions

 ON_PolynomialCurve ()
 
 ON_PolynomialCurve (const ON_BezierCurve &)
 
 ON_PolynomialCurve (const ON_PolynomialCurve &)
 
 ON_PolynomialCurve (int dim, bool bIsRational, int order)
 
 ~ON_PolynomialCurve ()
 
bool Create (int dim, bool bIsRational, int order)
 
void Destroy ()
 
bool Evaluate (double t, int der_count, int v_stride, double *v) const
 
ON_PolynomialCurveoperator= (const ON_BezierCurve &)
 
ON_PolynomialCurveoperator= (const ON_PolynomialCurve &)
 

Public Attributes

ON_4dPointArray m_cv
 coefficients ( m_cv.Count() = order of monomial ) More...
 
int m_dim
 dimension of polynomial curve (1,2, or 3) More...
 
ON_Interval m_domain
 domain of polynomial More...
 
int m_is_rat
 1 if polynomial curve is rational, 0 if polynomial curve is not rational More...
 
int m_order
 order (=degree+1) of polynomial More...
 

Constructor & Destructor Documentation

◆ ON_PolynomialCurve() [1/4]

ON_PolynomialCurve::ON_PolynomialCurve ( )

◆ ON_PolynomialCurve() [2/4]

ON_PolynomialCurve::ON_PolynomialCurve ( int  dim,
bool  bIsRational,
int  order 
)

Description: See ON_PolynomialCurve::Create. Parameters: dim - [in] dimension of the curve bIsRational - [in] true if rational order - [in] (>=2) order = degree+1

◆ ~ON_PolynomialCurve()

ON_PolynomialCurve::~ON_PolynomialCurve ( )

◆ ON_PolynomialCurve() [3/4]

ON_PolynomialCurve::ON_PolynomialCurve ( const ON_PolynomialCurve )

◆ ON_PolynomialCurve() [4/4]

ON_PolynomialCurve::ON_PolynomialCurve ( const ON_BezierCurve )

Member Function Documentation

◆ Create()

bool ON_PolynomialCurve::Create ( int  dim,
bool  bIsRational,
int  order 
)

Description: Initializes fields and allocates the m_cv array. Parameters: dim - [in] dimension of the curve bIsRational - [in] true if rational order - [in] (>=2) order = degree+1

◆ Destroy()

void ON_PolynomialCurve::Destroy ( )

Description: Deallocates the m_cv array and sets fields to zero.

◆ Evaluate()

bool ON_PolynomialCurve::Evaluate ( double  t,
int  der_count,
int  v_stride,
double *  v 
) const

Description: Evaluate a polynomial curve. Parameters: t - [in] evaluation parameter ( usually in Domain() ). der_count - [in] (>=0) number of derivatives to evaluate v_stride - [in] (>=Dimension()) stride to use for the v[] array v - [out] array of length (der_count+1)*v_stride curve(t) is returned in (v[0],...,v[m_dim-1]), curve'(t) is returned in (v[v_stride],...,v[v_stride+m_dim-1]), curve"(t) is returned in (v[2*v_stride],...,v[2*v_stride+m_dim-1]), etc. Returns: false if unable to evaluate.

◆ operator=() [1/2]

ON_PolynomialCurve& ON_PolynomialCurve::operator= ( const ON_BezierCurve )

◆ operator=() [2/2]

ON_PolynomialCurve& ON_PolynomialCurve::operator= ( const ON_PolynomialCurve )

Member Data Documentation

◆ m_cv

ON_4dPointArray ON_PolynomialCurve::m_cv

coefficients ( m_cv.Count() = order of monomial )

◆ m_dim

int ON_PolynomialCurve::m_dim

dimension of polynomial curve (1,2, or 3)

◆ m_domain

ON_Interval ON_PolynomialCurve::m_domain

domain of polynomial

◆ m_is_rat

int ON_PolynomialCurve::m_is_rat

1 if polynomial curve is rational, 0 if polynomial curve is not rational

◆ m_order

int ON_PolynomialCurve::m_order

order (=degree+1) of polynomial