Rhino C++ API
8.14
|
Functions | |
ON_ClassArray< T >::ON_ClassArray () ON_NOEXCEPT | |
construction //////////////////////////////////////////////////////// More... | |
ON_ClassArray< T >::ON_ClassArray (const ON_ClassArray< T > &) | |
Copy constructor. More... | |
ON_ClassArray< T >::ON_ClassArray (size_t) | |
size_t parameter = initial capacity More... | |
ON_ObjectArray< T >::ON_ObjectArray () | |
Class ON_ObjectArray<> More... | |
ON_ObjectArray< T >::ON_ObjectArray (const ON_ObjectArray< T > &) | |
ON_ObjectArray< T >::ON_ObjectArray (size_t) | |
size_t parameter = initial capacity More... | |
ON_SimpleArray< T >::ON_SimpleArray () ON_NOEXCEPT | |
construction //////////////////////////////////////////////////////// More... | |
ON_SimpleArray< T >::ON_SimpleArray (const ON_SimpleArray< T > &) | |
Copy constructor. More... | |
ON_SimpleArray< T >::ON_SimpleArray (size_t) | |
size_t parameter = initial capacity More... | |
ON_SimpleFixedSizePool< T >::ON_SimpleFixedSizePool () | |
construction //////////////////////////////////////////////////////// More... | |
ON_SimpleFixedSizePoolIterator< T >::ON_SimpleFixedSizePoolIterator (const class ON_SimpleFixedSizePool< T > &fsp) | |
ON_SimpleFixedSizePoolIterator< T >::ON_SimpleFixedSizePoolIterator (const class ON_SimpleFixedSizePoolIterator< T > &) | |
virtual | ON_ClassArray< T >::~ON_ClassArray () |
override for struct member deallocation, etc. More... | |
ON_ObjectArray< T >::~ON_ObjectArray () | |
override for struct member deallocation, etc. More... | |
virtual | ON_SimpleArray< T >::~ON_SimpleArray () |
ON_SimpleFixedSizePool< T >::~ON_SimpleFixedSizePool () | |
size_t | ON_SimpleFixedSizePool< T >::ActiveElementCount () const |
T * | ON_SimpleFixedSizePool< T >::AllocateElement () |
void | ON_SimpleArray< T >::Append (const T &) |
void | ON_ClassArray< T >::Append (const T &) |
void | ON_SimpleArray< T >::Append (int, const T *) |
Append copy of an array T[count]. More... | |
void | ON_ClassArray< T >::Append (int, const T *) |
Append copy of an array T[count]. More... | |
T & | ON_SimpleArray< T >::AppendNew () |
array operations //////////////////////////////////////////////////// More... | |
T & | ON_ClassArray< T >::AppendNew () |
array operations //////////////////////////////////////////////////// More... | |
T * | ON_SimpleArray< T >::Array () |
The Array() function return the. More... | |
T * | ON_ClassArray< T >::Array () |
The Array() function return the. More... | |
T * | ON_SimpleArray< T >::At (int) |
At(index) returns nullptr if index < 0 or index >= count. More... | |
T * | ON_ClassArray< T >::At (int) |
At(index) returns nullptr if index < 0 or index >= count. More... | |
const T * | ON_SimpleArray< T >::At (int) const |
const T * | ON_ClassArray< T >::At (int) const |
T * | ON_SimpleArray< T >::At (ON__INT64) |
T * | ON_ClassArray< T >::At (ON__INT64) |
const T * | ON_SimpleArray< T >::At (ON__INT64) const |
const T * | ON_ClassArray< T >::At (ON__INT64) const |
T * | ON_SimpleArray< T >::At (ON__UINT64) |
T * | ON_ClassArray< T >::At (ON__UINT64) |
const T * | ON_SimpleArray< T >::At (ON__UINT64) const |
const T * | ON_ClassArray< T >::At (ON__UINT64) const |
T * | ON_SimpleArray< T >::At (unsigned int) |
T * | ON_ClassArray< T >::At (unsigned int) |
const T * | ON_SimpleArray< T >::At (unsigned int) const |
const T * | ON_ClassArray< T >::At (unsigned int) const |
int | ON_SimpleArray< T >::BinarySearch (const T *, int(*)(const T *, const T *)) const |
See Also: ON_CompareIncreasing<T> and ON_CompareDeccreasing<T> More... | |
int | ON_ClassArray< T >::BinarySearch (const T *, int(*)(const T *, const T *)) const |
See Also: ON_CompareIncreasing<T> and ON_CompareDeccreasing<T> More... | |
int | ON_SimpleArray< T >::BinarySearch (const T *, int(*)(const T *, const T *), int) const |
int | ON_ClassArray< T >::BinarySearch (const T *, int(*)(const T *, const T *), int) const |
const T * | ON_SimpleArray< T >::BinarySearchPtr (const T *, int(*)(const T *, const T *)) const |
const T * | ON_SimpleArray< T >::BinarySearchPtr (const T *, int(*)(const T *, const T *), int) const |
int | ON_SimpleArray< T >::Capacity () const |
capacity of array More... | |
int | ON_ClassArray< T >::Capacity () const |
capacity of array More... | |
void | ON_ClassArray< T >::ConstructDefaultElement (T *) |
int | ON_SimpleArray< T >::Count () const |
query /////////////////////////////////////////////////////////////// More... | |
int | ON_ClassArray< T >::Count () const |
query /////////////////////////////////////////////////////////////// More... | |
static int | CrashTestHelper (int crash_type, ON_TextLog &textlog) |
static bool | CrashTestHelper_AllocationFailure (ON_TextLog &textlog, size_t sz) |
static int | CrashTestHelper_CallBoguslFuncPtr (ON_TextLog &textlog, int crash_type, int *stack_ptr) |
static int | CrashTestHelper_CallNullFuncPtr (ON_TextLog &textlog, int crash_type, int *stack_ptr) |
static int | CrashTestHelper_DerefBogusIntPtr (ON_TextLog &textlog, int crash_type, int *stack_ptr) |
static int | CrashTestHelper_DerefNullIntPtr (ON_TextLog &textlog, int crash_type, int *stack_ptr) |
static bool | CrashTestHelper_DivideByDoubleZero (ON_TextLog &textlog, const char *zero) |
static bool | CrashTestHelper_DivideByFloatZero (ON_TextLog &textlog, const char *zero) |
static bool | CrashTestHelper_DivideByIntZero (ON_TextLog &textlog, const char *zero) |
static bool | CrashTestHelper_DoubleOverflow (ON_TextLog &textlog, const char *sx, const char *sy) |
static void | CrashTestHelper_GetBogusFuncPtr (CRASHTEST__FUNCTION__POINTER__ *pp) |
static void | CrashTestHelper_GetBogusIntPtr (int **pp) |
static void | CrashTestHelper_GetNullFuncPtr (CRASHTEST__FUNCTION__POINTER__ *pp) |
static void | CrashTestHelper_GetNullIntPrt (int **pp) |
static bool | CrashTestHelper_LogNegativeNumber (ON_TextLog &textlog, const char *minus_one) |
static bool | CrashTestHelper_StackOverflow (ON_TextLog &textlog, int depth=0) |
static bool | CrashTestHelper_Throw (ON_TextLog &textlog, const char *si) |
bool | ON_SimpleFixedSizePool< T >::Create (size_t element_count_estimate, size_t block_element_count) |
T * | ON_SimpleFixedSizePoolIterator< T >::CurrentElement () |
ON__UINT32 | ON_SimpleArray< T >::DataCRC (ON__UINT32 current_remainder) const |
ON__UINT32 | ON_ObjectArray< T >::DataCRC (ON__UINT32 current_remainder) const |
void | ON_SimpleArray< T >::Destroy () |
onfree any memory and set count and capacity to zero More... | |
void | ON_ClassArray< T >::Destroy () |
onfree any memory and set count and capacity to zero More... | |
void | ON_SimpleFixedSizePool< T >::Destroy () |
void | ON_ClassArray< T >::DestroyElement (T &) |
T * | ON_SimpleFixedSizePool< T >::Element (size_t element_index) const |
size_t | ON_SimpleFixedSizePool< T >::ElementIndex (T *) const |
void | ON_SimpleArray< T >::EmergencyDestroy (void) |
emergency bailout /////////////////////////////////////////////////// More... | |
void | ON_ClassArray< T >::EmergencyDestroy (void) |
emergency bailout /////////////////////////////////////////////////// More... | |
void | ON_SimpleArray< T >::Empty () |
Sets count to 0, leaves capacity untouched. More... | |
void | ON_ClassArray< T >::Empty () |
Sets count to 0, leaves capacity untouched. More... | |
T * | ON_SimpleArray< T >::First () |
T * | ON_ClassArray< T >::First () |
T * | ON_SimpleFixedSizePoolIterator< T >::FirstBlock (size_t *block_element_count) |
T * | ON_SimpleFixedSizePoolIterator< T >::FirstElement () |
T * | ON_SimpleFixedSizePoolIterator< T >::FirstElement (size_t element_index) |
bool | ON_SimpleArray< T >::HeapSort (int(*)(const T *, const T *)) |
virtual bool | ON_ClassArray< T >::HeapSort (int(*)(const T *, const T *)) |
QuickSort() is generally the better choice. More... | |
bool | ON_ObjectArray< T >::HeapSort (int(*)(const T *, const T *)) |
void | ON_SimpleArray< T >::Insert (int, const T &) |
void | ON_ClassArray< T >::Insert (int, const T &) |
Insert called with a reference uses operator =. More... | |
int | ON_SimpleArray< T >::InsertInSortedList (const T &, int(*)(const T *, const T *)) |
int | ON_ClassArray< T >::InsertInSortedList (const T &, int(*)(const T *, const T *)) |
int | ON_SimpleArray< T >::InsertInSortedList (const T &, int(*)(const T *, const T *), int) |
int | ON_ClassArray< T >::InsertInSortedList (const T &, int(*)(const T *, const T *), int) |
T * | ON_SimpleArray< T >::KeepArray () |
T * | ON_ClassArray< T >::KeepArray () |
T * | ON_SimpleArray< T >::Last () |
T * | ON_ClassArray< T >::Last () |
void | ON_SimpleArray< T >::MemSet (unsigned char) |
void | ON_SimpleArray< T >::Move (int, int, int) |
implementation ////////////////////////////////////////////////////// More... | |
void | ON_ClassArray< T >::Move (int, int, int) |
implementation ////////////////////////////////////////////////////// More... | |
int | ON_SimpleArray< T >::NewCapacity () const |
int | ON_ClassArray< T >::NewCapacity () const |
T * | ON_SimpleFixedSizePoolIterator< T >::NextBlock (size_t *block_element_count) |
T * | ON_SimpleFixedSizePoolIterator< T >::NextElement () |
ON_DECL ON_3dVector | ON_2ndDerFromCurvature (ON_3dVector D1, ON_3dVector K) |
ON_DECL ON_3dVector | ON_3rdDerFromJerk (ON_3dVector D1, ON_3dVector D2, ON_3dVector J) |
ON_DECL ON_3dVector | ON_4thDerFromYank (ON_3dVector D1, ON_3dVector D2, ON_3dVector D3, ON_3dVector Y) |
bool | ON__PackTextureRectangles1 (ON_PackedTextureRectangle *top, const class ON_PackTextureRectanglesParameters *packing_parameters) |
do not export this function or declare it in a header file More... | |
bool | ON__PackTextureRectangles2 (ON_PackedTextureRectangle *top, const class ON_PackTextureRectanglesParameters *packing_parameters) |
do not export this function or declare it in a header file More... | |
const ON_DECL ON_wString | ON_AddIdPrefixToString (const ON_UUID id, const wchar_t *separator, const wchar_t *source) |
const ON_DECL ON_wString | ON_AddIdSuffixToString (const wchar_t *source, const wchar_t *separator, const ON_UUID id) |
ON_DECL bool | ON_Adjust2ndPointToDomain (const ON_2dPoint &First, ON_2dPoint &Second, const ON_Interval dom[2]) |
ON_DECL int | ON_ArePointsOnLine (int, bool, int, int, const double *, const ON_BoundingBox &, const ON_Line &, double) |
returns 0 = no, 1 = yes, 2 = points are coincident and on line More... | |
ON_DECL int | ON_ArePointsOnPlane (int, bool, int, int, const double *, const ON_BoundingBox &, const ON_Plane &, double) |
returns 0 = no, 1 = yes, 2 = points are coincident and on line More... | |
ON_DECL void | ON_Array_aA_plus_B (int, double, const double *, const double *, double *) |
ON_DECL void | ON_Array_aA_plus_B (int, float, const float *, const float *, float *) |
ON_DECL double | ON_ArrayDistance (int, const double *, const double *) |
ON_DECL double | ON_ArrayDistanceSquared (int, const double *, const double *) |
ON_DECL double | ON_ArrayDotDifference (int, const double *, const double *, const double *) |
ON_DECL double | ON_ArrayDotProduct (int, const double *, const double *) |
ON_DECL float | ON_ArrayDotProduct (int, const float *, const float *) |
ON_DECL double | ON_ArrayMagnitude (int, const double *) |
ON_DECL double | ON_ArrayMagnitudeSquared (int, const double *) |
ON_DECL void | ON_ArrayScale (int, double, const double *, double *) |
ON_DECL void | ON_ArrayScale (int, float, const float *, float *) |
ON_DECL bool | ON_Base32ToString (const ON_SimpleArray< unsigned char > &base32_digits, ON_String &sBase32) |
ON_DECL bool | ON_Base32ToString (const ON_SimpleArray< unsigned char > &base32_digits, ON_wString &sBase32) |
ON_DECL bool | ON_Base32ToString (const unsigned char *base32_digits, int base32_digit_count, char *sBase32) |
ON_DECL ON_NurbsSurface * | ON_BendBrepFace (const ON_BrepFace &face0, const ON_SimpleArray< ON_BendFaceConstraint > &constraints, double tolerance, double time_limit, ON_NurbsSurface *bent_surface, ON_TextLog *text_log=0) |
ON_DECL bool | ON_BeyondSinglePrecision (const ON_BoundingBox &bbox, ON_Xform *xform) |
const ON_DECL ON_2dex * | ON_BinarySearch2dexArray (int key_i, const ON_2dex *base, size_t nel) |
const ON_DECL ON_2udex * | ON_BinarySearch2udexArray (unsigned int key_i, const ON_2udex *base, size_t nel) |
const ON_DECL void * | ON_BinarySearchArrayFirst2udex (ON_2udex key, const void *base, size_t count, size_t sizeof_element, size_t key_offset) |
const ON_DECL void * | ON_BinarySearchArrayFirstUnsignedInt (unsigned int key, const void *base, size_t count, size_t sizeof_element, size_t key_offset) |
const ON_DECL void * | ON_BinarySearchArrayForUnsingedInt (unsigned int key, const void *base, size_t count, size_t sizeof_element, size_t key_offset) |
const ON_DECL double * | ON_BinarySearchDoubleArray (double key, const double *base, size_t nel) |
const ON_DECL int * | ON_BinarySearchIntArray (int key, const int *base, size_t nel) |
const ON_DECL unsigned int * | ON_BinarySearchUnsignedIntArray (unsigned int key, const unsigned int *base, size_t nel) |
ON_DECL double | ON_BinomialCoefficient (int i, int j) |
ON_DECL double | ON_BoundingBoxTolerance (int dim, const double *bboxmin, const double *bboxmax) |
ON_DECL ON_Brep * | ON_BrepBox (const ON_3dPoint *box_corners, ON_Brep *pBrep=nullptr) |
ON_DECL ON_Brep * | ON_BrepCone (const ON_Cone &cone, bool bCapBottom, ON_Brep *pBrep=nullptr) |
ON_DECL int | ON_BrepConeEdge (ON_Brep &brep, int edge_index, ON_3dPoint apex_point) |
ON_DECL int | ON_BrepConeFace (ON_Brep &brep, int face_index, ON_3dPoint apex_point) |
ON_DECL bool | ON_BrepConeLoop (ON_Brep &brep, int loop_index, ON_3dPoint apex_point) |
ON_DECL ON_Brep * | ON_BrepCylinder (const ON_Cylinder &cylinder, bool bCapBottom, bool bCapTop, ON_Brep *pBrep=nullptr) |
ON_DECL bool | ON_BrepExtrude (ON_Brep &brep, const ON_Curve &path_curve, bool bCap=true) |
ON_DECL int | ON_BrepExtrudeEdge (ON_Brep &brep, int edge_index, const ON_Curve &path_curve) |
ON_DECL int | ON_BrepExtrudeFace (ON_Brep &brep, int face_index, const ON_Curve &path_curve, bool bCap=true) |
ON_DECL int | ON_BrepExtrudeLoop (ON_Brep &brep, int loop_index, const ON_Curve &path_curve, bool bCap=true) |
ON_DECL int | ON_BrepExtrudeVertex (ON_Brep &brep, int vertex_index, const ON_Curve &path_curve) |
ON_DECL ON_Brep * | ON_BrepFromMesh (const ON_MeshTopology &mesh_topology, bool bTrimmedTriangles=true, ON_Brep *pBrep=nullptr) |
ON_DECL ON_Brep * | ON_BrepFromMeshWithNgons (const ON_MeshTopology &mesh_topology, bool bTrimmedTriangles, bool bUseNgonsIfTheyExist, double tolerance, ON_Brep *pBrep=nullptr) |
ON_DECL void | ON_BrepMergeAllEdges (ON_Brep &B) |
Merges all possible edges. More... | |
ON_DECL bool | ON_BrepMergeFaces (ON_Brep &B) |
ON_DECL int | ON_BrepMergeFaces (ON_Brep &B, int fid0, int fid1) |
These merge adjacent faces that have the same underlying surface. More... | |
ON_DECL ON_Brep * | ON_BrepQuadSphere (const ON_3dPoint &Center, double radius, ON_Brep *pBrep=nullptr) |
ON_DECL bool | ON_BrepRemoveSlits (ON_BrepFace &F) |
ON_DECL ON_Brep * | ON_BrepRevSurface (ON_RevSurface *&pRevSurface, bool bCapStart, bool bCapEnd, ON_Brep *pBrep=nullptr) |
ON_DECL ON_Brep * | ON_BrepSphere (const ON_Sphere &sphere, ON_Brep *pBrep=nullptr) |
ON_DECL ON_Brep * | ON_BrepTorus (const ON_Torus &torus, ON_Brep *pBrep=nullptr) |
ON_DECL ON_Brep * | ON_BrepTrimmedPlane (const ON_Plane &plane, const ON_Curve &boundary, ON_Brep *pBrep=nullptr) |
ON_DECL ON_Brep * | ON_BrepTrimmedPlane (const ON_Plane &plane, ON_SimpleArray< ON_Curve * > &boundary, bool bDuplicateCurves=true, ON_Brep *pBrep=nullptr) |
ON_DECL ON_Brep * | ON_BrepWedge (const ON_3dPoint *corners, ON_Brep *pBrep=nullptr) |
const ON_DECL ON_2dex | ON_BsplineControlPointSpans (int order, int control_point_count, int control_point_index) |
Get the indices of the B-spline spans where the specified control point is active. Note that a B-spline with n control points has (n-degree) many spans. If 0 <= span_index < (n-degree), then CV(span_index), ..., CV(span_index+degree) and {knot[span_index], ..., knot[span_index+2*degree-1]} are the control points and knots that are active in that span. The domain of the span is [knot[span_index+degree-1], knot[span_index+degree]]. More... | |
const ON_DECL ON_Interval | ON_BsplineControlPointSupport (int order, int control_point_count, const double *knots, int control_point_index) |
Get the interval in the B-spline domain where the control point is active. The domain = [knots[order-2], knots[control_point_count-1]]. The returned interval will be in domain and are the parameters where the control point influnces the value of the B-spline. More... | |
ON_DECL bool | ON_ChangeRationalBezierCurveWeights (int dim, int order, int cvstride, double *cv, int i0, double w0, int i1, double w1) |
ON_DECL bool | ON_ChangeRationalNurbsCurveEndWeights (int dim, int order, int cv_count, int cvstride, double *cv, double *knot, double w0, double w1) |
ON_DECL bool | ON_ClampKnotVector (int, int, double *, int) |
ON_DECL bool | ON_ClampKnotVector (int, int, int, int, double *, double *, int) |
ON_DECL struct ON_Vtable * | ON_ClassVtable (void *p) |
ON_DECL ON__UINT64 | ON_ClearWorkerThreadContext () |
ON_DECL int | ON_ClosedCurveOrientation (const ON_Curve &curve, const ON_Plane &plane) |
ON_DECL int | ON_ClosedCurveOrientation (const ON_Curve &curve, const ON_Xform *xform) |
ON_DECL double | ON_ClosestPointAngle (const ON_Line &, const ON_Curve &, ON_Interval, const ON_3dPoint &, ON_3dPoint &, double *, double *) |
ON_DECL bool | ON_ClosestPointBetweenQuads (const ON_3dPoint A[4], const ON_3dPoint B[4], double a[4], double b[4]) |
ON_DECL bool | ON_ClosestPointBetweenTriangleAndQuad (const ON_3dPoint Tri[3], const ON_3dPoint Quad[4], double t[3], double q[4]) |
ON_DECL bool | ON_ClosestPointBetweenTriangles (const ON_3dPoint A[3], const ON_3dPoint B[3], double a[3], double b[3]) |
ON_DECL bool | ON_ClosestPointToTriangle (ON_3dPoint A, ON_3dPoint B, ON_3dPoint C, ON_3dPoint P, double *a, double *b, double *c) |
ON_DECL bool | ON_ClosestPointToTriangleFast (const ON_3dPoint &A, const ON_3dPoint &B, const ON_3dPoint &C, ON_3dPoint P, double *a, double *b, double *c) |
ON_DECL bool | ON_CombineShortSegments (ON_Curve &crv, double tolerance) |
ON_DECL int | ON_Compare2dex (const ON_2dex *a, const ON_2dex *b) |
ON_DECL int | ON_Compare2udex (const ON_2udex *a, const ON_2udex *b) |
ON_DECL int | ON_Compare3dex (const ON_3dex *a, const ON_3dex *b) |
ON_DECL int | ON_Compare4dex (const ON_4dex *a, const ON_4dex *b) |
template<class T > | |
static int | ON_CompareDecreasing (const T *a, const T *b) |
ON_DECL int | ON_CompareDouble (double a, double b) |
ON_DECL int | ON_CompareDoubleArray (size_t count, const double *a, const double *b) |
ON_DECL int | ON_CompareFloat (float a, float b) |
template<class T > | |
static int | ON_CompareIncreasing (const T *a, const T *b) |
ON_DECL int | ON_CompareKnotVector (int, int, const double *, int, int, const double *) |
ON_DECL int | ON_ComparePoint (int dim, bool israt, const double *cv0, const double *cv1) |
ON_DECL int | ON_ComparePointList (int, bool, int, int, const double *, int, const double *) |
ON_DECL ON_ComponentState | ON_ComponentStateFromUnsigned (unsigned int state_as_unsigned) |
ON_DECL ON_Mesh * | ON_ControlPolygonMesh (const ON_NurbsSurface &nurbs_surface, bool bCleanMesh, ON_Mesh *input_mesh=nullptr) |
ON_DECL int | ON_ConvertMSMBCPToWideChar (ON__UINT32 windows_code_page, const char *sMBCS, int sMBCS_count, wchar_t *sWideChar, int sWideChar_capacity, unsigned int *error_status) |
ON_DECL void | ON_ConvertNurbSpanToBezier (int, int, int, double *, const double *, double, double) |
ON_DECL int | ON_ConvertUTF16ToUTF16 (int bTestByteOrder, const ON__UINT16 *sInputUTF16, int sInputUTF16_count, ON__UINT16 *sOutputUTF16, int sOutputUTF16_count, unsigned int *error_status, unsigned int error_mask, ON__UINT32 error_code_point, const ON__UINT16 **sNextInputUTF16) |
ON_DECL int | ON_ConvertUTF16ToUTF32 (int bTestByteOrder, const ON__UINT16 *sUTF16, int sUTF16_count, unsigned int *sUTF32, int sUTF32_count, unsigned int *error_status, unsigned int error_mask, ON__UINT32 error_code_point, const ON__UINT16 **sNextUTF16) |
ON_DECL int | ON_ConvertUTF16ToUTF8 (int bTestByteOrder, const ON__UINT16 *sUTF16, int sUTF16_count, char *sUTF8, int sUTF8_count, unsigned int *error_status, unsigned int error_mask, ON__UINT32 error_code_point, const ON__UINT16 **sNextUTF16) |
ON_DECL int | ON_ConvertUTF16ToWideChar (int bTestByteOrder, const ON__UINT16 *sUTF16, int sUTF16_count, wchar_t *sWideChar, int sWideChar_count, unsigned int *error_status, unsigned int error_mask, ON__UINT32 error_code_point, const ON__UINT16 **sNextUTF16) |
ON_DECL int | ON_ConvertUTF32ToUTF16 (int bTestByteOrder, const ON__UINT32 *sUTF32, int sUTF32_count, ON__UINT16 *sUTF16, int sUTF16_count, unsigned int *error_status, unsigned int error_mask, ON__UINT32 error_code_point, const ON__UINT32 **sNextUTF32) |
ON_DECL int | ON_ConvertUTF32ToUTF32 (int bTestByteOrder, const ON__UINT32 *sInputUTF32, int sInputUTF32_count, ON__UINT32 *sOuputUTF32, int sOutputUTF32_count, unsigned int *error_status, unsigned int error_mask, ON__UINT32 error_code_point, const ON__UINT32 **sNextInputUTF32) |
ON_DECL int | ON_ConvertUTF32ToUTF8 (int bTestByteOrder, const ON__UINT32 *sUTF32, int sUTF32_count, char *sUTF8, int sUTF8_count, unsigned int *error_status, unsigned int error_mask, ON__UINT32 error_code_point, const ON__UINT32 **sNextUTF32) |
ON_DECL int | ON_ConvertUTF32ToWideChar (int bTestByteOrder, const ON__UINT32 *sUTF32, int sUTF32_count, wchar_t *sWideChar, int sWideChar_count, unsigned int *error_status, unsigned int error_mask, ON__UINT32 error_code_point, const ON__UINT32 **sNextUTF32) |
ON_DECL int | ON_ConvertUTF8ToUTF16 (int bTestByteOrder, const char *sUTF8, int sUTF8_count, ON__UINT16 *sUTF16, int sUTF16_count, unsigned int *error_status, unsigned int error_mask, ON__UINT32 error_code_point, const char **sNextUTF8) |
ON_DECL int | ON_ConvertUTF8ToUTF32 (int bTestByteOrder, const char *sUTF8, int sUTF8_count, ON__UINT32 *sUTF32, int sUTF32_count, unsigned int *error_status, unsigned int error_mask, ON__UINT32 error_code_point, const char **sNextUTF8) |
ON_DECL int | ON_ConvertUTF8ToUTF8 (int bTestByteOrder, const char *sInputUTF8, int sInputUTF8_count, char *sOutputUTF8, int sOutputUTF8_count, unsigned int *error_status, unsigned int error_mask, ON__UINT32 error_code_point, const char **sNextInputUTF8) |
ON_DECL int | ON_ConvertUTF8ToWideChar (int bTestByteOrder, const char *sUTF8, int sUTF8_count, wchar_t *sWideChar, int sWideChar_count, unsigned int *error_status, unsigned int error_mask, ON__UINT32 error_code_point, const char **sNextUTF8) |
ON_DECL int | ON_ConvertWideCharToMSMBCP (const wchar_t *sWideChar, int sWideChar_count, ON__UINT32 windows_code_page, char *sMBCS, int sMBCS_capacity, unsigned int *error_status) |
ON_DECL int | ON_ConvertWideCharToUTF16 (int bTestByteOrder, const wchar_t *sWideChar, int sWideChar_count, ON__UINT16 *sUTF16, int sUTF16_count, unsigned int *error_status, unsigned int error_mask, ON__UINT32 error_code_point, const wchar_t **sNextWideChar) |
ON_DECL int | ON_ConvertWideCharToUTF32 (int bTestByteOrder, const wchar_t *sWideChar, int sWideChar_count, ON__UINT32 *sUTF32, int sUTF32_count, unsigned int *error_status, unsigned int error_mask, ON__UINT32 error_code_point, const wchar_t **sNextWideChar) |
ON_DECL int | ON_ConvertWideCharToUTF8 (int bTestByteOrder, const wchar_t *sWideChar, int sWideChar_count, char *sUTF8, int sUTF8_count, unsigned int *error_status, unsigned int error_mask, ON__UINT32 error_code_point, const wchar_t **sNextWideChar) |
ON_DECL int | ON_ConvexHull2d (const ON_SimpleArray< ON_2dPoint > &Pnt, ON_SimpleArray< ON_2dPoint > &Hull, ON_SimpleArray< int > *PntInd=nullptr) |
ON_DECL int | ON_CorrectBase32StringTypos (const char *sBase32, char *sBase32clean) |
ON_DECL int | ON_CorrectBase32StringTypos (const char *sBase32, ON_String &sBase32clean) |
ON_DECL int | ON_CorrectBase32StringTypos (const wchar_t *sBase32, ON_wString &sBase32clean) |
ON_DECL int | ON_CrashTest (int crash_type, ON_TextLog &text_log) |
ON_BEGIN_EXTERNC ON_DECL ON__UINT16 | ON_CRC16 (ON__UINT16 current_remainder, size_t sizeof_buffer, const void *buffer) |
ON_DECL ON__UINT32 | ON_CRC32 (ON__UINT32 current_remainder, size_t sizeof_buffer, const void *buffer) |
ON_DECL ON_UUID | ON_CreateId () |
ON_END_EXTERNC ON_DECL bool | ON_CreateUuid (ON_UUID &uuid) |
ON_DECL ON_3dVector | ON_CrossProduct (const double *, const double *) |
ON_DECL ON_3fVector | ON_CrossProduct (const float *, const float *) |
ON_DECL ON_3dVector | ON_CrossProduct (const ON_2dVector &, const ON_2dVector &) |
ON_DECL ON_3fVector | ON_CrossProduct (const ON_2fVector &, const ON_2fVector &) |
ON_DECL ON_3dVector | ON_CrossProduct (const ON_3dVector &, const ON_3dVector &) |
ON_DECL ON_3fVector | ON_CrossProduct (const ON_3fVector &, const ON_3fVector &) |
ON_DECL ON_Quaternion | ON_CrossProduct (const ON_Quaternion &p, const ON_Quaternion &q) |
ON_DECL bool | ON_CSXFirstOrderNecessaryConditions (ON_TextLog *text_log, const ON_X_EVENT &xevent, int end_index, const ON_Interval *curve_domain, const ON_Interval *surface_domain0, const ON_Interval *surface_domain1) |
ON_DECL double | ON_CurveOrientationArea (const ON_Curve *curve, const ON_Interval *domain, const ON_Xform *xform, bool bReverseCurve) |
ON_DECL bool | ON_CvxHullFromLeafBox (ON_ConvexHullPoint2 &Hull, const ON_SurfaceLeafBox &leaf) |
ON_DECL unsigned int | ON_DayOfGregorianYear (unsigned int year, unsigned int month, unsigned int day_of_month) |
ON_DECL unsigned int | ON_DaysInGregorianYear (unsigned int year) |
ON_DECL unsigned int | ON_DaysInMonthOfGregorianYear (unsigned int year, unsigned int month) |
ON_DECL void | ON_DBL_SNAN (double *x) |
ON_DECL int | ON_DebugWriteObject (const class ON_Object *pObject) |
ON_DECL int | ON_DebugWriteObjectArray (const ON_SimpleArray< const class ON_Object * > &object_list) |
const ON_DECL wchar_t * | ON_DebugWriteObjectDirectory () |
ON_DECL int | ON_DebugWriteObjects (size_t object_list_count, const ON_Object *const *object_list) |
ON_DECL int | ON_DebugWritePoint (const class ON_3dPoint *p3dPoint) |
ON_DECL int | ON_DebugWritePoints (const double *pPoint, int dim, bool is_rat, int count) |
ON__UINT32 ON_DECL | ON_DecalCRCFromNode (const ON_XMLNode &node) |
For internal use only. More... | |
ON_DECL double | ON_DecimalHoursFromHMS (int hour, int minute, int second) |
ON_DECL void | ON_DecimalHoursToHMS (double hours, int &hour, int &minute, int &second) |
ON_DECL void | ON_DecimalHoursToHMS (double hours, int &hour, int &minute, int &second, int &year, int &month, int &day) |
ON_DECL int | ON_DecodeSwapByteUTF16 (const ON__UINT16 *sUTF16, int sUTF16_count, struct ON_UnicodeErrorParameters *e, ON__UINT32 *unicode_code_point) |
ON_DECL int | ON_DecodeSwapByteUTF32 (const ON__UINT32 *sUTF32, int sUTF32_count, struct ON_UnicodeErrorParameters *e, ON__UINT32 *unicode_code_point) |
ON_DECL int | ON_DecodeUTF16 (const ON__UINT16 *sUTF16, int sUTF16_count, struct ON_UnicodeErrorParameters *e, ON__UINT32 *unicode_code_point) |
ON_DECL int | ON_DecodeUTF16BE (const ON__UINT16 *sUTF16, int sUTF16_count, struct ON_UnicodeErrorParameters *e, ON__UINT32 *unicode_code_point) |
ON_DECL int | ON_DecodeUTF16LE (const ON__UINT16 *sUTF16, int sUTF16_count, struct ON_UnicodeErrorParameters *e, ON__UINT32 *unicode_code_point) |
ON_DECL unsigned int | ON_DecodeUTF16SurrogatePair (unsigned int u1, unsigned int u2, unsigned int error_code_point) |
ON_DECL int | ON_DecodeUTF32 (const ON__UINT32 *sUTF32, int sUTF32_count, struct ON_UnicodeErrorParameters *e, ON__UINT32 *unicode_code_point) |
ON_DECL int | ON_DecodeUTF32BE (const ON__UINT32 *sUTF32, int sUTF32_count, struct ON_UnicodeErrorParameters *e, ON__UINT32 *unicode_code_point) |
ON_DECL int | ON_DecodeUTF32LE (const ON__UINT32 *sUTF32, int sUTF32_count, struct ON_UnicodeErrorParameters *e, ON__UINT32 *unicode_code_point) |
ON_DECL int | ON_DecodeUTF8 (const char *sUTF8, int sUTF8_count, struct ON_UnicodeErrorParameters *e, ON__UINT32 *unicode_code_point) |
ON_DECL int | ON_DecodeWideChar (const wchar_t *sWideChar, int sWideChar_count, struct ON_UnicodeErrorParameters *e, ON__UINT32 *unicode_code_point) |
ON_DECL int | ON_DecomposeVector (const ON_3dVector &V, const ON_3dVector &A, const ON_3dVector &B, double *x, double *y) |
ON_DECL double | ON_DegreesFromRadians (double angle_in_radians) |
ON_DECL void | ON_Disableonmalloc () |
ON_DECL bool | ON_DollyExtents (const ON_Viewport ¤t_vp, ON_BoundingBox camcoord_bbox, ON_Viewport &zoomed_vp) |
ON_DECL double | ON_DomainTolerance (double, double) |
ON_DECL double | ON_DotProduct (const ON_2dVector &, const ON_2dVector &) |
ON_DECL float | ON_DotProduct (const ON_2fVector &, const ON_2fVector &) |
ON_DECL double | ON_DotProduct (const ON_3dVector &, const ON_3dVector &) |
ON_DECL float | ON_DotProduct (const ON_3fVector &, const ON_3fVector &) |
ON_DECL double | ON_DoubleFromFloat (float x) |
ON_DECL void | ON_DumpSquishInfoText (const ON_Geometry *squished_geometry, ON_TextLog &text_log, const wchar_t *objid_locale_str, const wchar_t *meshcount_locale_str) |
ON_DECL ON_CurveTreeBezier * | ON_DuplicateCurveTreeBezier (const ON_CurveTreeBezier &src) |
ON_DECL ON_SurfaceTreeBezier * | ON_DuplicateSurfaceTreeBezier (const ON_SurfaceTreeBezier &src) |
ON_DECL double | ON_EigenvectorPrecision (const unsigned int N, const double *const *M, bool bTransposeM, double lambda, const double *eigenvector) |
ON_DECL void | ON_EnableDebugBreak (int bEnableDebugBreak) |
ON_DECL void | ON_EnableDebugBreakOnFirstError (int bEnableDebugBreak) |
ON_DECL void | ON_EnableDebugErrorMessage (int bEnableDebugErrorMessage) |
ON_DECL int | ON_EncodeUTF16 (ON__UINT32 unicode_code_point, ON__UINT16 sUTF16[2]) |
ON_DECL int | ON_EncodeUTF8 (ON__UINT32 u, char sUTF8[6]) |
ON_DECL int | ON_EncodeWideChar (ON__UINT32 code_point, size_t w_capacity, wchar_t *w) |
ON_DECL void ON_VARGS_FUNC_CDECL | ON_Error (const char *file_name, int line_number, const char *format,...) |
ON_DECL void ON_VARGS_FUNC_CDECL | ON_ErrorEx (const char *file_name, int line_number, const char *function_name, const char *format,...) |
ON_BEGIN_EXTERNC ON_DECL void | ON_ErrorMessage (int, const char *) |
ON_DECL double | ON_EvaluateBernsteinBasis (int, int, double) |
ON_DECL bool | ON_EvaluateBezier (int, bool, int, int, const double *, double, double, int, double, int, double *) |
ON_DECL void | ON_EvaluatedeCasteljau (int, int, int, int, double *, double) |
ON_DECL bool | ON_EvaluateNurbsBasis (int order, const double *knot, double t, double *N) |
ON_DECL bool | ON_EvaluateNurbsBasisDerivatives (int order, const double *knot, int der_count, double *N) |
ON_DECL bool | ON_EvaluateNurbsBlossom (int, int, int, const double *, const double *, const double *, double *) |
ON_DECL bool | ON_EvaluateNurbsCageSpan (int dim, bool is_rat, int order0, int order1, int order2, const double *knot0, const double *knot1, const double *knot2, int cv_stride0, int cv_stride1, int cv_stride2, const double *cv, int der_count, double t0, double t1, double t2, int v_stride, double *v) |
ON_DECL bool | ON_EvaluateNurbsDeBoor (int, int, int, double *, const double *, int, double, double) |
ON_DECL bool | ON_EvaluateNurbsSpan (int dim, bool is_rat, int order, const double *knot, int cv_stride, const double *cv, int der_count, double t, int v_stride, double *v) |
ON_DECL bool | ON_EvaluateNurbsSurfaceSpan (int dim, bool is_rat, int order0, int order1, const double *knot0, const double *knot1, int cv_stride0, int cv_stride1, const double *cv, int der_count, double s, double t, int v_stride, double *v) |
ON_DECL bool | ON_EvaluateQuotientRule (int dim, int der_count, int v_stride, double *v) |
ON_DECL bool | ON_EvaluateQuotientRule2 (int dim, int der_count, int v_stride, double *v) |
ON_DECL bool | ON_EvaluateQuotientRule3 (int dim, int der_count, int v_stride, double *v) |
ON_DECL void | ON_EvaluateSurfaceSectionalCurvature (const class ON_Surface *surface, const class ON_SectionAnalysisAppearance &appearance, ON_PlaneEquation plane_eqn, unsigned int uv_point_count, size_t uv_point_stride, const double *uv_points, ON_SimpleArray< ON_3dPoint > &points, ON_SimpleArray< ON_3dVector > &curvatures, ON_SimpleArray< ON_2dPoint > *refined_uv_points) |
ON_DECL bool | ON_EvCurvature (const ON_3dVector &, const ON_3dVector &, ON_3dVector &, ON_3dVector &) |
returns false if first derivative is zero More... | |
ON_DECL bool | ON_EvCurvature1Der (const ON_3dVector &D1, const ON_3dVector &D2, const ON_3dVector &D3, ON_3dVector &T, ON_3dVector &K, double *kprime, double *torsion) |
torsion More... | |
ON_DECL bool | ON_EvJacobian (double, double, double, double *) |
return false if determinant is (nearly) singular More... | |
ON_DECL bool | ON_EvJerk (ON_3dVector D1, ON_3dVector D2, ON_3dVector D3, ON_3dVector &T, ON_3dVector &K, ON_3dVector &J) |
ON_DECL bool | ON_EvNormal (int, const ON_3dVector &, const ON_3dVector &, const ON_3dVector &, const ON_3dVector &, const ON_3dVector &, ON_3dVector &) |
ON_DECL bool | ON_EvNormalPartials (const ON_3dVector &ds, const ON_3dVector &dt, const ON_3dVector &dss, const ON_3dVector &dst, const ON_3dVector &dtt, ON_3dVector &ns, ON_3dVector &nt) |
ON_DECL int | ON_EvNormalYank (const ON_Surface &srf, double u, double v, ON_3dVector srfDirection, ON_3dVector &T, ON_3dVector &K, ON_3dVector &J, ON_3dVector &Y) |
ON_DECL bool | ON_EvPrincipalCurvatures (const ON_3dVector &, const ON_3dVector &, const ON_3dVector &, const ON_3dVector &, const ON_3dVector &, const ON_3dVector &, double *, double *, double *, double *, ON_3dVector &, ON_3dVector &) |
ON_DECL bool | ON_EvPrincipalCurvatures (const ON_3dVector &, const ON_3dVector &, double l, double m, double n, const ON_3dVector &, double *, double *, double *, double *, ON_3dVector &, ON_3dVector &) |
ON_DECL bool | ON_EvSectionalCurvature (const ON_3dVector &S10, const ON_3dVector &S01, const ON_3dVector &S20, const ON_3dVector &S11, const ON_3dVector &S02, const ON_3dVector &planeNormal, ON_3dVector &K) |
ON_DECL bool | ON_EvTangent (const ON_3dVector &, const ON_3dVector &, ON_3dVector &) |
returns false if the returned tangent is zero More... | |
ON_DECL bool | ON_EvYank (ON_3dVector D1, ON_3dVector D2, ON_3dVector D3, ON_3dVector D4, ON_3dVector &T, ON_3dVector &K, ON_3dVector &J, ON_3dVector &Y) |
int | ON_FindLocalMinimum (int(*)(void *, double, double *, double *), void *, double, double, double, double, double, int, double *) |
find a local minimum of a 1 parameter function More... | |
ON_DECL bool | ON_FindMeshMeshIntersectionSets (ON_SimpleArray< ON_MMX_POINT > &pArray, double tol) |
This function is soon going to be deprecated. It always uses the old code. More... | |
ON_DECL bool | ON_FixBrepLoop (ON_Brep &B, int loop_id, bool bCompact=true) |
ON_DECL bool | ON_FixBrepLoops (ON_Brep &B, ON_SimpleArray< int > *loop_ids=0) |
ON_DECL void | ON_FixNurbsSurfacePole (ON_NurbsSurface &srf, int side, const ON_3dPoint *pPole) |
ON_DECL void | ON_FixNurbsSurfaceSeam (ON_NurbsSurface &srf, int dir, bool bMakeG1) |
ON_DECL float | ON_FloatCeil (double x) |
ON_DECL float | ON_FloatFloor (double x) |
ON_DECL float | ON_FloatFromDouble (double x) |
ON_DECL void | ON_FLT_SNAN (float *x) |
ON_DECL bool | ON_ForceMatchCurveEnds (ON_Curve &Crv0, int end0, ON_Curve &Crv1, int end1) |
ON_DECL bool | ON_FPU_AfterDotNetJITUse (void) |
ON_DECL bool | ON_FPU_AfterSloppyCall (void) |
ON_DECL bool | ON_FPU_BeforeSloppyCall (void) |
ON_DECL bool | ON_FPU_Check (bool bCheckExceptionStatus, bool bCheckControl, bool bCall_ON_Error) |
ON_DECL void | ON_FPU_ClearExceptionStatus () |
ON_DECL ON__UINT32 | ON_FPU_ControlWord () |
ON_DECL bool | ON_FPU_EnableInvalidStatusCheck (bool bEnableInvalidStatusCheck) |
ON_DECL ON__UINT32 | ON_FPU_ExceptionStatus () |
ON_DECL ON__UINT32 | ON_FPU_Init (void) |
ON_DECL ON__UINT32 | ON_FPU_InitControlWord (void) |
ON_DECL bool | ON_FPU_InvalidStatusCheckEnabled () |
ON_DECL bool | ON_FPU_UnmaskExceptions (ON__UINT32 unmasked_ex) |
ON_DECL int | ON_Get3dConvexHull (const ON_SimpleArray< ON_3dPoint > &points, ON_SimpleArray< ON_PlaneEquation > &hull) |
ON_DECL int | ON_GetBase32Digits (const ON_SimpleArray< unsigned char > &x, ON_SimpleArray< unsigned char > &base32_digits) |
ON_DECL int | ON_GetBase32Digits (const unsigned char *x, int x_count, unsigned char *base32_digits) |
ON_DECL bool | ON_GetCageXform (const ON_NurbsCage &cage, ON_Xform &cage_xform) |
ON_DECL bool | ON_GetClosestPointInPointList (int point_count, const ON_3dPoint *point_list, ON_3dPoint P, int *closest_point_index) |
ON_DECL bool | ON_GetClosestPointOnTriangle (const double A[3], const double B[3], const double C[3], const double N[3], const double test_point[3], double triangle_bc[3]) |
ON_DECL bool | ON_GetClosestPointOnTriangle (const float A[3], const float B[3], const float C[3], const float N[3], const double test_point[3], double triangle_bc[3]) |
ON_DECL bool | ON_GetConicEquationThrough6Points (int stride, const double *points2d, double conic[6], double *max_pivot, double *min_pivot, double *zero_pivot) |
ON_DECL int | ON_GetDebugBreak (void) |
ON_DECL int | ON_GetDebugBreakOnFirstError (void) |
ON_DECL int | ON_GetDebugErrorMessage (void) |
ON_DECL unsigned int | ON_GetEigenvectors (const unsigned int N, const double *const *M, bool bTransposeM, double lambda, unsigned int lambda_multiplicity, const double *termination_tolerances, double **eigenvectors, double *eigenprecision, double *eigenpivots) |
ON_DECL bool | ON_GetEllipseConicEquation (double a, double b, double x0, double y0, double alpha, double conic[6]) |
ON_DECL bool | ON_GetEndCapTransformation (ON_3dPoint P, ON_3dVector T, ON_3dVector U, const ON_3dVector *Normal, ON_Xform &xform, ON_Xform *scale2d, ON_Xform *rot2d) |
ON_DECL int | ON_GetErrorCount (void) |
ON_DECL double | ON_GetFittingTolerance (const class ON_SurfaceTreeNode *snodeA, const class ON_SurfaceTreeNode *snodeB, double intersection_tolerance, double fitting_tolerance) |
ON_DECL bool | ON_GetFunctionRoot (void(*func)(void *, double, double *, double *), void *funcarg, double t0, double t1, double *root) |
ON_DECL bool | ON_GetGregorianMonthAndDayOfMonth (unsigned int year, unsigned int day_of_year, unsigned int *month, unsigned int *day_of_month) |
ON_DECL bool | ON_GetGrevilleAbcissae (int, int, const double *, bool, double *) |
ON_DECL bool | ON_GetGrevilleKnotVector (int, const double *, bool, int, int, double *) |
ON_DECL bool | ON_GetHighCurvatureSpans (const ON_Curve &crv, double tolerance, ON_SimpleArray< int > *span_indices) |
ON_DECL bool | ON_GetKnotVectorDomain (int, int, const double *, double *, double *) |
ON_DECL bool | ON_GetKnotVectorSpanVector (int, int, const double *, double *) |
ON_DECL int | ON_GetMathErrorCount (void) |
ON_DECL bool | ON_GetMatrixSVD (int row_count, int col_count, double const *const *A, double **&U, double *&W, double **&V) |
ON_DECL bool | ON_GetMeshMeshClosestPoint (const ON_Mesh &MeshA, const ON_Mesh &MeshB, double max_dist, bool bUseMultipleThreads, int *fidA, double a[4], int *fidB, double b[4]) |
ON_DECL ON_UUID | ON_GetMostRecentClassIdCreateUuid () |
ON_DECL bool | ON_GetNextCurveSpan (const ON_Curve &crv, double t0, double t1, double tolerance, bool(*check)(const ON_Curve &, double, double, double), ON_Interval *seg_dom, int *span_index) |
ON_DECL bool | ON_GetParameterTolerance (double, double, double, double *, double *) |
ON_DECL bool | ON_GetPointGridBoundingBox (int dim, bool is_rat, int point_count0, int point_count1, int point_stride0, int point_stride1, const double *point_grid, double *boxmin, double *boxmax, int bGrowBox) |
ON_DECL bool | ON_GetPointListBoundingBox (int dim, bool is_rat, int count, int stride, const double *point_list, double *boxmin, double *boxmax, int bGrowBox) |
ON_DECL bool | ON_GetPointListBoundingBox (int dim, bool is_rat, int count, int stride, const double *point_list, ON_BoundingBox &bbox, int bGrowBox=false, const ON_Xform *xform=0) |
ON_DECL bool | ON_GetPointListBoundingBox (int dim, bool is_rat, int count, int stride, const float *point_list, float *boxmin, float *boxmax, int bGrowBox) |
ON_DECL bool | ON_GetPointListBoundingBox (int dim, bool is_rat, int count, int stride, const float *point_list, ON_BoundingBox &bbox, int bGrowBox=false, const ON_Xform *xform=0) |
ON_DECL unsigned int * | ON_GetPointLocationIds (size_t point_count, const class ON_2dPoint *points, unsigned int first_point_id, unsigned int *point_ids, unsigned int *point_id_map) |
ON_DECL unsigned int * | ON_GetPointLocationIds (size_t point_count, const class ON_2fPoint *points, unsigned int first_point_id, unsigned int *point_ids, unsigned int *point_id_map) |
ON_DECL unsigned int * | ON_GetPointLocationIds (size_t point_count, const class ON_3dPoint *points, unsigned int first_point_id, unsigned int *point_ids, unsigned int *point_id_map) |
ON_DECL unsigned int * | ON_GetPointLocationIds (size_t point_count, const class ON_3fPoint *points, unsigned int first_point_id, unsigned int *point_ids, unsigned int *point_id_map) |
ON_DECL unsigned int * | ON_GetPointLocationIds (size_t point_dim, size_t point_count, size_t point_stride, const double *points, unsigned int first_point_id, unsigned int *point_ids, unsigned int *point_id_map) |
ON_DECL unsigned int * | ON_GetPointLocationIds (size_t point_dim, size_t point_count, size_t point_stride, const float *points, unsigned int first_point_id, unsigned int *point_ids, unsigned int *point_id_map) |
ON_DECL bool | ON_GetPolylineLength (int, bool, int, int, const double *, double *) |
ON_DECL bool | ON_GetShortSpans (const ON_Curve &crv, double tolerance, ON_SimpleArray< int > *span_indices) |
ON_DECL int | ON_GetSpanIndices (int order, int cv_count, const double *knot, int *) |
ON_DECL bool | ON_GetTrianglePlaneEquation (const ON_3dPoint &A, const ON_3dPoint &B, const ON_3dPoint &C, double *a, double *b, double *c, double *d, double *evaluation_tol) |
ON_DECL unsigned int | ON_GetVersionQuartet (unsigned int major_version, unsigned int minor_version, unsigned int year, unsigned int month, unsigned int day_of_month, unsigned int hour, unsigned int minute, unsigned int branch, unsigned short quartet_values[4]) |
ON_DECL unsigned int | ON_GetVersionString (unsigned int major_version, unsigned int minor_version, unsigned int year, unsigned int month, unsigned int day_of_month, unsigned int hour, unsigned int minute, unsigned int branch, size_t string_buffer_capacity, char *string_buffer) |
ON_DECL unsigned int | ON_GetVersionWideString (unsigned int major_version, unsigned int minor_version, unsigned int year, unsigned int month, unsigned int day_of_month, unsigned int hour, unsigned int minute, unsigned int branch, size_t string_buffer_capacity, wchar_t *string_buffer) |
ON_DECL bool | ON_GetViewportRotationAngles (const ON_3dVector &, const ON_3dVector &, const ON_3dVector &, double *, double *, double *) |
ON_DECL int | ON_GetWarningCount (void) |
void | ON_GL (const int, const int, const double *, GLfloat *, int=0, double *=nullptr) |
void | ON_GL (const ON_3dPoint &) |
must be bracketed by calls to glBegin(GL_POINTS) / glEnd() More... | |
void | ON_GL (const ON_Brep &, GLUnurbsObj *) |
Use ON_GL( const ON_Brep&, ...) to render OpenNURBS b-reps. More... | |
void | ON_GL (const ON_BrepFace &, GLUnurbsObj *) |
void | ON_GL (const ON_Color &, double, GLfloat[4]) |
void | ON_GL (const ON_Color &, GLfloat[4]) |
Use ON_GL( const ON_Color ...) to set GL color to OpenNURBS color. More... | |
void | ON_GL (const ON_Curve &, GLUnurbsObj *, GLenum=0, double[][4]=nullptr) |
void | ON_GL (const ON_Light &, GLenum) |
void | ON_GL (const ON_Light *, GLenum) |
void | ON_GL (const ON_Material &) |
Use ON_GL( const ON_Material ...) to set GL material to OpenNURBS material. More... | |
void | ON_GL (const ON_Material *) |
void | ON_GL (const ON_Mesh &) |
Use ON_GL( const ON_Mesh&, ...) to render OpenNURBS meshes. More... | |
void | ON_GL (const ON_NurbsCurve &, GLUnurbsObj *, GLenum=0, int=1, double *=nullptr, double[][4]=nullptr) |
void | ON_GL (const ON_NurbsSurface &, GLUnurbsObj *, GLenum=0, int=1, double *=nullptr, double *=nullptr) |
void | ON_GL (const ON_Point &) |
Use ON_GL( const ON_Point, ...) to render single points. More... | |
void | ON_GL (const ON_PointCloud &) |
Use ON_GL( const ON_PointCloud, ...) to render Rhino point sets. More... | |
void | ON_GL (const ON_Surface &, GLUnurbsObj *) |
must be bracketed by calls to gluBeginSurface( nobj )/gluEndSurface( nobj ) More... | |
void | ON_GL (const ON_Viewport &) |
void | ON_GL (int, int, int, int, const double *, int, const double *, GLUnurbsObj *, GLenum=0, int=1, double *=nullptr, double[][4]=nullptr) |
void | ON_GL (ON_Viewport &, int, int, int, int) |
ON_DECL unsigned | ON_GreatestCommonDivisor (unsigned a, unsigned b) |
ON_DECL double | ON_GrevilleAbcissa (int, const double *) |
ON_DECL double | ON_HairlinePrintWidth () |
ON_DECL void | ON_hsort (void *base, size_t count, size_t sizeof_element, int(*compare)(const void *, const void *)) |
ON_DECL void | ON_hsort (void *base, size_t count, size_t sizeof_element, int(*compare)(void *, const void *, const void *), void *context) |
void | ON_HSORT_FNAME (ON_SORT_TEMPLATE_TYPE *base, size_t nel) |
const ON_DECL ON_wString | ON_IdToString (ON_UUID id) |
ON_DECL bool | ON_IncreaseBezierDegree (int, bool, int, int, double *) |
ON_DECL ON__UINT64 | ON_IndexFromNotUniqueId (ON_UUID not_unique_id) |
ON_DECL int | ON_InsertKnot (double, int, int, int, int, int, double *, double *, int *) |
ON_DECL double | ON_Integrate (const class ON_Curve &curve, double(*f)(ON__UINT_PTR context, int limit_direction, double t), ON__UINT_PTR f_context, ON_Interval integration_limit, double relative_tolerance, double absolute_tolerance, double *error_bound) |
Calculates the definite integral of a smooth (C-infinity) function of one variable using a Rhomberg integration technique and returns returns Integral(f(t)*|curve'(t)|*dt). The C-infinity requirement is used by the Rhomberg algorithm when estimating error bounds and convergence. If you choose to pass a C2 function, you are likely to converge while getting less accurate results and incorrect error bound estimates. Using a C0 or C1 fucntion will ofter return nonsense. More... | |
ON_DECL double | ON_Integrate (const class ON_Surface &surface, double(*f)(ON__UINT_PTR context, int limit_direction, double s, double t), ON__UINT_PTR f_context, ON_Interval integration_limit1, ON_Interval integration_limit2, double relative_tolerance, double absolute_tolerance, double *error_bound) |
Calculates the definite integral of a smooth (C-infinity) function of two variables using a Rhomberg integration technique and returns returns Integral(f(s,t)*|dS/ds(s,t) x dS/dt(s,t)|*ds*dt), where dS/ds and dS/dt are the surface's first partial derivatives. The C-infinity requirement is used by the Rhomberg algorithm when estimating error bounds and convergence. If you choose to pass a C2 function, you are likely to converge while getting less accurate results and incorrect error bound estimates. Using a C0 or C1 fucntion will ofter return nonsense. More... | |
ON_DECL double | ON_Integrate (double(*f)(ON__UINT_PTR context, int limit_direction, double s, double t), ON__UINT_PTR f_context, const ON_SimpleArray< double > &limits1, const ON_SimpleArray< double > &limits2, double relative_tolerance, double absolute_tolerance, double *error_bound) |
Calculates the definite integral of a piecewise smooth (C-infinity) function of two variables using a Rhomberg integration technique. The C-infinity requirement is used by the Rhomberg algorithm when estimating error bounds and convergence. If you choose to pass a C2 function, you are likely to converge while getting less accurate results and incorrect error bound estimates. Using a C0 or C1 fucntion will ofter return nonsense. More... | |
ON_DECL double | ON_Integrate (double(*f)(ON__UINT_PTR context, int limit_direction, double s, double t), ON__UINT_PTR f_context, ON_Interval limits1, ON_Interval limits2, double relative_tolerance, double absolute_tolerance, double *error_bound) |
Calculates the definite integral of a smooth (C-infinity) function of two variables using a Rhomberg integration technique. The C-infinity requirement is used by the Rhomberg algorithm when estimating error bounds and convergence. If you choose to pass a C2 function, you are likely to converge while getting less accurate results and incorrect error bound estimates. Using a C0 or C1 fucntion will ofter return nonsense. More... | |
ON_DECL double | ON_Integrate (double(*f)(ON__UINT_PTR context, int limit_direction, double t), ON__UINT_PTR f_context, const ON_SimpleArray< double > &limits, double relative_tolerance, double absolute_tolerance, double *error_bound) |
Calculates the definite integral of a piecewise smooth (C-infinity) function of one variable using a Rhomberg integration technique and returns returns Integral(f(t)dt). The C-infinity requirement is used by the Rhomberg algorithm when estimating error bounds and convergence. If you choose to pass a C2 function, you are likely to converge while getting less accurate results and incorrect error bound estimates. Using a C0 or C1 fucntion will ofter return nonsense. More... | |
ON_DECL double | ON_Integrate (double(*f)(ON__UINT_PTR context, int limit_direction, double t), ON__UINT_PTR f_context, ON_Interval limits, double relative_tolerance, double absolute_tolerance, double *error_bound) |
Calculates the definite integral of a smooth (C-infinity) function of one variable using a Rhomberg integration technique and returns returns Integral(f(t)dt). The C-infinity requirement is used by the Rhomberg algorithm when estimating error bounds and convergence. If you choose to pass a C2 function, you are likely to converge while getting less accurate results and incorrect error bound estimates. Using a C0 or C1 fucntion will ofter return nonsense. More... | |
void * | ON_Internal_CompareExchangePointer (void *volatile *dest, void *exchange, void *comparand) |
ON_DECL int | ON_Intersect (const ON_Arc &arc0, const ON_Arc &arc1, ON_3dPoint &point0, ON_3dPoint &point1) |
ON_DECL bool | ON_Intersect (const ON_BoundingBox &bbox, const ON_Line &line, double tolerance, ON_Interval *line_parameters) |
ON_DECL int | ON_Intersect (const ON_Circle &c0, const ON_Circle &c1, ON_3dPoint &point0, ON_3dPoint &point1) |
ON_DECL int | ON_Intersect (const ON_Line &, const ON_Cylinder &, ON_3dPoint &, ON_3dPoint &) |
ON_DECL bool | ON_Intersect (const ON_Line &, const ON_Line &, double *, double *) |
ON_DECL bool | ON_Intersect (const ON_Line &, const ON_Plane &, double *) |
ON_DECL int | ON_Intersect (const ON_Line &, const ON_Sphere &, ON_3dPoint &, ON_3dPoint &) |
ON_DECL int | ON_Intersect (const ON_Line &line, const ON_Arc &arc, double *line_t0, ON_3dPoint &arc_point0, double *line_t1, ON_3dPoint &arc_point1) |
ON_DECL int | ON_Intersect (const ON_Line &line, const ON_Circle &circle, double *line_t0, ON_3dPoint &circle_point0, double *line_t1, ON_3dPoint &circle_point1) |
ON_DECL bool | ON_Intersect (const ON_Line &line, const ON_PlaneEquation &plane_equation, double *line_parameter) |
ON_DECL bool | ON_Intersect (const ON_Plane &, const ON_Plane &, const ON_Plane &, ON_3dPoint &) |
ON_DECL bool | ON_Intersect (const ON_Plane &, const ON_Plane &, ON_Line &) |
ON_DECL int | ON_Intersect (const ON_Plane &, const ON_Sphere &, ON_Circle &) |
ON_DECL int | ON_Intersect (const ON_Plane &plane, const ON_Arc &arc, ON_3dPoint &point0, ON_3dPoint &point1) |
ON_DECL int | ON_Intersect (const ON_Plane &plane, const ON_Circle &circle, ON_3dPoint &point0, ON_3dPoint &point1) |
ON_DECL int | ON_Intersect (const ON_Sphere &sphere0, const ON_Sphere &sphere1, ON_Circle &circle) |
ON_DECL unsigned int | ON_IntersectCoplanarLineAndTriangle (const double A[3], const double B[3], const double C[3], const double N[3], const double P[3], const double Q[3], double line_t[2], double triangle_bc[2][3]) |
ON_DECL unsigned int | ON_IntersectLineAndTriangle (const double A[3], const double B[3], const double C[3], const ON_TrianglePlane *tri_plane, const double P[3], const double Q[3], double tolerance, double line_t[2], double triangle_bc[2][3]) |
ON_DECL bool | ON_IntersectLineLine (const ON_Line &lineA, const ON_Line &lineB, double *a, double *b, double tolerance, bool bIntersectSegments) |
ON_DECL bool | ON_IntersectMeshRay (const ON_Mesh *mesh, const ON_3dRay &ray, double tolerance, ON_SimpleArray< double > &ray_ts) |
ON_DECL bool | ON_IntersectViewFrustumPlane (const ON_Viewport &vp, const ON_PlaneEquation &plane_equation, ON_SimpleArray< ON_3dPoint > &points) |
ON_DECL int | ON_InvertSVDW (int count, const double *W, double *&invW) |
ON_DECL bool | ON_Is2dPatternSquished (const ON_Geometry *geometry) |
ON_DECL bool | ON_IsConicEquationAnEllipse (const double conic[6], ON_2dPoint ¢er, ON_2dVector &major_axis, ON_2dVector &minor_axis, double *major_radius, double *minor_radius) |
ON_DECL bool | ON_IsContinuous (ON::continuity c, ON_3dPoint Pa, ON_3dVector D1a, ON_3dVector D2a, ON_3dPoint Pb, ON_3dVector D1b, ON_3dVector D2b, 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) |
ON_DECL bool | ON_IsConvexPolyline (const ON_SimpleArray< ON_3dPoint > &points, bool bStrictlyConvex) |
ON_DECL bool | ON_IsConvexPolyline (size_t point_dim, size_t point_count, const double *points, size_t point_stride, bool bStrictlyConvex) |
ON_DECL bool | ON_IsCurvatureDiscontinuity (const ON_3dVector Km, const ON_3dVector Kp, double cos_angle_tolerance, double curvature_tolerance, double zero_curvature, double radius_tolerance) |
ON_DECL bool | ON_IsCurvatureDiscontinuity (const ON_3dVector Km, const ON_3dVector Kp, double cos_angle_tolerance, double curvature_tolerance, double zero_curvature, double radius_tolerance, double relative_tolerance) |
void ON_DECL | ON_IsG1Closed (const ON_Surface &Srf, bool closed[2]) |
ON_DECL bool | ON_IsG2CurvatureContinuous (const ON_3dVector Km, const ON_3dVector Kp, double cos_angle_tolerance, double curvature_tolerance) |
ON_DECL bool | ON_IsGregorianLeapYear (unsigned int year) |
ON_DECL bool | ON_IsGsmoothCurvatureContinuous (const ON_3dVector Km, const ON_3dVector Kp, double cos_angle_tolerance, double curvature_tolerance) |
ON_DECL bool | ON_IsHairlinePrintWidth (double width_mm) |
ON_DECL bool | ON_IsKnotVectorClamped (int order, int cv_count, const double *knot, int=2) |
ON_DECL bool | ON_IsKnotVectorPeriodic (int order, int cv_count, const double *knot) |
ON_DECL bool | ON_IsKnotVectorUniform (int order, int cv_count, const double *knot) |
bool | ON_IsLongChunkTypecode (ON__UINT32 typecode) |
ON_DECL bool | ON_IsNaNd (double x) |
ON_DECL bool | ON_IsNaNf (float x) |
ON_DECL bool | ON_IsNotValid () |
ON_DECL bool | ON_IsNullPtr (const ON__INT_PTR ptr) |
ON_DECL bool | ON_IsNullPtr (const ON__UINT_PTR ptr) |
ON_DECL bool | ON_IsNullPtr (const void *ptr) |
ON_DECL unsigned int | ON_IsOpennurbsApplicationId (ON_UUID id) |
ON_DECL bool | ON_IsOrthogonalFrame (const ON_2dVector &, const ON_2dVector &) |
ON_DECL bool | ON_IsOrthogonalFrame (const ON_2fVector &, const ON_2fVector &) |
ON_DECL bool | ON_IsOrthogonalFrame (const ON_3dVector &, const ON_3dVector &, const ON_3dVector &) |
ON_DECL bool | ON_IsOrthogonalFrame (const ON_3fVector &, const ON_3fVector &, const ON_3fVector &) |
ON_DECL bool | ON_IsOrthonormalFrame (const ON_2dVector &, const ON_2dVector &) |
ON_DECL bool | ON_IsOrthonormalFrame (const ON_2fVector &, const ON_2fVector &) |
ON_DECL bool | ON_IsOrthonormalFrame (const ON_3dVector &, const ON_3dVector &, const ON_3dVector &) |
ON_DECL bool | ON_IsOrthonormalFrame (const ON_3fVector &, const ON_3fVector &, const ON_3fVector &) |
ON_DECL bool | ON_IsPointGridClosed (int, bool, int, int, int, int, const double *, int) |
ON_DECL bool | ON_IsPointListClosed (int, bool, int, int, const double *) |
ON_DECL int | ON_IsPointListPlanar (bool bRational, int count, int stride, const double *points, const double *boxMin, const double *boxMax, double tolerance, ON_PlaneEquation *plane_equation) |
bool | ON_IsPotentialWindowsCodePage932DoubleByteEncoding (ON__UINT32 lead_byte, ON__UINT32 trailing_byte) |
bool | ON_IsPotentialWindowsCodePage932SingleByteEncoding (ON__UINT32 x) |
bool | ON_IsPotentialWindowsCodePage949DoubleByteEncoding (ON__UINT32 lead_byte, ON__UINT32 trailing_byte) |
bool | ON_IsPotentialWindowsCodePage949SingleByteEncoding (ON__UINT32 x) |
ON_DECL bool | ON_IsPrivateUseUnicodeCodePoint (ON__UINT32 unicode_code_point) |
ON_DECL bool | ON_IsProjectedPointOnTriangleBoundary (const double A[3], const double B[3], const double C[3], const double N[3], const double test_point[3]) |
ON_DECL bool | ON_IsProjectedPointOnTriangleBoundary (const float A[3], const float B[3], const float C[3], const float N[3], const double test_point[3]) |
ON_DECL bool | ON_IsQNaNd (double x) |
ON_DECL bool | ON_IsQNaNf (float x) |
ON_DECL unsigned int | ON_IsRhinoApplicationId (ON_UUID id) |
ON_DECL bool | ON_IsRightHandFrame (const ON_2dVector &, const ON_2dVector &) |
ON_DECL bool | ON_IsRightHandFrame (const ON_2fVector &, const ON_2fVector &) |
ON_DECL bool | ON_IsRightHandFrame (const ON_3dVector &, const ON_3dVector &, const ON_3dVector &) |
ON_DECL bool | ON_IsRightHandFrame (const ON_3fVector &, const ON_3fVector &, const ON_3fVector &) |
bool | ON_IsShortChunkTypecode (ON__UINT32 typecode) |
ON_DECL bool | ON_IsSNaNd (double x) |
ON_DECL bool | ON_IsSNaNf (float x) |
ON_DECL bool | ON_IsStandardUnicodeCodePoint (ON__UINT32 unicode_code_point) |
ON_DECL int | ON_IsUnicodeC1ControlCodePoint (ON__UINT32 u) |
ON_DECL bool | ON_IsUnicodeControlCodePoint (ON__UINT32 code_point, bool bNullReturnValue) |
ON_DECL int | ON_IsUnicodeSpaceCodePoint (ON__UINT32 u) |
ON_DECL int | ON_IsUnicodeSpaceOrControlCodePoint (ON__UINT32 u) |
ON_DECL enum ON_UnicodeEncoding | ON_IsUTFByteOrderMark (const void *buffer, size_t sizeof_buffer) |
ON_DECL bool | ON_IsValid (double x) |
ON_DECL bool | ON_IsValidFloat (float x) |
ON_DECL bool | ON_IsValidKnotVector (int order, int cv_count, const double *knot, ON_TextLog *text_log=0) |
ON_DECL bool | ON_IsValidNegativeNumber (double x) |
ON_DECL bool | ON_IsValidPointGrid (int, bool, int, int, int, int, const double *) |
ON_DECL bool | ON_IsValidPointList (int, bool, int, int, const double *) |
ON_DECL bool | ON_IsValidPointList (int, bool, int, int, const float *) |
ON_DECL bool | ON_IsValidPositiveNumber (double x) |
ON_DECL int | ON_IsValidSingleByteUTF8CharValue (char c) |
ON_DEPRECATED. More... | |
ON_DECL int | ON_IsValidSingleElementUTF16Value (ON__UINT32 c) |
ON_DEPRECATED. More... | |
ON_DECL int | ON_IsValidSingleElementUTF8Value (ON__UINT32 c) |
ON_DEPRECATED. More... | |
ON_DECL int | ON_IsValidSingleElementWideCharValue (wchar_t w) |
ON_DECL int | ON_IsValidUnicodeCodePoint (ON__UINT32 unicode_code_point) |
ON_DECL int | ON_IsValidUTF16Singleton (ON__UINT32 c) |
ON_DECL int | ON_IsValidUTF16SurrogatePair (unsigned int w1, unsigned int w2) |
ON_DECL int | ON_IsValidUTF32Value (ON__UINT32 c) |
ON_DECL int | ON_IsValidUTF8Singleton (ON__UINT32 c) |
ON_DECL int | ON_IsValidUTF8SingletonChar (char c) |
ON_DECL int | ON_JoinCurves (const ON_SimpleArray< const ON_Curve * > &InCurves, ON_SimpleArray< ON_Curve * > &OutCurves, double join_tol, bool bPreserveDirection=false, ON_SimpleArray< int > *key=0) |
ON_DECL int | ON_JoinCurves (const ON_SimpleArray< const ON_Curve * > &InCurves, ON_SimpleArray< ON_Curve * > &OutCurves, double join_tol, double kink_tol, bool bUseTanAngle, bool bPreserveDirection=false, ON_SimpleArray< int > *key=0) |
ON_DECL int | ON_JoinCurvesOld (const ON_SimpleArray< const ON_Curve * > &InCurves, ON_SimpleArray< ON_Curve * > &OutCurves, double join_tol, bool bPreserveDirection, ON_SimpleArray< int > *key) |
ON_DECL int | ON_JoinLines (const ON_SimpleArray< ON_Line > &InLines, ON_ClassArray< ON_Polyline > &OutPolylines, double tolerance, bool bPreserveDirection, ON_SimpleArray< int > *pKey) |
ON_DECL int | ON_JoinPolylines (const ON_SimpleArray< const ON_Polyline * > &InPlines, ON_SimpleArray< ON_Polyline * > &OutPlines, double join_tol, double kink_tol, bool bUseTanAngle, bool bPreserveDirection=false, ON_SimpleArray< int > *key=0) |
ON_DECL int | ON_KnotCount (int, int) |
ON_DECL int | ON_KnotMultiplicity (int, int, const double *, int) |
ON_DECL double | ON_KnotTolerance (int, int, const double *, int) |
ON_DECL bool | ON_KnotVectorHasBezierSpans (int order, int cv_count, const double *knot) |
returns true if all knots have multiplicity = degree More... | |
ON_DECL int | ON_KnotVectorSpanCount (int, int, const double *) |
ON_DECL ON::knot_style | ON_KnotVectorStyle (int order, int cv_count, const double *knot) |
ON_DECL unsigned | ON_LeastCommonMultiple (unsigned a, unsigned b) |
The least common multiple of a and b is (a/gcd)*(b/gcd)*(gcd), where gcd = greatest common divisor of and b. More... | |
ON_DECL double | ON_Length2d (double x, double y) |
ON_DECL double | ON_Length2dSquared (double x, double y) |
ON_DECL double | ON_Length3d (double x, double y, double z) |
ON_DECL double | ON_Length3dSquared (double x, double y, double z) |
ON_2dPoint ON_DECL | ON_LiftInverse (ON_2dPoint P, ON_Interval dom[2], bool closed[2]) |
ON_DECL ON_SimpleArray< ON_2dPoint > | ON_LiftToCover (const ON_SimpleArray< ON_2dPoint > &in, const ON_Interval dom[2], bool closed[2], double normband=1.0/3.0) |
ON_DECL double | ON_LinearInterpolation (double t, double x, double y) |
ON_DECL int | ON_LineTriangleIntersect (const ON_3dPoint &A, const ON_3dPoint &B, const ON_3dPoint &C, const ON_3dPoint &P, const ON_3dPoint &Q, double abc[2][3], double t[2], double tol) |
ON_DECL bool | ON_MakeClampedUniformKnotVector (int order, int cv_count, double *knot, double delta=1.0) |
ON_DECL bool | ON_MakeKnotVectorPeriodic (int, int, double *) |
ON_DECL bool | ON_MakePeriodicUniformKnotVector (int order, int cv_count, double *knot, double delta=1.0) |
ON_DECL ON__UINT32 | ON_MapMSSBCPToUnicode (ON__UINT32 code_page, ON__UINT32 code_page_single_byte_encoding) |
ON_DECL ON__UINT32 | ON_MapRTFcharsetToWindowsCodePage (ON__UINT32 rtf_charset, ON__UINT32 default_code_page) |
ON_DECL ON__UINT32 | ON_MapUnicodeToMSSBCP (ON__UINT32 code_page, ON__UINT32 unicode_code_point) |
int | ON_MapWindowsCodePage932ToUnicode (ON__UINT32 code_page_932_character_value, ON__UINT32 *unicode_code_point) |
int | ON_MapWindowsCodePage949ToUnicode (ON__UINT32 code_page_949_character_value, ON__UINT32 *unicode_code_point) |
ON_DECL void | ON_MathError (const char *, const char *, const char *) |
ON_DECL double | ON_MatrixSolutionPrecision (const unsigned int N, const double *const *M, bool bTransposeM, double lambda, const double *X, const double *B) |
ON_DECL double | ON_Max (double a, double b) |
ON_DECL float | ON_Max (float a, float b) |
ON_DECL int | ON_Max (int a, int b) |
ON_DECL double | ON_MaximumCoordinate (const double *data, int dim, bool is_rat, int count) |
Find the largest absolute value of coordinates from an array of points (possibly homogeneous). More... | |
ON_DECL double | ON_MaximumCoordinate (const double *data, int dim, bool is_rat, int count, int stride) |
stride>=dim+is_rat More... | |
ON_DECL ON_memory_error_handler | ON_memory_error_register_handler (ON_memory_error_handler) |
ON_DECL int | ON_memory_error_test_handler (int error_code) |
ON_DECL void | ON_MemoryManagerBegin (void) |
ON_DECL void | ON_MemoryManagerEnd (void) |
ON_DECL size_t | ON_MemoryPageSize () |
ON_DECL ON_Brep * | ON_MergeBreps (const ON_Brep &brep0, const ON_Brep &brep1, double tolerance) |
ON_DECL bool | ON_Mesh2dPolygon (int point_count, int point_stride, const double *P, int tri_stride, int *triangle) |
ON_DECL int | ON_Mesh2dRegion (int point_count, int point_stride, const double *points, int edge_count, int edge_stride, const int *edges, const int *edge_side, ON_SimpleArray< ON_3dex > &triangles) |
Fill in a 2d region with triangles. More... | |
ON_DECL int | ON_Mesh2dRegion (unsigned int point_count, unsigned int point_stride, const double *points, unsigned int edge_count, unsigned int edge_stride, const unsigned int *edges, unsigned int edge_side_stride, const unsigned char *edge_side, bool bOuterBoundaryIsConvexHull, bool bPermitVertexAdditions, bool bPermitEdgeSplitting, ON_SimpleArray< ON_3dex > &triangles, ON_SimpleArray< ON_2dPoint > &new_points) |
Fill in a 2d region with triangles. More... | |
ON_DECL int | ON_Mesh2dRegion (unsigned int point_count, unsigned int point_stride, const double *points, unsigned int edge_count, unsigned int edge_stride, const unsigned int *edges, unsigned int edge_side_stride, const unsigned char *edge_side, bool bPermitVertexAdditions, bool bPermitEdgeSplitting, ON_SimpleArray< ON_3dex > &triangles, ON_SimpleArray< ON_2dPoint > &new_points) |
Fill in a 2d region with triangles. More... | |
ON_DECL int | ON_Mesh2dRegion (unsigned int point_count, unsigned int point_stride, const double *points, unsigned int edge_count, unsigned int edge_stride, const unsigned int *edges, unsigned int edge_side_stride, const unsigned char *edge_side, ON_SimpleArray< ON_3dex > &triangles, ON_SimpleArray< ON_2dPoint > &new_points) |
Fill in a 2d region with triangles. More... | |
ON_DECL int | ON_MeshClashSearch (int mesh_listA_count, const ON_Mesh *const *mesh_listA, int mesh_listB_count, const ON_Mesh *const *mesh_listB, double distance, bool bUseMultipleThreads, int max_event_count, ON_SimpleArray< class ON_ClashEvent > &clash_events) |
ON_DECL int | ON_MeshFaceClashSearch (const class ON_Mesh *meshA, const class ON_RTree *meshAtree, const class ON_Mesh *meshB, const class ON_RTree *meshBtree, double distance, bool bUseMultipleThreads, int max_event_count, ON_SimpleArray< class ON_ClashEvent > &clash_events) |
ON_DECL void | ON_MeshFaceClashSearch (const class ON_Mesh *meshA, const class ON_RTree *meshAtree, const class ON_Mesh *meshB, const class ON_RTree *meshBtree, double distance, bool bUseMultipleThreads, int max_event_count, ON_SimpleArray< int > &meshA_face_indices, ON_SimpleArray< int > &meshB_face_indices) |
ON_DECL bool | ON_MeshGetClosestPoint (const ON_Mesh *mesh, ON_3dPoint P, ON_MESH_POINT *t, double distance_tolerance=0.0) |
ON_DECL bool | ON_MeshMeshIntersect (const ON_Mesh *meshA, const ON_Mesh *meshB, ON_ClassArray< ON_MMX_Polyline > &plines, ON_ClassArray< ON_MMX_Polyline > &overlapplines, double intersection_tolerance=0.0, double overlap_tolerance=0.0, bool bDebug=false) |
This function is soon going to be deprecated. It always uses the old code. More... | |
ON_DECL bool | ON_MeshMeshIntersectOldCompliant (const ON_Mesh *meshA, const ON_Mesh *meshB, ON_ClassArray< ON_Polyline > &plines, ON_ClassArray< ON_Polyline > &overlapplines, double intersection_tolerance=0.0, double overlap_tolerance=0.0, bool bDebug=false) |
ON_DECL ON_Mesh * | ON_MeshSurface (const ON_Surface &surface, int mesh_density=0, ON_Mesh *mesh=0) |
ON_DECL ON_Mesh * | ON_MeshSurface (const ON_Surface &surface, int u_count, const double *u, int v_count, const double *v, bool bDoublePrecisionMesh, ON_Mesh *mesh) |
ON_DECL ON_Mesh * | ON_MeshSurface (const ON_Surface &surface, int u_count, const double *u, int v_count, const double *v, ON_Mesh *mesh=0) |
ON_DECL double | ON_Min (double a, double b) |
ON_DECL float | ON_Min (float a, float b) |
ON_DECL int | ON_Min (int a, int b) |
ON_DECL double | ON_Minimize (unsigned n, double(*f)(ON__UINT_PTR context, const double *t, double *grad), ON__UINT_PTR f_context, const ON_Interval search_domain[], const double t0[], double terminate_value, double relative_tolerance, double zero_tolerance, unsigned maximum_iterations, double t[], bool *bConverged) |
Find a local minimum of the object function f(t[]) of n independent variables. The function must be C2 on the search domain. The search begins at t0[]. More... | |
const ON_DECL ON__UINT32 * | ON_MSSBCP_0x80_0xFF_Unicode (ON__UINT32 code_page) |
ON_DECL int | on_MultiByteToWideChar (const char *, int, wchar_t *, int) |
ON_DECL bool | ON_MX_GetUseNewCode () |
ON_DECL void | ON_MX_SetUseNewCode (bool value) |
ON_DECL ON_CurveTreeBezier * | ON_NewCurveTreeBezier (const ON_BezierCurve &bez) |
ON_DECL ON_CurveTreeBezier * | ON_NewCurveTreeBezier (int dim, bool is_rat, int order) |
ON_DECL ON_SurfaceTreeBezier * | ON_NewSurfaceTreeBezier (const ON_BezierSurface &bez) |
ON_DECL ON_SurfaceTreeBezier * | ON_NewSurfaceTreeBezier (int dim, bool is_rat, int order0, int order1) |
ON__UINT64 | ON_NextContentSerialNumber () |
ON_DECL ON_UUID | ON_NextNotUniqueId (ON_UUID not_unique_id) |
ON_DECL int | ON_NextNurbsSpanIndex (int order, int cv_count, const double *knot, int) |
ON_DECL ON_3dVector | ON_NormalCurvature (const ON_3dVector &, const ON_3dVector &, const ON_3dVector &, const ON_3dVector &, const ON_3dVector &, const ON_3dVector &, const ON_3dVector &) |
ON_DECL ON_UUID | ON_NotUniqueIdFromIndex (ON__UINT32 index_32_bit) |
ON_DECL ON_UUID | ON_NotUniqueIdFromIndex (ON__UINT64 index_64_bit) |
ON_DECL int | ON_NurbsSpanIndex (int order, int cv_count, const double *knot, double t, int side, int hint) |
ON_DECL ON_NurbsSurface * | ON_NurbsSurfaceQuadrilateral (const ON_3dPoint &P, const ON_3dPoint &Q, const ON_3dPoint &R, const ON_3dPoint &S, ON_NurbsSurface *nurbs_surface=nullptr) |
ON_DECL bool | ON_OrderEdgesAroundVertex (const ON_Brep &B, int vid, ON_2dex *trim_ends, bool &bClosed) |
ON_DECL bool | ON_OrderEdgesAroundVertex (const ON_Brep &B, int vid, ON_SimpleArray< ON_2dex > &trim_ends, bool &bClosed) |
ON_DECL bool | ON_PackTextureRectangles (class ON_PackedTextureRectangle *rectangle_list, const class ON_PackTextureRectanglesParameters *packing_parameters) |
ON_DECL bool | ON_PackTextureRectangles (ON_SimpleArray< ON_PackedTextureRectangle > &rectangle_array, const class ON_PackTextureRectanglesParameters *packing_parameters) |
ON_DECL bool | ON_PackTextureRectangles (size_t rectangle_count, class ON_PackedTextureRectangle *rectangle_array, const class ON_PackTextureRectanglesParameters *packing_parameters) |
ON_DECL int | ON_ParseAngleArcDegreesExpression (const wchar_t *str, int str_count, ON::AngleUnitSystem default_str_angle_unit_system, double *angle_value_in_arc_degrees) |
ON_DECL int | ON_ParseAngleExpression (const wchar_t *str, int str_count, ON_ParseSettings parse_settings, const ON::AngleUnitSystem angle_value_unit_system, double *angle_value, ON_ParseSettings *parse_results, ON::AngleUnitSystem *str_angle_unit_system) |
ON_DECL int | ON_ParseAngleExpression (const wchar_t *str, int str_count, ON_ParseSettings parse_settings, double *angle_value, ON_ParseSettings *parse_results, ON::AngleUnitSystem *str_angle_unit_system) |
ON_DECL int | ON_ParseAngleRadiansExpression (const wchar_t *str, int str_count, ON::AngleUnitSystem default_str_angle_unit_system, double *angle_value_in_radians) |
ON_DECL int | ON_ParseAngleUnitName (const wchar_t *str, int str_count, int prefered_locale_id, ON::AngleUnitSystem *angle_unit_system) |
ON_DECL int | ON_ParseAngleUnitName (const wchar_t *str, int str_count, ON_ParseSettings parse_settings, ON::AngleUnitSystem *angle_unit_system) |
ON_DECL int | ON_ParseLengthExpression (const wchar_t *str, int str_count, ON::AngleUnitSystem default_str_angle_unit_system, const ON_UnitSystem &length_value_unit_system, double *length_value) |
ON_DECL int | ON_ParseLengthExpression (const wchar_t *str, int str_count, ON::AngleUnitSystem default_str_angle_unit_system, ON::LengthUnitSystem length_value_unit_system, double *length_value) |
ON_DECL int | ON_ParseLengthExpression (const wchar_t *str, int str_count, ON_ParseSettings parse_settings, const ON_UnitSystem &length_value_unit_system, double *length_value, ON_ParseSettings *parse_results, ON::LengthUnitSystem *str_length_unit_system) |
ON_DECL int | ON_ParseLengthExpression (const wchar_t *str, int str_count, ON_ParseSettings parse_settings, double *length_value, ON_ParseSettings *parse_results, ON::LengthUnitSystem *str_length_unit_system) |
ON_DECL int | ON_ParseLengthExpression (const wchar_t *str, int str_count, ON_ParseSettings parse_settings, ON::LengthUnitSystem length_value_unit_system, double *length_value, ON_ParseSettings *parse_results, ON::LengthUnitSystem *str_length_unit_system) |
ON_DECL int | ON_ParseLengthUnitName (const wchar_t *str, int str_count, int prefered_locale_id, ON::LengthUnitSystem *length_unit_system) |
ON_DECL int | ON_ParseLengthUnitName (const wchar_t *str, int str_count, ON_ParseSettings parse_settings, ON::LengthUnitSystem *length_unit_system) |
ON_DECL int | ON_ParseNumber (const wchar_t *str, int str_count, ON_ParseSettings parse_settings, ON_ParseSettings *parse_results, double *value) |
ON_DECL int | ON_ParseNumberExpression (const wchar_t *str, int str_count, ON_ParseSettings parse_settings, ON_ParseSettings *parse_results, double *value) |
ON_DECL int | ON_ParsePointExpression (const wchar_t *str, int str_count, ON::AngleUnitSystem default_str_angle_unit_system, const ON_UnitSystem &point_value_unit_system, ON_3dPoint *point_value) |
ON_DECL int | ON_ParsePointExpression (const wchar_t *str, int str_count, ON::AngleUnitSystem default_str_angle_unit_system, ON::LengthUnitSystem point_value_unit_system, ON_3dPoint *point_value) |
ON_DECL int | ON_ParsePointExpression (const wchar_t *str, int str_count, ON_ParseSettings parse_settings, const ON_UnitSystem &point_value_unit_system, ON_3dPoint *point_value, ON_ParseSettings *parse_results) |
ON_DECL int | ON_ParsePointExpression (const wchar_t *str, int str_count, ON_ParseSettings parse_settings, ON::LengthUnitSystem point_value_unit_system, ON_3dPoint *point_value, ON_ParseSettings *parse_results) |
const ON_DECL char * | ON_ParseUuidString (const char *sUUID, ON_UUID *uuid) |
ON_DECL bool | ON_PassesNanTest () |
ON_DECL ON_BoundingBox | ON_PointGridBoundingBox (int dim, bool is_rat, int point_count0, int point_count1, int point_stride0, int point_stride1, const double *point_grid) |
ON_DECL ON_BoundingBox | ON_PointListBoundingBox (int dim, bool is_rat, int count, int stride, const double *point_list) |
ON_DECL ON_BoundingBox | ON_PointListBoundingBox (int dim, bool is_rat, int count, int stride, const float *point_list) |
ON_DECL bool | ON_PointsAreCoincident (const ON_3dPoint &, const ON_3dPoint &) |
ON_DECL bool | ON_PointsAreCoincident (int dim, bool is_rat, const double *pointA, const double *pointB) |
ON_DECL bool | ON_PointsAreCoincident (int dim, bool is_rat, int point_count, int point_stride, const double *points) |
const ON_DECL wchar_t * | ON_PostEffectTypeString (ON_PostEffect::Types type) |
Helper function to get the type of a post effect as a string. More... | |
ON_DECL bool | ON_Pullback3dVector (const ON_3dVector &, double, const ON_3dVector &, const ON_3dVector &, const ON_3dVector &, const ON_3dVector &, const ON_3dVector &, ON_2dVector &) |
ON_DECL void | ON_qsort (void *base, size_t count, size_t sizeof_element, int(*compare)(const void *, const void *)) |
ON_DECL void | ON_qsort (void *base, size_t count, size_t sizeof_element, int(*compare)(void *, const void *, const void *), void *context) |
static void | ON_QSORT_SHORT_SORT_FNAME (ON_SORT_TEMPLATE_TYPE *, ON_SORT_TEMPLATE_TYPE *) |
void | ON_quacksort (BASETYPE *base, size_t nel, size_t width, int(*compar)(const void *, const void *)) |
implementation of quick sort with minimum swaps for partition sizes 4 and less More... | |
ON_DECL ON_Quaternion | ON_QuaternionProduct (const ON_Quaternion &p, const ON_Quaternion &q) |
ON_DECL double | ON_RadiansFromDegrees (double angle_in_degrees) |
ON__UINT32 | on_rand (void) |
ON__UINT32 | on_random_number (struct ON_RANDOM_NUMBER_CONTEXT *rand_context) |
void | on_random_number_seed (ON__UINT32 s, struct ON_RANDOM_NUMBER_CONTEXT *rand_context) |
ON_DECL void ON_VARGS_FUNC_CDECL | ON_REMOVE_ASAP_AssertEx (int, const char *file_name, int line_number, const char *function_name, const char *format,...) |
Ideally - these "assert" functions will be deleted when the SDK can be changed. More... | |
ON_DECL bool | ON_RemoveBezierSingAt0 (int, int, int, double *) |
ON_DECL bool | ON_RemoveBezierSingAt1 (int, int, int, double *) |
const ON_DECL ON_wString | ON_RemoveIdPrefixFromString (const ON_UUID id, const wchar_t *separator, const wchar_t *source) |
const ON_DECL ON_wString | ON_RemoveIdSuffixFromString (const wchar_t *source, const wchar_t *separator, const ON_UUID id) |
ON_DECL bool | ON_ReparameterizeRationalBezierCurve (double c, int dim, int order, int cvstride, double *cv) |
ON_DECL bool | ON_ReparameterizeRationalNurbsCurve (double c, int dim, int order, int cv_count, int cvstride, double *cv, double *knot) |
ON_DECL bool | ON_ReverseKnotVector (int, int, double *) |
ON_DECL bool | ON_ReversePointGrid (int, bool, int, int, int, int, double *, int) |
ON_DECL bool | ON_ReversePointList (int, bool, int, int, double *) |
ON_DECL int | ON_Round (double x) |
ON_DECL int | ON_RowReduce (int row_count, int col_count, double zero_pivot, double **A, double **B, double pivots[2]) |
ON_DECL unsigned int | ON_RowReduce (unsigned int row_count, unsigned col_count, double zero_pivot_tolerance, const double *const *constA, bool bInitializeB, bool bInitializeColumnPermutation, double **A, double **B, unsigned int *column_permutation, double pivots[3]) |
ON_DECL bool | ON_RunXMLTests (const wchar_t *test_folder) |
const ON_DECL ON_String | ON_SdkVersionNumberToString (unsigned int sdk_version_number, unsigned int sdk_service_release_number) |
const ON_DECL ON_wString | ON_SdkVersionNumberToWideString (unsigned int sdk_version_number, unsigned int sdk_service_release_number) |
ON_DECL int | ON_SearchMonotoneArray (const double *, int, double) |
ON_DECL ON__UINT64 | ON_SecondsSinceJanOne1970UTC () |
ON_DECL void | ON_SendLogMessageToCloud (ON_LogMessageType msg_type, const wchar_t *wszClass, const wchar_t *wszEventDesc, const wchar_t *wszMessage) |
void | ON_SetBinaryArchiveOpenNURBSVersion (class ON_BinaryArchive &, unsigned int) |
ON_DECL bool | ON_SetCurveCurveIntersectionDir (ON_3dVector N, int xcount, ON_X_EVENT *xevent, double a0, double a1, double b0, double b1) |
ON_DECL bool | ON_SetCurveSurfaceIntersectionDir (int xcount, ON_X_EVENT *xevent, double t0, double t1, double u0, double u1, double v0, double v1) |
ON_DECL bool | ON_SetCVFromDerivative (int end, int d, const double *D, ON_BezierCurve &bezier_curve) |
ON_DECL void | ON_SetDebugWriteObjectDirectory (const wchar_t *directory_name) |
ON_DECL bool | ON_SetKnotVectorDomain (int order, int cv_count, double *knot, double t0, double t1) |
ON_DECL void | ON_SetSendLogMessageToCloudProc (ON_SSLMTC_PROC) |
ON_DECL ON__UINT64 | ON_SetWorkerThreadContext (void(*fTerminateThreadFunction)(ON__UINT_PTR), ON__UINT_PTR function_parameter) |
void | ON_SHA1_Accumulate2dPointArray (class ON_SHA1 &sha1, const class ON_SimpleArray< ON_2dPoint > &a) |
void | ON_SHA1_Accumulate2dVectorArray (class ON_SHA1 &sha1, const class ON_SimpleArray< ON_2dVector > &a) |
void | ON_SHA1_Accumulate2fPointArray (class ON_SHA1 &sha1, const class ON_SimpleArray< ON_2fPoint > &a) |
void | ON_SHA1_Accumulate2fVectorArray (class ON_SHA1 &sha1, const class ON_SimpleArray< ON_2fVector > &a) |
void | ON_SHA1_Accumulate3dPointArray (class ON_SHA1 &sha1, const class ON_SimpleArray< ON_3dPoint > &a) |
void | ON_SHA1_Accumulate3dVectorArray (class ON_SHA1 &sha1, const class ON_SimpleArray< ON_3dVector > &a) |
void | ON_SHA1_Accumulate3fPointArray (class ON_SHA1 &sha1, const class ON_SimpleArray< ON_3fPoint > &a) |
void | ON_SHA1_Accumulate3fVectorArray (class ON_SHA1 &sha1, const class ON_SimpleArray< ON_3fVector > &a) |
void | ON_SHA1_Accumulate4dPointArray (class ON_SHA1 &sha1, const class ON_SimpleArray< ON_4dPoint > &a) |
void | ON_SHA1_Accumulate4fPointArray (class ON_SHA1 &sha1, const class ON_SimpleArray< ON_4fPoint > &a) |
ON_DECL int | ON_SimpleQuadraticMinimize (int(*f)(void *, double, double *), void *f_arg, double ax, double bx, double cx, double desired_min, double stop_tol, int max_it, double *t_addr=0, double *min_f=0) |
ON_DECL int | ON_Solve2x2 (double, double, double, double, double, double, double *, double *, double *) |
ON_DECL int | ON_Solve3x2 (const double[3], const double[3], double, double, double, double *, double *, double *, double *) |
ON_DECL int | ON_Solve3x3 (const double row0[3], const double row1[3], const double row2[3], double d0, double d1, double d2, double *x_addr, double *y_addr, double *z_addr, double *pivot_ratio) |
ON_DECL int | ON_Solve4x4 (const double row0[4], const double row1[4], const double row2[4], const double row3[4], double d0, double d1, double d2, double d3, double *x_addr, double *y_addr, double *z_addr, double *w_addr, double *pivot_ratio) |
ON_DECL int | ON_SolveCubicEquation (double a, double b, double c, double d, double *r1, double *r2, double *r3) |
ON_DECL double | ON_SolveNxN (bool bFullPivot, bool bNormalize, int n, double *M[], double B[], double X[]) |
ON_DECL int | ON_SolveQuadraticEquation (double, double, double, double *, double *) |
ON_DECL bool | ON_SolveSVD (int row_count, int col_count, double const *const *U, const double *invW, double const *const *V, const double *B, double *&X) |
ON_DECL int | ON_SolveTriDiagonal (int, int, double *, const double *, double *, const double *, double *) |
ON_DECL void | ON_Sort (ON::sort_algorithm method, int *index, const void *base, size_t count, size_t sizeof_element, int(*compare)(const void *, const void *)) |
ON_DECL void | ON_Sort (ON::sort_algorithm method, int *index, const void *base, size_t count, size_t sizeof_element, int(*compare)(const void *, const void *, void *), void *context) |
ON_DECL void | ON_Sort (ON::sort_algorithm method, unsigned int *index, const void *base, size_t count, size_t sizeof_element, int(*compare)(const void *, const void *)) |
ON_DECL void | ON_Sort (ON::sort_algorithm method, unsigned int *index, const void *base, size_t count, size_t sizeof_element, int(*compare)(const void *, const void *, void *), void *context) |
ON_DECL bool | ON_SortCurves (const ON_SimpleArray< const ON_Curve * > &curves, ON_SimpleArray< int > &index, ON_SimpleArray< bool > &bReverse) |
ON_DECL bool | ON_SortCurves (const ON_SimpleArray< ON_Curve * > &curves, ON_SimpleArray< int > &index, ON_SimpleArray< bool > &bReverse) |
ON_DECL bool | ON_SortCurves (int curve_count, const ON_Curve *const *curve_list, int *index, bool *bReverse) |
ON_DECL void | ON_SortDoubleArray (ON::sort_algorithm sort_algorithm, double *a, size_t nel) |
ON_DECL void | ON_SortDoubleArrayDecreasing (double *a, size_t nel) |
ON_DECL void | ON_SortDoubleArrayIncreasing (double *a, size_t nel) |
ON_DECL void | ON_SortIntArray (ON::sort_algorithm sort_algorithm, int *a, size_t nel) |
ON_DECL bool | ON_SortLines (const ON_SimpleArray< ON_Line > &line_list, int *index, bool *bReverse) |
ON_DECL bool | ON_SortLines (int line_count, const ON_Line *line_list, int *index, bool *bReverse) |
ON_DECL void | ON_SortStringArray (ON::sort_algorithm sort_algorithm, char **a, size_t nel) |
ON_DECL void | ON_SortUINT64Array (ON::sort_algorithm sort_algorithm, ON__UINT64 *a, size_t nel) |
ON_DECL void | ON_SortUnsignedIntArray (ON::sort_algorithm sort_algorithm, unsigned int *a, size_t nel) |
ON_DECL double | ON_SpanTolerance (int, int, const double *, int) |
ON_DECL void | on_splitpath (const char *path, const char **volume, const char **dir, const char **fname, const char **ext) |
ON_DECL bool | ON_SquishBack2dMarks (const ON_Geometry *squished_geometry, const ON_SimpleArray< const ON_Geometry * > *marks, ON_SimpleArray< ON_Geometry * > *squished_marks) |
ON_DECL ON_Mesh * | ON_SquishMesh (const ON_Mesh *mesh, const ON_SquishParameters *squish_parameters, const ON_SquishConstraints *squish_constraints, const ON_SimpleArray< const ON_Geometry * > *marks, ON_SimpleArray< ON_Geometry * > *squished_marks, ON_Mesh *squished_mesh) |
ON_DECL ON_Mesh * | ON_SquishMesh (const ON_Mesh *mesh, const ON_SquishParameters *squish_parameters, const ON_SquishConstraints *squish_constraints, ON_Mesh *squished_mesh) |
ON_DECL ON_Brep * | ON_SquishSurface (const ON_Surface *surface, const ON_SquishParameters *squish_parameters, const ON_SimpleArray< const ON_Geometry * > *marks, ON_SimpleArray< ON_Geometry * > *squished_marks, ON_Brep *squished_brep) |
ON_DECL ON_Brep * | ON_SquishSurface (const ON_Surface *surface, const ON_SquishParameters *squish_parameters, ON_Brep *squished_brep) |
void | on_srand (ON__UINT32 s) |
ON_STATIC_ASSERT (sizeof(ON__INT16)==2) | |
ON_STATIC_ASSERT (sizeof(ON__INT32)==4) | |
ON_STATIC_ASSERT (sizeof(ON__INT64)==8) | |
ON_STATIC_ASSERT (sizeof(ON__INT8)==1) | |
ON_STATIC_ASSERT (sizeof(ON__UINT16)==2) | |
ON_STATIC_ASSERT (sizeof(ON__UINT32)==4) | |
ON_STATIC_ASSERT (sizeof(ON__UINT64)==8) | |
ON_STATIC_ASSERT (sizeof(ON__UINT8)==1) | |
ON_STATIC_ASSERT_MSG (ON_SIZEOF_POINTER==sizeof(void *), "ON_SIZEOF_POINTER must be equal to sizeof(void*)") | |
ON_STATIC_ASSERT_MSG (sizeof(ON__INT_PTR)==sizeof(void *), "ON_INT_PTR must be an integer type with sizeof(ON_INT_PTR) = sizeof(void*)") | |
ON_STATIC_ASSERT_MSG (sizeof(ON__UINT_PTR)==sizeof(void *), "ON_UINT_PTR must be an integer type with sizeof(ON_UINT_PTR) = sizeof(void*)") | |
ON_DECL std::string ON_VARGS_FUNC_CDECL | ON_std_string_format (const char *format,...) ON_NOEXCEPT |
ON_DECL std::wstring ON_VARGS_FUNC_CDECL | ON_std_wstring_format (const wchar_t *format,...) ON_NOEXCEPT |
ON_DECL int | on_stricmp (const char *, const char *) |
ON_DECL int | ON_StringCompareOrdinalUTF16 (const ON__UINT16 *string1, int element_count1, const ON__UINT16 *string2, int element_count2, bool bOrdinalIgnoreCase) |
ON_DECL int | ON_StringCompareOrdinalUTF32 (const ON__UINT32 *string1, int element_count1, const ON__UINT32 *string2, int element_count2, bool bOrdinalIgnoreCase) |
ON_DECL int | ON_StringCompareOrdinalUTF8 (const char *string1, int element_count1, const char *string2, int element_count2, bool bOrdinalIgnoreCase) |
ON_DECL int | ON_StringCompareOrdinalWideChar (const wchar_t *string1, int element_count1, const wchar_t *string2, int element_count2, bool bOrdinalIgnoreCase) |
const ON_SHA1_Hash | ON_StringContentHash (const char *sUTF8, int element_count, ON_StringMapOrdinalType mapping) |
const ON_SHA1_Hash | ON_StringContentHash (const wchar_t *sWideString, int element_count, ON_StringMapOrdinalType mapping) |
ON_DECL int | ON_StringLengthUTF16 (const ON__UINT16 *string) |
ON_DECL int | ON_StringLengthUTF16 (const ON__UINT16 *string, size_t string_capacity) |
ON_DECL int | ON_StringLengthUTF32 (const ON__UINT32 *string) |
ON_DECL int | ON_StringLengthUTF32 (const ON__UINT32 *string, size_t string_capacity) |
ON_DECL int | ON_StringLengthUTF8 (const char *string) |
ON_DECL int | ON_StringLengthUTF8 (const char *string, size_t string_capacity) |
ON_DECL int | ON_StringLengthWideChar (const wchar_t *string) |
ON_DECL int | ON_StringLengthWideChar (const wchar_t *string, size_t string_capacity) |
ON_DECL ON_StringMapOrdinalType | ON_StringMapOrdinalTypeFromStringMapType (ON_StringMapType map_type) |
ON_DECL int | ON_StringToBase32 (const char *sBase32, unsigned char *base32_digits) |
ON_DECL int | ON_StringToBase32 (const ON_String &sBase32, ON_SimpleArray< unsigned char > &base32_digits) |
ON_DECL int | ON_StringToBase32 (const ON_wString &sBase32, ON_SimpleArray< unsigned char > &base32_digits) |
ON_DECL char * | on_strlwr (char *) |
on_strlwr() calls _strlwr() or strlwr() depending on OS More... | |
ON_DECL int | on_strnicmp (const char *s1, const char *s2, int n) |
ON_DECL char * | on_strrev (char *) |
on_strrev() calls _strrev() or strrev() depending on OS More... | |
ON_DECL char * | on_strupr (char *) |
on_strupr() calls _strupr() or strupr() depending on OS More... | |
ON_SubDComponentLocation | ON_SubDComponentLocationFromUnsigned (unsigned int loc_as_unsigned) |
bool | ON_SubDComponentRegionBreakpoint (const class ON_SubDComponentRegion *component_region) |
ON_DECL ON_SubDEndCapStyle | ON_SubDEndCapStyleFromUnsigned (unsigned int subd_cap_style_as_unsigned) |
Convert an integer value to an ON_SubDEndCapStyle enum value. More... | |
const ON_DECL ON_wString | ON_SubDEndCapStyleToString (ON_SubDEndCapStyle subd_cap_style) |
Convert subd_cap_style to a string description. More... | |
bool | ON_SubDFaceRegionBreakpoint (unsigned int level0_face_id, const class ON_SubDComponentRegionIndex ®ion_index) |
ON_DECL ON_SubDHashType | ON_SubDHashTypeFromUnsigned (unsigned int subd_hash_type_as_unsigned) |
const ON_DECL ON_wString | ON_SubDHashTypeToString (ON_SubDHashType subd_hash_type, bool bVerbose) |
ON_DECL double | ON_SuperfluousKnot (int order, int cv_count, const double *knot, int) |
ON_DECL bool | ON_SwapPointGridCoordinates (int, int, int, int, double *, int, int) |
ON_DECL bool | ON_SwapPointListCoordinates (int, int, double *, int, int) |
ON_DECL bool | ON_SwapPointListCoordinates (int, int, float *, int, int) |
ON_DECL bool | ON_Sym3x3EigenSolver (double A, double B, double C, double D, double E, double F, double *e1, ON_3dVector &E1, double *e2, ON_3dVector &E2, double *e3, ON_3dVector &E3) |
ON_DECL bool | ON_Test_MSSBCP (bool bWindowsAPITest, ON_TextLog &text_log) |
ON_DECL bool | ON_Test_MSSBCP (const ON__UINT32 code_page, bool bWindowsAPITest, ON_TextLog &text_log) |
ON_END_EXTERNC ON_DECL ON__UINT32 | ON_Test_MSSBCP (const ON__UINT32 code_page, const ON__UINT32 char_encoding, bool bWindowsAPITest, ON_TextLog &text_log) |
ON_DECL bool | ON_Test_PrintPlatformMSSBCPToUnicodeTable (const ON__UINT32 code_page, ON__UINT32 char_encoding0, ON__UINT32 char_encoding1, ON_TextLog &text_log) |
ON_DECL void | ON_TestHashSpeed (size_t byte_count, bool bTestCRC16, bool bTestCRC32, bool bTestMD5, bool bTestSHA1, ON_TextLog &text_log) |
ON_DECL void | ON_TestHashSpeed (size_t byte_count, ON__UINT16 *crc16, ON__UINT32 *crc32, ON_MD5_Hash *md5_hash, ON_SHA1_Hash *sha1_hash, double elapsed_time_in_seconds[4]) |
ON_DECL void | ON_TestHashSpeed (size_t byte_count, ON_TextLog &text_log) |
ON_DECL double | ON_TestMathFunction (int function_index, double x, double y) |
ON_DECL bool | ON_TestVersionNumber (unsigned int major, unsigned int minor, unsigned int year, unsigned int month, unsigned int day_of_month, unsigned int platform_branch, unsigned int version_as_unsigned_number) |
ON_DECL bool | ON_TransformBrepComponents (ON_Brep *brep, int brep_component_count, const ON_COMPONENT_INDEX *brep_components, ON_Xform xform, double tolerance, double time_limit, bool bUseMultipleThreads) |
ON_DECL bool | ON_TransformPointGrid (int, bool, int, int, int, int, double *, const ON_Xform &) |
ON_DECL bool | ON_TransformPointList (int, bool, int, int, double *, const ON_Xform &) |
ON_DECL bool | ON_TransformPointList (int, bool, int, int, float *, const ON_Xform &) |
ON_DECL bool | ON_TransformVectorList (int, int, int, double *, const ON_Xform &) |
ON_DECL bool | ON_TransformVectorList (int, int, int, float *, const ON_Xform &) |
ON_DECL double | ON_TriangleArea2d (ON_2dPoint A, ON_2dPoint B, ON_2dPoint C) |
ON_DECL double | ON_TriangleArea3d (ON_3dPoint A, ON_3dPoint B, ON_3dPoint C) |
ON_DECL ON_3dVector | ON_TriangleNormal (const ON_3dPoint &A, const ON_3dPoint &B, const ON_3dPoint &C) |
ON_DECL ON_Curve * | ON_TrimCurve (const ON_Curve &curve, ON_Interval trim_parameters) |
ON_DECL double | ON_TrinomialCoefficient (int i, int j, int k) |
ON_DECL double | ON_TripleProduct (const double *, const double *, const double *) |
ON_DECL float | ON_TripleProduct (const float *, const float *, const float *) |
ON_DECL double | ON_TripleProduct (const ON_3dVector &, const ON_3dVector &, const ON_3dVector &) |
ON_DECL float | ON_TripleProduct (const ON_3fVector &, const ON_3fVector &, const ON_3fVector &) |
ON_DECL bool | ON_TuneupEvaluationParameter (int side, double s0, double s1, double *s) |
ON_DECL bool | ON_UnclampKnotVectorForExperts (int cv_dim, int order, int cv_count, int cv_stride, double *cv, double *knot, int end) |
ON_DECL size_t | ON_UncompressBuffer (size_t sizeof_compressed_buffer, const void *compressed_buffer, size_t sizeof_uncompressed_buffer, void *uncompressed_buffer) |
ON_DECL ON__UINT32 | ON_UnicodeMapCodePoint (const ON_Locale &locale, ON_StringMapType map_type, ON__UINT32 unicode_code_point) |
ON_DECL ON__UINT32 | ON_UnicodeMapCodePointOrdinal (ON_StringMapOrdinalType map_type, ON__UINT32 unicode_code_point) |
ON_DECL enum ON_UnicodeEncoding | ON_UnicodeNativeCPU_UTF16 () |
ON_DECL enum ON_UnicodeEncoding | ON_UnicodeNativeCPU_UTF32 () |
ON_DECL unsigned | ON_UnicodeSubcriptFromCodePoint (unsigned cp, unsigned no_subscript_cp) |
When possible, converts a code point to a subscript code point. Note that many common fonts typecast the Unicode digit subscripts as vulgar fraction denominators rather than a proper subscript. More... | |
ON_DECL unsigned | ON_UnicodeSubscriptFromDigit (unsigned decimal_digit) |
Get the Unicode code point for a decimal digit subscript. More... | |
ON_DECL unsigned | ON_UnicodeSuperscriptFromCodePoint (unsigned cp, unsigned no_superscript_cp) |
When possible, converts a code point to a superscript code point. Note that many common fonts typecast the Unicode digit superscripts as vulgar fraction numerators rather than a proper superscript. More... | |
ON_DECL unsigned | ON_UnicodeSuperscriptFromDigit (unsigned decimal_digit) |
Get the Unicode code point for a decimal digit superscript. More... | |
ON_DECL std::string | ON_UTF16_to_std_string (int bTestByteOrder, const ON__UINT16 *sInputUTF, int sInputUTF_count, unsigned int *error_status, unsigned int error_mask, ON__UINT32 error_code_point, const ON__UINT16 **sEndElement) ON_NOEXCEPT |
ON_DECL std::wstring | ON_UTF16_to_std_wstring (int bTestByteOrder, const ON__UINT16 *sInputUTF, int sInputUTF_count, unsigned int *error_status, unsigned int error_mask, ON__UINT32 error_code_point, const ON__UINT16 **sEndElement) ON_NOEXCEPT |
ON_DECL std::string | ON_UTF32_to_std_string (int bTestByteOrder, const ON__UINT32 *sInputUTF, int sInputUTF_count, unsigned int *error_status, unsigned int error_mask, ON__UINT32 error_code_point, const ON__UINT32 **sEndElement) ON_NOEXCEPT |
ON_DECL std::wstring | ON_UTF32_to_std_wstring (int bTestByteOrder, const ON__UINT32 *sInputUTF, int sInputUTF_count, unsigned int *error_status, unsigned int error_mask, ON__UINT32 error_code_point, const ON__UINT32 **sEndElement) ON_NOEXCEPT |
ON_DECL std::string | ON_UTF8_to_std_string (int bTestByteOrder, const char *sInputUTF, int sInputUTF_count, unsigned int *error_status, unsigned int error_mask, ON__UINT32 error_code_point, const char **sEndElement) ON_NOEXCEPT |
ON_DECL std::wstring | ON_UTF8_to_std_wstring (int bTestByteOrder, const char *sInputUTF, int sInputUTF_count, unsigned int *error_status, unsigned int error_mask, ON__UINT32 error_code_point, const char **sEndElement) ON_NOEXCEPT |
ON_DECL std::wstring | ON_UTF_std_string_to_std_wstring (int bTestByteOrder, const std::string &sInputUTF, int sInputUTF_count, unsigned int *error_status, unsigned int error_mask, ON__UINT32 error_code_point, int *end_element_index) ON_NOEXCEPT |
ON_DECL std::string | ON_UTF_std_wstring_to_std_string (int bTestByteOrder, const std::wstring &sInputUTF, int sInputUTF_count, unsigned int *error_status, unsigned int error_mask, ON__UINT32 error_code_point, int *end_element_index) ON_NOEXCEPT |
std::string | ON_UTF_WideChar_to_std_string (int bTestByteOrder, const wchar_t *sInputUTF, int sInputUTF_count, unsigned int *error_status, unsigned int error_mask, ON__UINT32 error_code_point, int *end_element_index) ON_NOEXCEPT |
std::wstring | ON_UTF_WideChar_to_std_wstring (int bTestByteOrder, const wchar_t *sInputUTF, int sInputUTF_count, unsigned int *error_status, unsigned int error_mask, ON__UINT32 error_code_point, int *end_element_index) ON_NOEXCEPT |
ON_DECL unsigned int | ON_UTFSizeofByteOrderMark (enum ON_UnicodeEncoding e) |
ON_DECL int | ON_UuidCompare (const ON_UUID &a, const ON_UUID &b) |
ON_DECL int | ON_UuidCompare (const ON_UUID *a, const ON_UUID *b) |
ON_DECL ON_UUID | ON_UuidFromString (const char *s) |
ON_DECL ON_UUID | ON_UuidFromString (const wchar_t *s) |
ON_DECL bool | ON_UuidIsNil (const ON_UUID &uuid) |
ON_DECL bool | ON_UuidIsNotNil (const ON_UUID &uuid) |
ON_DECL char * | ON_UuidToString (const ON_UUID &uuid, char *s) |
const ON_DECL char * | ON_UuidToString (const ON_UUID &uuid, ON_String &s) |
const ON_DECL wchar_t * | ON_UuidToString (const ON_UUID &uuid, ON_wString &s) |
ON_DECL wchar_t * | ON_UuidToString (const ON_UUID &uuid, wchar_t *s) |
ON_DECL bool | ON_ValidateBrepLoop (const ON_Brep &B, int loop_id) |
See ON_ValidateBrepLoops. More... | |
ON_DECL bool | ON_ValidateBrepLoops (const ON_Brep &B, ON_SimpleArray< int > *loop_ids=0) |
ON_DECL bool | ON_ValidateCurveCVSpacing (const ON_NurbsCurve &crv, double close_tol, double stack_tol, ON_SimpleArray< int > &close_ids, ON_SimpleArray< int > &stacked_ids, double &chord_length) |
ON_DECL bool | ON_ValidateCurveSet (const ON_SimpleArray< const ON_Curve * > &Crvs, double close_dist_tol, double good_dist_tol, double close_kink_tol, double good_kink_tol, double close_curvature_tol, double good_curvature_tol, ON_SimpleArray< ON_2dex > &overlap_problems, ON_SimpleArray< ON_Interval > &overlap_subdoms, ON_SimpleArray< ON_4dex > &g0_problems, ON_SimpleArray< ON_4dex > &g1_problems, ON_SimpleArray< ON_4dex > &g2_problems) |
ON_DECL bool | ON_ValidateEdgeTrims (const ON_Brep &brep, int edge_index, ON_TextLog *text_log, ON_BrepTrimPoint *bad_tp, int *bad_eti, double *deviation) |
ON_DECL bool | ON_ValidateNurbsSurfacePole (const ON_NurbsSurface &srf, int side, double tolerance, ON_3dPoint *pAvgPole) |
ON_DECL bool | ON_ValidateSurfaceCVSpacing (const ON_NurbsSurface &srf, double close_tol, double stack_tol, ON_SimpleArray< ON_2dex > &close_ids, ON_SimpleArray< ON_2dex > &stacked_ids) |
ON_DECL bool | ON_ValidateSurfaceSeam (const ON_Surface &srf, int dir, double dist_tol, double angle_tol, bool &bIsCloseG1) |
ON_DECL unsigned int | ON_VersionNumberConstruct (unsigned int major_version, unsigned int minor_version, unsigned int year, unsigned int month, unsigned int day_of_month, unsigned int platform_branch) |
ON_DECL unsigned int | ON_VersionNumberFromYearMonthDateFormat (unsigned int major_version, unsigned int yyyy_mm_dd_n_version_number) |
ON_DECL bool | ON_VersionNumberIsValid (unsigned int version_number) |
ON_DECL bool | ON_VersionNumberIsYearMonthDateFormat (unsigned int archive_3dm_version, unsigned int version_number) |
ON_DECL unsigned int | ON_VersionNumberMinimum (unsigned int major_version) |
ON_DECL bool | ON_VersionNumberParse (unsigned int version_number, unsigned int *version_major, unsigned int *version_minor, unsigned int *version_year, unsigned int *version_month, unsigned int *version_day_of_month, unsigned int *version_branch) |
const ON_DECL ON_String | ON_VersionNumberToString (unsigned int version_number, bool bUnsignedFormat, bool bDateFormat) |
const ON_DECL ON_wString | ON_VersionNumberToWideString (unsigned int version_number, bool bUnsignedFormat, bool bDateFormat) |
ON_DECL bool | ON_ViewportFromRhinoView (ON::view_projection, const ON_3dPoint &, double, double, double, double, double, int, int, ON_Viewport &) |
ON_DECL double | ON_VoronoiArea2d (const ON_2dPoint &p0, const ON_2dPoint &p1, const ON_2dPoint &p2) |
Compute the Voronoi area contribution of a 2d triangle. More... | |
ON_DECL double | ON_VoronoiArea3d (const ON_3dPoint &p0, const ON_3dPoint &p1, const ON_3dPoint &p2) |
Compute the Voronoi area contribution of a 3d triangle. More... | |
ON_DECL void ON_VARGS_FUNC_CDECL | ON_Warning (const char *file_name, int line_number, const char *format,...) |
ON_DECL void ON_VARGS_FUNC_CDECL | ON_WarningEx (const char *file_name, int line_number, const char *function_name, const char *format,...) |
ON_BEGIN_EXTERNC ON_DECL int | on_wcsicmp (const wchar_t *, const wchar_t *) |
ON_DECL wchar_t * | on_wcslwr (wchar_t *) |
on_wcslwr() calls _wcslwr() or wcslwr() depending on OS More... | |
ON_DECL wchar_t * | on_wcsrev (wchar_t *) |
on_wcsrev() calls _wcsrev() or wcsrev() depending on OS More... | |
ON_DECL wchar_t * | on_wcsupr (wchar_t *) |
on_wcsupr() calls _wcsupr() or wcsupr() depending on OS More... | |
ON_DECL double | ON_WedgeProduct (const ON_2dVector &A, const ON_2dVector &B) |
ON_DECL int | on_WideCharToMultiByte (const wchar_t *, int, char *, int) |
ON_DECL ON__UINT64 | ON_WorkerThreadContextSerialNumber () |
ON_DECL ON__UINT64 | ON_WorkerThreadEnableTerminateRequest () |
ON_DECL ON__UINT64 | ON_WorkerThreadTerminateRequestStatus () |
ON_DECL bool | ON_WorldBBoxIsInTightBBox (const ON_BoundingBox &tight_bbox, const ON_BoundingBox &world_bbox, const ON_Xform *xform) |
bool | ON_WriteMultipleObjectArchive (const wchar_t *filename, int version, size_t object_list_count, const ON_Object *const *object_list) |
ON_DECL bool | ON_WriteMultipleObjectArchive (ON_BinaryArchive &archive, int version, const ON_SimpleArray< const ON_Object * > &object_list) |
ON_DECL bool | ON_WriteMultipleObjectArchive (ON_BinaryArchive &archive, int version, size_t object_list_count, const ON_Object *const *object_list) |
ON_DECL bool | ON_WriteOneObjectArchive (const wchar_t *filename, const ON_Object &object) |
ON_DECL bool | ON_WriteOneObjectArchive (ON_BinaryArchive &archive, int version, const ON_Object &object) |
ON_DECL void | on_wsplitpath (const wchar_t *path, const wchar_t **volume, const wchar_t **dir, const wchar_t **fname, const wchar_t **ext) |
ON_DECL void * | oncalloc (size_t, size_t) |
ON_DECL void | onfree (void *) |
ON_DECL void * | onmalloc (size_t) |
ON_DECL void * | onmalloc_forever (size_t) |
ON_DECL unsigned char * | onmbsdup (const unsigned char *) |
ON_DECL void * | onmemdup (const void *, size_t) |
ON_DECL void * | onrealloc (void *, size_t) |
ON_DECL char * | onstrdup (const char *) |
ON_DECL wchar_t * | onwcsdup (const wchar_t *) |
ON_SimpleArray< T >::operator const T * () const | |
ON_ClassArray< T >::operator const T * () const | |
ON_SimpleArray< T >::operator T* () | |
The cast operators return a pointer. More... | |
ON_ClassArray< T >::operator T* () | |
The cast operators return a pointer. More... | |
ON_DECL bool | operator!= (const char *lhs, const ON_String &rhs) |
ON_DECL bool | operator!= (const class ON_ParseSettings &a, const class ON_ParseSettings &b) |
bool | operator!= (const class ON_TextMask &lhs, const class ON_TextMask &rhs) |
ON_DECL bool | operator!= (const ON_2dSize &lhs, const ON_2dSize &rhs) |
ON_DECL bool | operator!= (const ON_2iBoundingBox &, const ON_2iBoundingBox &) |
ON_DECL bool | operator!= (const ON_2iPoint &, const ON_2iPoint &) |
ON_DECL bool | operator!= (const ON_2iSize &lhs, const ON_2iSize &rhs) |
ON_DECL bool | operator!= (const ON_2iVector &, const ON_2iVector &) |
ON_DECL bool | operator!= (const ON_4dRect &, const ON_4dRect &) |
ON_DECL bool | operator!= (const ON_4iRect &, const ON_4iRect &) |
ON_DECL bool | operator!= (const ON_AngleUnitName &a, const ON_AngleUnitName &b) |
ON_DECL bool | operator!= (const ON_BoundingBox &lhs, const ON_BoundingBox &rhs) |
ON_DECL bool | operator!= (const ON_LengthUnitName &a, const ON_LengthUnitName &b) |
ON_DECL bool | operator!= (const ON_Line &a, const ON_Line &b) |
ON_DECL bool | operator!= (const ON_ManifestMapItem &lhs, const ON_ManifestMapItem &rhs) |
ON_DECL bool | operator!= (const ON_MappingTag &lhs, const ON_MappingTag &rhs) |
ON_DECL bool | operator!= (const ON_Material &, const ON_Material &) |
ON_DECL bool | operator!= (const ON_MD5_Hash &a, const ON_MD5_Hash &b) |
ON_DECL bool | operator!= (const ON_MeshParameters &a, const ON_MeshParameters &b) |
bool | operator!= (const ON_ModelComponentContentMark &lhs, const ON_ModelComponentContentMark &rhs) |
ON_DECL bool | operator!= (const ON_NameHash &a, const ON_NameHash &b) |
ON_DECL bool | operator!= (const ON_SHA1_Hash &a, const ON_SHA1_Hash &b) |
ON_DECL bool | operator!= (const ON_String &lhs, const char *rhs) |
ON_DECL bool | operator!= (const ON_String &lhs, const ON_String &rhs) |
ON_DECL bool | operator!= (const ON_SubDEdgeSharpness &lhs, const ON_SubDEdgeSharpness &rhs) |
bool | operator!= (const ON_SubDExpandEdgesParameters &lhs, const ON_SubDExpandEdgesParameters &rhs) |
ON_WIP_DECL bool | operator!= (const ON_SubDFaceParameter &lhs, const ON_SubDFaceParameter &rhs) |
bool | operator!= (const ON_SubDHash &lhs, const ON_SubDHash &rhs) |
bool | operator!= (const ON_SubDToBrepParameters &lhs, const ON_SubDToBrepParameters &rhs) |
ON_DECL bool | operator!= (const ON_SurfaceCurvature &lhs, const ON_SurfaceCurvature &rhs) |
ON_DECL bool | operator!= (const ON_SurfaceCurvatureColorMapping &lhs, const ON_SurfaceCurvatureColorMapping &rhs) |
Returns true if some property of lhs and rhs is different and no double is a nan. More... | |
ON_DECL bool | operator!= (const ON_SurfaceDraftAngleColorMapping &lhs, const ON_SurfaceDraftAngleColorMapping &rhs) |
Returns true if some property of lhs and rhs is different and no double is a nan. More... | |
ON_DECL bool | operator!= (const ON_Triangle &a, const ON_Triangle &b) |
ON_DECL bool | operator!= (const ON_wString &lhs, const ON_wString &rhs) |
ON_DECL bool | operator!= (const ON_wString &lhs, const wchar_t *rhs) |
bool | operator!= (const struct ON_UUID_struct &a, const struct ON_UUID_struct &b) |
ON_DECL bool | operator!= (const wchar_t *lhs, const ON_wString &rhs) |
ON_DECL bool | operator!= (ON_Big5CodePoint lhs, ON_Big5CodePoint rhs) |
ON_DECL bool | operator!= (ON_Big5UnicodePair lhs, ON_Big5UnicodePair rhs) |
ON_DECL bool | operator!= (ON_SubDComponentPtr lhs, ON_SubDComponentPtr rhs) |
ON_DECL bool | operator!= (ON_SubDEdgePtr lhs, ON_SubDEdgePtr rhs) |
ON_DECL bool | operator!= (ON_SubDFacePtr lhs, ON_SubDFacePtr rhs) |
ON_DECL bool | operator!= (ON_SubDSectorId, ON_SubDSectorId) |
ON_DECL bool | operator!= (ON_SubDVertexPtr lhs, ON_SubDVertexPtr rhs) |
ON_DECL bool | operator!= (ON_UnicodeShortCodePoint lhs, ON_UnicodeShortCodePoint rhs) |
ON_DECL ON_ParseSettings | operator&& (const class ON_ParseSettings &a, const class ON_ParseSettings &b) |
const ON_DECL ON_PlaneEquation | operator* (const ON_Xform &, const ON_PlaneEquation &) |
const ON_DECL ON_Xform | operator* (const ON_Xform &xform, double c) |
const ON_DECL ON_Xform | operator* (double c, const ON_Xform &xform) |
ON_DECL ON_2dPoint | operator* (double, const ON_2dPoint &) |
ON_DECL ON_2dVector | operator* (double, const ON_2dVector &) |
ON_DECL ON_2dPoint | operator* (double, const ON_2fPoint &) |
ON_DECL ON_2dVector | operator* (double, const ON_2fVector &) |
ON_DECL ON_3dPoint | operator* (double, const ON_3dPoint &) |
ON_DECL ON_3dVector | operator* (double, const ON_3dVector &) |
ON_DECL ON_3dPoint | operator* (double, const ON_3fPoint &) |
ON_DECL ON_3dVector | operator* (double, const ON_3fVector &) |
ON_DECL ON_4dPoint | operator* (double, const ON_4dPoint &) |
ON_DECL ON_4dPoint | operator* (double, const ON_4fPoint &) |
ON_DECL ON_Quaternion | operator* (double, const ON_Quaternion &) |
ON_DECL ON_2dPoint | operator* (float, const ON_2dPoint &) |
ON_DECL ON_2dVector | operator* (float, const ON_2dVector &) |
ON_DECL ON_2fPoint | operator* (float, const ON_2fPoint &) |
ON_DECL ON_2fVector | operator* (float, const ON_2fVector &) |
ON_DECL ON_3dPoint | operator* (float, const ON_3dPoint &) |
ON_DECL ON_3dVector | operator* (float, const ON_3dVector &) |
ON_DECL ON_3fPoint | operator* (float, const ON_3fPoint &) |
ON_DECL ON_3fVector | operator* (float, const ON_3fVector &) |
ON_DECL ON_4fPoint | operator* (float, const ON_4fPoint &) |
ON_DECL ON_Quaternion | operator* (float, const ON_Quaternion &) |
ON_DECL ON_2dPoint | operator* (int, const ON_2dPoint &) |
ON_DECL ON_2dVector | operator* (int, const ON_2dVector &) |
ON_DECL ON_2fPoint | operator* (int, const ON_2fPoint &) |
ON_DECL ON_2fVector | operator* (int, const ON_2fVector &) |
ON_DECL ON_2iVector | operator* (int, const ON_2iVector &) |
ON_DECL ON_3dPoint | operator* (int, const ON_3dPoint &) |
ON_DECL ON_3dVector | operator* (int, const ON_3dVector &) |
ON_DECL ON_3fPoint | operator* (int, const ON_3fPoint &) |
ON_DECL ON_3fVector | operator* (int, const ON_3fVector &) |
ON_DECL ON_Quaternion | operator* (int, const ON_Quaternion &) |
ON_DECL ON_2iPoint | operator+ (const ON_2iPoint &, const ON_2iVector &) |
ON_DECL ON_2iVector | operator+ (const ON_2iVector &, const ON_2iVector &) |
ON_DECL ON_2iPoint | operator- (const ON_2iPoint &, const ON_2iVector &) |
ON_DECL ON_2iVector | operator- (const ON_2iVector &, const ON_2iVector &) |
ON_DECL bool | operator< (const char *lhs, const ON_String &rhs) |
ON_DECL bool | operator< (const ON_NameHash &a, const ON_NameHash &b) |
ON_DECL bool | operator< (const ON_String &lhs, const char *rhs) |
ON_DECL bool | operator< (const ON_String &lhs, const ON_String &rhs) |
ON_DECL bool | operator< (const ON_wString &lhs, const ON_wString &rhs) |
ON_DECL bool | operator< (const ON_wString &lhs, const wchar_t *rhs) |
ON_DECL bool | operator< (const wchar_t *lhs, const ON_wString &rhs) |
ON_DECL bool | operator< (ON_Big5CodePoint lhs, ON_Big5CodePoint rhs) |
ON_DECL bool | operator< (ON_SubDSectorId, ON_SubDSectorId) |
ON_DECL bool | operator< (ON_UnicodeShortCodePoint lhs, ON_UnicodeShortCodePoint rhs) |
ON_DECL bool | operator<= (const char *lhs, const ON_String &rhs) |
ON_DECL bool | operator<= (const ON_NameHash &a, const ON_NameHash &b) |
ON_DECL bool | operator<= (const ON_String &lhs, const char *rhs) |
ON_DECL bool | operator<= (const ON_String &lhs, const ON_String &rhs) |
ON_DECL bool | operator<= (const ON_wString &lhs, const ON_wString &rhs) |
ON_DECL bool | operator<= (const ON_wString &lhs, const wchar_t *rhs) |
ON_DECL bool | operator<= (const wchar_t *lhs, const ON_wString &rhs) |
ON_DECL bool | operator<= (ON_Big5CodePoint lhs, ON_Big5CodePoint rhs) |
ON_DECL bool | operator<= (ON_SubDSectorId, ON_SubDSectorId) |
ON_DECL bool | operator<= (ON_UnicodeShortCodePoint lhs, ON_UnicodeShortCodePoint rhs) |
ON_ClassArray< T > & | ON_ClassArray< T >::operator= (const ON_ClassArray< T > &) |
Assignment operator. More... | |
ON_ObjectArray< T > & | ON_ObjectArray< T >::operator= (const ON_ObjectArray< T > &) |
ON_SimpleArray< T > & | ON_SimpleArray< T >::operator= (const ON_SimpleArray< T > &) |
ON_DECL bool | operator== (const char *lhs, const ON_String &rhs) |
ON_DECL bool | operator== (const class ON_ParseSettings &a, const class ON_ParseSettings &b) |
bool | operator== (const class ON_TextMask &lhs, const class ON_TextMask &rhs) |
ON_DECL bool | operator== (const ON_2dSize &lhs, const ON_2dSize &rhs) |
ON_DECL bool | operator== (const ON_2iBoundingBox &, const ON_2iBoundingBox &) |
ON_DECL bool | operator== (const ON_2iPoint &, const ON_2iPoint &) |
ON_DECL bool | operator== (const ON_2iSize &lhs, const ON_2iSize &rhs) |
ON_DECL bool | operator== (const ON_2iVector &, const ON_2iVector &) |
ON_DECL bool | operator== (const ON_4dRect &, const ON_4dRect &) |
ON_DECL bool | operator== (const ON_4iRect &, const ON_4iRect &) |
ON_DECL bool | operator== (const ON_AngleUnitName &a, const ON_AngleUnitName &b) |
ON_DECL bool | operator== (const ON_BoundingBox &lhs, const ON_BoundingBox &rhs) |
ON_DECL bool | operator== (const ON_LengthUnitName &a, const ON_LengthUnitName &b) |
ON_DECL bool | operator== (const ON_Line &a, const ON_Line &b) |
ON_DECL bool | operator== (const ON_ManifestMapItem &lhs, const ON_ManifestMapItem &rhs) |
ON_DECL bool | operator== (const ON_MappingTag &lhs, const ON_MappingTag &rhs) |
ON_DECL bool | operator== (const ON_Material &, const ON_Material &) |
ON_DECL bool | operator== (const ON_MD5_Hash &a, const ON_MD5_Hash &b) |
ON_DECL bool | operator== (const ON_MeshParameters &a, const ON_MeshParameters &b) |
bool | operator== (const ON_ModelComponentContentMark &lhs, const ON_ModelComponentContentMark &rhs) |
ON_DECL bool | operator== (const ON_NameHash &a, const ON_NameHash &b) |
ON_DECL bool | operator== (const ON_SHA1_Hash &a, const ON_SHA1_Hash &b) |
ON_DECL bool | operator== (const ON_String &lhs, const char *rhs) |
ON_DECL bool | operator== (const ON_String &lhs, const ON_String &rhs) |
ON_DECL bool | operator== (const ON_SubDEdgeSharpness &lhs, const ON_SubDEdgeSharpness &rhs) |
bool | operator== (const ON_SubDExpandEdgesParameters &lhs, const ON_SubDExpandEdgesParameters &rhs) |
ON_WIP_DECL bool | operator== (const ON_SubDFaceParameter &lhs, const ON_SubDFaceParameter &rhs) |
bool | operator== (const ON_SubDHash &lhs, const ON_SubDHash &rhs) |
bool | operator== (const ON_SubDToBrepParameters &lhs, const ON_SubDToBrepParameters &rhs) |
ON_DECL bool | operator== (const ON_SurfaceCurvature &lhs, const ON_SurfaceCurvature &rhs) |
ON_DECL bool | operator== (const ON_SurfaceCurvatureColorMapping &lhs, const ON_SurfaceCurvatureColorMapping &rhs) |
Returns true if all properties of lhs and rhs are identical and no double is a nan. More... | |
ON_DECL bool | operator== (const ON_SurfaceDraftAngleColorMapping &lhs, const ON_SurfaceDraftAngleColorMapping &rhs) |
Returns true if all properties of lhs and rhs are identical and no double is a nan. More... | |
ON_DECL bool | operator== (const ON_Triangle &a, const ON_Triangle &b) |
ON_DECL bool | operator== (const ON_wString &lhs, const ON_wString &rhs) |
ON_DECL bool | operator== (const ON_wString &lhs, const wchar_t *rhs) |
bool | operator== (const struct ON_UUID_struct &a, const struct ON_UUID_struct &b) |
basic C++ declarations More... | |
ON_DECL bool | operator== (const wchar_t *lhs, const ON_wString &rhs) |
ON_DECL bool | operator== (ON_Big5CodePoint lhs, ON_Big5CodePoint rhs) |
ON_DECL bool | operator== (ON_Big5UnicodePair lhs, ON_Big5UnicodePair rhs) |
ON_DECL bool | operator== (ON_SubDComponentPtr lhs, ON_SubDComponentPtr rhs) |
ON_DECL bool | operator== (ON_SubDEdgePtr lhs, ON_SubDEdgePtr rhs) |
ON_DECL bool | operator== (ON_SubDFacePtr lhs, ON_SubDFacePtr rhs) |
ON_DECL bool | operator== (ON_SubDSectorId, ON_SubDSectorId) |
ON_DECL bool | operator== (ON_SubDVertexPtr lhs, ON_SubDVertexPtr rhs) |
ON_DECL bool | operator== (ON_UnicodeShortCodePoint lhs, ON_UnicodeShortCodePoint rhs) |
ON_DECL bool | operator> (const char *lhs, const ON_String &rhs) |
ON_DECL bool | operator> (const ON_NameHash &a, const ON_NameHash &b) |
ON_DECL bool | operator> (const ON_String &lhs, const char *rhs) |
ON_DECL bool | operator> (const ON_String &lhs, const ON_String &rhs) |
ON_DECL bool | operator> (const ON_wString &lhs, const ON_wString &rhs) |
ON_DECL bool | operator> (const ON_wString &lhs, const wchar_t *rhs) |
ON_DECL bool | operator> (const wchar_t *lhs, const ON_wString &rhs) |
ON_DECL bool | operator> (ON_Big5CodePoint lhs, ON_Big5CodePoint rhs) |
ON_DECL bool | operator> (ON_SubDSectorId, ON_SubDSectorId) |
ON_DECL bool | operator> (ON_UnicodeShortCodePoint lhs, ON_UnicodeShortCodePoint rhs) |
ON_DECL bool | operator>= (const char *lhs, const ON_String &rhs) |
ON_DECL bool | operator>= (const ON_NameHash &a, const ON_NameHash &b) |
ON_DECL bool | operator>= (const ON_String &lhs, const char *rhs) |
ON_DECL bool | operator>= (const ON_String &lhs, const ON_String &rhs) |
ON_DECL bool | operator>= (const ON_wString &lhs, const ON_wString &rhs) |
ON_DECL bool | operator>= (const ON_wString &lhs, const wchar_t *rhs) |
ON_DECL bool | operator>= (const wchar_t *lhs, const ON_wString &rhs) |
ON_DECL bool | operator>= (ON_Big5CodePoint lhs, ON_Big5CodePoint rhs) |
ON_DECL bool | operator>= (ON_SubDSectorId, ON_SubDSectorId) |
ON_DECL bool | operator>= (ON_UnicodeShortCodePoint lhs, ON_UnicodeShortCodePoint rhs) |
T & | ON_SimpleArray< T >::operator[] (int) |
T & | ON_ClassArray< T >::operator[] (int) |
const T & | ON_SimpleArray< T >::operator[] (int) const |
const T & | ON_ClassArray< T >::operator[] (int) const |
T & | ON_SimpleArray< T >::operator[] (ON__INT64) |
T & | ON_ClassArray< T >::operator[] (ON__INT64) |
const T & | ON_SimpleArray< T >::operator[] (ON__INT64) const |
const T & | ON_ClassArray< T >::operator[] (ON__INT64) const |
T & | ON_SimpleArray< T >::operator[] (ON__UINT64) |
T & | ON_ClassArray< T >::operator[] (ON__UINT64) |
const T & | ON_SimpleArray< T >::operator[] (ON__UINT64) const |
const T & | ON_ClassArray< T >::operator[] (ON__UINT64) const |
T & | ON_SimpleArray< T >::operator[] (unsigned int) |
T & | ON_ClassArray< T >::operator[] (unsigned int) |
const T & | ON_SimpleArray< T >::operator[] (unsigned int) const |
const T & | ON_ClassArray< T >::operator[] (unsigned int) const |
ON_DECL ON_ParseSettings | operator|| (const class ON_ParseSettings &a, const class ON_ParseSettings &b) |
bool | ON_SimpleArray< T >::Permute (const int *) |
bool | ON_ClassArray< T >::Permute (const int *) |
void | ON_SimpleArray< T >::Prepend (int, const T *) |
Prepend copy of an array T[count]. More... | |
ON_DECL ON_SDFQueryResult | QueryBoundingBox (const ON_BoundingBox &bb, const ON_SignedDistanceFunction &sdf, double tolerance) |
these functions are not in any header but need testing More... | |
ON_DECL ON_SDFQueryResult | QueryCurveTreeLeaf (const ON_CurveTreeBezier &node, const ON_SignedDistanceFunction &sdf, double tolerance) |
bool | ON_SimpleArray< T >::QuickSort (int(*)(const T *, const T *)) |
See Also: ON_CompareIncreasing<T> and ON_CompareDeccreasing<T> More... | |
virtual bool | ON_ClassArray< T >::QuickSort (int(*)(const T *, const T *)) |
Sorts the array using the heap sort algorithm. More... | |
bool | ON_ObjectArray< T >::QuickSort (int(*)(const T *, const T *)) |
bool | ON_SimpleArray< T >::QuickSortAndRemoveDuplicates (int(*)(const T *, const T *)) |
See Also: ON_CompareIncreasing<T> and ON_CompareDeccreasing<T> More... | |
virtual T * | ON_SimpleArray< T >::Realloc (T *, int) |
low level memory management ////////////////////////////////////////// More... | |
virtual T * | ON_ClassArray< T >::Realloc (T *, int) |
low level memory management /////////////////////////////////////// More... | |
T * | ON_ObjectArray< T >::Realloc (T *, int) |
void | ON_SimpleArray< T >::Remove () |
void | ON_ClassArray< T >::Remove () |
virtual void | ON_SimpleArray< T >::Remove (int) |
void | ON_ClassArray< T >::Remove (int) |
void | ON_SimpleArray< T >::RemoveIf (bool predicate(const T &key)) |
void | ON_SimpleArray< T >::RemoveValue (const T &) |
T * | ON_SimpleArray< T >::Reserve (size_t) |
memory management //////////////////////////////////////////////////// More... | |
T * | ON_ClassArray< T >::Reserve (size_t) |
memory management ///////////////////////////////////////////////// More... | |
void | ON_SimpleFixedSizePoolIterator< T >::Reset () |
void | ON_SimpleFixedSizePool< T >::ReturnAll () |
void | ON_SimpleFixedSizePool< T >::ReturnElement (T *p) |
void | ON_SimpleArray< T >::Reverse () |
reverse order More... | |
void | ON_ClassArray< T >::Reverse () |
reverse order More... | |
int | ON_SimpleArray< T >::Search (const T &) const |
int | ON_SimpleArray< T >::Search (const T *, int(*)(const T *, const T *)) const |
See Also: ON_CompareIncreasing<T> and ON_CompareDeccreasing<T> More... | |
int | ON_ClassArray< T >::Search (const T *, int(*)(const T *, const T *)) const |
void | ON_SimpleArray< T >::SetArray (T *) |
void | ON_ClassArray< T >::SetArray (T *) |
void | ON_SimpleArray< T >::SetArray (T *, int, int) |
void | ON_ClassArray< T >::SetArray (T *, int, int) |
T * | ON_SimpleArray< T >::SetCapacity (size_t) |
T * | ON_ClassArray< T >::SetCapacity (size_t) |
void | ON_SimpleArray< T >::SetCount (int) |
low level memory management ////////////////////////////////////////// More... | |
void | ON_ClassArray< T >::SetCount (int) |
low level memory management ////////////////////////////////////////// More... | |
void | ON_SimpleArray< T >::SetRange (int from, int count, T) |
void | ON_SimpleArray< T >::Shrink () |
remove unused capacity More... | |
void | ON_ClassArray< T >::Shrink () |
remove unused capacity More... | |
unsigned int | ON_SimpleArray< T >::SizeOfArray () const |
amount of memory in the m_a[] array More... | |
unsigned int | ON_ClassArray< T >::SizeOfArray () const |
amount of memory in the m_a[] array More... | |
unsigned int | ON_SimpleArray< T >::SizeOfElement () const |
amount of memory in an m_a[] array element More... | |
unsigned int | ON_ClassArray< T >::SizeOfElement () const |
amount of memory in an m_a[] array element More... | |
size_t | ON_SimpleFixedSizePool< T >::SizeofElement () const |
bool | ON_SimpleArray< T >::Sort (ON::sort_algorithm sort_algorithm, int *, int(*)(const T *, const T *)) const |
bool | ON_ClassArray< T >::Sort (ON::sort_algorithm sort_algorithm, int *, int(*)(const T *, const T *)) const |
bool | ON_SimpleArray< T >::Sort (ON::sort_algorithm sort_algorithm, int *, int(*)(const T *, const T *, void *), void *) const |
bool | ON_ClassArray< T >::Sort (ON::sort_algorithm sort_algorithm, int *, int(*)(const T *, const T *, void *), void *) const |
void | ON_SimpleArray< T >::Swap (int, int) |
swap elements i and j More... | |
void | ON_ClassArray< T >::Swap (int, int) |
swap elements i and j More... | |
static void | SwapBigInts (unsigned char *a, unsigned char *b, size_t width) |
static void | SwapChars (unsigned char *a, unsigned char *b, size_t width) |
static void | SwapInts (unsigned char *a, unsigned char *b, size_t width) |
size_t | ON_SimpleFixedSizePool< T >::TotalElementCount () const |
unsigned int | ON_SimpleArray< T >::UnsignedCount () const |
unsigned int | ON_ClassArray< T >::UnsignedCount () const |
ON_BEGIN_EXTERNC voidpf | zcalloc (voidpf, unsigned, unsigned) |
void | zcfree (voidpf, voidpf) |
void | ON_SimpleArray< T >::Zero () |
void | ON_ClassArray< T >::Zero () |
#define _GNU_SOURCE |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org. Determines what compiler is being used.
#define BASETYPE void * |
ON_SORT_TEMPLATE_TYPE -> double, int, ....
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org. See opennurbs_sort.cpp for examples showing how to use opennurbs_quacksort_template.h to define type specific sorting functions.
#define DATATYPE unsigned char |
#define DATAWIDTH m_width |
#define MY_ZCALLOC |
have zlib use oncalloc() and onfree() for memory management
#define ON_1_OVER_SQRT2 0.7071067811865475244008445 |
#define ON_2PI (2.0*ON_PI) |
double precision ON_2PI = 2.0*ON_PI. ON_2PI radians = 360 degrees.
#define ON__SET__THIS__PTR | ( | ptr | ) | if (ptr) *((void**)this) = ptr |
#define ON_ArrayCount | ( | a | ) | (sizeof(a)/sizeof((a)[0])) |
#define ON_ASSERT | ( | cond | ) | ON_REMOVE_ASAP_AssertEx(cond,__FILE__,__LINE__,OPENNURBS__FUNCTION__, #cond " is false") |
Do not use ON_ASSERT. If a condition can be checked by ON_ASSERT, then the code must be written detect and respond to that condition. This define will be deleted ASAP. It is being used to detect situations where a crash will occur and then letting the crash occur.
#define ON_ASSERT_OR_RETURN | ( | cond, | |
returncode | |||
) | do{if (!(cond)) {ON_ErrorEx(__FILE__,__LINE__,OPENNURBS__FUNCTION__, #cond " is false");return(returncode);}}while(0) |
#define ON_ASSERT_OR_RETURNVOID | ( | cond | ) | do{if (!(cond)) {ON_ErrorEx(__FILE__,__LINE__,OPENNURBS__FUNCTION__, #cond " is false");return;}}while(0) |
#define ON_BEGIN_EXTERNC extern "C" { |
#define ON_CALLBACK_CDECL |
/ Compilers that require special declaration of callback functions / will change ON_CALLBACK_CDECL accordingly.
#define ON_CLASS |
export/import compiling or using OpenNurbs as a static library
#define ON_CLASS_ID | ( | cls | ) | ON_CLASS_RTTI( cls ).Uuid() |
Description: ON_CLASS_ID is a macro to get the class's uuid from a class name. Example: / Get the class id for ON_Brep. ON_UUID brep_class_id = ON_CLASS_ID(ON_Brep);
#define ON_CLASS_RTTI | ( | cls | ) | cls::m_##cls##_class_rtti |
Description: ON_CLASS_RTTI is a macro to get the class's run-time type information from class name. Example: / Get the ON_Brep class's run-time type information. const ON_ClassId& brep_rtti = ON_CLASS_RTTI(ON_Brep);
#define ON_COMPILER_GNU |
////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////// / / ON_COMPILER_GNU /
#define ON_COS_PI_OVER_12 0.9659258262890682867497433 |
#define ON_CURVE_PIPING_ACCURACY L"accuracy" |
#define ON_CURVE_PIPING_BOX L"box" |
#define ON_CURVE_PIPING_CAP_TYPE L"cap-type" |
#define ON_CURVE_PIPING_DOME L"dome" |
#define ON_CURVE_PIPING_FLAT L"flat" |
#define ON_CURVE_PIPING_NONE L"none" |
#define ON_CURVE_PIPING_ON L"on" |
#define ON_CURVE_PIPING_RADIUS L"radius" |
#define ON_CURVE_PIPING_ROOT L"curve-piping-object-data" |
#define ON_CURVE_PIPING_SEGMENTS L"segments" |
#define ON_CURVE_PIPING_WELD L"weld" |
'Weld' is a legacy name. The real name is 'Faceted' but this is the INVERSE of weld.
#define ON_CV_COORDINATE_IS_VALID | ( | x | ) | (-1.0e307 < x && x < 1.0e307) |
March 27, 2024 - Tim Fix for https://mcneel.myjetbrains.com/youtrack/issue/RH-81184 The vertexes were crap just not quite ON_UNSET_VALUE crap
#define ON_DBL_MAX 1.7976931348623158e+308 |
#define ON_DBL_MIN 2.22507385850720200e-308 |
#define ON_DECL |
#define ON_DEFAULT_ANGLE_TOLERANCE ON_DEFAULT_ANGLE_TOLERANCE_RADIANS |
#define ON_DEFAULT_ANGLE_TOLERANCE_COSINE 0.99984769515639123915701155881391 |
#define ON_DEFAULT_ANGLE_TOLERANCE_DEGREES (ON_DEFAULT_ANGLE_TOLERANCE_RADIANS * 180.0/ON_PI) |
#define ON_DEFAULT_ANGLE_TOLERANCE_RADIANS (ON_PI/180.0) |
default value for angle tolerances = 1 degree
#define ON_DEFAULT_DISTANCE_TOLERANCE_MM 0.01 |
#define ON_DEGREES_TO_RADIANS (ON_PI/180.0) |
angle_in_degrees = ON_DEGREES_TO_RADIANS*angle_in_radians
#define ON_DEPRECATED |
ON_DEPRECATED is used to mark deprecated functions.
#define ON_DEPRECATED_MSG | ( | s | ) |
#define ON_DepthImage_DEPTH_TYPE double |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org. Description: ON_DepthImage is a tool for geometry calculations that want to use depth buffer rendering techniques. The depth buffer is a double precision depth buffer and the calculations are all performed in double precision.
#define ON_DISPLACEMENT_BLACK_POINT L"black-point" |
#define ON_DISPLACEMENT_CHANNEL L"channel" |
#define ON_DISPLACEMENT_FACE_COUNT_LIMIT L"face-count-limit" |
#define ON_DISPLACEMENT_FACE_COUNT_LIMIT_ENABLED L"face-count-limit-enabled" |
#define ON_DISPLACEMENT_FAIRING_AMOUNT L"fairing-amount" |
#define ON_DISPLACEMENT_FAIRING_ENABLED L"fairing-enabled" |
#define ON_DISPLACEMENT_MESH_MEMORY_LIMIT L"mesh-memory-limit" |
#define ON_DISPLACEMENT_ON L"on" |
#define ON_DISPLACEMENT_POST_WELD_ANGLE L"post-weld-angle" |
#define ON_DISPLACEMENT_REFINE_SENSITIVITY L"refine-sensitivity" |
#define ON_DISPLACEMENT_REFINE_STEPS L"refine-steps" |
#define ON_DISPLACEMENT_ROOT L"new-displacement-object-data" |
Displacement
#define ON_DISPLACEMENT_SUB L"sub" |
#define ON_DISPLACEMENT_SUB_BLACK_POINT L"sub-black-point" |
#define ON_DISPLACEMENT_SUB_CHANNEL L"sub-channel" |
#define ON_DISPLACEMENT_SUB_INDEX L"sub-index" |
#define ON_DISPLACEMENT_SUB_OBJECT_COUNT L"sub-object-count" |
#define ON_DISPLACEMENT_SUB_ON L"sub-on" |
#define ON_DISPLACEMENT_SUB_TEXTURE L"sub-texture" |
#define ON_DISPLACEMENT_SUB_WHITE_POINT L"sub-white-point" |
#define ON_DISPLACEMENT_SWEEP_PITCH L"sweep-pitch" |
#define ON_DISPLACEMENT_SWEEP_RES_FORMULA L"sweep-res-formula" |
#define ON_DISPLACEMENT_TEXTURE L"texture" |
#define ON_DISPLACEMENT_WHITE_POINT L"white-point" |
#define ON_DOUBLE_BYTE_CODE_PAGE_SUPPORT |
/ / Copyright (c) 1993-2012 Robert McNeel & Associates. All rights reserved. / OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert / McNeel & Associates. / / THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. / ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF / MERCHANTABILITY ARE HEREBY DISCLAIMED. /
/ For complete openNURBS copyright information see http://www.opennurbs.org. / ////////////////////////////////////////////////////////////// This check is included in all opennurbs source .c and .cpp files to insure ON_COMPILING_OPENNURBS is defined when opennurbs source is compiled. When opennurbs source is being compiled, ON_COMPILING_OPENNURBS is defined and the opennurbs .h files alter what is declared and how it is declared. When we do not have access to Windows code page tools, we have to add in code to get convert Windows and Apple multibyte encodings to UNICODE encodings.
In practice, the primary use of the double byte code page support is in parsing rich text (RTF) in ON_TextContent classes created on computers with Eastern European and Asian locales as the default locale.
Many Western European and Americas locales are handled by the single byte code pages 1252 and 10000. Code pages for other locales will be added as needed because embedding the large double byte tables makes the resulting libraries large.
At this time opennurbs does not ship the code page N to UNICODE translation tables as separate files that can be loaded on demand because of the added installation and runtime lookup complexities.
When possible, Rhino and opennurbs replace code page encodings with UNICODE in RTF. All runtimes strings use UNICODE UTF-8, UTF-16, or UTF-32 encodings. Whenever possible, the UNICODE encoding is used to retrieve glyph information from fonts.
#define ON_EDGE_SOFTENING_CHAMFER L"chamfer" |
#define ON_EDGE_SOFTENING_EDGE_THRESHOLD L"edge-threshold" |
#define ON_EDGE_SOFTENING_FORCE_SOFTENING L"force-softening" |
#define ON_EDGE_SOFTENING_ON L"on" |
#define ON_EDGE_SOFTENING_ROOT L"edge-softening-object-data" |
Edge Softening
#define ON_EDGE_SOFTENING_SOFTENING L"softening" |
#define ON_EDGE_SOFTENING_UNWELD L"unweld" |
#define ON_END_EXTERNC } |
#define ON_ENUM_FROM_UNSIGNED_CASE | ( | e | ) | case (unsigned int)e: return(e); break |
/ Declarations in header (.H) files look like / / ON_DECL type function(): / extern ON_EXTERN_DECL type global_variable; / class ON_CLASS classname {}; / ON_TEMPLATE template class ON_CLASS template<T>; /
#define ON_ENUM_TO_STRING_CASE | ( | e | ) | case e: return( ON_String(#e) ); break |
#define ON_ENUM_TO_STRING_CASE_SET | ( | e, | |
s | |||
) | case e: (s)=ON_String(#e); break |
#define ON_ENUM_TO_WIDE_STRING_CASE | ( | e | ) | case e: return( ON_wString(#e) ); break |
#define ON_ENUM_TO_WIDE_STRING_CASE_SET | ( | e, | |
s | |||
) | case e: (s)=ON_wString(#e); break |
#define ON_ENVIRONMENT_PROJECTION_BOX L"box" |
Environment projections.
#define ON_ENVIRONMENT_PROJECTION_CUBE_MAP L"cubemap" |
#define ON_ENVIRONMENT_PROJECTION_CUBE_MAP_HORZ L"horizontal-cross-cubemap" |
#define ON_ENVIRONMENT_PROJECTION_CUBE_MAP_VERT L"vertical-cross-cubemap" |
#define ON_ENVIRONMENT_PROJECTION_EMAP L"emap" |
#define ON_ENVIRONMENT_PROJECTION_HEMISPHERICAL L"hemispherical" |
#define ON_ENVIRONMENT_PROJECTION_LIGHT_PROBE L"lightprobe" |
#define ON_ENVIRONMENT_PROJECTION_PLANAR L"planar" |
#define ON_ENVIRONMENT_PROJECTION_SPHERICAL L"spherical" |
#define ON_ENVIRONMENT_SIMULATION_BACKGROUND_COLOR L"background-color" |
Environment simulation.
#define ON_ENVIRONMENT_SIMULATION_BACKGROUND_IMAGE L"background-image" |
#define ON_ENVIRONMENT_SIMULATION_BACKGROUND_PROJECTION L"background-projection" |
#define ON_EPSILON 2.2204460492503131e-16 |
ON_EPSILON = 2^-52.
#define ON_ERROR | ( | msg | ) | ON_ErrorEx(__FILE__,__LINE__,OPENNURBS__FUNCTION__,msg) |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org. / Macros used to log errors and warnings. The ON_Warning() and ON_Error() / functions are defined in opennurbs_error.cpp.
#define ON_EXTERN_DECL |
#define ON_EXTERNC extern "C" |
C++ extern "C" declaration for C linkage.
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org. Includes all openNURBS toolkit defines and enums.
#define ON_FLOAT_EPSILON 1.192092896e-07 |
#define ON_FLT_MAX 3.402823466e+38F |
#define ON_forigin ON_3fPoint::Origin |
OBSOLETE - use ON_3fPoint::Origin.
#define ON_FPU_CW_DEFAULT ( ON_FPU_EX_ALL | ON_FPU_PC_53 | ON_FPU_RC_NEAR ) |
FPU default control word for Rhino and OpenNURBS
#define ON_FPU_CW_DEFAULT_MASK ( ON_FPU_CW_EX_MASK | ON_FPU_CW_PC_MASK | ON_FPU_CW_RC_MASK ) |
#define ON_FPU_CW_EX_MASK 0x0008001f |
FPU exception mask bits
#define ON_FPU_CW_PC_MASK 0x00030000 |
FPU control word precision control bits
#define ON_FPU_CW_RC_MASK 0x00000300 |
FPU control word rounding control bits
#define ON_FPU_EX_ALL (ON_FPU_EX_INEXACT|ON_FPU_EX_UNDERFLOW|ON_FPU_EX_OVERFLOW|ON_FPU_EX_ZERODIVIDE|ON_FPU_EX_INVALID|ON_FPU_EX_DENORMAL) |
Use ON_FPU_EX_ALL to mask all FPU exceptions.
#define ON_FPU_EX_DENORMAL 0x00080000 |
denormal exception mask
#define ON_FPU_EX_INEXACT 0x00000001 |
inexact (precision)
#define ON_FPU_EX_INVALID 0x00000010 |
invalid
#define ON_FPU_EX_MINOR (ON_FPU_EX_INEXACT|ON_FPU_EX_UNDERFLOW|ON_FPU_EX_DENORMAL) |
Minor FPU exceptions that are common and generally benign These should be masked unless you are doing something unusual.
#define ON_FPU_EX_OVERFLOW 0x00000004 |
overflow
#define ON_FPU_EX_UNDERFLOW 0x00000002 |
underflow
#define ON_FPU_EX_ZERODIVIDE 0x00000008 |
zero divide
#define ON_FPU_PC_24 0x00020000 |
24 bits
#define ON_FPU_PC_53 0x00010000 |
53 bits
#define ON_FPU_PC_64 0x00000000 |
64 bits
#define ON_FPU_RC_CHOP 0x00000300 |
chop
#define ON_FPU_RC_DOWN 0x00000100 |
down
#define ON_FPU_RC_NEAR 0x00000000 |
near
#define ON_FPU_RC_UP 0x00000200 |
up
#define ON_FPU_SW_BAD (ON_FPU_SW_OVERFLOW|ON_FPU_SW_ZERODIVIDE) |
"Bad" FPU status - results of calculation are suspect
As of November 2014, .NET makes it impossible to use the invalid status bit to detect serious floating point bugs and errors. See the comment above the declaration of ON_FPU_EnableInvalidStatusCheck() for more details. define ON_FPU_SW_BAD (ON_FPU_SW_OVERFLOW|ON_FPU_SW_ZERODIVIDE|ON_FPU_SW_INVALID)
#define ON_FPU_SW_DENORMAL 0x00080000 |
denormal status bit - ok - happens on occasion
#define ON_FPU_SW_INEXACT 0x00000001 |
inexact (precision) - ok - happens frequently
FPU control and query tools FPU status word bits
#define ON_FPU_SW_INVALID 0x00000010 |
invalid - bad
#define ON_FPU_SW_OVERFLOW 0x00000004 |
overflow - bad
#define ON_FPU_SW_UNDERFLOW 0x00000002 |
underflow - ok - happens on occasion
#define ON_FPU_SW_ZERODIVIDE 0x00000008 |
zero divide - bad
#define ON_fxaxis ON_3fVector::XAxis |
OBSOLETE - use ON_3fVector::XAxis.
#define ON_fyaxis ON_3fVector::YAxis |
OBSOLETE - use ON_3fVector::YAxis.
#define ON_fzaxis ON_3fVector::ZAxis |
OBSOLETE - use ON_3fVector::ZAxis.
#define ON_HALFPI (0.5*ON_PI) |
double precision ON_HALFPI = 0.5*ON_PI. ON_HALFPI radians = 90 degrees.
#define ON_HAS_RVALUEREF |
/ Compilers that do not support the C++ 11 rvalue refs / will change ON_HAS_RVALUEREF accordingly.
#define ON_HSORT_COPY | ( | dst, | |
src | |||
) | *dst = *src |
ON_SORT_TEMPLATE_TYPE -> double, int, ....
See opennurbs_sort.cpp for examples of using openurbs_hsort_template.c to define type specific heap sort functions. use type compares
#define ON_INT_FROM_ENUM | ( | e | ) | ((int)static_cast<unsigned int>(e)) |
#define ON_INTERNAL_SDK |
#define ON_IntSleepLock_Set | ( | lock, | |
lock_value | |||
) | lock=lock_value |
#define ON_IntSleepLock_Test | ( | lock, | |
test_value, | |||
sleep_value | |||
) | lock; |
if (test_value==lock) lock=sleep_value
#define ON_IS_FINITE | ( | x | ) | (_finite(x)?true:false) |
class ON_CLASS ON_TimeLimit { ON_TimeLimit(); ON_TimeLimit(ON__UINT64 time_limit_seconds); void SetTimeLimit(ON__UINT64 time_limit_seconds); bool Continue() const; bool IsSet() const; private: ON__UINT64 m_time_limit[2]; }; The ON_IS_FINITE and ON_IS_VALID defines are much faster than calling ON_IsValid(), but need to be used when the macro expansion works. Returns true if x is a finite double. Specifically, _finite returns a nonzero value (true) if its argument x is not infinite, that is, if -INF < x < +INF. It returns 0 (false) if the argument is infinite or a NaN.
If you are trying to compile opennurbs on a platform that does not support finite(), then see if you can use _fpclass(), fpclass(), _isnan(), or isnan(). If you can't find anything, then just set this function to return true.
#define ON_IS_FINITE_FLOAT | ( | x | ) | ((x) <= 3.402823466e+38F && (x) >= -3.402823466e+38F) |
#define ON_IS_INFINITE_FLOAT | ( | x | ) | ((x) > 3.402823466e+38F || (x) < -3.402823466e+38F) |
#define ON_IS_NAN | ( | x | ) | (!((x)==(x))) |
#define ON_IS_UNSET_DOUBLE | ( | x | ) | (ON_UNSET_VALUE == (x) || ON_UNSET_POSITIVE_VALUE == (x)) |
#define ON_IS_UNSET_FLOAT | ( | x | ) | (ON_UNSET_FLOAT == (x) || ON_UNSET_POSITIVE_FLOAT == (x)) |
#define ON_IS_VALID | ( | x | ) | ((x) > ON_UNSET_VALUE && (x) < ON_UNSET_POSITIVE_VALUE) |
#define ON_IS_VALID_FLOAT | ( | x | ) | ((x) > ON_UNSET_FLOAT && (x) < ON_UNSET_POSITIVE_FLOAT) |
#define ON_KIND_ENVIRONMENT L"environment" |
#define ON_KIND_MATERIAL L"material" |
Strings returned by ON_RenderContent::Kind().
#define ON_KIND_TEXTURE L"texture" |
#define ON_LOG10 2.302585092994045684017991 |
#define ON_LOG2 0.6931471805599453094172321 |
#define ON_MATERIAL_ALPHA_TRANSPARENCY L"alpha-transparency" |
General parameters used by materials that simulate ON_Material.
#define ON_MATERIAL_AMBIENT L"ambient" |
#define ON_MATERIAL_CLARITY_AMOUNT L"clarity-amount" |
#define ON_MATERIAL_DIFFUSE L"diffuse" |
#define ON_MATERIAL_DISABLE_LIGHTING L"disable-lighting" |
#define ON_MATERIAL_EMISSION L"emission" |
#define ON_MATERIAL_FLAMINGO_LIBRARY L"flamingo-library" |
#define ON_MATERIAL_FRESNEL_ENABLED L"fresnel-enabled" |
#define ON_MATERIAL_IOR L"ior" |
#define ON_MATERIAL_IS_PHYSICALLY_BASED L"is-physically-based" |
#define ON_MATERIAL_POLISH_AMOUNT L"polish-amount" |
#define ON_MATERIAL_REFLECTIVITY_AMOUNT L"reflectivity" |
#define ON_MATERIAL_REFLECTIVITY_COLOR L"reflectivity-color" |
#define ON_MATERIAL_SHINE L"shine" |
Value is 0.0..1.0, NOT ON_Material::MaxShine.
#define ON_MATERIAL_SIM_REFLECTION_COLOR L"reflection" |
Used by simulation, not by Custom Material field.
#define ON_MATERIAL_SIM_TRANSPARENT_COLOR L"transparent" |
Used by simulation, not by Custom Material field.
#define ON_MATERIAL_SPECULAR L"specular" |
#define ON_MATERIAL_TRANSPARENCY_AMOUNT L"transparency" |
#define ON_MATERIAL_TRANSPARENCY_COLOR L"transparency-color" |
#define ON_MAX_SIZE_T SIZE_MAX |
#define ON_MAXIMUM_WORLD_COORDINATE_VALUE 1.34217728e8 |
ON_MAXIMUM_VALUE = 2^27.
/ Bugs in geometry calculations involving world coordinates / values > ON_MAXIMUM_WORLD_COORDINATE_VALUE / will be a low priority.
#define ON_MINIMUM_ANGLE_TOLERANCE (ON_DEFAULT_ANGLE_TOLERANCE/10.0) |
#define ON_MSC_CDECL ON_CALLBACK_CDECL |
////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////// / / BEGIN - fill in missing types and defines / / If you are using an old compiler, then define ON_NEED_* when / you define ON_COMPILER_* above. / ////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////// / / Validate ON_SIZEOF_WCHAR_T and set ON_WCHAR_T_ENCODING / ////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////// / / BEGIN - OBSOLETE defines / / These legacy defines will be removed from V6 /
#define ON_NO_SLEEPLOCK_SUPPORT |
#error Need to fill in the following defines or comment out this error for single threaded applications
#define ON_NOEXCEPT noexcept |
/ Compilers that do not support the C++ 11 noexcept keyword / or similar will change ON_NOEXCEPT accordingly.
#define ON_NONSENSE_WORLD_COORDINATE_VALUE 1.0e100 |
ON_NONSENSE_WORLD_COORDINATE_VALUE = 1.0e100.
/ Any 3d coordinate value >= ON_NONSENSE_WORLD_COORDINATE_VALUE / will be adjusted as needed. Any calculation creating 3d coordinates / with values >= ON_NONSENSE_WORLD_COORDINATE_VALUE should be / inspected for bugs.
#define ON_OBJECT_DECLARE | ( | cls | ) |
All classes derived from ON_Object must have the declaration macro ON_OBJECT_DECLARE( <classname> ); as the first line in their class definition, must have a robust operator=(), should have a robust copy constructor, and must have exactly one of the following implementation macros in a .cpp file. Classes with a pure virtual function: ON_VIRTUAL_OBJECT_IMPLEMENT( <classname>, <basclassname>, <classuuid> ) Classes with an operator= and copy constructor. ON_OBJECT_IMPLEMENT( <classname>, <basclassname>, <classuuid> ) Classes with an operator=, but no copy constructor. ON_OBJECT_IMPLEMENT_NO_COPYCTOR( <classname>, <basclassname>, <classuuid> )
#define ON_OBJECT_DECLARE_OVERRIDE override |
#define ON_OBJECT_DECLARE_OVERRIDE |
#define ON_OBJECT_DECLARE_OVERRIDE override |
#define ON_OBJECT_DECLARE_VIRTUAL |
Every other use of ON_OBJECT_DECLARE() is in derived class.
#define ON_OBJECT_DECLARE_VIRTUAL virtual |
Every other use of ON_OBJECT_DECLARE() is in derived class.
#define ON_OBJECT_DECLARE_VIRTUAL |
Every other use of ON_OBJECT_DECLARE() is in derived class.
#define ON_OBJECT_IMPLEMENT | ( | cls, | |
basecls, | |||
uuid | |||
) |
Classes derived from ON_Object that have a valid default constructor, valid copy constructor, operator new and operator= can use ON_OBJECT_IMPLEMENT in their implementation. Classes implemented with ON_OBJECT_IMPLEMENT can be created from their run-time type information id and their Duplicate() function will use the class's copy constructor to create a deep copy.
#define ON_OBJECT_IMPLEMENT_NO_COPY | ( | cls, | |
basecls, | |||
uuid | |||
) |
Classes derived from ON_Object that have a valid default constructor, operator new and operator=, but do not have a valid copy constructor or assignment operator, can use ON_OBJECT_IMPLEMENT_NO_COPY in their implementation. Classes implemented with ON_OBJECT_IMPLEMENT_NO_COPY can be created from their run-time type information id and their Duplicate() function will silently return a nullptr. CopyFrom will return false.
#define ON_OBJECT_IMPLEMENT_NO_COPYCTOR | ( | cls, | |
basecls, | |||
uuid | |||
) |
Classes derived from ON_Object that have a valid default constructor, operator new and operator=, but do not have a valid copy constructor, can use ON_OBJECT_IMPLEMENT_NO_COPYCTOR in their implementation. Classes implemented with ON_OBJECT_IMPLEMENT_NO_COPYCTOR can be created from their run-time type information id and their Duplicate() function will use the class's default constructor and operator= to create a deep copy.
#define ON_origin ON_3dPoint::Origin |
OBSOLETE - use ON_3dPoint::Origin.
#define ON_PARTICLE_SYSTEM_WIP |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org.
#define ON_PBR_MATERIAL_ALPHA L"pbr-alpha" |
#define ON_PBR_MATERIAL_ANISOTROPIC L"pbr-anisotropic" |
#define ON_PBR_MATERIAL_ANISOTROPIC_ROTATION L"pbr-anisotropic-rotation" |
#define ON_PBR_MATERIAL_BASE_COLOR L"pbr-base-color" |
#define ON_PBR_MATERIAL_BRDF L"pbr-brdf" |
#define ON_PBR_MATERIAL_BRDF_GGX L"ggx" |
#define ON_PBR_MATERIAL_BRDF_WARD L"ward" |
#define ON_PBR_MATERIAL_CLEARCOAT L"pbr-clearcoat" |
#define ON_PBR_MATERIAL_CLEARCOAT_BUMP L"pbr-clearcoat-bump" |
#define ON_PBR_MATERIAL_CLEARCOAT_ROUGHNESS L"pbr-clearcoat-roughness" |
#define ON_PBR_MATERIAL_EMISSION_COLOR L"pbr-emission" |
#define ON_PBR_MATERIAL_EMISSION_MULTIPLIER L"emission-multiplier" |
#define ON_PBR_MATERIAL_METALLIC L"pbr-metallic" |
#define ON_PBR_MATERIAL_OPACITY L"pbr-opacity" |
#define ON_PBR_MATERIAL_OPACITY_IOR L"pbr-opacity-ior" |
#define ON_PBR_MATERIAL_OPACITY_ROUGHNESS L"pbr-opacity-roughness" |
#define ON_PBR_MATERIAL_ROUGHNESS L"pbr-roughness" |
#define ON_PBR_MATERIAL_SHEEN L"pbr-sheen" |
#define ON_PBR_MATERIAL_SHEEN_TINT L"pbr-sheen-tint" |
#define ON_PBR_MATERIAL_SPECULAR L"pbr-specular" |
#define ON_PBR_MATERIAL_SPECULAR_TINT L"pbr-specular-tint" |
#define ON_PBR_MATERIAL_SUBSURFACE L"pbr-subsurface" |
#define ON_PBR_MATERIAL_SUBSURFACE_SCATTERING_COLOR L"pbr-subsurface-scattering-color" |
#define ON_PBR_MATERIAL_SUBSURFACE_SCATTERING_RADIUS L"pbr-subsurface-scattering-radius" |
#define ON_PBR_MATERIAL_USE_BASE_COLOR_TEXTURE_ALPHA L"pbr-use-base-color-texture-alpha" |
#define ON_PI 3.141592653589793238462643 |
double precision ON_PI = 3.141592653589793238462643. ON_PI radians = 180 degrees
#define ON_PLUS_MESH_INTERSECTION_INC_ |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org.
#define ON_PLUS_RECTPACK2_INC_ |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org.
#define ON_PointerSleepLock_Set | ( | ptr_type, | |
ptr, | |||
ptr_value | |||
) | (ptr_type*)(ptr); ((ptr)=(ptr_value)); |
#define ON_PointerSleepLock_SuspendThisThread | ( | n | ) | usleep(n) |
Sleeps the THREAD not the PROCESS.
#define ON_PointerSleepLock_Test | ( | ptr_type, | |
ptr | |||
) | (ptr_type*)(ON_Internal_CompareExchangePointer((void* volatile*)(&(ptr)),(void*)1,(void*)0)) |
#define ON_PRAGMA_WARNING_AFTER_DIRTY_INCLUDE ON_PRAGMA_WARNING_POP |
#define ON_PRAGMA_WARNING_BEFORE_DIRTY_INCLUDE ON_PRAGMA_WARNING_PUSH |
#define ON_PRAGMA_WARNING_DISABLE_CLANG | ( | ON_PRAGMA_WARNING_DISABLE_param | ) |
#define ON_PRAGMA_WARNING_DISABLE_GNU | ( | ON_PRAGMA_WARNING_DISABLE_param | ) | GCC diagnostic ignored ON_PRAGMA_WARNING_DISABLE_param |
Apple CLang warning disable.
#define ON_PRAGMA_WARNING_DISABLE_MSC | ( | ON_PRAGMA_WARNING_DISABLE_param | ) |
These defines will be set to something more appropriate when opennurbs_system_compiler detects the compiler and platform.
#define ON_PRAGMA_WARNING_POP GCC diagnostic pop |
Gnu gcc warning state pop.
#define ON_PRAGMA_WARNING_PUSH GCC diagnostic push |
Gnu gcc warning state push.
/ Usage example - disables gcc warning xyz - See Gnu gcc docs for warning options #pragma ON_PRAGMA_WARNING_PUSH #pragma ON_PRAGMA_WARNING_DISABLE_CLANG("-Wxyx") ... #pragma ON_PRAGMA_WARNING_POP
#define ON_PTR_SEMAPHORE1 ((ON__UINT_PTR)8) |
The ON_PTR_SEMAPHORE* values are used in rare cases when a special signal must be passed as a pointer argument. The values must be a multiple of 8 to suppress runtime pointer alignment checks. The values must never be a valid user heap or stack pointer value.
#define ON_PTR_SEMAPHORE2 ((ON__UINT_PTR)16) |
#define ON_PTR_SEMAPHORE3 ((ON__UINT_PTR)24) |
#define ON_PTR_SEMAPHORE4 ((ON__UINT_PTR)32) |
#define ON_PTR_SEMAPHORE_MAX ((ON__UINT_PTR)32) |
#define ON_QSORT_CUTOFF 8 /* testing shows that this is good value */ |
NOTE: 14 April 2011 Dale Lear: Replace this code with Mikko's "quacksort", once "quacksort" is fully debugged This code is based ont the VC 2010 crt qsort.c file and must not be released with public opennurbs. See opennurbs_sort.cpp for examples of using openurbs_qsort_template.c to define type specific quick sort functions.
#define ON_QSORT_SHORT_SORT_FNAME ON__shortsort |
The default name for the short sort helper function is ON__shortsort.
When opennurbs_qsort_template.h is included more than once in the same file for sorting the same type with different compare functions, then either 1) After the first include, define ON_SORT_TEMPLATE_HAVE_SHORT_SORT to prevent generation of an identical short-sort function or 2) Define different values of ON_QSORT_SHORT_SORT_FNAME to generate different short-sort helper functions.
#define ON_QSORT_STKSIZ (8*sizeof(void*) - 2) |
Note: the theoretical number of stack entries required is no more than 1 + log2(num). But we switch to insertion sort for CUTOFF elements or less, so we really only need 1 + log2(num) - log2(CUTOFF) stack entries. For a CUTOFF of 8, that means we need no more than 30 stack entries for 32 bit platforms, and 62 for 64-bit platforms.
#define ON_QUACKSORT_SWAP_FUNCS_DEFINED |
In some files this template is used multiple times. The ON_QUACKSORT_SWAP_FUNCS_DEFINED define prevents multiple definitions of the static Swap*() functions.
#define ON_RADIANS_TO_DEGREES (180.0/ON_PI) |
angle_in_radians = ON_RADIANS_TO_DEGREES*angle_in_degrees
#define ON_RDK_BACKGROUND_ENVIRONMENT L"environment" |
#define ON_RDK_CURRENT_CONTENT L"content" |
#define ON_RDK_CURRENT_RENDER_PRESET L"current-preset" |
#define ON_RDK_CUSTOM_IMAGE_SIZE_IS_PRESET L"custom-image-size-is-preset" |
#define ON_RDK_CUSTOM_REFLECTIVE_ENVIRONMENT L"custom-env-for-refl-and-refr" |
#define ON_RDK_CUSTOM_REFLECTIVE_ENVIRONMENT_ON L"custom-env-for-refl-and-refr-on" |
#define ON_RDK_DECAL L"decal" |
#define ON_RDK_DECAL_CUSTOM L"custom" |
#define ON_RDK_DECAL_CUSTOM_PARAMS L"parameters" |
#define ON_RDK_DECAL_CUSTOM_RENDERER L"renderer" |
#define ON_RDK_DECAL_HEIGHT L"height" |
#define ON_RDK_DECAL_HORZ_SWEEP_END L"latitude-stop" |
#define ON_RDK_DECAL_HORZ_SWEEP_STA L"latitude-start" |
#define ON_RDK_DECAL_INSTANCE_ID L"instance-id" |
#define ON_RDK_DECAL_IS_TEMPORARY L"is-temporary" |
#define ON_RDK_DECAL_IS_VISIBLE L"is-visible" |
#define ON_RDK_DECAL_MAP_TO_INSIDE_ON L"map-to-inside-on" |
#define ON_RDK_DECAL_MAPPING L"mapping" |
#define ON_RDK_DECAL_MAPPING_CYLINDRICAL L"cylindrical" |
#define ON_RDK_DECAL_MAPPING_NONE L"none" |
#define ON_RDK_DECAL_MAPPING_PLANAR L"planar" |
--— +++++++++++++++++++
#define ON_RDK_DECAL_MAPPING_SPHERICAL L"spherical" |
#define ON_RDK_DECAL_MAPPING_UV L"uv" |
#define ON_RDK_DECAL_MAX_U L"max-u" |
#define ON_RDK_DECAL_MAX_V L"max-v" |
#define ON_RDK_DECAL_MIN_U L"min-u" |
#define ON_RDK_DECAL_MIN_V L"min-v" |
#define ON_RDK_DECAL_ORIGIN L"origin" |
#define ON_RDK_DECAL_PROJECTION L"projection" |
#define ON_RDK_DECAL_PROJECTION_BACKWARD L"backward" |
#define ON_RDK_DECAL_PROJECTION_BOTH L"both" |
#define ON_RDK_DECAL_PROJECTION_FORWARD L"forward" |
--— ++++++++++++++++++++++
#define ON_RDK_DECAL_PROJECTION_NONE L"none" |
#define ON_RDK_DECAL_RADIUS L"radius" |
#define ON_RDK_DECAL_TEXTURE_INSTANCE L"texture-instance" |
#define ON_RDK_DECAL_TRANSPARENCY L"transparency" |
#define ON_RDK_DECAL_VECTOR_ACROSS L"vector-across" |
#define ON_RDK_DECAL_VECTOR_UP L"vector-up" |
#define ON_RDK_DECAL_VERT_SWEEP_END L"longitude-stop" |
#define ON_RDK_DECAL_VERT_SWEEP_STA L"longitude-start" |
#define ON_RDK_DECALS L"decals" |
Decals (stored in object attributes user data).
#define ON_RDK_DEFAULT_CONTENT_SECTION L"default-content-section" |
#define ON_RDK_DITHERING_ENABLED L"use-dithering" |
#define ON_RDK_DITHERING_METHOD L"dithering" |
#define ON_RDK_DITHERING_METHOD_FLOYD_STEINBERG L"floyd-steinberg" |
#define ON_RDK_DITHERING_METHOD_SIMPLE_NOISE L"simple-noise" |
#define ON_RDK_DOCUMENT L"render-content-manager-document" |
This is the structure of the RDK document XML.
#define ON_RDK_EMBED_SUPPORT_FILES_ON L"embed-support-files-on" |
#define ON_RDK_EXCLUDED_RENDER_ENGINES L"excluded-render-engines" |
#define ON_RDK_FILTERS L"filters" |
#define ON_RDK_GP_ALTITUDE L"altitude" |
#define ON_RDK_GP_AUTO_ALTITUDE L"auto-altitude" |
#define ON_RDK_GP_ENABLED L"on" |
#define ON_RDK_GP_MATERIAL_ID L"material" |
#define ON_RDK_GP_SHADOW_ONLY L"shadow-only" |
#define ON_RDK_GP_SHOW_UNDERSIDE L"show-underside" |
#define ON_RDK_GP_TEXTURE_OFFSET L"texture-offset" |
#define ON_RDK_GP_TEXTURE_OFFSET_LOCKED L"offset-lock" |
Keep old string.
#define ON_RDK_GP_TEXTURE_ROTATION L"texture-rotation" |
#define ON_RDK_GP_TEXTURE_SIZE L"texture-size" |
#define ON_RDK_GP_TEXTURE_SIZE_LOCKED L"repeat-lock" |
Keep old string.
#define ON_RDK_GROUND_PLANE L"ground-plane" |
#define ON_RDK_IMPORT L"import" |
#define ON_RDK_MISCELLANEOUS L"miscellaneous" |
#define ON_RDK_NAME_COLLISION_SUPPRESS L"smart-merge-name-collision-suppress" |
#define ON_RDK_NAME_FILTER L"name-filter" |
#define ON_RDK_NAME_FILTER_INVERT L"name-filter-invert" |
#define ON_RDK_NAMED_CPLANES L"named-cplanes" |
#define ON_RDK_NAMED_POSITIONS L"named-positions" |
#define ON_RDK_NAMED_SNAPSHOTS L"named-snapshots" |
#define ON_RDK_NAMED_VIEWS L"named-views" |
#define ON_RDK_PASTE L"paste" |
#define ON_RDK_PEP_ID L"id" |
#define ON_RDK_PEP_LOCAL_NAME L"name" |
#define ON_RDK_PEP_ON L"on" |
#define ON_RDK_PEP_PARAMS L"state" |
This should really be 'params'.
#define ON_RDK_PEP_PLUG_IN L"plug-in" |
#define ON_RDK_PEP_SELECTION L"selection" |
#define ON_RDK_PEP_SHOWN L"shown" |
#define ON_RDK_PEP_TYPE_EARLY L"early" |
#define ON_RDK_PEP_TYPE_LATE L"late" |
#define ON_RDK_PEP_TYPE_TONE_MAPPING L"tone-mapping" |
#define ON_RDK_POST_EFFECTS L"post-effects-new" |
#define ON_RDK_POST_PROCESS_GAMMA L"gamma" |
Keep original XML tag.
#define ON_RDK_POST_PROCESS_GAMMA_ON L"use-post-process-gamma" |
#define ON_RDK_POSTFIX_SECTION L"-section" |
#define ON_RDK_PRE_PROCESS_GAMMA_ON L"use-linear-workflow" |
#define ON_RDK_RCH_LIST L"list" |
#define ON_RDK_RCH_MODE L"mode" |
#define ON_RDK_RCH_MODE_AUTOMATIC L"automatic" |
#define ON_RDK_RCH_MODE_CUSTOM L"custom" |
#define ON_RDK_RENDER_CHANNELS L"render-channels" |
#define ON_RDK_RENDERING L"rendering" |
#define ON_RDK_SAFE_FRAME L"safe-frame" |
#define ON_RDK_SETTINGS L"settings" |
#define ON_RDK_SF_4x3_FIELD_GRID_ON L"field-display-on" |
#define ON_RDK_SF_ACTION_FRAME L"action-frame" |
#define ON_RDK_SF_ENABLED L"on" |
#define ON_RDK_SF_LIVE_FRAME L"live-frame" |
#define ON_RDK_SF_PERSPECTIVE_ONLY L"perspective-only" |
#define ON_RDK_SF_TITLE_FRAME L"title-frame" |
#define ON_RDK_SFF_LINK L"link" |
#define ON_RDK_SFF_ON L"on" |
#define ON_RDK_SFF_XSCALE L"x-scale" |
#define ON_RDK_SFF_YSCALE L"y-scale" |
#define ON_RDK_SHOW_HIDDEN L"show-hidden-materials" |
#define ON_RDK_SHOW_REFERENCE L"show-reference-materials" |
#define ON_RDK_SHOW_UNASSIGNED L"show-unassigned-materials" |
#define ON_RDK_SHOW_V4 L"show-v4-materials" |
#define ON_RDK_SORT_MODE L"sort-mode" |
#define ON_RDK_SORT_MODE_ASCENDING L"ascending" |
#define ON_RDK_SORT_MODE_CUSTOM L"custom" |
#define ON_RDK_SORT_MODE_DESCENDING L"descending" |
#define ON_RDK_SUN L"sun" |
#define ON_RDK_SUN_ALTITUDE L"sun-altitude" |
#define ON_RDK_SUN_AZIMUTH L"sun-azimuth" |
#define ON_RDK_SUN_DATE_DAY L"day" |
#define ON_RDK_SUN_DATE_MONTH L"month" |
#define ON_RDK_SUN_DATE_YEAR L"year" |
#define ON_RDK_SUN_DAYLIGHT_SAVING_MINUTES L"daylight-saving-minutes" |
#define ON_RDK_SUN_DAYLIGHT_SAVING_ON L"daylight-saving-on" |
#define ON_RDK_SUN_ENABLE_ALLOWED L"enable-allowed" |
#define ON_RDK_SUN_ENABLE_ON L"enable-on" |
#define ON_RDK_SUN_INTENSITY L"intensity" |
#define ON_RDK_SUN_MANUAL_CONTROL_ALLOWED L"manual-control-allowed" |
#define ON_RDK_SUN_MANUAL_CONTROL_ON L"manual-control-on" |
#define ON_RDK_SUN_NORTH L"north" |
#define ON_RDK_SUN_OBSERVER_LATITUDE L"observer-latitude" |
#define ON_RDK_SUN_OBSERVER_LONGITUDE L"observer-longitude" |
#define ON_RDK_SUN_OBSERVER_TIMEZONE L"observer-timezone" |
#define ON_RDK_SUN_SHADOW_INTENSITY L"shadow-intensity" |
#define ON_RDK_SUN_SKYLIGHT_ENABLED L"skylight-on" |
#define ON_RDK_SUN_SKYLIGHT_ENVIRONMENT_ID L"skylight-custom-environment" |
#define ON_RDK_SUN_SKYLIGHT_ENVIRONMENT_OVERRIDE L"skylight-custom-environment-on" |
#define ON_RDK_SUN_SKYLIGHT_SHADOW_INTENSITY L"skylight-shadow-intensity" |
#define ON_RDK_SUN_TIME_HOURS L"time" |
#define ON_RDK_UUIDS L"uuids" |
#define ON_RELATIVE_CURVATURE_TOLERANCE 0.05 |
#define ON_RELATIVE_TOLERANCE 2.27373675443232059478759765625e-13 |
ON_RELATIVE_TOLERANCE = 2^-42.
/ In cases when an relative "zero" tolerance is / required for comparing model space coordinates, / (fabs(a)+fabs(b))*ON_RELATIVE_TOLERANCE is used. / ON_RELATIVE_TOLERANCE should be larger than / ON_EPSILON and smaller than no larger than / ON_ZERO_TOLERANCE*2^-10. /
#define ON_RENDER_CONTENT_AUTO_DELETE L"auto-delete" |
#define ON_RENDER_CONTENT_CHILD_SLOT_NAME L"child-slot-name" |
#define ON_RENDER_CONTENT_GROUP_ID L"group-id" |
#define ON_RENDER_CONTENT_HIDDEN L"hidden" |
#define ON_RENDER_CONTENT_INSTANCE_ID L"instance-id" |
#define ON_RENDER_CONTENT_INSTANCE_NAME L"instance-name" |
#define ON_RENDER_CONTENT_NOTES L"notes" |
#define ON_RENDER_CONTENT_PARAMETERS L"parameters" |
#define ON_RENDER_CONTENT_PARAMETERS_V8 L"parameters-v8" |
#define ON_RENDER_CONTENT_PLUG_IN_ID L"plug-in-id" |
#define ON_RENDER_CONTENT_REFERENCE L"reference" |
#define ON_RENDER_CONTENT_RENDER_ENGINE_ID L"render-engine-id" |
#define ON_RENDER_CONTENT_SIMULATION L"simulation" |
#define ON_RENDER_CONTENT_TAGS L"tags" |
#define ON_RENDER_CONTENT_TYPE_ID L"type-id" |
#define ON_RENDER_CONTENT_TYPE_NAME L"type-name" |
Render Content.
#define ON_RENDER_MATERIAL_TEXTURE_SIMULATION_AMOUNT L"amount" |
#define ON_RENDER_MATERIAL_TEXTURE_SIMULATION_FILENAME L"filename" |
#define ON_RENDER_MATERIAL_TEXTURE_SIMULATION_FILTER L"filter" |
#define ON_RENDER_MATERIAL_TEXTURE_SIMULATION_FORMAT L"Texture-%u-" |
Material's texture simulation.
#define ON_RENDER_MATERIAL_TEXTURE_SIMULATION_MODE L"mode" |
#define ON_RENDER_MATERIAL_TEXTURE_SIMULATION_ON L"on" |
#define ON_RENDER_MATERIAL_TEXTURE_SIMULATION_TYPE L"type" |
#define ON_RENDER_MATERIAL_TEXTURE_SIMULATION_UVW L"uvw" |
#define ON_RENDER_MATERIAL_TEXTURE_SIMULATION_WRAP_U L"wrap-u" |
#define ON_RENDER_MATERIAL_TEXTURE_SIMULATION_WRAP_V L"wrap-v" |
#define ON_RENDER_TEXTURE_FILENAME L"filename" |
#define ON_RTree_MAX_NODE_COUNT 6 |
#define ON_RTree_MIN_NODE_COUNT 2 |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org. The opennurbs rtree code is a modified version of the free and unrestricted R-tree implementation obtained from http://www.superliminal.com/sources/sources.htm
The first lines on the website indicate the code is free and unrestricted:
Free Source Code Here are a few useful bits of free source code. You're completely free to use them for any purpose whatsoever. All I ask is that if you find one to be particularly valuable, then consider sending feedback. Please send bugs and suggestions too. Enjoy
The readme.txt file included with the R-tree source says
LICENSE: Entirely free for all uses. Enjoy!
The original authors are
AUTHORS 1983 Original algorithm and test code by Antonin Guttman and Michael Stonebraker, UC Berkely 1994 ANCI C ported from original test code by Melinda Green - melin 1995 Sphere volume fix for degeneracy problem submitted by Paul Brook 2004 Templated C++ port by Greg Douglas da@s uperl imin al.co m
The opennurbs version adds some custom memory allocation and replaces the leaf iterator. The rest of the changes are cosmetic. Minimum and maximum number of elements in ON_RTreeNode::m_branch[]. must have ON_RTree_MAX_NODE_COUNT > ON_RTree_MIN_NODE_COUNT
#define ON_SHUTLINING_AUTO_UPDATE L"auto-update" |
#define ON_SHUTLINING_CURVE L"curve" |
#define ON_SHUTLINING_CURVE_ENABLED L"enabled" |
#define ON_SHUTLINING_CURVE_IS_BUMP L"is-bump" |
#define ON_SHUTLINING_CURVE_PROFILE L"profile" |
#define ON_SHUTLINING_CURVE_PULL L"pull" |
#define ON_SHUTLINING_CURVE_RADIUS L"radius" |
#define ON_SHUTLINING_CURVE_UUID L"uuid" |
#define ON_SHUTLINING_FACETED L"faceted" |
#define ON_SHUTLINING_FORCE_UPDATE L"force-update" |
#define ON_SHUTLINING_ON L"on" |
#define ON_SHUTLINING_ROOT L"shut-lining-object-data" |
#define ON_SIN_PI_OVER_12 0.2588190451025207623488990 |
#define ON_SleepLock_SuspendThisThread | ( | n | ) | usleep(n) |
Sleeps the THREAD not the PROCESS.
#define ON_SLEEPLOCK_USES_STD_ATOMIC_FLAG |
Use std::atomic_lock and std::this_thread::sleep_for(std::chrono::milliseconds(...))
#define ON_SQRT2 1.414213562373095048801689 |
#define ON_SQRT3 1.732050807568877293527446 |
#define ON_SQRT3_OVER_2 0.8660254037844386467637230 |
#define ON_SQRT_EPSILON 1.490116119385000000e-8 |
#define ON_SQRT_FLOAT_EPSILON 3.452669830725202719e-4 |
#define ON_STATIC_ASSERT | ( | expr | ) | typedef char on_static_assert_t[(expr) != 0] |
< C++17
////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////// / / BEGIN - ON_COMPILER_* defines / / ON_COMPILER_* specifies the C/C++ compiler used. / At most one the ON_COMPILER_* should be defined. / / Compilers with a better static_assert declaration / may change ON_STATIC_ASSERT accordingly. < C++11
#define ON_STATIC_ASSERT_MSG | ( | expr, | |
msg | |||
) | typedef char on_static_assert_t[(expr) != 0] |
#define ON_TESTS_BUILD |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org. WARNING: DO NOT INCLUDE THIS FILE WITH THE DISTRIBUTION OF OPENNURBS OR IN THE RHINO SDK PURPOSE: this file is used to expose functions that are normally not part of the API of opennurbs, with the purpose of being able to unit tests such functions as part of the build.
USAGE: Include the function signatures prepended with ON_DECL to export the function in the opennurbs library. This will allow the tests to call the function directly.
DEFINES: This file defines the symbol ON_TESTS_BUILD which you can use to fine tune your code.
#define ON_TEXT_BRACKET_FRACTION |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org.
#define ON_TEXTURE_CHILD_SLOT_NAME_BITMAP_TEXTURE L"bitmap-texture" |
Standard texture child slot names.
#define ON_TEXTURE_CHILD_SLOT_NAME_BUMP_TEXTURE L"bump-texture" |
#define ON_TEXTURE_CHILD_SLOT_NAME_ENVIRONMENT_TEXTURE L"environment-texture" |
#define ON_TEXTURE_CHILD_SLOT_NAME_TRANSPARENCY_TEXTURE L"transparency-texture" |
#define ON_TEXTURE_SIMULATION_BLEND_CONSTANT_A L"blend-constant-a" |
#define ON_TEXTURE_SIMULATION_FILENAME L"filename" |
#define ON_TEXTURE_SIMULATION_HAS_TRANSPARENT_COLOR L"has-trans-color" |
#define ON_TEXTURE_SIMULATION_MAG_FILTER L"mag-filter" |
#define ON_TEXTURE_SIMULATION_MAPPING_CHANNEL L"mapping-channel" |
#define ON_TEXTURE_SIMULATION_MIN_FILTER L"min-filter" |
#define ON_TEXTURE_SIMULATION_MODE L"mode" |
#define ON_TEXTURE_SIMULATION_OFFSET L"offset" |
#define ON_TEXTURE_SIMULATION_ON L"on" |
Texture simulation.
#define ON_TEXTURE_SIMULATION_PROJECTION_MODE L"projection-mode" |
#define ON_TEXTURE_SIMULATION_REPEAT L"repeat" |
#define ON_TEXTURE_SIMULATION_ROTATION L"rotation" |
#define ON_TEXTURE_SIMULATION_TRANSPARENCY_TEXTURE_ID L"transparency-texture-id" |
#define ON_TEXTURE_SIMULATION_TRANSPARENT_COLOR L"trans-color" |
#define ON_TEXTURE_SIMULATION_TRANSPARENT_COLOR_SENSITIVITY L"trans-color-sensitivity" |
#define ON_TEXTURE_SIMULATION_TREAT_AS_LINEAR L"treat-as-linear" |
#define ON_TEXTURE_SIMULATION_TYPE L"type" |
#define ON_TEXTURE_SIMULATION_WRAP_TYPE L"wrap-type" |
#define ON_THICKENING_BOTH_SIDES L"both-sides" |
#define ON_THICKENING_DISTANCE L"distance" |
#define ON_THICKENING_OFFSET_ONLY L"offset-only" |
#define ON_THICKENING_ON L"on" |
#define ON_THICKENING_ROOT L"thickening-object-data" |
Thickening
#define ON_THICKENING_SOLID L"solid" |
#define ON_UINT_FROM_ENUM | ( | e | ) | (static_cast<unsigned int>(e)) |
#define ON_UINT_MAX (~(0U)) |
#define ON_UNSET_COLOR 0xFFFFFFFF |
/ In cases where lazy evaluation of a color value is / performed, this value is used to indicate the value / has not been computed.
#define ON_UNSET_FLOAT -ON_UNSET_POSITIVE_FLOAT |
#define ON_UNSET_INT_INDEX ((const int)-2147483647) |
When signed int values are used in a context where 0 and small negative values are valid indices and there needs to be a value that indicates the index is not set, use ON_UNSET_INT_INDEX. This value is INT_MIN+1
#define ON_unset_point ON_3dPoint::UnsetPoint |
OBSOLETE - use ON_3dPoint::UnsetPoint.
common points and vectors
ON_unset_point is obsolete - use ON_3dPoint::UnsetPoint
#define ON_UNSET_POINT ON_3dPoint::UnsetPoint |
OBSOLETE - use ON_3dPoint::UnsetPoint.
#define ON_UNSET_POSITIVE_FLOAT 1.234321e+38f |
/ ON_UNSET_FLOAT is used to indicate a texture coordinate / value cannot be calculated or is not well defined.
/ In hindsight, this value should have been ON_FLT_QNAN / because many calculation convert float texture coordinates / to doubles and the "unset"ness attribute is lost.
#define ON_UNSET_POSITIVE_VALUE 1.23432101234321e+308 |
/ In cases where lazy evaluation of a double value is / performed, b-rep tolerances being a notable example, / this value is used to indicate the value has not been / computed. This value must be < -1.0e308. and > -ON_DBL_MAX / / The reasons ON_UNSET_VALUE is a valid finite number are: / / 1) It needs to round trip through fprintf/sscanf. / 2) It needs to persist unchanged through assignment / and not generate exceptions when assigned. / 3) ON_UNSET_VALUE == ON_UNSET_VALUE needs to be true. / 4) ON_UNSET_VALUE != ON_UNSET_VALUE needs to be false. / / Ideally, it would also have these SNaN attributes / * When used in a calculation, a floating point exception / occurs. / * No possibility of a valid calculation would generate / ON_UNSET_VALUE. / * float f = (float)ON_UNSET_VALUE would create an invalid / float and generate an exception.
#define ON_UNSET_UINT_INDEX 0xFFFFFFFFU |
When unsigned int values are used in a context where 0 is a valid index and there needs to be a value that indicates the index is not set, use ON_UNSET_UINT_INDEX.
#define ON_UNSET_VALUE -ON_UNSET_POSITIVE_VALUE |
#define ON_UNSET_VECTOR ON_3dVector::UnsetVector |
OBSOLETE - use ON_3dPoint::UnsetVector.
#define ON_UUID_DEFINED |
ON_UUID is a 16 byte universally unique identifier.
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org. This code also exists in version.h, but needs to be here to solve include ordering problems, and for standalone opennurbs.dll builds.
#define ON_VARGS_FUNC_CDECL |
/ Compilers that require special declaration of callback functions / will change ON_CALLBACK_CDECL accordingly.
#define ON_VERSION_NUMBER_CTOR | ( | major, | |
minor, | |||
year, | |||
month, | |||
day_of_month, | |||
branch | |||
) |
ON_VERSION_NUMBER_CTOR(major,minor,year,month,day_of_month,branch) is a macro whose value is the opennurbs version number encoding for the specified major, minor, year, month and day_of_month values.
In almost every situation, it is best to used the function call ON_VersionNumberConstruct(major,minor,year,month,day_of_month,branch) to get this value. The ON_VERSION_NUMBER_CTOR macro is for rare and unusual situations where the C preprocessor needs this value.
#define ON_VERSION_NUMBER_DAYOFYEAR | ( | year, | |
month, | |||
day_of_month | |||
) |
ON_VERSION_NUMBER_DAYOFYEAR(year, month, day_of_month) is a macro whose value is the cardinal day of the year for the specified year, month and day_of_month.
In almost every situation, it is best to used the function call ON_DayOfGregorianYear(year,month,day_of_month) to get this value. The ON_VERSION_NUMBER_DAYOFYEAR macro is for rare and unusual situations where the C preprocessor needs this value.
#define ON_VERSION_NUMBER_FEBDAYS | ( | year | ) |
ON_VERSION_NUMBER_FEBDAYS(year) is a macro whose value is the number of days in the month of February in a specified year.
In almost every situation, it is best to used the function call ON_DaysInMonthOfGregorianYear(year,2) to get this value. The ON_VERSION_NUMBER_FEBDAYS macro is for rare and unusual situations where the C preprocessor needs this value.
#define ON_VERSION_NUMBER_PLATFORM_ID | ( | branch | ) | (((branch) > 0x0U) ? (0x02U - ((branch) % 0x02U)) : 0x0U) |
branch is 0 for developer builds, odd for windows builds, and even for Mac builds When compressed into 2 bits, the type of build (Commercial/Beta/WIP) is not encoded.
branch 0: developer build 1: Windows Commercial build 2: Mac Commercial build 3: Windows BETA build 4: Mac Beta build 5: Windows WIP build 6: Mac WIP build
ON_VERSION_NUMBER_PLATFORM_ID(branch) = = 0: developer build 1: Windows build 2: Mac build
NOTE WELL: ON_VERSION_NUMBER_PLATFORM_ID(branch) must be a value between 0 and 3.
#define ON_VERSION_NUMBER_TIME | ( | year, | |
month, | |||
day_of_month | |||
) | ((((year)-2000)*367) + (ON_VERSION_NUMBER_DAYOFYEAR(year,month,day_of_month))) |
#define ON_VIRTUAL_OBJECT_IMPLEMENT | ( | cls, | |
basecls, | |||
uuid | |||
) |
Classes derived from ON_Object that are pure virtual classes, or do not have a valid default constructor, valid operator new or valid operator= must use ON_VIRTUAL_OBJECT_IMPLEMENT in their implementation. Classes implemented with ON_VIRTUAL_OBJECT_IMPLEMENT cannot be serialized using ON_BinaryArchive::ReadObject()/WriteObject() or duplicated using ON_Object::Duplicate(). The Cast() and ClassId() members work on classes implemented with ON_VIRTUAL_OBJECT_IMPLEMENT, ON_OBJECT_IMPLEMENT or ON_OBJECT_IMPLEMENT_NO_COPYCTOR
#define ON_WARNING | ( | msg | ) | ON_WarningEx(__FILE__,__LINE__,OPENNURBS__FUNCTION__,msg) |
#define ON_WIP_CLASS ON_CLASS |
#endif
Functions with ON_WIP_DECL are works in progress. Classes with ON_WIP_CLASS are works in progress. Externals with ON_WIP_EXTERN_DECL are works in progress. These items can be seen and used in Rhino core code. These items are not part of the public SDK. These items can and will change or be removed at any time without notice. Any C++ code using ON_WIP_* features is likely to fail catastrophically at the most inconvenient time imaginable.
#define ON_WIP_DECL ON_DECL |
#define ON_WIP_EXTERN_DECL ON_EXTERN_DECL |
#define ON_WIP_SDK |
Dale Lear 2024-March-14 Why are ON_WIP_SDK and ON_INTERNAL_SDK defined here? This seems exactly the opposite of what should happen. I think these should be wrapped in a #if defined(OPENNURBS_IN_RHINO) ... #endif block and that change needs extensive testing.
#if defined(OPENNURBS_IN_RHINO)
#define ON_xaxis ON_3dVector::XAxis |
OBSOLETE - use ON_3dVector::XAxis.
#define ON_XML_SLASH L"/" |
#define ON_yaxis ON_3dVector::YAxis |
OBSOLETE - use ON_3dVector::YAxis.
#define ON_zaxis ON_3dVector::ZAxis |
OBSOLETE - use ON_3dVector::ZAxis.
#define ON_ZERO_CURVATURE_TOLERANCE 1.0e-8 |
/ The default test for deciding if a curvature value should be / treated as zero is / length(curvature) <= ON_ZERO_CURVATURE_TOLERANCE. / ON_ZERO_CURVATURE_TOLERANCE must be set so that / ON_ZERO_CURVATURE_TOLERANCE >= sqrt(3)*ON_ZERO_TOLERANCE / so that K.IsTiny() = true implies |K| <= ON_ZERO_CURVATURE_TOLERANCE
#define ON_ZERO_TOLERANCE 2.3283064365386962890625e-10 |
/ In cases when an absolute "zero" tolerance / is required to compare model space coordinates, / ON_ZERO_TOLERANCE is used. The value of / ON_ZERO_TOLERANCE should be no smaller than / ON_EPSILON and should be several orders of / magnitude smaller than ON_SQRT_EPSILON / #define ON_ZERO_TOLERANCE 1.0e-12 ON_ZERO_TOLERANCE = 2^-32
#define OPENNURBS__FUNCTION__ "" |
For definition of PRIu64 to print 64-bit ints portably.
/ / END - OBSOLETE defines / ////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////// To debug linking pragma path issues, uncomment the following line pragma message( "OPENNURBS_OUTPUT_DIR = " OPENNURBS_PP2STR(OPENNURBS_OUTPUT_DIR) ) As of September, 2018 Freetype is not reliable on Windows, MacOS, and iOS. Its mapping from UNICODE code points to glyph indices is buggy. It does not support OpenType variable fonts like Windows 10 Bahnschrift. It does not support font simulation (Windows does a great job here.) Its support for multiple locale names is limited. Its support for PANOSE1 is limited. It does not support font substitution. Windows uses the Direct Write SDK for font and glyph calculations. MacOS and iOS use the Apple Core Text SDK for font and glyph calculations. not Windows, Apple, or Android To disable freetype support, comment out the following define. To enable freetype support, define OPENNURBS_FREETYPE_SUPPORT NOTE WELL: freetype is not delivered in a 32-bit version. Whenever possible use native OS tools for font and glyph support. Things like names, outlines, metrics, UNICODE mapping will generally work better align with user's experiences on that platform. Freetype is basically a platform neutral font file file reading toolkit and has all the limitations that arise from that approach to complex information modern OSs manage in complicated ways. #define OPENNURBS_FREETYPE_SUPPORT /////////////////////////////////////////////////////////////////////////////// / / Validate defines / / Validate ON_x_ENDIAN defines / Validate ON_xBIT_RUNTIME defines / Validate ON_SIZEOF_POINTER defines
#define OPENNURBS_CURRENT_ARCHIVE_VERSION 80 |
Jan 2017 November 2016 Rhino 7 WIP writes version 6 files. October 23 1019, Rhino 7 WIP writes version 7 files. May 17 2021, Rhino 8 WIP writes version 8 files.
More generally, in a stable release product, OPENNURBS_CURRENT_ARCHIVE_VERSION = OPENNURBS_VERSION_MAJOR*10. But for some period of time at the beginning of the Rhino (N+1) WIP development cycle, Rhino (N+1) WIP writes Rhino N files. That's why OPENNURBS_CURRENT_ARCHIVE_VERSION is sometimes (OPENNURBS_VERSION_MAJOR*10) and is sometimes ((OPENNURBS_VERSION_MAJOR-1)*10)
#define OPENNURBS_GIT_BRANCH_NAME RMA_GIT_BRANCH_NAME_STRING |
#define OPENNURBS_GIT_REVISION_HASH RMA_GIT_REVISION_HASH_STRING |
The build process modifies version.h and sets RMA_SRC_SVN_REVISION = "<git revision SHA-1 hash>" before compiling applications.
#define OPENNURBS_GL_INC_ |
< Open GL utilities (for GL NURBS stuff)
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org.
Definitions of ON_GL() functions that demonstrate how to use GL to display OpenNURBS objects.
Unsupported compiler: Support for other compilers is not available < Open GL basic definitions
#define OPENNURBS_INC_IN_PROGRESS |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org. Includes all openNURBS toolkit headers required to use the openNURBS toolkit library. See readme.txt for details.
#define OPENNURBS_MAX_VERSION_MAJOR 0x03F |
#define OPENNURBS_MAX_VERSION_MINOR 0x07F |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org. Values that identify the version are defined below.
The function ON_VersionNumberConstruct(major,minor,year,month,day_of_month,branch) creates a 4-byte unsigned integer that encodes the version information.
The function ON_GetVersionNumberStringConstruct() creates a "major.minor.yyddd.hhmmb" version string where ddd = day of year (1 to 366).
The function ON_GetVersionNumberQuarted() returns an array of 4 unsigned short values (major,minor,yyddd,hhmmb) where ddd = day of year (1 to 366). All McNeel Rhino build version information is in ../version.h The McNeel Rhino build process automatically creates ../version.h and it specifies all version information in all code used by Rhino.
When opennurbs is released as a public source code library, a file named opennurbs_public_version.h is created in the folder containing opennurbs.h. it is a verbatim copy of the ../version.h file that is current at that time.
#define OPENNURBS_PLUS_INC_ |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org.
#define OPENNURBS_PLUS_SILHOUETTE_INC_ |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org.
#define OPENNURBS_PLUS_SLEEPLOCK_INC_ |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org.
#define OPENNURBS_PP2STR | ( | s | ) | OPENNURBS_PP2STR_HELPER(s) |
#define OPENNURBS_PP2STR_HELPER | ( | s | ) | #s |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org. Includes all system headers required to use the openNURBS toolkit.
#define OPENNURBS_PUBLIC |
#define OPENNURBS_PUBLIC_INC_IN_PROGRESS |
Copyright (c) 1993-2024 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org. Includes all openNURBS toolkit headers required to use the openNURBS toolkit library. See readme.txt for details.
#define OPENNURBS_SLEEPLOCK_AVAILABLE |
#define OPENNURBS_SLEEPLOCK_INC_ |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org.
#define OPENNURBS_STRING_VALUE_INC_ |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org.
#define OPENNURBS_SUBD_DATA_INC_ |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org. WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING
The definitions in opennurbs_subd_data.h change randomly and unpredictably. Never include this file in any code you write, even as a hack. If you ignore this warning, your code will crash randomly and unpredictably
#define OPENNURBS_SUBD_PLUS_INC_ |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org.
#define OPENNURBS_VERSION_BRANCH RMA_VERSION_BRANCH |
branch => 0 Use ON::VersionBranch() to get this value. This number identifies the branch used in the build.
The build system automatically sets the value before compiling any code.
The file checked into the source code repository always has branch set to 0.
RMA_VERSION_BRANCH is defined in opennurbs_version.h 0: developer build 1: Windows Commercial build 2: Mac Commercial build 3: Windows BETA build 4: Mac Beta build 5: Windows WIP build 6: Mac WIP build define OPENNURBS_VERSION_BRANCH 0
#define OPENNURBS_VERSION_DAY_OF_MONTH RMA_VERSION_DATE |
#define OPENNURBS_VERSION_HOUR RMA_VERSION_HOUR |
#define OPENNURBS_VERSION_MAJOR RMA_VERSION_MAJOR |
Major version number >= 0 and <= 63 Minor version number >= 0 and <= 127
#define OPENNURBS_VERSION_MINOR RMA_VERSION_MINOR |
#define OPENNURBS_VERSION_MINUTE RMA_VERSION_MINUTE |
#define OPENNURBS_VERSION_MONTH RMA_VERSION_MONTH |
#define OPENNURBS_VERSION_NUMBER |
OPENNURBS_VERSION_NUMBER is a macro whose value is the opennurbs version number.
Always use ON::Version() when you need this value. The OPENNURBS_VERSION_NUMBER macro is for rare and unusual situations where the C preprocessor needs this value.
#define OPENNURBS_VERSION_QUARTET_STRING RMA_VERSION_WITH_PERIODS_STRING |
OPENNURBS_VERSION_QUARTET_STRING is a macro whose value is the opennurbs version quartet as a string.
#define OPENNURBS_VERSION_QUARTET_WITH_COMMAS VERSION_WITH_COMMAS |
#define OPENNURBS_VERSION_QUARTET_WITH_PERIODS VERSION_WITH_PERIODS |
#define OPENNURBS_VERSION_QUARTET_WSTRING RMA_VERSION_WITH_PERIODS_WSTRING |
#define OPENNURBS_VERSION_YEAR RMA_VERSION_YEAR |
The five OPENNURBS_VERSION_... time defines are set automatically by the build system as the first step in each build.
#define RTFFIRSTCHAR |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org.
#define Swap | ( | a, | |
b | |||
) | m_swapfunc(a,b,m_width) |
#define TCODE_ANALYSIS_MESH (TCODE_GEOMETRY | 0x0018) |
#define TCODE_ANGULAR_DIMENSION (TCODE_ANNOTATION | 0x0007) |
#define TCODE_ANNOTATION 0x00200000 |
#define TCODE_ANNOTATION_LEADER (TCODE_ANNOTATION | 0x0005) |
#define TCODE_ANNOTATION_SETTINGS (TCODE_ANNOTATION | 0x0001) |
/////////////////////////////////////////////////////////////////////////////////// / / TCODE_OPENNURBS_CLASS / length of entire openNURBS class object chunk / / TCODE_OPENNURBS_CLASS_UUID / length of uuid (16 byte UUID + 4 byte CRC) / 16 byte UUID ( a.k.a. GUID ) openNURBS class ID - determines specific openNURBS class / 4 bytes (32 bit CRC of the UUID) / / TCODE_OPENNURBS_CLASS_DATA / length of object data / ... data that defines object / use ON_classname::Read() to read this data and ON_classname::Write() / to write this data / 4 bytes (32 bit CRC of the object data) / / TCODE_OPENNURBS_CLASS_USERDATA ( 0 or more user data chunks) / / TCODE_OPENNURBS_CLASS_END / 4 bytes = 0 / /////////////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////////// / / / The TCODEs below were used in the version 1 file format and are needed so that / the these files can be read and (optionally) written by the current OpenNURBS / toolkit. / / ///////////////////////////////////////////////////////////////////////////////////
#define TCODE_ANONYMOUS_CHUNK (TCODE_USER | TCODE_CRC | 0x0000 ) |
#define TCODE_BITMAP_RECORD (TCODE_TABLEREC | TCODE_CRC | 0x0090) /* bitmap table record derived from ON_Bitmap */ |
records in bitmap table
#define TCODE_BITMAP_TABLE (TCODE_TABLE | 0x0016) /* embedded bitmaps */ |
#define TCODE_BITMAPPREVIEW (TCODE_INTERFACE | 0x0014) |
#define TCODE_BUMPMAP (TCODE_DISPLAY | 0x0003) |
#define TCODE_COMMENTBLOCK 0x00000001 |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org. 3dm defines, structs and typedefs Typecode format 4 bytes long
x xxxxxxxxxxxxxxx,x xxx xxxx xxxx x x xx | | | | | | | | | | | | | | | +— "stuff" bit | | | | | | | +– specific codes | | | | | +– RESERVED - DO NOT USE (should be 0) (will be used to control CRC on/off) | | | +– category:_000 0000 0000 0001 Legacy geometry TCODE_LEGACY_GEOMETRY | _000 0000 0000 0010 openNURBS object TCODE_OPENNURBS_OBJECT | _000 0000 0000 0100 – RESERVED - DO NOT USE (should be 0 in any typecode) – | _000 0000 0000 1000 – RESERVED - DO NOT USE (should be 0 in any typecode) –
| _000 0000 0001 0000 Geometry TCODE_GEOMETRY | _000 0000 0010 0000 Annotation | _000 0000 0100 0000 Display Attributes TCODE_DISPLAY | _000 0000 1000 0000 Rendering TCODE_RENDER
| _000 0001 0000 0000
| _000 0010 0000 0000 Interface TCODE_INTERFACE | _000 0100 0000 0000 – RESERVED - DO NOT USE (should be 0 in any typecode) – | _000 1000 0000 0000 Tolerances TCODE_TOLERANCE | _001 0000 0000 0000 Tables TCODE_TABLE
| _010 0000 0000 0000 Table record TCODE_TABLEREC | _100 0000 0000 0000 User information TCODE_USER | +– format: 0 - data size in header - data block follows TCODE_SHORT 1 - data in header - no data block follows / The TCODE_COMMENTBLOCK is the first chunk in the file, starts 32 bytes into / the file, and contains text information terminated with a ^Z. This ^Z and / contents of this chunk were expanded in February 2000. Files written with / code released earlier than this will not have the ^Z. / / The TCODE_ENDOFFILE is the last chunk in the file and the first 4 bytes / of information in this chunk is an integer that contains the file length. / This chunk was added in February 2000 and files written with code released / earlier than this will not have this termination block.
#define TCODE_COMPRESSED_MESH_GEOMETRY (TCODE_GEOMETRY | 0x0017) |
#define TCODE_CPLANE (TCODE_INTERFACE | 0x0003) |
#define TCODE_CRC 0x8000 |
#define TCODE_CURRENTLAYER (TCODE_SHORT | TCODE_DISPLAY | 0x0025 ) |
#define TCODE_DICTIONARY (TCODE_USER | TCODE_CRC | 0x0010) |
#define TCODE_DICTIONARY_END (TCODE_USER | TCODE_SHORT | 0x0013) |
#define TCODE_DICTIONARY_ENTRY (TCODE_USER | TCODE_CRC | 0x0012) |
#define TCODE_DICTIONARY_ID (TCODE_USER | TCODE_CRC | 0x0011) |
#define TCODE_DIMSTYLE_RECORD (TCODE_TABLEREC | TCODE_CRC | 0x0075) |
records in dimension style table
#define TCODE_DIMSTYLE_TABLE (TCODE_TABLE | 0x0020) /* annotation dimension style table */ |
#define TCODE_DISP_AM_RESOLUTION (TCODE_SHORT | TCODE_DISPLAY | 0x0005) |
#define TCODE_DISP_CPLINES (TCODE_SHORT | TCODE_DISPLAY | 0x0022) |
#define TCODE_DISP_MAXLENGTH (TCODE_DISPLAY | 0x0023) |
#define TCODE_DISPLAY 0x00400000 |
#define TCODE_ENDOFFILE 0x00007FFF |
#define TCODE_ENDOFFILE_GOO |
#define TCODE_ENDOFTABLE 0xFFFFFFFF |
#define TCODE_FONT_RECORD (TCODE_TABLEREC | TCODE_CRC | 0x0074) |
records in font table
#define TCODE_FONT_TABLE (TCODE_TABLE | 0x0019) /* annotation font table */ |
#define TCODE_GEOMETRY 0x00100000 |
#define TCODE_GROUP_RECORD (TCODE_TABLEREC | TCODE_CRC | 0x0073) |
records in group table
#define TCODE_GROUP_TABLE (TCODE_TABLE | 0x0018) /* group table */ |
#define TCODE_HATCHPATTERN_RECORD (TCODE_TABLEREC | TCODE_CRC | 0x0077) |
records in hatch pattern table
#define TCODE_HATCHPATTERN_TABLE (TCODE_TABLE | 0x0022) /* hatch pattern table */ |
#define TCODE_HIDE_TRACE (TCODE_INTERFACE | 0x000E) |
#define TCODE_HISTORYRECORD_RECORD (TCODE_TABLEREC | TCODE_CRC | 0x007B) |
records in history record pattern table
#define TCODE_HISTORYRECORD_TABLE (TCODE_TABLE | 0x0026) /* history records */ |
#define TCODE_INSTANCE_DEFINITION_RECORD (TCODE_TABLEREC | TCODE_CRC | 0x0076) |
records in instance definition table
#define TCODE_INSTANCE_DEFINITION_TABLE (TCODE_TABLE | 0x0021) /* instance definition table */ |
#define TCODE_INTERFACE 0x02000000 |
#define TCODE_LAYER (TCODE_DISPLAY | 0x0010) |
#define TCODE_LAYER_OBSELETE_1 (TCODE_SHORT | TCODE_DISPLAY | 0x0013) |
obsolete layer typecodes from earlier betas - not used anymore
#define TCODE_LAYER_OBSELETE_2 (TCODE_SHORT | TCODE_DISPLAY | 0x0014) |
#define TCODE_LAYER_OBSELETE_3 (TCODE_SHORT | TCODE_DISPLAY | 0x0015) |
#define TCODE_LAYER_RECORD (TCODE_TABLEREC | TCODE_CRC | 0x0050) /* layer table record derived from ON_Layer */ |
records in layer table
#define TCODE_LAYER_TABLE (TCODE_TABLE | 0x0011) /* layers */ |
#define TCODE_LAYERINDEX (TCODE_SHORT | TCODE_DISPLAY | 0x0034) |
#define TCODE_LAYERLOCKED (TCODE_SHORT | TCODE_DISPLAY | 0x0018) |
#define TCODE_LAYERMATERIALINDEX (TCODE_SHORT | TCODE_DISPLAY | 0x0035) |
#define TCODE_LAYERNAME (TCODE_DISPLAY | 0x0011) |
#define TCODE_LAYERON (TCODE_SHORT | TCODE_DISPLAY | 0x0016) |
these were only ever used by AccuModel and never by Rhino
#define TCODE_LAYERPICKABLE (TCODE_SHORT | TCODE_DISPLAY | 0x0030) |
#define TCODE_LAYERREF (TCODE_SHORT | TCODE_TABLEREC | 0x0001) |
#define TCODE_LAYERRENDERABLE (TCODE_SHORT | TCODE_DISPLAY | 0x0032) |
#define TCODE_LAYERSNAPABLE (TCODE_SHORT | TCODE_DISPLAY | 0x0031) |
#define TCODE_LAYERSTATE (TCODE_SHORT | TCODE_DISPLAY | 0x0033) |
use LAYERSTATE ( 0 = LAYER_ON, 1 = LAYER_OFF, 2 = LAYER_LOCKED ) instead of above individual toggles
#define TCODE_LAYERTABLE (TCODE_SHORT | TCODE_TABLE | 0x0001) /* obsolete - do not use */ |
#define TCODE_LAYERTHAWED (TCODE_SHORT | TCODE_DISPLAY | 0x0017) |
#define TCODE_LAYERVISIBLE (TCODE_SHORT | TCODE_DISPLAY | 0x0012) |
#define TCODE_LEGACY_ASM (TCODE_LEGACY_GEOMETRY | 0x0001) |
legacy objects from Rhino 1.x
#define TCODE_LEGACY_ASMSTUFF (TCODE_LEGACY_GEOMETRY | TCODE_STUFF | TCODE_LEGACY_ASM) |
#define TCODE_LEGACY_BND (TCODE_LEGACY_GEOMETRY | 0x0005) |
#define TCODE_LEGACY_BNDSTUFF (TCODE_LEGACY_GEOMETRY | TCODE_STUFF | TCODE_LEGACY_BND) |
#define TCODE_LEGACY_CRV (TCODE_LEGACY_GEOMETRY | 0x0008) |
#define TCODE_LEGACY_CRVSTUFF (TCODE_LEGACY_GEOMETRY | TCODE_STUFF | TCODE_LEGACY_CRV) |
#define TCODE_LEGACY_FAC (TCODE_LEGACY_GEOMETRY | 0x0004) |
#define TCODE_LEGACY_FACSTUFF (TCODE_LEGACY_GEOMETRY | TCODE_STUFF | TCODE_LEGACY_FAC) |
#define TCODE_LEGACY_GEOMETRY 0x00010000 |
#define TCODE_LEGACY_PNT (TCODE_LEGACY_GEOMETRY | 0x000A) |
#define TCODE_LEGACY_PNTSTUFF (TCODE_LEGACY_GEOMETRY | TCODE_STUFF | TCODE_LEGACY_PNT) |
#define TCODE_LEGACY_PRT (TCODE_LEGACY_GEOMETRY | 0x0002) |
#define TCODE_LEGACY_PRTSTUFF (TCODE_LEGACY_GEOMETRY | TCODE_STUFF | TCODE_LEGACY_PRT) |
#define TCODE_LEGACY_SHL (TCODE_LEGACY_GEOMETRY | 0x0003) |
#define TCODE_LEGACY_SHLSTUFF (TCODE_LEGACY_GEOMETRY | TCODE_STUFF | TCODE_LEGACY_SHL) |
#define TCODE_LEGACY_SPL (TCODE_LEGACY_GEOMETRY | 0x0009) |
#define TCODE_LEGACY_SPLSTUFF (TCODE_LEGACY_GEOMETRY | TCODE_STUFF | TCODE_LEGACY_SPL) |
#define TCODE_LEGACY_SRF (TCODE_LEGACY_GEOMETRY | 0x0007) |
#define TCODE_LEGACY_SRFSTUFF (TCODE_LEGACY_GEOMETRY | TCODE_STUFF | TCODE_LEGACY_SRF) |
#define TCODE_LEGACY_TOL_ANGLE (TCODE_TOLERANCE | 0x0002) |
#define TCODE_LEGACY_TOL_FIT (TCODE_TOLERANCE | 0x0001) |
#define TCODE_LEGACY_TRM (TCODE_LEGACY_GEOMETRY | 0x0006) |
#define TCODE_LEGACY_TRMSTUFF (TCODE_LEGACY_GEOMETRY | TCODE_STUFF | TCODE_LEGACY_TRM) |
#define TCODE_LIGHT_RECORD (TCODE_TABLEREC | TCODE_CRC | 0x0060) /* light table record derived from ON_Light */ |
records in light table
#define TCODE_LIGHT_RECORD_ATTRIBUTES (TCODE_INTERFACE | TCODE_CRC | 0x0061) /* ON_3dmObjectAttributes chunk */ |
#define TCODE_LIGHT_RECORD_ATTRIBUTES_USERDATA (TCODE_INTERFACE | 0x0062) /* ON_3dmObjectAttributes userdata chunk */ |
#define TCODE_LIGHT_RECORD_END (TCODE_INTERFACE | TCODE_SHORT | 0x006F) |
#define TCODE_LIGHT_TABLE (TCODE_TABLE | 0x0012) /* rendering lights */ |
#define TCODE_LINEAR_DIMENSION (TCODE_ANNOTATION | 0x0006) |
#define TCODE_LINETYPE_RECORD (TCODE_TABLEREC | TCODE_CRC | 0x0078) |
records in linetye pattern table
#define TCODE_LINETYPE_TABLE (TCODE_TABLE | 0x0023) /* linetype table */ |
#define TCODE_MATERIAL_RECORD (TCODE_TABLEREC | TCODE_CRC | 0x0040) /* material table record derived from ON_Material */ |
records in material table
#define TCODE_MATERIAL_TABLE (TCODE_TABLE | 0x0010) /* rendering materials */ |
The openNURBS toolkit allows users to write all openNURBS classed that are / derived from ON_Object using using TCODE_OPENNURBS_CLASS chunks. / In the .3dm file these TCODE_OPENNURBS_CLASS chunks are always have the / following format. tables added 17 February 2000
#define TCODE_MAXIMIZED_VIEWPORT (TCODE_SHORT | TCODE_INTERFACE | 0x0011) |
#define TCODE_MESH_OBJECT (TCODE_GEOMETRY | 0x0015) |
#define TCODE_MODEL_ATTRIBUTES_CHUNK (TCODE_USER | TCODE_CRC | 0x0002 ) |
#define TCODE_NAME (TCODE_INTERFACE | 0x0001) |
#define TCODE_NAMED_CPLANE (TCODE_INTERFACE | 0x0004) |
#define TCODE_NAMED_VIEW (TCODE_INTERFACE | 0x0005) |
#define TCODE_NEAR_CLIP_PLANE (TCODE_INTERFACE | 0x000D) |
#define TCODE_NOTES (TCODE_INTERFACE | 0x000F) |
#define TCODE_OBJECT_RECORD (TCODE_TABLEREC | TCODE_CRC | 0x0070) |
records in object table
#define TCODE_OBJECT_RECORD_ATTRIBUTES (TCODE_INTERFACE | TCODE_CRC | 0x0072) /* ON_3dmObjectAttributes chunk */ |
#define TCODE_OBJECT_RECORD_ATTRIBUTES_USERDATA (TCODE_INTERFACE | 0x0073) /* ON_3dmObjectAttributes userdata chunk */ |
#define TCODE_OBJECT_RECORD_END (TCODE_INTERFACE | TCODE_SHORT | 0x007F) |
#define TCODE_OBJECT_RECORD_HISTORY (TCODE_INTERFACE | TCODE_CRC | 0x0074) /* construction history */ |
#define TCODE_OBJECT_RECORD_HISTORY_DATA (TCODE_INTERFACE | TCODE_CRC | 0x0076) /* construction history data */ |
#define TCODE_OBJECT_RECORD_HISTORY_HEADER (TCODE_INTERFACE | TCODE_CRC | 0x0075) /* construction history header*/ |
#define TCODE_OBJECT_RECORD_TYPE (TCODE_INTERFACE | TCODE_SHORT | 0x0071) /* ON::object_type value */ |
#define TCODE_OBJECT_TABLE (TCODE_TABLE | 0x0013) /* geometry and annotation */ |
#define TCODE_OBSOLETE_LAYERSET_RECORD (TCODE_TABLEREC | TCODE_CRC | 0x0079) |
OBSOLETE records in layer set table
#define TCODE_OBSOLETE_LAYERSET_TABLE (TCODE_TABLE | 0x0024) /* obsolete layer set table */ |
#define TCODE_OLD_FULLMESH (TCODE_GEOMETRY | 0x0014) |
#define TCODE_OLD_MESH_UV (TCODE_GEOMETRY | 0x0013) |
#define TCODE_OLD_MESH_VERTEX_NORMALS (TCODE_GEOMETRY | 0x0012) |
#define TCODE_OLD_RH_TRIMESH (TCODE_GEOMETRY | 0x0011) |
#define TCODE_OPENNURBS_BUFFER (TCODE_OPENNURBS_OBJECT | TCODE_CRC | 0x0100) /* chunk stores ON_Buffer classes */ |
OpenNURBS classes the require a unique tcode
#define TCODE_OPENNURBS_CLASS (TCODE_OPENNURBS_OBJECT | 0x7FFA) |
/////////////////////////////////////////////////////////////////////////////////// / / TCODE_OBJECT_RECORD / 4 byte length of entire object record / / TCODE_OBJECT_RECORD_TYPE required - used to quickly filter and skip unwanted objects / 4 byte ON::object_type / / TCODE_OPENNURBS_CLASS / 4 byte length / TCODE_OPENNURBS_CLASS_UUID / 4 byte length = 20 / value of ON_ClassId::m_uuid for this class / 4 byte CRC / TCODE_OPENNURBS_CLASS_DATA / 4 byte length / class specific data for geometry or annotation object / 4 byte CRC / TCODE_OPENNURBS_CLASS_USERDATA (1 chunk per piece of user data) / 4 byte length / 2 byte chunk version 2.1 / TCODE_OPENNURBS_CLASS_USERDATA_HEADER / 4 byte length / 16 byte value of ON_ClassId::m_uuid for this child class of ON_UserData / 16 byte value of ON_UserData::m_userdata_uuid / 4 byte value of ON_UserData::m_userdata_copycount / 128 byte value of ON_UserData::m_userdata_xform / 16 byte value of ON_UserData::m_application_uuid (in ver 2.1 chunks) / TCODE_ANONYMOUS_CHUNK / 4 byte length / specific user data / TCODE_OPENNURBS_CLASS_END / / TCODE_OBJECT_RECORD_ATTRIBUTES (optional) / 4 byte length / ON_3dmObjectAttributes information / 4 byte crc / / TCODE_OBJECT_RECORD_ATTRIBUTES_USERDATA (optional) / 4 byte length / TCODE_OPENNURBS_CLASS_USERDATA (1 chunk per piece of user data) / 4 byte length / 2 byte chunk version 2.1 / TCODE_OPENNURBS_CLASS_USERDATA_HEADER / 4 byte length / 16 byte value of ON_ClassId::m_uuid for this child class of ON_UserData / 16 byte value of ON_UserData::m_userdata_uuid / 4 byte value of ON_UserData::m_userdata_copycount / 128 byte value of ON_UserData::m_userdata_xform / 16 byte value of ON_UserData::m_application_uuid (in ver 2.1 chunks) / TCODE_ANONYMOUS_CHUNK / 4 byte length / specific user data / / TCODE_OBJECT_RECORD_HISTORY (optional) construction history / 4 byte length / 2 byte chunk version / TCODE_OBJECT_RECORD_HISTORY_HEADER / 4 byte length / 2 byte chunk version / ... / 4 byte crc / TCODE_OBJECT_RECORD_HISTORY_DATA / 4 byte length / 2 byte chunk version / ... / 4 byte crc / / TCODE_OBJECT_RECORD_END required - marks end of object record / ///////////////////////////////////////////////////////////////////////////////////
#define TCODE_OPENNURBS_CLASS_DATA (TCODE_OPENNURBS_OBJECT | TCODE_CRC | 0x7FFC) |
#define TCODE_OPENNURBS_CLASS_END (TCODE_OPENNURBS_OBJECT | TCODE_SHORT | 0x7FFF) |
#define TCODE_OPENNURBS_CLASS_USERDATA (TCODE_OPENNURBS_OBJECT | 0x7FFD) |
#define TCODE_OPENNURBS_CLASS_USERDATA_HEADER (TCODE_OPENNURBS_OBJECT | TCODE_CRC | 0x7FF9) |
#define TCODE_OPENNURBS_CLASS_UUID (TCODE_OPENNURBS_OBJECT | TCODE_CRC | 0x7FFB) |
#define TCODE_OPENNURBS_OBJECT 0x00020000 |
#define TCODE_PROPERTIES_APPLICATION (TCODE_TABLEREC | TCODE_CRC | 0x0024) |
#define TCODE_PROPERTIES_AS_FILE_NAME (TCODE_TABLEREC | TCODE_CRC | 0x0027 ) |
#define TCODE_PROPERTIES_COMPRESSED_PREVIEWIMAGE (TCODE_TABLEREC | TCODE_CRC | 0x0025) |
#define TCODE_PROPERTIES_NOTES (TCODE_TABLEREC | TCODE_CRC | 0x0022) |
#define TCODE_PROPERTIES_OPENNURBS_VERSION (TCODE_TABLEREC | TCODE_SHORT | 0x0026) |
#define TCODE_PROPERTIES_PREVIEWIMAGE (TCODE_TABLEREC | TCODE_CRC | 0x0023) |
#define TCODE_PROPERTIES_REVISIONHISTORY (TCODE_TABLEREC | TCODE_CRC | 0x0021) |
records in properties table
#define TCODE_PROPERTIES_TABLE |
#define TCODE_RADIAL_DIMENSION (TCODE_ANNOTATION | 0x0008) |
#define TCODE_RENDER 0x00800000 |
#define TCODE_RENDER_MATERIAL_ID (TCODE_DISPLAY | 0x0007) /* id for render material */ |
#define TCODE_RENDERMESHPARAMS (TCODE_DISPLAY | 0x0020) /* block of parameters for render meshes */ |
#define TCODE_RGB (TCODE_SHORT | TCODE_DISPLAY | 0x0001) |
#define TCODE_RGBDISPLAY (TCODE_SHORT | TCODE_DISPLAY | 0x0006) /* will be used for color by object */ |
#define TCODE_RH_POINT (TCODE_GEOMETRY | 0x0001) |
legacy objects from Rhino 1.x
#define TCODE_RH_SPOTLIGHT (TCODE_RENDER | 0x0001) |
#define TCODE_RHINOIO_OBJECT_BREP (TCODE_OPENNURBS_OBJECT | 0x000B) /* old CRhinoBrep */ |
#define TCODE_RHINOIO_OBJECT_DATA (TCODE_OPENNURBS_OBJECT | 0xFFFE) /* obsolete - don't confuse with TCODE_OPENNURBS_OBJECT_DATA */ |
#define TCODE_RHINOIO_OBJECT_END (TCODE_OPENNURBS_OBJECT | 0xFFFF) /* obsolete - don't confuse with TCODE_OPENNURBS_OBJECT_END */ |
#define TCODE_RHINOIO_OBJECT_NURBS_CURVE (TCODE_OPENNURBS_OBJECT | 0x0008) /* old CRhinoNurbsCurve */ |
old RhinoIO toolkit (pre February 2000) defines
#define TCODE_RHINOIO_OBJECT_NURBS_SURFACE (TCODE_OPENNURBS_OBJECT | 0x0009) /* old CRhinoNurbsSurface */ |
#define TCODE_SETTINGS__NEVER__USE__THIS (TCODE_TABLEREC | TCODE_CRC | 0x003E) |
#define TCODE_SETTINGS_ANALYSISMESH (TCODE_TABLEREC | TCODE_CRC | 0x0033) |
#define TCODE_SETTINGS_ANNOTATION (TCODE_TABLEREC | TCODE_CRC | 0x0034) |
#define TCODE_SETTINGS_ATTRIBUTES (TCODE_TABLEREC | TCODE_CRC | 0x0134) |
added 29 October 2002 as a chunk to hold new and future ON_3dmSettings information
#define TCODE_SETTINGS_CURRENT_COLOR (TCODE_TABLEREC | TCODE_CRC | 0x003A) |
#define TCODE_SETTINGS_CURRENT_DIMSTYLE_INDEX (TCODE_TABLEREC | TCODE_SHORT | 0x0133) |
#define TCODE_SETTINGS_CURRENT_FONT_INDEX (TCODE_TABLEREC | TCODE_SHORT | 0x0132) |
#define TCODE_SETTINGS_CURRENT_LAYER_INDEX (TCODE_TABLEREC | TCODE_SHORT | 0x0038) |
#define TCODE_SETTINGS_CURRENT_MATERIAL_INDEX (TCODE_TABLEREC | TCODE_CRC | 0x0039) |
#define TCODE_SETTINGS_CURRENT_WIRE_DENSITY (TCODE_TABLEREC | TCODE_SHORT | 0x003C) |
#define TCODE_SETTINGS_GRID_DEFAULTS (TCODE_TABLEREC | TCODE_CRC | 0x003F) |
#define TCODE_SETTINGS_MODEL_URL (TCODE_TABLEREC | TCODE_CRC | 0x0131) |
#define TCODE_SETTINGS_NAMED_CPLANE_LIST (TCODE_TABLEREC | TCODE_CRC | 0x0035) |
#define TCODE_SETTINGS_NAMED_VIEW_LIST (TCODE_TABLEREC | TCODE_CRC | 0x0036) |
#define TCODE_SETTINGS_PLUGINLIST (TCODE_TABLEREC | TCODE_CRC | 0x0135) |
records in settings table
#define TCODE_SETTINGS_RENDER (TCODE_TABLEREC | TCODE_CRC | 0x003D) |
#define TCODE_SETTINGS_RENDER_USERDATA (TCODE_TABLEREC | TCODE_CRC | 0x0136) |
2016-Nov-28 RH-33298 ON_3dmRenderSettings user data in ON_3dmSettings.m_RenderSettings
#define TCODE_SETTINGS_RENDERMESH (TCODE_TABLEREC | TCODE_CRC | 0x0032) |
#define TCODE_SETTINGS_TABLE |
#define TCODE_SETTINGS_UNITSANDTOLS (TCODE_TABLEREC | TCODE_CRC | 0x0031) |
#define TCODE_SETTINGS_VIEW_LIST (TCODE_TABLEREC | TCODE_CRC | 0x0037) |
#define TCODE_SHORT 0x80000000 |
#define TCODE_SHOWGRID (TCODE_SHORT | TCODE_INTERFACE | 0x0007) |
#define TCODE_SHOWGRIDAXES (TCODE_SHORT | TCODE_INTERFACE | 0x0008) |
#define TCODE_SHOWWORLDAXES (TCODE_SHORT | TCODE_INTERFACE | 0x0009) |
#define TCODE_SNAPSIZE (TCODE_INTERFACE | 0x000C) |
#define TCODE_STUFF 0x0100 |
#define TCODE_SUMMARY (TCODE_INTERFACE | 0x0013) |
#define TCODE_TABLE 0x10000000 |
#define TCODE_TABLEREC 0x20000000 |
#define TCODE_TEXT_BLOCK (TCODE_ANNOTATION | 0x0004) |
#define TCODE_TEXTURE_MAPPING_RECORD (TCODE_TABLEREC | TCODE_CRC | 0x007A) |
records in linetye pattern table
#define TCODE_TEXTURE_MAPPING_TABLE (TCODE_TABLE | 0x0025) /* texture mappings */ |
#define TCODE_TEXTUREMAP (TCODE_DISPLAY | 0x0002) |
#define TCODE_TOLERANCE 0x08000000 |
#define TCODE_TRANSPARENCY (TCODE_SHORT | TCODE_DISPLAY | 0x0004) |
#define TCODE_UNIT_AND_TOLERANCES (TCODE_INTERFACE | 0x0010) |
#define TCODE_USER 0x40000000 |
#define TCODE_USER_RECORD (TCODE_TABLEREC | 0x0081) |
information saved by the plug-in is in a TCODE_USER_RECORD chunk
#define TCODE_USER_TABLE (TCODE_TABLE | 0x0017) /* user table */ |
#define TCODE_USER_TABLE_RECORD_HEADER (TCODE_TABLEREC | TCODE_CRC | 0x0082) |
the user record header was added in 200910190 and is inside the TCODE_USER_TABLE_UUID chunk
#define TCODE_USER_TABLE_UUID (TCODE_TABLEREC | TCODE_CRC | 0x0080) |
records in user table Each user table entry has two top level chunks, a TCODE_USER_TABLE_UUID chunk and a TCODE_USER_RECORD chunk. The TCODE_USER_TABLE_UUID chunk contains the plug-in id and, if the archive is V5 or later and was written by an opennurbs with version >= 200910190, a TCODE_USER_TABLE_RECORD_HEADER chunk.
#define TCODE_UTF8_STRING_CHUNK (TCODE_USER | TCODE_CRC | 0x0001 ) |
#define TCODE_VIEW (TCODE_INTERFACE | 0x0002) |
#define TCODE_VIEW_ATTRIBUTES (TCODE_TABLEREC | TCODE_CRC | 0x0C3B) |
added 29 October 2002 as a chunk to hold new and future ON_3dmView information
#define TCODE_VIEW_CPLANE (TCODE_TABLEREC | TCODE_CRC | 0x013B) |
subrecords if view record
#define TCODE_VIEW_NAME (TCODE_TABLEREC | TCODE_CRC | 0x0A3B) |
#define TCODE_VIEW_POSITION (TCODE_TABLEREC | TCODE_CRC | 0x0B3B) |
#define TCODE_VIEW_RECORD (TCODE_TABLEREC | TCODE_CRC | 0x003B) |
views are subrecords in the settings table
#define TCODE_VIEW_SHOWCONAXES (TCODE_TABLEREC | TCODE_SHORT | 0x043B) |
#define TCODE_VIEW_SHOWCONGRID (TCODE_TABLEREC | TCODE_SHORT | 0x033B) |
#define TCODE_VIEW_SHOWWORLDAXES (TCODE_TABLEREC | TCODE_SHORT | 0x053B) |
#define TCODE_VIEW_TARGET (TCODE_TABLEREC | TCODE_CRC | 0x083B) |
#define TCODE_VIEW_TRACEIMAGE (TCODE_TABLEREC | TCODE_CRC | 0x063B) |
#define TCODE_VIEW_V3_DISPLAYMODE (TCODE_TABLEREC | TCODE_SHORT | 0x093B) |
#define TCODE_VIEW_VIEWPORT (TCODE_TABLEREC | TCODE_CRC | 0x023B) |
#define TCODE_VIEW_VIEWPORT_USERDATA (TCODE_TABLEREC | TCODE_CRC | 0x0D3B) |
added 27 June 2008 as a chunk to hold userdata on ON_Viewports saved in named view list
#define TCODE_VIEW_WALLPAPER (TCODE_TABLEREC | TCODE_CRC | 0x073B) |
#define TCODE_VIEW_WALLPAPER_V3 (TCODE_TABLEREC | TCODE_CRC | 0x074B) |
#define TCODE_VIEWPORT (TCODE_INTERFACE | 0x0006) |
#define TCODE_VIEWPORT_POSITION (TCODE_INTERFACE | 0x000A) |
#define TCODE_VIEWPORT_TRACEINFO (TCODE_INTERFACE | 0x000B) |
#define TCODE_VIEWPORT_V1_DISPLAYMODE (TCODE_SHORT | TCODE_INTERFACE | 0x0015) |
#define TCODE_VIEWPORT_WALLPAPER (TCODE_INTERFACE | 0x0012) |
#define TCODE_XDATA (TCODE_USER | 0x0001) |
#define Z_PREFIX |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org. If you are using opennurbs as a statically linked library, then you may make calls to the same zlib that opennurbs uses. This zlib is compiled with z_ symbol projectection. All the necessary header files are included by opennurbs.h.
If you are using opennurbs as a DLL or writing a Rhino plug-in and you want to use the same zlib that opennurbs uses, then compile opennurbs_zlib_memory.cpp into your application and statically link with the zlib library. All the necessary header files are included by opennurbs.h. decorates zlib functions with a "z_" prefix to prevent symbol collision.
typedef int(* CRASHTEST__FUNCTION__POINTER__) (int) |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org. / This code defines a global function call MyGlobalCrashTestFunction / that you can call from a release build to test your program's / behavior when it crashes. #define ON_CRASH_TEST_STATICS #include "opennurbs_plus_crashtest.h" #undef ON_CRASH_TEST_STATICS int MyGlobalCrashTestFunction( int crash_type, ON_TextLog& textlog ) { /crash_type / 0 = NullPtrDeRef / 1 = BogusPtrDeRef / 2 = CallNullFuncPtr / 3 = CallBogusFuncPtr / 4 = Call CRT _abort / 5 = Call CRT _exit99 / 6 = DivideByDoubleZero / 7 = DivideByFloatZero / 8 = DivideByIntZero / 9 = log(negative number) / 10 = double overflow exception / 11 = calling throw(123) return CrashTestHelper(crash_type,textlog); ///< static function defined in opennurbs_plus_crashtest.h } For testing crash handling.
typedef ON_TextureMapping( * GET_TEXMAP_FROM_DOCUMENT) (const class CRhinoDoc &, const ON_MappingChannel *) |
typedef int16_t ON__INT16 |
typedef int32_t ON__INT32 |
typedef int64_t ON__INT64 |
typedef int8_t ON__INT8 |
/ To print the value of a preprocessor macro, do something like: / / #pragma message( "MY_MACRO = " OPENNURBS_PP2STR(MY_MACRO) ) / / Typically something mysterious is defining a macro whose value / you would like to see at compile time so you can fix a issue / involving the preprocessor macro's value. / Define ON_NO_WINDOWS if you are compiling on a Windows system but want / to explicitly exclude inclusion of windows.h. compiler choice
typedef uint16_t ON__UINT16 |
typedef uint32_t ON__UINT32 |
typedef uint64_t ON__UINT64 |
typedef uint8_t ON__UINT8 |
typedef ON__UINT_PTR ON_CRT_locale_t |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org.
A list of region boundaries that bound a single connected region of the plane. The first boundary is always the outer boundary.
A list of curve subdomains that form a closed boundary with active space on the left.
typedef struct tagFontKey ON_FontKey |
typedef int(* ON_memory_error_handler) (int) |
/////////////////////////////////////////////////////////////////////////// / / ALL memory management in the openNURBS toolkit is done through calls to / onmalloc(), oncalloc(), onrealloc(), onfree(), / onmemdup(), onstrdup(), ..., and the / new and delete operators / The on*() functions are all declared in opennurbs_memory.h and defined / in opennurbs_memory.c. The new and delete operators that use onmalloc() / and onfree() are defined in opennurbs_plus_memory_new.cpp. / / You may OPTIONALLY provide your own memory management functions. See / opennurbs_memory.c for details. / /////////////////////////////////////////////////////////////////////////// / / Details: / / void* onmalloc( site_t sz ); / / If sz is zero, nullptr is returned. / If sz is positive and there is not enough memory to satisfy / the allocation request, the ON_memory_error_handler(0) is called / and nullptr is returned.
/ / If you have implemented multiple memory pools in a custom manager, / the request is sent to the current pool. /
/ / void* oncalloc( size_t num, size_t sz ); / / If sz or num is zero, nullptr is returned. / If sz and num are positive and there is not enough memory to satisfy / the allocation request, the ON_memory_error_handler(0) is called / and nullptr is returned. / / If you have implemented multiple memory pools in a custom manager, / the request is sent to the current pool. /
/
/ void* onrealloc( void* p, size_t sz ); / / If p is nullptr, then onmalloc(sz) is called. / If sz is zero, then onfree(p) is called and / nullptr is returned. / If p is not nullptr, sz is positive, and there is not / enough memory to to satisfy the allocation request, / the ON_memory_error_handler(0) is called and nullptr is returned. / If p is not nullptr and is known to be invalid, then / ON_memory_error_handler(1) is called. / / If you have implemented multiple memory pools in a custom manager, / the request is sent to the current pool. / / NOTE WELL: Microsoft's VC 6.0 realloc() contains a bug that can cause / crashes and should be avoided. See MSDN Knowledge Base / article ID Q225099 for more information. / / / void onfree( void* p ); / / nullptr p is tolerated but considered poor style. / If p is not nullptr and is known to be invalid, then / ON_memory_error_handler(2) is called. / / void* onmemdup( const void* src, size_t sz ); / / If src is not nullptr and sz is positive, then onmalloc( sz ) / is called to get memory, sz bytes of src are copied into this / memory, and the pointer to this memory is returned. / If onmalloc() returns nullptr, then nullptr is returned. / If src is nullptr or sz is zero, then nullptr is returned. /
/ / char* onstrdup( const char* src ); / / If src is not nullptr, then onmemdup( sc, (strlen(src)+1)*sizeof(src[0]) ) / is called. If onmemdup() returns nullptr, then nullptr is returned. / If src is nullptr, then nullptr is returned. /
/ / ON_register_memory_error_handler( ON_memory_error_handler my_handler ); / / Use this function to specify the error handler function that will be called / if an error occurs. See the description of ON_memory_error_handler() for the / error handler function specification. / / int ON_memory_error_handler( int error_number ); / / This function is called when an error occurs. The values of error_number / are: / / 0: There is not enough memory to satisfy an onmalloc() or onrealloc() / request. / / If ON_memory_error_handler() returns 0, then onmalloc() or onrealloc() / returns nullptr. If ON_memory_error_handler() returns 1, the allocation / is attempted again. / / 1: An invalid pointer was passed to onrealloc(). / / If ON_memory_error_handler() returns 0, then onrealloc() returns nullptr. / If ON_memory_error_handler() returns 1, the reallocation is attempted / again; / / 2: An invalid pointer was passed to onfree(). / / If ON_memory_error_handler() returns 0, then free() returns. / If ON_memory_error_handler() returns 1, the deallocation is / attempted again; / ^^^ see comments above for details ^^^ /////////////////////////////////////////////////////////// / / Memory error handler - the default handler does nothing. / / / See opennurbs_memory.c for instructions on using / custom memory managers. / / ON_memory_error_register_handler() returns a pointer to / the handler you are replacing. If you pass a nullptr, / the default memory error handler is used. The default / memory error handler returns 0 for all errors. / / The input to ON_memory_error_handler(int) is: / / 0: malloc/calloc/realloc request returned nullptr / 1: invalid pointer passed to realloc() / 2: invalid pointer passed to free() / 3: msize query returned zero or 0xFFFFFFFF / / If ON_memory_error_handler(int) returns / / 0: The malloc()/calloc()/realloc()/msize() request returns 0. / 1: The call to malloc()/calloc()/realloc()/msize() is repeated. /
error handling
typedef class ON_NurbsSurface*(* ON_PLUS_FUNCTION_BendBrepFace) (const class ON_BrepFace *face0, const ON_SimpleArray< ON_BendFaceConstraint > *, double, double, class ON_NurbsSurface *, ON_TextLog *) |
Used by ON_BendBrepFace()
typedef bool(* ON_PLUS_FUNCTION_BezierCurve_GetLocalClosestPoint) (const class ON_BezierCurve *, ON_3dPoint, double, double *, const ON_Interval *) |
Used by ON_BezierCurve::
typedef bool(* ON_PLUS_FUNCTION_BezierCurve_GetTightBoundingBox) (const class ON_BezierCurve *, ON_BoundingBox *, bool, const ON_Xform *) |
Used by ON_BezierCurve::
typedef bool(* ON_PLUS_FUNCTION_BezierCurve_LocalIntersectCurve) (const class ON_BezierCurve *, const class ON_BezierCurve *, double *, const ON_Interval *, const ON_Interval *) |
Used by ON_BezierCurve::
typedef bool(* ON_PLUS_FUNCTION_BezierCurve_LocalIntersectSurface) (const class ON_BezierCurve *, const class ON_BezierSurface *, double *, const ON_Interval *, const ON_Interval *, const ON_Interval *) |
Used by ON_BezierCurve::
typedef bool(* ON_PLUS_FUNCTION_BezierSurface_GetClosestPoint) (const class ON_BezierSurface *, ON_3dPoint, double, double, double *, double *, const ON_Interval *, const ON_Interval *) |
typedef bool(* ON_PLUS_FUNCTION_Brep_GetEdgeOrTrimParameter) (const ON_Brep &, int, double, double *, bool) |
Used by ON_Brep::GetEdgeParameter().
typedef bool(* ON_PLUS_FUNCTION_Brep_IsPointInsideHelper) (const ON_Brep &, ON_3dPoint, double, bool) |
Used by ON_Brep::
typedef int(* ON_PLUS_FUNCTION_Brep_MassProperties) (const ON_Brep &, void *, int, ON_3dPoint, ON_MassProperties &, bool, bool, bool, bool, double, double) |
Used by ON_Brep::
typedef ON_Brep*(* ON_PLUS_FUNCTION_Brep_MergeBrepsHelper) (const ON_Brep &, const ON_Brep &, double) |
Used by ON_Brep::
typedef int(* ON_PLUS_FUNCTION_Brep_Mesh) (const ON_Brep &, const ON_MeshParameters &, ON_SimpleArray< ON_Mesh * > &) |
Used by ON_Brep::
typedef bool(* ON_PLUS_FUNCTION_Brep_RegionTopologyHelper) (const ON_Brep &, ON_BrepRegionTopology &) |
Used by ON_Brep::
typedef bool(* ON_PLUS_FUNCTION_Brep_Silhouette) (const ON_SilhouetteParameters, const ON_Brep &, const ON_PlaneEquation *, size_t, ON_ClassArray< ON_SIL_EVENT > &, ON_ProgressReporter *, ON_Terminator *) |
Used by ON_Brep::GetSilhouette()
typedef bool(* ON_PLUS_FUNCTION_Brep_SplitFaces) (ON_Brep &, bool, int, const int *, const int *, const double *) |
Used by ON_Brep::
typedef bool(* ON_PLUS_FUNCTION_BrepCloseTrimGap) (class ON_Brep *, class ON_BrepTrim *, class ON_BrepTrim *) |
Used by ON_Brep::CloseTrimGap()
typedef ON_Mesh*(* ON_PLUS_FUNCTION_BrepFace_Mesh) (const ON_BrepFace &, const ON_MeshParameters &, ON_Mesh *) |
Used by ON_BrepFace::
typedef bool(* ON_PLUS_FUNCTION_BrepFace_Silhouette) (const ON_SilhouetteParameters, const ON_BrepFace &, const ON_PlaneEquation *, size_t, ON_ClassArray< ON_SIL_EVENT > &, ON_ProgressReporter *, ON_Terminator *) |
Used by ON_BrepFace::GetSilhouette()
typedef bool(* ON_PLUS_FUNCTION_BrepFaceGetIsoIntervals) (const class ON_BrepFace *, int, double, ON_SimpleArray< ON_Interval > *, ON_SimpleArray< ON_Curve * > *, ON_SimpleArray< struct ON_BrepFaceIsoInterval > *) |
Used by ON_BrepFace::GetIsoIntervals()
typedef bool(* ON_PLUS_FUNCTION_Check2dPatternHasMapBackInfo) (const ON_Geometry *geom) |
Used by ON_Is2dPatternSquished()
typedef ON_SquisherImpl*(* ON_PLUS_FUNCTION_CreateSquisherImpl) () |
\
Used by ON_Squisher::Create()
typedef ON_NurbsCurve*(* ON_PLUS_FUNCTION_Curve_CreateCubicLoft) (int, int, int, const double *, double, int, ON::cubic_loft_end_condition, ON::cubic_loft_end_condition, ON_NurbsCurve *) |
Used by ON_Curve::CreateCubicLoft()
typedef int(* ON_PLUS_FUNCTION_Curve_MassProperties) (const ON_Curve &, void *, int, ON_3dPoint, ON_3dVector, ON_MassProperties &, bool, bool, bool, bool, double, double) |
typedef class ON_PolylineCurve*(* ON_PLUS_FUNCTION_Curve_Mesh) (const ON_Curve *, const ON_MeshCurveParameters *, class ON_PolylineCurve *, bool, const ON_Interval *) |
Used by ON_Curve::MeshCurve().
typedef const class ON_CurveTreeNode*(* ON_PLUS_FUNCTION_CurveTreeNode_GetClosestPoint) (const class ON_CurveTreeNode *, ON_3dPoint, double *, ON_3dPoint *, double, const ON_Interval *) |
Used by ON_CurveTreeNode::
typedef int(* ON_PLUS_FUNCTION_CurveTreeNode_IntersectCurveTree) (const class ON_CurveTreeNode *, const class ON_CurveTreeNode *, ON_SimpleArray< ON_X_EVENT > &, double, double, const ON_Interval *, const ON_Interval *) |
Used by ON_CurveTreeNode::
typedef int(* ON_PLUS_FUNCTION_CurveTreeNode_IntersectPlane) (const class ON_CurveTreeNode *, const class ON_PlaneEquation &, ON_SimpleArray< ON_X_EVENT > &, double, double, const ON_Interval *) |
Used by ON_CurveTreeNode::
typedef int(* ON_PLUS_FUNCTION_CurveTreeNode_IntersectSelf) (const class ON_CurveTreeNode *, ON_SimpleArray< ON_X_EVENT > &, double, const ON_Interval *) |
Used by ON_CurveTreeNode::
typedef int(* ON_PLUS_FUNCTION_CurveTreeNode_IntersectSurfaceTree) (const class ON_CurveTreeNode *, const class ON_SurfaceTreeNode *, ON_SimpleArray< ON_X_EVENT > &, double, double, const ON_Interval *, const ON_Interval *, const ON_Interval *) |
Used by ON_CurveTreeNode::
typedef void(* ON_PLUS_FUNCTION_DumpSquishInfoText) (const ON_Geometry *geom, ON_TextLog &text_log, const wchar_t *objid_locale_str, const wchar_t *meshcount_locale_str) |
Used by ON_DumpSquishInfoText()
typedef ON_Curve*(* ON_PLUS_FUNCTION_Extrusion_Pullback) (const ON_Extrusion &, const ON_Curve &, double, const ON_Interval *, ON_3dPoint, ON_3dPoint, ON_FitResult *) |
Used by ON_Extrusion::Pullback().
typedef ON_Curve*(* ON_PLUS_FUNCTION_Extrusion_Pushup) (const ON_Extrusion &, const ON_Curve &, double, const ON_Interval *, ON_FitResult *) |
Used by ON_Extrusion::Pushup().
typedef int(* ON_PLUS_FUNCTION_GetMatrixSVD) (int, int, int, double const *const *, double **&, double *&, double **&) |
Used by ON_GetMatrixSVD()
typedef ON_HiddenLineDrawingImplBase*(* ON_PLUS_FUNCTION_GetNew_HiddenLineDrawing) (ON_SimpleArray< class ON_HLDFullCurve * > &, ON_SimpleArray< class ON_HLDCurve * > &, ON_SimpleArray< const class ON_HLD_Object * > &) |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org. Used by ON_HiddenLineDrawing constructors
typedef double(* ON_PLUS_FUNCTION_Integrate1) (double(*f)(ON__UINT_PTR context, int limit_direction, double t), ON__UINT_PTR f_context, const ON_SimpleArray< double > &limits, double relative_tolerance, double absolute_tolerance, double *error_bound) |
Used by ON_Integrate() for one variable functions
typedef double(* ON_PLUS_FUNCTION_Integrate2) (double(*f)(ON__UINT_PTR context, int limit_direction, double s, double t), ON__UINT_PTR f_context, const ON_SimpleArray< double > &limits1, const ON_SimpleArray< double > &limits2, double relative_tolerance, double absolute_tolerance, double *error_bound) |
Used by ON_Integrate() for two variable functions
typedef int(* ON_PLUS_FUNCTION_IsPointListPlanar) (bool, int, int, const double *, const double *, const double *, double, ON_PlaneEquation *) |
Used by ON_IsPointListPlanar()
typedef class ON_PolylineCurve*(* ON_PLUS_FUNCTION_MapBackCurve) (const ON_Mesh &mesh0, double mesh0_edge_length, const ON_3fPoint *V1, const ON_Curve &curve0, ON_PolylineCurve *curve1) |
Used by ON_MapBackCurve()
typedef bool(* ON_PLUS_FUNCTION_MapBackPoint) (const ON_Mesh &mesh0, const ON_3fPoint *V1, ON_3dPoint P0, ON_MESH_POINT &P1) |
Used by ON_MapBackPoint()
typedef int(* ON_PLUS_FUNCTION_Mesh2dPolygon) (int, int, const double *, int, int *) |
Used by ON_Mesh2dPolygon()
typedef int(* ON_PLUS_FUNCTION_Mesh2dRegion) (unsigned int, unsigned int, const double *, unsigned int, unsigned int, const unsigned int *, unsigned int, const unsigned char *, bool, bool, bool, ON_SimpleArray< ON_3dex > &, ON_SimpleArray< ON_2dPoint > *) |
Used by ON_Triangulate2dRegion::
typedef bool(* ON_PLUS_FUNCTION_Mesh_IsPointInside) (const ON_Mesh &, ON_3dPoint, double, bool) |
Used by ON_Mesh::IsPointInside().
typedef int(* ON_PLUS_FUNCTION_Mesh_MassProperties) (const ON_Mesh &, void *, int, ON_3dPoint, ON_MassProperties &, bool, bool, bool, bool, double, double) |
Used by ON_Mesh::
typedef bool(* ON_PLUS_FUNCTION_Mesh_Silhouette) (const ON_SilhouetteParameters, const ON_Mesh &, const ON_PlaneEquation *, size_t, ON_ClassArray< ON_SIL_EVENT > &, ON_ProgressReporter *, ON_Terminator *) |
Used by ON_Mesh::GetSilhouette()
typedef int(* ON_PLUS_FUNCTION_Mesh_SolidOrientation) (const ON_Mesh &) |
Used by ON_Mesh::SolidOrientation().
typedef void(* ON_PLUS_FUNCTION_MeshClashSearch) (int, const class ON_Mesh *const *, int, const class ON_Mesh *const *, const class ON_Mesh *, const class ON_RTree *, const class ON_Mesh *, const class ON_RTree *, double, bool, int, ON_SimpleArray< class ON_ClashEvent > &) |
Used by ON_MeshClashSearch()
typedef double(* ON_PLUS_FUNCTION_Minimize) (unsigned n, double(*f)(ON__UINT_PTR context, const double *t, double *grad), ON__UINT_PTR context, const ON_Interval search_domain[], const double t0[], double terminate_value, double relative_tolerance, double zero_tolerance, unsigned maximum_iterations, double t[], bool *bConverged) |
Used by ON_Minimize()
typedef ON_Mesh*(* ON_PLUS_FUNCTION_NurbsSurface_Mesh) (const ON_NurbsSurface &, const ON_MeshParameters &, ON_Mesh *) |
Used by ON_NurbsSurface::CreateMesh().
typedef bool(* ON_PLUS_FUNCTION_OldMeshBooleansPickTwoSides) (class ON_Mesh *, int, class ON_SimpleArray< int > *, class ON_Mesh *, bool) |
Used by New mesh booleans.
typedef bool(* ON_PLUS_FUNCTION_ON_NurbsCurve_RemoveKnots) (ON_NurbsCurve *, int, int, double) |
Used by ON_NurbsCurve::RemoveKnots()
typedef bool(* ON_PLUS_FUNCTION_ON_NurbsGrevilleInterpolate) (int, int, int, int, double *, const double *, int, int, int, const double *) |
typedef bool(* ON_PLUS_FUNCTION_ON_NurbsSurface_RemoveKnots) (ON_NurbsSurface *, int, int, int) |
Used by ON_NurbsCurve::RemoveKnots()
typedef unsigned int(* ON_PLUS_FUNCTION_Outline_GetOutlineMesh) (const class ON_Outline &, double, double, ON_SimpleArray< ON_2dPoint > &, ON_SimpleArray< ON_3udex > &, double *, double *, class ONX_ErrorCounter *) |
Used by ON_Outline::GetOutlineMesh().
typedef ON_Mesh*(* ON_PLUS_FUNCTION_PlaneSurface_Mesh) (const ON_PlaneSurface &, const ON_MeshParameters &, ON_Mesh *) |
Used by ON_PlaneSurface::CreateMesh().
typedef ON_Mesh*(* ON_PLUS_FUNCTION_RevSurface_Mesh) (const ON_RevSurface &, const ON_MeshParameters &, ON_Mesh *) |
Used by ON_RevSurface::CreateMesh().
typedef int(* ON_PLUS_FUNCTION_SimpleCreate2dMesh) (const ON_SimpleArray< ON_2dPoint > &points, const ON_SimpleArray< ON_2udex > &edges, const ON_SimpleArray< unsigned char > &dirs, ON_SimpleArray< ON_3dex > &triangulation, ON_SimpleArray< ON_2dPoint > &new_pts, ON_TextLog *text_log) |
Used by mesh intersections to tessellate
typedef bool(* ON_PLUS_FUNCTION_SquishBack2dMarks) (const ON_Geometry *squished_geometry, const ON_SimpleArray< const ON_Geometry * > *marks, ON_SimpleArray< ON_Geometry * > *squishedback_marks) |
Used by ON_SquishBack2dMarks()
typedef class ON_Mesh*(* ON_PLUS_FUNCTION_SquishMesh) (const class ON_Mesh *, const class ON_SquishParameters *, const ON_SimpleArray< const ON_Geometry * > *, ON_SimpleArray< ON_Geometry * > *, class ON_Mesh *) |
Used by ON_SquishMesh()
typedef class ON_Brep*(* ON_PLUS_FUNCTION_SquishSurface) (const class ON_Surface *, const class ON_SquishParameters *, const ON_SimpleArray< const ON_Geometry * > *, ON_SimpleArray< ON_Geometry * > *, class ON_Brep *) |
Used by ON_SquishSurface()
typedef ON_Mesh*(* ON_PLUS_FUNCTION_SumSurface_Mesh) (const ON_SumSurface &, const ON_MeshParameters &, ON_Mesh *) |
Used by ON_SumSurface::CreateMesh().
typedef ON_NurbsSurface*(* ON_PLUS_FUNCTION_Surface_CreateCubicLoft) (int, const ON_Curve *const *, double, int, ON::cubic_loft_end_condition, ON::cubic_loft_end_condition, ON_NurbsSurface *) |
Used by ON_Surface::CreateCubicLoft()
typedef ON_NurbsSurface*(* ON_PLUS_FUNCTION_Surface_CreateLinearLoft) (int, const ON_Curve *const *, double, int, ON_NurbsSurface *) |
Used by ON_Surface::CreateLinearLoft()
typedef int(* ON_PLUS_FUNCTION_Surface_MassProperties) (const ON_Surface &, void *, int, ON_3dPoint, ON_MassProperties &, bool, bool, bool, bool, double, double) |
typedef bool(* ON_PLUS_FUNCTION_Surface_Silhouette) (const ON_SilhouetteParameters, const ON_Surface &, const ON_Interval *, const ON_Interval *, const ON_PlaneEquation *, size_t, ON_ClassArray< ON_SIL_EVENT > &, ON_ProgressReporter *, ON_Terminator *) |
Used by ON_Surface::GetSilhouette()
typedef const class ON_SurfaceTreeNode*(* ON_PLUS_FUNCTION_SurfaceTreeNode_GetClosestPoint) (const class ON_SurfaceTreeNode *, ON_3dPoint, double *, double *, ON_3dPoint *, double, const ON_Interval *, const ON_Interval *) |
Used by ON_SurfaceTreeNode::
typedef int(* ON_PLUS_FUNCTION_SurfaceTreeNode_IntersectSurfaceTree) (const class ON_SurfaceTreeNode *, const class ON_SurfaceTreeNode *, ON_ClassArray< ON_SSX_EVENT > &, double, double, double, const ON_Interval *, const ON_Interval *, const ON_Interval *, const ON_Interval *) |
Used by ON_SurfaceTreeNode::
typedef bool(* ON_PLUS_FUNCTION_TransformBrepComponents) (ON_Brep *, int, const ON_COMPONENT_INDEX *, ON_Xform, double, double, bool) |
Used by ON_TransformBrepComponents()
typedef void(* ON_SSLMTC_PROC) (int msg_type, const ON_wString *pClass, const ON_wString *pEventDesc, const ON_wString *pMessage) |
typedef bool(* ON_StreamCallbackFunction) (void *context, ON__UINT32 size, const void *buffer) |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org.
typedef struct ON_UUID_struct ON_UUID |
ON_UUID is a 16 byte universally unique identifier.
typedef int(* ON_Vtable_func) (void) |
typedef ON_wString ON_XMeshEventComponentString[2] |
typedef bool(* ON_XMLRecurseChildrenCallback) (class ON_XMLNode *, void *) |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org.
typedef bool( * TEXMAP_BREP_FACE_CLOSEST_POINT) (const ON_BrepFace *, const ON_3dPoint *, ON_3dPoint &) |
typedef int( * TEXMAP_INTERSECT_LINE_SURFACE) (const ON_Line *, const ON_BrepFace *, ON_SimpleArray< ON_X_EVENT > &) |
|
strong |
|
strong |
|
strong |
|
strong |
|
strong |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org. ON_ComponentState and ON_ComponentStatus
Provides a set of values describing component state.
para>This is not a bit field.
para>Some of these values are mutually exclusive and should not be combined.
|
strong |
|
strong |
Return codes to be used in operations that attempt to fit to a tolerance.
For example ON_Surface::Pullback() and ON_Surface::PushUp().
Enumerator | |
---|---|
unknown | |
in_tolerance | |
not_in_tolerance |
|
strong |
|
strong |
|
strong |
|
strong |
ON_PickType specifies what type of pick is occurring.
|
strong |
|
strong |
The types of deformation allowed in the squish process
0 = free 1 = stretch mostly 2 = stretch only (no compression) 3 = compress mostly 4 = compress only (no stretching) 5 = custom
|
strong |
Represents the type of flattening to use
|
strong |
|
strong |
|
strong |
The ON_SubDComponentLocation enum is used when an ON_SubD component is referenced and it is important to distinguish between the component's location in the SubD control net and its location in the SubD limit surface.
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org.
|
strong |
ON_SubDEdgeTag identifies the type of subdivision edge. Different tags use different subdivision algorithms to calculate the subdivision point.
Enumerator | |
---|---|
Unset | summary> Not a valid edge tag and the default value for ON_SubDEdge.m_edge_tag. This encourages developers to thoughtfully initialize ON_SubDEdge.m_edge_tag. or use ON_SubD.UpdateAllTagsAndSectorCoefficients() to automatically set the m_edge_tag values at an appropriate time. /summary> summary> At least one the edge's vertices must be tagged as ON_SubDVertexTag::Smooth. The edge must have exactly two faces. The edge's subdivision point is (A1 + A2 + S(f1) + S(f2))/4, where Ai = ON_SubDEdge.Vertex(i)->ControlNetPoint() and S(fi) = ON_SubDEdge.Face(i)->SubdivisionPoint(). /summary> |
Smooth | summary> Both of the edge's vertices must be tagged as ON_SubDVertexTag::Dart, ON_SubDVertexTag::Crease, or ON_SubDVertexTag::Corner. (The vertex tags can be different.) The edge can have any number of faces. The edge's subdivision point is (A1+A2)/2 where Ai = ON_SubDEdge.Vertex(i)->ControlNetPoint(). /summary> |
Crease | summary> This tag appears only on level 0 edges that have exactly two neighboring faces and both of the edge's vertices are tagged as ON_SubDVertexTag::Dart, ON_SubDVertexTag::Crease, or ON_SubDVertexTag::Corner. The level 1 subdivision point for a level 0 edge tagged as ON_SubDEdgeTag::SmoothX is the standard smooth edge subdivision point. When subdivided, the new subdivision vertex will be tagged as ON_SubDVertexTag::Smooth and the subdivided edges will be tagged as ON_SubDEdgeTag::Smooth. |
SmoothX |
|
strong |
ON_SubDEdgeType describes a subdivision edge. ON_SubDEdgeType is typically used when generating text descriptions or filtering edges during selection processes. Do not confuse ON_SubDEdgeType and ON_SubDEdgeTag. The unique types are single bits and suitable for use in bitwise logic.
Enumerator | |
---|---|
Unset | summary> Type is unset or the edge is not valid. /summary> summary> The edge has zero faces and the tag is ON_SubDEdgeTag::Crease. /summary> |
Wire | summary> The edge has one face and the tag is ON_SubDEdgeTag::Crease. /summary> |
Boundary | summary> The edge has two faces, the tag is ON_SubDEdgeTag::Smooth or ON_SubDEdgeTag::SmoothX, and the edge sharpness is zero. Note that ON_SubEdge::IsSmoothNotSharp() returns true if and only if ON_SubEdge::EdgeType() is InteriorSmooth. /summary> |
InteriorSmooth | summary> The edge has two faces, the tag is ON_SubDEdgeTag::Smooth or ON_SubDEdgeTag::SmoothX, and the edge sharpness is nonzero. Note that ON_SubEdge::IsSharp() returns true if and only if ON_SubEdge::EdgeType() is InteriorSharp. /summary> |
InteriorSharp | summary> The edge has two faces and the tag is ON_SubDEdgeTag::Crease. /summary> |
InteriorCrease | summary> The edge has three or more faces and the tag is ON_SubDEdgeTag::Crease. /summary> |
Nonmanifold | summary> The edge has an invalid combination of face count, tag, and sharpness properties. /summary> |
Invalid | summary> A mask for all interior edge types. Interior edges have 2 faces. /summary> |
InteriorMask | summary> A mask for all valid edge types. /summary> |
ValidTypesMask |
|
strong |
ON_SubDEndCapStyle enumerates the type of end caps functions like ON_SubD::CreateCylinder will create. Use ON_SubDEndCapStyleFromUnsigned(integer value) to convert integer values to an ON_SubDEndCapStyle. Use ON_SubDEndCapStyleToString(end_cap_style) to convert ON_SubDEndCapStyle values to string descriptions.
|
strong |
ON_SubDGetControlNetMeshPriority specifies what type of ON_SubD information is most important to transfer to the ON_Mesh.
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org. Definition of subdivision surface
|
strong |
ON_SubDHashType used used to specify what type of SubD information is hashed (topology or geometry).
|
strong |
ON_SubDTextureCoordinateType identifies the way ON_SubDMeshFragment texture coordinates are set from an ON_SubDFace.
Enumerator | |
---|---|
Unset | summary> Texture domains are not set. /summary> summary> Each SubDFace uses the unit square in texture space. /summary> |
Unpacked | summary> The face's pack rect is used to set fragment texture coordinates. When possible, adjacent quads with the same ON_SubDFace::PackId() value are assigned adjacent rectangles in texture space. /summary> |
Packed | summary> All ON_SubDMeshFragment texture coordinate values are zero. /summary> |
Zero | summary> All ON_SubDMeshFragment texture coordinate values are ON_DBL_QNAN. /summary> |
Nan | summary> All ON_SubDMeshFragment texture coordinate values are set by barycentric interpolation of ON_SubDFace.TexturePoint() values. /summary> |
FromFaceTexturePoints | summary> Texture coordinates are set from an ON_TextureMapping and transformation specified by ON_SubD::TextureMappingTag(). In all other cases, ON_SubD::TextureMappingTag() can be set, but is ignored. /summary> |
FromMapping |
|
strong |
ON_SubDVertexTag identifies the type of subdivision vertex. Different tags use different subdivision algorithms to determine where the subdivision point and limit point are located. There are topological constraints that restrict which tags can be assigned.
Enumerator | |
---|---|
Unset | summary> Not a valid vertex tag and the default value for ON_SubDVertex.m_vertex_tag. This encourages developers to thoughtfully initialize ON_SubDVertex.m_vertex_tag or use ON_SubD.UpdateAllTagsAndSectorCoefficients() to automatically set the m_vertex_tag values at an appropriate time. /summary> summary> Must be an interior vertex. All edges attached to a smooth vertex must be tagged as ON_SubDEdgeTag::Smooth and must have 2 faces. /summary> |
Smooth | summary> Can be an interior or a boundary vertex. Exactly two edges ending at a crease vertex must be tagged as ON_SubDEdgeTag::Crease and may have 1 or 2 faces. All other edges ending at a crease must be tagged as tagON_SubD::EdgeTag::Smooth and have 2 faces. Below P = ON_SubDVertex.ControlNetPoint() and Ai = ON_SubDVertex.Edge(i)->OtherEndVertex()->ControlNetPoint(). A crease vertex subdivision point is (6*P + A1 + A2)/8. A crease vertex limit surface point is (4*P + A1 + A2)/6. /summary> |
Crease | summary> Can be an interior, boundary, nonmanifold, or isolated vertex. The location of a corner vertex is fixed. The all subdivision points and the limit point are at the initial vertex location. The edges ending at a corner vertex can be smooth or crease edges. A corner vertex subdivision point is P where P = ON_SubDVertex.ControlNetPoint(). A corner vertex limit surface point is P where P = ON_SubDVertex.ControlNetPoint(). /summary> |
Corner | summary> Must be an interior vertex. |
Dart |
|
strong |
enum ON_UnicodeCodePoint |
Unicode code point values for that are hard to include in code or are useful for testing encoding and glyph rendering. Code points >= U+0080 require UTF-8 multiple byte encodings. Code points >= U+10000 require UTF-16 surrogate pair encodings.
UTF-8 encodings: The UTF-8 encoding for codepoint values from 0 to 127 is a single single byte (char).
The UTF-8 encoding for codepoint values >= 128 require multiple bytes. UTF-16 encodings: The UTF-16 encoding of every codepoint in this enum except Wastebasket is a single word (unsigned short).
enum ON_UnicodeEncoding |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org.
ON_ClassArray< T >::ON_ClassArray |
construction ////////////////////////////////////////////////////////
ON_ClassArray< T >::ON_ClassArray | ( | const ON_ClassArray< T > & | src | ) |
Copy constructor.
< operator= defined below
ON_ClassArray< T >::ON_ClassArray | ( | size_t | c | ) |
size_t parameter = initial capacity
ON_ObjectArray< T >::ON_ObjectArray |
Class ON_ObjectArray<>
ON_ObjectArray< T >::ON_ObjectArray | ( | const ON_ObjectArray< T > & | src | ) |
ON_ObjectArray< T >::ON_ObjectArray | ( | size_t | c | ) |
size_t parameter = initial capacity
ON_SimpleArray< T >::ON_SimpleArray |
construction ////////////////////////////////////////////////////////
These constructors create an array that uses onrealloc() to manage the array memory.
ON_SimpleArray< T >::ON_SimpleArray | ( | const ON_SimpleArray< T > & | src | ) |
Copy constructor.
< operator= defined below
ON_SimpleArray< T >::ON_SimpleArray | ( | size_t | c | ) |
size_t parameter = initial capacity
ON_SimpleFixedSizePool< T >::ON_SimpleFixedSizePool |
construction ////////////////////////////////////////////////////////
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org.
ON_SimpleFixedSizePoolIterator< T >::ON_SimpleFixedSizePoolIterator | ( | const class ON_SimpleFixedSizePool< T > & | fsp | ) |
ON_SimpleFixedSizePoolIterator< T >::ON_SimpleFixedSizePoolIterator | ( | const class ON_SimpleFixedSizePoolIterator< T > & | fsp_it | ) |
|
virtual |
override for struct member deallocation, etc.
ON_ObjectArray< T >::~ON_ObjectArray |
override for struct member deallocation, etc.
|
virtual |
ON_SimpleFixedSizePool< T >::~ON_SimpleFixedSizePool |
size_t ON_SimpleFixedSizePool< T >::ActiveElementCount |
Returns: Number of active elements. (Elements that have been returned are not active.)
T * ON_SimpleFixedSizePool< T >::AllocateElement |
Returns: A pointer to sizeof_element bytes. The memory is zeroed.
void ON_SimpleArray< T >::Append | ( | const T & | x | ) |
Append copy of element. Increments count by 1.
26 Sep 2005 Dale Lear x is in the block of memory about to be reallocated.
void ON_ClassArray< T >::Append | ( | const T & | x | ) |
Append copy of element. Increments count by 1.
< (int) cast is for 64 bit pointers
26 Sep 2005 Dale Lear User passed in an element of the m_a[] that will get reallocated by the call to Reserve(newcapacity).
< ON_*Array<> templates do not require robust copy constructor.
< ON_*Array<> templates require a robust operator=.
void ON_SimpleArray< T >::Append | ( | int | count, |
const T * | buffer | ||
) |
Append copy of an array T[count].
buffer is in the block of memory about to be reallocated
void ON_ClassArray< T >::Append | ( | int | count, |
const T * | p | ||
) |
Append copy of an array T[count].
T & ON_SimpleArray< T >::AppendNew |
array operations ////////////////////////////////////////////////////
Most efficient way to add a new element to the array. Increases count by 1. Returned element is memset to zero.
T & ON_ClassArray< T >::AppendNew |
array operations ////////////////////////////////////////////////////
Most efficient way to add a new class to the array. Increases count by 1.
First destroy what's there ..
and then get a properly initialized element
const T * ON_SimpleArray< T >::Array |
The Array() function return the.
const T * ON_ClassArray< T >::Array |
The Array() function return the.
T * ON_SimpleArray< T >::At | ( | int | i | ) |
At(index) returns nullptr if index < 0 or index >= count.
T * ON_ClassArray< T >::At | ( | int | i | ) |
At(index) returns nullptr if index < 0 or index >= count.
const T * ON_SimpleArray< T >::At | ( | int | i | ) | const |
const T * ON_ClassArray< T >::At | ( | int | i | ) | const |
T * ON_SimpleArray< T >::At | ( | ON__INT64 | i | ) |
T * ON_ClassArray< T >::At | ( | ON__INT64 | i | ) |
const T * ON_SimpleArray< T >::At | ( | ON__INT64 | i | ) | const |
const T * ON_ClassArray< T >::At | ( | ON__INT64 | i | ) | const |
T * ON_SimpleArray< T >::At | ( | ON__UINT64 | i | ) |
T * ON_ClassArray< T >::At | ( | ON__UINT64 | i | ) |
const T * ON_SimpleArray< T >::At | ( | ON__UINT64 | i | ) | const |
const T * ON_ClassArray< T >::At | ( | ON__UINT64 | i | ) | const |
T * ON_SimpleArray< T >::At | ( | unsigned int | i | ) |
T * ON_ClassArray< T >::At | ( | unsigned int | i | ) |
const T * ON_SimpleArray< T >::At | ( | unsigned int | i | ) | const |
const T * ON_ClassArray< T >::At | ( | unsigned int | i | ) | const |
int ON_SimpleArray< T >::BinarySearch | ( | const T * | key, |
int(*)(const T *, const T *) | compar | ||
) | const |
See Also: ON_CompareIncreasing<T> and ON_CompareDeccreasing<T>
BinarySearch( p, compare ) does a fast search of a sorted array and returns the smallest index "i" of the element that satisfies 0==compare(p,&array[i]).
BinarySearch( p, compare, count ) does a fast search of the first count element sorted array and returns the smallest index "i" of the element that satisfies 0==compare(p,&array[i]). The version that takes a "count" is useful when elements are being appended during a calculation and the appended elements are not sorted.
If the search is successful, BinarySearch() returns the index of the element (>=0). If the search is not successful, BinarySearch() returns -1.
Use QuickSort( compare ) or, in rare cases and after meaningful performance testing using optimzed release builds, HeapSort( compare ) to sort the array.
This worked on a wide range of 32 bit compilers.
Convert "found" pointer to array index.
In an ideal world, return ((int)(found - m_a)) would work everywhere. In practice, this should work any 32 bit compiler and we can hope the optimzer generates efficient code.
"key" not found
int ON_ClassArray< T >::BinarySearch | ( | const T * | key, |
int(*)(const T *, const T *) | compar | ||
) | const |
See Also: ON_CompareIncreasing<T> and ON_CompareDeccreasing<T>
BinarySearch( p, compare ) does a fast search of a sorted array and returns the smallest index "i" of the element that satisfies 0==compare(p,&array[i]).
BinarySearch( p, compare, count ) does a fast search of the first count element sorted array and returns the smallest index "i" of the element that satisfies 0==compare(p,&array[i]). The version that takes a "count" is useful when elements are being appended during a calculation and the appended elements are not sorted.
If the search is successful, BinarySearch() returns the index of the element (>=0). If the search is not successful, BinarySearch() returns -1. Use QuickSort( compare ) or, in rare cases and after meaningful performance testing using optimzed release builds, HeapSort( compare ) to sort the array.
int ON_SimpleArray< T >::BinarySearch | ( | const T * | key, |
int(*)(const T *, const T *) | compar, | ||
int | count | ||
) | const |
This worked on a wide range of 32 bit compilers.
Convert "found" pointer to array index.
In an ideal world, return ((int)(found - m_a)) would work everywhere. In practice, this should work any 32 bit compiler and we can hope the optimzer generates efficient code.
"key" not found
int ON_ClassArray< T >::BinarySearch | ( | const T * | key, |
int(*)(const T *, const T *) | compar, | ||
int | count | ||
) | const |
const T * ON_SimpleArray< T >::BinarySearchPtr | ( | const T * | key, |
int(*)(const T *, const T *) | compar | ||
) | const |
const T * ON_SimpleArray< T >::BinarySearchPtr | ( | const T * | key, |
int(*)(const T *, const T *) | compar, | ||
int | count | ||
) | const |
int ON_SimpleArray< T >::Capacity |
capacity of array
int ON_ClassArray< T >::Capacity |
capacity of array
|
protected |
use placement ( new(size_t,void*) ) to construct T in supplied memory
int ON_SimpleArray< T >::Count |
query ///////////////////////////////////////////////////////////////
number of elements in array
int ON_ClassArray< T >::Count |
query ///////////////////////////////////////////////////////////////
number of elements in array
|
static |
Description: Create a condition that should result in a crash. The intended use is for testing application crash handling. Parameters: crash_type - [in] 0: dereference nullptr data pointer 1: dereference bogus data pointer (0xCACAF00D) 2: dereference nullptr function pointer 3: dereference bogus function pointer (0xCACAF00D) 4: call abort() 5: call exit(99); 6: double divide by 0.0 - FPU exception well designed apps will mask the exception but detect the error 7: float divide by 0.0 - FPU exception well designed apps will mask the exception but detect the error 8: int divide by 0 - will crash 9: log(-1.0) - should call math error handler 10: double overflow - FPU exception well designed apps will mask the exception but detect the error 11: throw(123) - well designed apps with catch the exception before crashing Returns: Value of crash_type parameter.
Note: The code and calls are intentionally obtuse so that it is difficult for an optimizer to not perform the calculation.
< dereference nullptr pointer
< dereference bogus pointer
< call nullptr function pointer
< divide by zero
|
static |
|
static |
< sets ptr = nullptr
< dereferences bogus function pointer and crashes
|
static |
< sets ptr = nullptr
< dereferences nullptr function pointer and crashes
|
static |
< sets ptr = 0xCACAF00D
< dereferences bogus pointer and crashes
|
static |
< sets ptr = nullptr
< dereferences nullptr pointer and crashes
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
bool ON_SimpleFixedSizePool< T >::Create | ( | size_t | element_count_estimate, |
size_t | block_element_count | ||
) |
Description: Create a fixed size memory pool. Parameters: element_count_estimate - [in] (0 = good default) If you know how many elements you will need, pass that number here. It is better to slightly overestimate than to slightly underestimate. If you do not have a good estimate, then use zero. block_element_count - [in] (0 = good default) If block_element_count is zero, Create() will calculate a block size that is efficient for most applications. If you are an expert user and want to specify the number of blocks, then pass the number of elements per block here. When block_element_count > 0 and element_count_estimate > 0, the first block will be large enough element_count_estimate*sizeof(T) bytes; in this case do not ask for extraordinarily large amounts of contiguous heap. Remarks: You must call Create() on an unused ON_FixedSizePool or call Destroy() before calling create. Returns: True if successful and the pool can be used.
T * ON_SimpleFixedSizePoolIterator< T >::CurrentElement |
Returns: The most recently returned value from a call to FirstElement() or NextElement(). Remarks: Do not make any calls to FirstBlock() or NextBlock() when using FirstElement() and NextElement() to iterate through elements.
ON__UINT32 ON_SimpleArray< T >::DataCRC | ( | ON__UINT32 | current_remainder | ) | const |
ON__UINT32 ON_ObjectArray< T >::DataCRC | ( | ON__UINT32 | current_remainder | ) | const |
The "this->" in this->m_count and this->m_a are needed for gcc 4 to compile.
void ON_SimpleArray< T >::Destroy |
onfree any memory and set count and capacity to zero
void ON_ClassArray< T >::Destroy |
onfree any memory and set count and capacity to zero
void ON_SimpleFixedSizePool< T >::Destroy |
Description: Destroy the pool and free all the heap. The pool cannot be used again until Create() is called.
|
protected |
T * ON_SimpleFixedSizePool< T >::Element | ( | size_t | element_index | ) | const |
Description: Get the i-th element in the pool. Parameters: element_index - [in] Returns: A pointer to the i-th element. The first element has index = 0 and is the element returned by the first call to AllocateElement(). The last element has index = ElementCount()-1. If i is out of range, null is returned. Remarks: It is faster to use FirstElement() and NextElement() to iterate through the entire list of elements. This function is relatively efficient when there are a few large blocks in the pool or element_index is small compared to the number of elements in the first few blocks.
If ReturnElement() is not used or AllocateElement() calls to are made after any use of ReturnElement(), then the i-th element is the one returned by the (i+1)-th call to AllocateElement().
size_t ON_SimpleFixedSizePool< T >::ElementIndex | ( | T * | element_ptr | ) | const |
void ON_SimpleArray< T >::EmergencyDestroy | ( | void | ) |
emergency bailout ///////////////////////////////////////////////////
emergency destroy ///////////////////////////////////////////////////
call only when memory used by this array may have become invalid for reasons beyond your control. EmergencyDestroy() zeros anything that could possibly cause ~ON_SimpleArray() to crash.
void ON_ClassArray< T >::EmergencyDestroy | ( | void | ) |
emergency bailout ///////////////////////////////////////////////////
emergency destroy ///////////////////////////////////////////////////
call only when memory used by this array may have become invalid for reasons beyond your control. EmergencyDestroy() zeros anything that could possibly cause ~ON_ClassArray() to crash.
void ON_SimpleArray< T >::Empty |
Sets count to 0, leaves capacity untouched.
Removes elements for which predicate returns true. Decrements count by removed items. Does not change capacity
void ON_ClassArray< T >::Empty |
Sets count to 0, leaves capacity untouched.
This call to memset is ok even when T has a vtable because in-place construction is used later.
const T * ON_SimpleArray< T >::First |
const T * ON_ClassArray< T >::First |
T * ON_SimpleFixedSizePoolIterator< T >::FirstBlock | ( | size_t * | block_element_count | ) |
Description: Get a pointer to the first element in the first block. Parameters: block_element_count - [out] (can be null) If not null, the number of elements allocated from the first block is returned in block_element_count. Note that if you have used ReturnElement(), some of these elements may have been returned. Example: The loop will iterate through all the blocks.
/ iterate through all blocks in the pool size_t block_element_count = 0; for ( void* p = FirstBlock(&block_element_count); 0 != p; p = NextBlock(&block_element_count) ) { ElementType* e = (ElementType*)p; for ( size_t i = 0; i < block_element_count; i++, e = ((const char*)e) + SizeofElement() ) { ... } }
Returns: The first block when iterating the list of blocks. Remarks: The heap for a fixed size memory pool is simply a linked list of blocks. FirstBlock() and NextBlock() can be used to iterate through the list of blocks.
Do not make any calls to FirstElement() or NextElement() when using FirstBlock() and NextBlock() to iterate through blocks.
T * ON_SimpleFixedSizePoolIterator< T >::FirstElement |
Description: Get the first element when iterating through the list of elements. Parameters: element_index - [in] If you use the version of FirstElement() that has an element_index parameter, then the iteration begins at that element. Example: The loop will iterate through all the elements returned from AllocateElement(), including any that have be returned to the pool using ReturnElement().
/ iterate through all elements in the pool / This iteration will go through TotalElements() items. for ( void* p = FirstElement(); 0 != p; p = NextElement() ) { / If you are not using ReturnElement(), then you may process / "p" immediately. If you have used ReturnElement(), then you / must check some value in p located after the first sizeof(void*) / bytes to see if p is active. if ( p is not active ) continue;
... process p }
Returns: The first element when iterating through the list of elements. Remarks: FirstElement() and NextElement() will return elements that have been returned to the pool using ReturnElement(). If you use ReturnElement(), then be sure to mark the element so it can be identified and skipped.
Do not make any calls to FirstBlock() or NextBlock() when using FirstElement() and NextElement() to iterate through elements.
T * ON_SimpleFixedSizePoolIterator< T >::FirstElement | ( | size_t | element_index | ) |
bool ON_SimpleArray< T >::HeapSort | ( | int(*)(const T *, const T *) | compar | ) |
Sorts the array using the heap sort algorithm. QuickSort() is generally the better choice.
|
virtual |
QuickSort() is generally the better choice.
Sorts the array using the heap sort algorithm. See Also: ON_CompareIncreasing<T> and ON_CompareDeccreasing<T>
Reimplemented in ON_ObjectArray< T >, ON_ObjectArray< ON_Texture >, ON_ObjectArray< ON_Linetype >, ON_ObjectArray< ON_Light >, ON_ObjectArray< ON_BrepVertex >, ON_ObjectArray< ON_BrepTrim >, ON_ObjectArray< ON_BrepRegion >, ON_ObjectArray< ON_BrepLoop >, ON_ObjectArray< ON_BrepFaceSide >, ON_ObjectArray< ON_BrepFace >, and ON_ObjectArray< ON_BrepEdge >.
|
virtual |
virtual ON_ClassArray<T> override that calls MemoryRelocate on each element after the heap sort. QuickSort() is generally the better choice.
The "this->" in this->m_count and this->m_a are needed for gcc 4 to compile.
The MemoryRelocate step is required to synch userdata back pointers so the user data destructor will work correctly.
Reimplemented from ON_ClassArray< T >.
void ON_SimpleArray< T >::Insert | ( | int | i, |
const T & | x | ||
) |
Insert copy of element. Uses memmove() to perform any necessary moving. Increases count by 1.
x is in the block of memory about to be reallocated.
void ON_ClassArray< T >::Insert | ( | int | i, |
const T & | x | ||
) |
Insert called with a reference uses operator =.
Insert copy of element. Uses memmove() to perform any necessary moving. Increases count by 1.
This call to memset is ok even when T has a vtable because in-place construction is used later.
< uses T::operator=() to copy x to array
int ON_SimpleArray< T >::InsertInSortedList | ( | const T & | e, |
int(*)(const T *, const T *) | compar | ||
) |
int ON_ClassArray< T >::InsertInSortedList | ( | const T & | e, |
int(*)(const T *, const T *) | compar | ||
) |
int ON_SimpleArray< T >::InsertInSortedList | ( | const T & | e, |
int(*)(const T *, const T *) | compar, | ||
int | count | ||
) |
int ON_ClassArray< T >::InsertInSortedList | ( | const T & | e, |
int(*)(const T *, const T *) | compar, | ||
int | count | ||
) |
T * ON_SimpleArray< T >::KeepArray |
Description: Expert user tool to take charge of the memory used by the dynamic array. Returns: A pointer to the array and zeros out this class. The returned pointer is on the heap and must be deallocated by calling onfree().
T * ON_ClassArray< T >::KeepArray |
returns pointer to array and zeros out this class. Caller is responsible for calling destructor on each element and then using onfree() to release array memory. E.g.,
for (int i=capacity;i>=0;i–) { array[i].~T(); } onfree(array);
const T * ON_SimpleArray< T >::Last |
const T * ON_ClassArray< T >::Last |
void ON_SimpleArray< T >::MemSet | ( | unsigned char | value | ) |
Sets all bytes in array memory to value. Count and capacity are not changed.
|
protected |
implementation //////////////////////////////////////////////////////
array operations ////////////////////////////////////////////////////
private function for moving blocks of array memory caller is responsible for updating m_count.
|
protected |
implementation //////////////////////////////////////////////////////
array operations ////////////////////////////////////////////////////
private function for moving blocks of array memory caller is responsible for updating m_count and managing destruction/creation.
This call to memmove is ok, even when T is a class with a vtable because the it doesn't change the vtable for the class. Classes that have back pointers, like ON_UserData, are handled elsewhere and cannot be in ON_ClassArray<>s.
int ON_SimpleArray< T >::NewCapacity |
is < current Count(), then count is reduced to value. When the dynamic array needs to grow, this calculates the new value for m_capacity.
Note: This code appears in ON_SimpleArray<T>::NewCapacity() and ON_ClassArray<T>::NewCapacity(). Changes made to either function should be made to both functions. Because this code is template code that has to support dynamic linking and the code is defined in a header, I'm using copy-and-paste rather than a static.
This function returns 2*m_count unless that will result in an additional allocation of more than cap_size bytes. The cap_size concept was added in January 2010 because some calculations on enormous models were slightly underestimating the initial Reserve() size and then wasting gigabytes of memory.
cap_size = 128 MB on 32-bit os, 256 MB on 64 bit os
Growing the array will increase the memory use by more than cap_size.
int ON_ClassArray< T >::NewCapacity |
is < current Count(), then count is reduced to value. When the dynamic array needs to grow, this calculates the new value for m_capacity.
Note: This code appears in ON_SimpleArray<T>::NewCapacity() and ON_ClassArray<T>::NewCapacity(). Changes made to either function should be made to both functions. Because this code is template code that has to support dynamic linking and the code is defined in a header, I'm using copy-and-paste rather than a static.
This function returns 2*m_count unless that will result in an additional allocation of more than cap_size bytes. The cap_size concept was added in January 2010 because some calculations on enormous models were slightly underestimating the initial Reserve() size and then wasting gigabytes of memory.
cap_size = 128 MB on 32-bit os, 256 MB on 64 bit os
Growing the array will increase the memory use by more than cap_size.
T * ON_SimpleFixedSizePoolIterator< T >::NextBlock | ( | size_t * | block_element_count | ) |
Description: Get the next block when iterating through the blocks. Parameters: block_element_count - [out] (can be null) If not null, the number of elements allocated from the block is returned in block_element_count. Note that if you have used ReturnElement(), some of these elements may have been returned. Example: See the FirstBlock() documentation. Returns: The next block when iterating through the blocks. Remarks: Do not make any calls to FirstElement() or NextElement() when using FirstBlock() and NextBlock() to iterate through blocks.
T * ON_SimpleFixedSizePoolIterator< T >::NextElement |
Description: Get the next element when iterating through the list of elements. If FirstElement() is not called, then the first call to NextElement() returns the first element. Example: See the FirstElement() documentation. Returns: The next element when iterating through the list of elements. Remarks: FirstElement() and NextElement() will return elements that have been returned to the pool using ReturnElement(). If you use ReturnElement(), then be sure to mark the element so it can be identified and skipped.
Do not make any calls to FirstBlock() or NextBlock() when using FirstElement() and NextElement() to iterate through elements.
ON_DECL ON_3dVector ON_2ndDerFromCurvature | ( | ON_3dVector | D1, |
ON_3dVector | K | ||
) |
Description: Given the first derivative and a curvature, calculate the shortest possible second derivative such that a curve with the input first derivative and calculated second derivative would have the specified curvature. Parameters: D1 - [in] first derivative K - [in] curvature Returns: 2nd derivative. Remarks: You can add any multiple of the tangent to the returned second derivative without changing the curvature.
ON_DECL ON_3dVector ON_3rdDerFromJerk | ( | ON_3dVector | D1, |
ON_3dVector | D2, | ||
ON_3dVector | J | ||
) |
Description: Given the first derivative, second derivative, and a jerk, calculate the shortest possible third derivative such that a curve with the input first derivative, input second derivative, and calculated third derivative would have the specified jerk. Parameters: D1 - [in] first derivative D2 - [in] second derivative J - [in] jerk Returns: 3rdd derivative. Remarks: You can add any multiple of the tangent to the returned third derivative without changing the jerk.
ON_DECL ON_3dVector ON_4thDerFromYank | ( | ON_3dVector | D1, |
ON_3dVector | D2, | ||
ON_3dVector | D3, | ||
ON_3dVector | Y | ||
) |
Description: Given the first derivative, second derivative, third derivative, and a yank, calculate the shortest possible forth derivative such that a curve with the input first derivative, input second derivative, input third derivative and calculated forth derivative would have the specified yank Parameters: D1 - [in] first derivative D2 - [in] second derivative D3 - [in] second derivative Y - [in] yank Returns: 4th derivative. Remarks: You can add any multiple of the tangent to the returned forth derivative without changing the yank.
bool ON__PackTextureRectangles1 | ( | ON_PackedTextureRectangle * | top, |
const class ON_PackTextureRectanglesParameters * | packing_parameters | ||
) |
do not export this function or declare it in a header file
bool ON__PackTextureRectangles2 | ( | ON_PackedTextureRectangle * | top, |
const class ON_PackTextureRectanglesParameters * | packing_parameters | ||
) |
do not export this function or declare it in a header file
const ON_DECL ON_wString ON_AddIdPrefixToString | ( | const ON_UUID | id, |
const wchar_t * | separator, | ||
const wchar_t * | source | ||
) |
const ON_DECL ON_wString ON_AddIdSuffixToString | ( | const wchar_t * | source, |
const wchar_t * | separator, | ||
const ON_UUID | id | ||
) |
ON_DECL bool ON_Adjust2ndPointToDomain | ( | const ON_2dPoint & | First, |
ON_2dPoint & | Second, | ||
const ON_Interval | dom[2] | ||
) |
Adjust the second point to be within the domains, when the first point is on the edge of on of the domains and some other conditions hold. This function is here because it is needed in several places. It is not meant for general use.
ON_DECL int ON_ArePointsOnLine | ( | int | , |
bool | , | ||
int | , | ||
int | , | ||
const double * | , | ||
const ON_BoundingBox & | , | ||
const ON_Line & | , | ||
double | |||
) |
returns 0 = no, 1 = yes, 2 = points are coincident and on line
ON_DECL int ON_ArePointsOnPlane | ( | int | , |
bool | , | ||
int | , | ||
int | , | ||
const double * | , | ||
const ON_BoundingBox & | , | ||
const ON_Plane & | , | ||
double | |||
) |
returns 0 = no, 1 = yes, 2 = points are coincident and on line
ON_DECL void ON_Array_aA_plus_B | ( | int | , |
double | , | ||
const double * | , | ||
const double * | , | ||
double * | |||
) |
ON_DECL void ON_Array_aA_plus_B | ( | int | , |
float | , | ||
const float * | , | ||
const float * | , | ||
float * | |||
) |
ON_DECL double ON_ArrayDistance | ( | int | , |
const double * | , | ||
const double * | |||
) |
ON_DECL double ON_ArrayDistanceSquared | ( | int | , |
const double * | , | ||
const double * | |||
) |
ON_DECL double ON_ArrayDotDifference | ( | int | , |
const double * | , | ||
const double * | , | ||
const double * | |||
) |
ON_DECL double ON_ArrayDotProduct | ( | int | , |
const double * | , | ||
const double * | |||
) |
ON_DECL float ON_ArrayDotProduct | ( | int | , |
const float * | , | ||
const float * | |||
) |
ON_DECL double ON_ArrayMagnitude | ( | int | , |
const double * | |||
) |
ON_DECL double ON_ArrayMagnitudeSquared | ( | int | , |
const double * | |||
) |
ON_DECL void ON_ArrayScale | ( | int | , |
double | , | ||
const double * | , | ||
double * | |||
) |
ON_DECL void ON_ArrayScale | ( | int | , |
float | , | ||
const float * | , | ||
float * | |||
) |
ON_DECL bool ON_Base32ToString | ( | const ON_SimpleArray< unsigned char > & | base32_digits, |
ON_String & | sBase32 | ||
) |
Description: Convert a list of base32 digits into a string form. Parameters: base32_digits - [in] base32_digit_count - [in] base32_digits[] is an array of length base32_digit_count. Each element is in the range 0 to 31. sBase32 - [out] sBase32[] must be an array of length base32_digit_count+1 or 2, whichever is greater. The string representation of the base 32 number will be put in this string. A hash mark symbol (#) is used to indicate an error in the input value. The returned string is null terminated. Returns True if the input is valid. False if the input is not valid, in which case hash marks indicate the invalid entries.
ON_DECL bool ON_Base32ToString | ( | const ON_SimpleArray< unsigned char > & | base32_digits, |
ON_wString & | sBase32 | ||
) |
ON_DECL bool ON_Base32ToString | ( | const unsigned char * | base32_digits, |
int | base32_digit_count, | ||
char * | sBase32 | ||
) |
ON_DECL ON_NurbsSurface* ON_BendBrepFace | ( | const ON_BrepFace & | face0, |
const ON_SimpleArray< ON_BendFaceConstraint > & | constraints, | ||
double | tolerance, | ||
double | time_limit, | ||
ON_NurbsSurface * | bent_surface, | ||
ON_TextLog * | text_log = 0 |
||
) |
Description: Calculate a surface that can be used to deform a brep face so that is has a new boundary. Parameters: face0 - [in] existing valid face constraints - [in] Desired face boundary locations, surface singularities, and closed/periodic surface constraints. tolerance - [in] Desired tolerance time_limit - [in] If the deformation is extreme, it can take a long time to calculate the result. If time_limit > 0, then the value specifies the maximum amount of time in seconds you want to spend before giving up. bent_surface - [in] If bent_surface is not null, the result will be stored in this surface.
If bent_surface is null or is not a valid NURBS surface, then the face0->NurbForm() will be used as the starting surface.
If bent_surface is not null and a valid NURBS surface, then it will be used as the starting surface. In this case the knots must be set and the domain must include the range of all face0's trim curves. text_log - [in] optional parameter to use when debugging Returns: A surface that can be used to update face0.
ON_DECL bool ON_BeyondSinglePrecision | ( | const ON_BoundingBox & | bbox, |
ON_Xform * | xform | ||
) |
Description: Determine if an object is too large or too far from the origin for single precision coordinates to be useful. Parameters: bbox - [in] Bounding box of an object with single precision coordinates. An ON_Mesh is an example of an object with single precision coordinates. xform - [out] If this function returns false and xform is not null, then the identity transform is returned. If this function returns true and xform is not null, then the transform moves the region contained in bbox to a location where single precision coordinates will have enough information for the object to be useful. Returns: true: The region contained in bbox is too large or too far from the origin for single precision coordinates to be useful. false: A single precision object contained in bbox will be satisfactory for common calculations.
const ON_DECL ON_2udex* ON_BinarySearch2udexArray | ( | unsigned int | key_i, |
const ON_2udex * | base, | ||
size_t | nel | ||
) |
const ON_DECL void* ON_BinarySearchArrayFirst2udex | ( | ON_2udex | key, |
const void * | base, | ||
size_t | count, | ||
size_t | sizeof_element, | ||
size_t | key_offset | ||
) |
const ON_DECL void* ON_BinarySearchArrayFirstUnsignedInt | ( | unsigned int | key, |
const void * | base, | ||
size_t | count, | ||
size_t | sizeof_element, | ||
size_t | key_offset | ||
) |
const ON_DECL void* ON_BinarySearchArrayForUnsingedInt | ( | unsigned int | key, |
const void * | base, | ||
size_t | count, | ||
size_t | sizeof_element, | ||
size_t | key_offset | ||
) |
const ON_DECL double* ON_BinarySearchDoubleArray | ( | double | key, |
const double * | base, | ||
size_t | nel | ||
) |
const ON_DECL int* ON_BinarySearchIntArray | ( | int | key, |
const int * | base, | ||
size_t | nel | ||
) |
const ON_DECL unsigned int* ON_BinarySearchUnsignedIntArray | ( | unsigned int | key, |
const unsigned int * | base, | ||
size_t | nel | ||
) |
ON_DECL double ON_BinomialCoefficient | ( | int | i, |
int | j | ||
) |
Description: Compute a binomial coefficient. Parameters: i - [in] j - [in] Returns: (i+j)!/(i!j!), if 0 <= i and 0 <= j, and 0 otherwise. See Also: ON_TrinomialCoefficient() Remarks: If (i+j) <= 52, this function is fast and returns the exact value of the binomial coefficient.
For (i+j) > 52, the coefficient is computed recursively using the formula bc(i,j) = bc(i-1,j) + bc(i,j-1). For (i+j) much larger than 60, this is inefficient. If you need binomial coefficients for large i and j, then you should probably be using something like Stirling's Formula.
(Look up "Stirling" or "Gamma function" in a calculus book.)
ON_DECL double ON_BoundingBoxTolerance | ( | int | dim, |
const double * | bboxmin, | ||
const double * | bboxmax | ||
) |
ON_DECL ON_Brep* ON_BrepBox | ( | const ON_3dPoint * | box_corners, |
ON_Brep * | pBrep = nullptr |
||
) |
Description: Get an ON_Brep definition of a box. Parameters: box_corners - [in] 8 points defining the box corners arranged as the vN labels indicate.
v7_______e6_____v6 |\ |\ | e7 | e5 | \ ______e4_____\ e11 v4 | v5 | | e10 | | | | | v3---|---e2----v2 e9 \ e8 \ | e3 | e1 | \ | \ | \v0_____e0_____\v1
pBrep - [in] if not nullptr, this brep will be used and returned. Returns: An ON_Brep representation of the box with topology
edge vertices m_E[ 0] m_V[0], m_V[1] m_E[ 1] m_V[1], m_V[2] m_E[ 2] m_V[2], m_V[3] m_E[ 3] m_V[3], m_V[0] m_E[ 4] m_V[4], m_V[5] m_E[ 5] m_V[5], m_V[6] m_E[ 6] m_V[6], m_V[7] m_E[ 7] m_V[7], m_V[4] m_E[ 8] m_V[0], m_V[4] m_E[ 9] m_V[1], m_V[5] m_E[10] m_V[2], m_V[6] m_E[11] m_V[3], m_V[7]
face boundary edges m_F[0] +m_E[0] +m_E[9] -m_E[4] -m_E[8] m_F[1] +m_E[1] +m_E[10] -m_E[5] -m_E[9] m_F[2] +m_E[2] +m_E[11] -m_E[6] -m_E[10] m_F[3] +m_E[3] +m_E[8] -m_E[7] -m_E[11] m_F[4] -m_E[3] -m_E[2] -m_E[1] -m_E[0] / m_F[5] +m_E[4] +m_E[5] +m_E[6] +m_E[7]
Description: Get an ON_Brep definition of a cone. Parameters: cylinder - [in] cylinder.IsFinite() must be true bCapBase - [in] if true the base of the cone should be capped. pBrep - [in] if not nullptr, this brep will be used and returned. Returns: An ON_Brep representation of the cone with a single face for the cone, an edge along the cone seam, and vertices at the base and apex ends of this seam edge. The optional cap is a single face with one circular edge starting and ending at the base vertex.
ON_DECL int ON_BrepConeEdge | ( | ON_Brep & | brep, |
int | edge_index, | ||
ON_3dPoint | apex_point | ||
) |
Description: Cone an edge in a brep. Parameters: brep - [in/out] edge_index - [in] index of face to extrude. apex_point - [in] apex of cone. Returns: @untitled table 0 failure 1 successful See Also: ON_BrepExtrudeFace ON_BrepExtrudeLoop ON_BrepExtrudeEdge ON_BrepExtrudeVertex ON_BrepConeFace ON_BrepConeLoop ON_BrepConeEdge Remarks: The new face is appended to brep.m_F[].
ON_DECL int ON_BrepConeFace | ( | ON_Brep & | brep, |
int | face_index, | ||
ON_3dPoint | apex_point | ||
) |
Description: Cone a face in a brep. Parameters: brep - [in/out] face_index - [in] index of face to extrude. apex_point - [in] apex of cone. Returns: @untitled table 0 failure 1 successful See Also: ON_BrepExtrudeFace ON_BrepExtrudeLoop ON_BrepExtrudeEdge ON_BrepExtrudeVertex ON_BrepConeFace ON_BrepConeLoop ON_BrepConeEdge Remarks: The new faces are appended to brep.m_F[].
ON_DECL bool ON_BrepConeLoop | ( | ON_Brep & | brep, |
int | loop_index, | ||
ON_3dPoint | apex_point | ||
) |
Description: Cone a loop in a brep. Parameters: brep - [in/out] loop_index - [in] index of face to extrude. apex_point - [in] apex of cone. Returns: @untitled table 0 failure 1 successful See Also: ON_BrepExtrudeFace ON_BrepExtrudeLoop ON_BrepExtrudeEdge ON_BrepExtrudeVertex ON_BrepConeFace ON_BrepConeLoop ON_BrepConeEdge Remarks: The new faces are appended to brep.m_F[].
ON_DECL ON_Brep* ON_BrepCylinder | ( | const ON_Cylinder & | cylinder, |
bool | bCapBottom, | ||
bool | bCapTop, | ||
ON_Brep * | pBrep = nullptr |
||
) |
Description: Get an ON_Brep definition of a cylinder. Parameters: cylinder - [in] cylinder.IsFinite() must be true bCapBottom - [in] if true end at cylinder.m_height[0] should be capped bCapTop - [in] if true end at cylinder.m_height[1] should be capped pBrep - [in] if not nullptr, this brep will be used and returned. Returns: An ON_Brep representation of the cylinder with a single face for the cylinder, an edge along the cylinder seam, and vertices at the bottom and top ends of this seam edge. The optional bottom/top caps are single faces with one circular edge starting and ending at the bottom/top vertex.
Description: Extrude a brep Parameters: brep - [in/out] path_curve - [in] path to extrude along. bCap - [in] if true, the extrusion is capped with a translation of the input brep. Returns: True if successful. See Also: ON_BrepExtrudeFace ON_BrepExtrudeLoop ON_BrepExtrudeEdge ON_BrepExtrudeVertex ON_BrepConeFace ON_BrepConeLoop ON_BrepConeEdge Remarks: The new faces are appended to brep.m_F[]. It is the caller's responsibility to insure the result does not self intersect.
Description: Extrude an edge in a brep. Parameters: brep - [in/out] edge_index - [in] index of face to extrude. path_curve - [in] path to extrude along. Returns: @untitled table 0 failure 1 successful See Also: ON_BrepExtrude ON_BrepExtrudeFace ON_BrepExtrudeLoop ON_BrepExtrudeVertex ON_BrepConeFace ON_BrepConeLoop ON_BrepConeEdge Remarks: The new face is appended to brep.m_F[].
ON_DECL int ON_BrepExtrudeFace | ( | ON_Brep & | brep, |
int | face_index, | ||
const ON_Curve & | path_curve, | ||
bool | bCap = true |
||
) |
Description: Extrude a face in a brep. Parameters: brep - [in/out] face_index - [in] index of face to extrude. path_curve - [in] path to extrude along. bCap - [in] if true, the extrusion is capped with a translation of the face being extruded. Example: Extrude a face along a vector.
ON_Brep brep = ...; int face_index = ...; ON_3dVector v = ...; ON_LineCurve line_curve( ON_Line( ON_3dPoint::Origin, vector ) ); ON_BrepExtrudeFace( brep, face_index, line_curve, true );
Returns: @untitled table 0 failure 1 successful - no cap added 2 successful - cap added as last face See Also: ON_BrepExtrude ON_BrepExtrudeLoop ON_BrepExtrudeEdge ON_BrepExtrudeVertex ON_BrepConeFace ON_BrepConeLoop ON_BrepConeEdge Remarks: The new faces are appended to brep.m_F[]. If a cap is requested it is the last face in the returned brep.m_F[]
ON_DECL int ON_BrepExtrudeLoop | ( | ON_Brep & | brep, |
int | loop_index, | ||
const ON_Curve & | path_curve, | ||
bool | bCap = true |
||
) |
Description: Extrude a loop in a brep. Parameters: brep - [in/out] loop_index - [in] index of face to extrude. path_curve - [in] path to extrude along. bCap - [in] if true and the loop is closed, the extrusion is capped. Returns: @untitled table 0 failure 1 successful - no cap added 2 successful - cap added as last face See Also: ON_BrepExtrude ON_BrepExtrudeFace ON_BrepExtrudeEdge ON_BrepExtrudeVertex ON_BrepConeFace ON_BrepConeLoop ON_BrepConeEdge Remarks: The new faces are appended to brep.m_F[]. If a cap is requested it is the last face in the returned brep.m_F[]
Description: Extrude a vertex in a brep. Parameters: brep - [in/out] vertex_index - [in] index of vertex to extrude. path_curve - [in] path to extrude along. Returns: @untitled table 0 failure 1 successful See Also: ON_BrepExtrude ON_BrepExtrudeFace ON_BrepExtrudeLoop ON_BrepExtrudeEdge ON_BrepConeFace ON_BrepConeLoop ON_BrepConeEdge Remarks: The new vertex is appended to brep.m_V[] and the new edge is appended to brep.m_E[].
ON_DECL ON_Brep* ON_BrepFromMesh | ( | const ON_MeshTopology & | mesh_topology, |
bool | bTrimmedTriangles = true , |
||
ON_Brep * | pBrep = nullptr |
||
) |
brep construction tools Description: Create a brep representation of a mesh. Parameters: mesh_topology - [in] bTrimmedTriangles - [in] if true, triangles in the mesh will be represented by trimmed planes in the brep. If false, triangles in the mesh will be represented by untrimmed singular bilinear NURBS surfaces in the brep. pBrep - [in] If not nullptr, this the mesh representation will be put into this brep. Example:
ON_Mesh mesh = ...; ON_Brep* pBrep = ON_BrepFromMesh( mesh.Topology() ); ... delete pBrep;
See Also ON_BrepFromMesh( const ON_Mesh& mesh, ... );
ON_DECL ON_Brep* ON_BrepFromMeshWithNgons | ( | const ON_MeshTopology & | mesh_topology, |
bool | bTrimmedTriangles, | ||
bool | bUseNgonsIfTheyExist, | ||
double | tolerance, | ||
ON_Brep * | pBrep = nullptr |
||
) |
Description: Create a brep representation of a mesh. Parameters: mesh_topology - [in] bTrimmedTriangles - [in] if true, triangles in the mesh will be represented by trimmed planes in the brep. If false, triangles in the mesh will be represented by untrimmed singular bilinear NURBS surfaces in the brep. bUseNgonsIfTheyExist - [in] if the mesh has ngons and bUseNgonsIfTheyExist is true then trimmed planes will be created for the ngons regardless of bTrimmedTriangles. tolerance - [in] used to determine if an ngon is planar. pBrep - [in] If not nullptr, this the mesh representation will be put into this brep. Example:
ON_Mesh mesh = ...; ON_Brep* pBrep = ON_BrepFromMesh( mesh.Topology() ); ... delete pBrep;
See Also ON_BrepFromMesh( const ON_Mesh& mesh, ... );
These merge adjacent faces that have the same underlying surface.
ON_DECL ON_Brep* ON_BrepQuadSphere | ( | const ON_3dPoint & | Center, |
double | radius, | ||
ON_Brep * | pBrep = nullptr |
||
) |
Description: Get an ON_Brep definition of a sphere. Parameters: Center - [in] Center of sphere radius - [int] Radius of sphere pBrep - [in] if not nullptr, this brep will be used and returned. Returns: An ON_Brep representation of the sphere with six similar faces, each an untrimmed rational quadratic surface
ON_DECL bool ON_BrepRemoveSlits | ( | ON_BrepFace & | F | ) |
This removes all slit trims from F that are not joined to another face. Unlike ON_Brep::RemoveSlits(), this will remove slit pairs from a loop in cases that will result in the creation of more loops. Caller is responsible for calling ON_Brep::Compact() to get rid of deleted trims and loops.
ON_DECL ON_Brep* ON_BrepRevSurface | ( | ON_RevSurface *& | pRevSurface, |
bool | bCapStart, | ||
bool | bCapEnd, | ||
ON_Brep * | pBrep = nullptr |
||
) |
Description: Get an ON_Brep form of a surface of revolution. Parameters: pRevSurface - [in] pointer to a surface of revolution. The brep will manage this pointer and delete it in ~ON_Brep. bCapStart - [in] if true, the start of the revolute is not on the axis of revolution, and the surface of revolution is closed, then a circular cap will be added to close of the hole at the start of the revolute. bCapEnd - [in] if true, the end of the revolute is not on the axis of revolution, and the surface of revolution is closed, then a circular cap will be added to close of the hole at the end of the revolute. pBrep - [in] if not nullptr, this brep will be used and returned. Returns: @untitled table true successful false brep cannot be created from this surface. Remarks: The surface class must be created with new because it will be destroyed with the delete operator in ~ON_Brep.
ON_DECL ON_Brep* ON_BrepTrimmedPlane | ( | const ON_Plane & | plane, |
const ON_Curve & | boundary, | ||
ON_Brep * | pBrep = nullptr |
||
) |
Description: Create an ON_Brep trimmed plane. Parameters: plane - [in] plane that will be trimmed. boundary - [in] a simple (no self intersections) closed curve that defines the outer boundary of the trimmed plane. This curve is copied for use in the brep. pBrep - [in] if not nullptr, this brep will be used and returned. Returns: An ON_Brep representation of the trimmed plane with a single face. See Also: ON_Brep::NewPlanarFaceLoop()
ON_DECL ON_Brep* ON_BrepTrimmedPlane | ( | const ON_Plane & | plane, |
ON_SimpleArray< ON_Curve * > & | boundary, | ||
bool | bDuplicateCurves = true , |
||
ON_Brep * | pBrep = nullptr |
||
) |
Description: Get an ON_Brep definition of a trimmed plane. Parameters: plane - [in] plane that will be trimmed. boundary - [in] a list of 3d curves that form a simple (no self intersections) closed curve that defines the outer boundary of the trimmed plane. bDuplicateCurves - [in] if true, duplicates of the curves in the boundary array are used in the brep. If false the curves in the boundary array are used in the brep and the brep's destructor will delete the curves. pBrep - [in] if not nullptr, this brep will be used and returned. Returns: An ON_Brep representation of the trimmed plane with a single face. See Also: ON_Brep::NewPlanarFaceLoop()
ON_DECL ON_Brep* ON_BrepWedge | ( | const ON_3dPoint * | corners, |
ON_Brep * | pBrep = nullptr |
||
) |
Description: Get an ON_Brep definition of a wedge. Parameters: corners - [in] 6 points defining the box corners arranged as the vN labels indicate.
/v5 /|\ / | \ e5 | e4 / e8 \ /__e3_____\ v3| | |v4 | | | | /v2 | e6 / \ e7 | / \ | | e2 e1| |/ \| /____e0___\ v0 v1
pBrep - [in] if not nullptr, this brep will be used and returned. Returns: An ON_Brep representation of the wedge with topology
edge vertices m_E[ 0] m_V[0], m_V[1] m_E[ 1] m_V[1], m_V[2] m_E[ 2] m_V[2], m_V[0] m_E[ 3] m_V[3], m_V[4] m_E[ 4] m_V[4], m_V[5] m_E[ 5] m_V[5], m_V[0] m_E[ 6] m_V[0], m_V[3] m_E[ 7] m_V[1], m_V[4] m_E[ 8] m_V[2], m_V[5]
face boundary edges m_F[0] +m_E[0] +m_E[7] -m_E[3] -m_E[6] m_F[1] +m_E[1] +m_E[8] -m_E[4] -m_E[7] m_F[2] +m_E[2] +m_E[6] -m_E[5] -m_E[8] m_F[3] +m_E[3] +m_E[8] -m_E[7] -m_E[11] m_F[4] -m_E[2] -m_E[1] -m_E[0] m_F[5] +m_E[3] +m_E[4] +m_E[5]
const ON_DECL ON_2dex ON_BsplineControlPointSpans | ( | int | order, |
int | control_point_count, | ||
int | control_point_index | ||
) |
Get the indices of the B-spline spans where the specified control point is active. Note that a B-spline with n control points has (n-degree) many spans. If 0 <= span_index < (n-degree), then CV(span_index), ..., CV(span_index+degree) and {knot[span_index], ..., knot[span_index+2*degree-1]} are the control points and knots that are active in that span. The domain of the span is [knot[span_index+degree-1], knot[span_index+degree]].
order | B-spline order. order >= 2 (order = degree + 1) |
control_point_count | Number of B-spline control points. control_point_count >= order |
control_point_index | 0 <= control_point_index < control_point_count |
const ON_DECL ON_Interval ON_BsplineControlPointSupport | ( | int | order, |
int | control_point_count, | ||
const double * | knots, | ||
int | control_point_index | ||
) |
Get the interval in the B-spline domain where the control point is active. The domain = [knots[order-2], knots[control_point_count-1]]. The returned interval will be in domain and are the parameters where the control point influnces the value of the B-spline.
order | Order of the B-spline knot vector. order >= 2 (order = degree + 1) |
control_point_count | Number of B-spline control points. control_point_count >= order |
knots | knots[] is the B-spline knot vector and is an array of (order + control_point_count - 2) doubles. |
control_point_index | 0 <= control_point_index < control_point_count |
ON_DECL bool ON_ChangeRationalBezierCurveWeights | ( | int | dim, |
int | order, | ||
int | cvstride, | ||
double * | cv, | ||
int | i0, | ||
double | w0, | ||
int | i1, | ||
double | w1 | ||
) |
Description: Use a combination of scaling and reparameterization to set two rational Bezier weights to specified values. Parameters: dim - [in] order - [in] cvstride - [in] ( >= dim+1) cv - [in/out] homogeneous rational control points i0 - [in] w0 - [in] i1 - [in] w1 - [in] The i0-th cv will have weight w0 and the i1-th cv will have weight w1. If v0 and v1 are the cv's input weights, then v0, v1, w0 and w1 must all be nonzero, and w0*v0 and w1*v1 must have the same sign. Returns: true if successful Remarks: The equations s * r^i0 = w0/v0 s * r^i1 = w1/v1 determine the scaling and reparameterization necessary to change v0,v1 to w0,w1.
If the input Bezier has control vertices {B_0, ..., B_d}, then the output Bezier has control vertices {s*B_0, ... s*r^i * B_i, ..., s*r^d * B_d}.
ON_DECL bool ON_ChangeRationalNurbsCurveEndWeights | ( | int | dim, |
int | order, | ||
int | cv_count, | ||
int | cvstride, | ||
double * | cv, | ||
double * | knot, | ||
double | w0, | ||
double | w1 | ||
) |
Description: Use a combination of scaling and reparameterization to set the end weights to the specified values. This Parameters: dim - [in] order - [in] cvstride - [in] (>=dim+1) cv - [in/out] homogeneous rational control points knot - in/out w0 - [in] w1 - [in] The first cv will have weight w0 and the last cv will have weight w1. If v0 and v1 are the cv's input weights, then v0, v1, w0 and w1 must all be nonzero, and w0*v0 and w1*v1 must have the same sign. Returns: true if successful See Also: ON_ReparameterizeRationalNurbsCurve
ON_DECL bool ON_ClampKnotVector | ( | int | , |
int | , | ||
double * | , | ||
int | |||
) |
ON_DECL bool ON_ClampKnotVector | ( | int | , |
int | , | ||
int | , | ||
int | , | ||
double * | , | ||
double * | , | ||
int | |||
) |
Description: Expert user function to get a pointer to a class's vtable. Parameters: pClass - [in] a class that has a vtable. If you pass a class that does not have a vtable, then the returned pointer is garbage. Returns: A pointer to the vtable.
ON_DECL ON__UINT64 ON_ClearWorkerThreadContext | ( | ) |
Description: Clear all worker thread context information. Returns: 0: No worker thread context was set. >0: Serial number of the worker thread context that was cleared.
Description: Determine the orientation (counterclockwise or clockwise) of a closed planar curve. Parameters: curve - [in] simple (no self intersections) closed planar curve xform - [in] Transformation to map the curve to the xy plane. If the curve is parallel to the xy plane, you may pass nullptr. plane - [in] If curve is on plane then determine the orientation in relation to plane's orientation. Returns: +1: The curve's orientation is counter clockwise in the xy plane. -1: The curve's orientation is clockwise in the xy plane. 0: Unable to compute the curve's orientation.
ON_DECL double ON_ClosestPointAngle | ( | const ON_Line & | , |
const ON_Curve & | , | ||
ON_Interval | , | ||
const ON_3dPoint & | , | ||
ON_3dPoint & | , | ||
double * | , | ||
double * | |||
) |
ON_DECL bool ON_ClosestPointBetweenQuads | ( | const ON_3dPoint | A[4], |
const ON_3dPoint | B[4], | ||
double | a[4], | ||
double | b[4] | ||
) |
Description: Finds the barycentric coordinates of a pair of points on two triangles that are as close as any other pair. Parameters: A - [in] first quad corners, in order around the quad B - [in] second quad corners, in order around the quad a - [out] barycentric coordinates for quad A b - [out] barycentric coordinates for quad B
If ON_ClosestPointBetweenQuads() returns true, then (a[0])*A[0] + (a[1])*A[1] + (a[2])*A[2] + (a[3])*A[3] is the point on quad A and (b[0])*B[0] + (b[1])*B[1] + (b[2])*B[2] + (b[3])*B[3] is the point on quad B. It is always the case that a[0]+a[1]+a[2]+a[3] = 1, a[0]>=0, a[1]>0, a[2]>0, a[3]>0. b[0]+b[1]+b[2]+b[3] = 1, b[0]>=0, b[1]>0, b[2]>0, b[3]>0 The surface of Quad is defined to be the two triangle surfaces, <Quad[0], Quad[1], Quad[2]> and <Quad[2], Quad[3], Quad[0]>. It will always be the case that either q[1]=0 or q[3]=0.
Returns: True if successful.
ON_DECL bool ON_ClosestPointBetweenTriangleAndQuad | ( | const ON_3dPoint | Tri[3], |
const ON_3dPoint | Quad[4], | ||
double | t[3], | ||
double | q[4] | ||
) |
Description: Finds the barycentric coordinates of a pair of points on two triangles that are as close as any other pair. Parameters: Tri - [in] triangle corners Quad - [in] quad corners in order around the quad t - [out] barycentric coordinates for Tri q - [out] barycentric coordinates for Quad
If ON_ClosestPointBetweenTriangleAndQuad() returns true, then (t[0])*Tri[0] + (t[1])*Tri[1] + (t[2])*Tri[2] is the point on Tri and (q[0])*Quad[0] + (q[1])*Quad[1] + (q[2])*Quad[2] + (q[3])*Quad[3] is the point on Quad. It is always the case that t[0]+t[1]+t[2] = 1, t[0]>=0, t[1]>0, t[2]>0, q[0]+q[1]+q[2]+q[3] = 1, q[0]>=0, q[1]>0, q[2]>0, q[3]. The surface of Quad is defined to be the two triangle surfaces, <Quad[0], Quad[1], Quad[2]> and <Quad[2], Quad[3], Quad[0]>. It will always be the case that either q[1]=0 or q[3]=0.
Returns: True if successful.
ON_DECL bool ON_ClosestPointBetweenTriangles | ( | const ON_3dPoint | A[3], |
const ON_3dPoint | B[3], | ||
double | a[3], | ||
double | b[3] | ||
) |
Description: Finds the barycentric coordinates of a pair of points on two triangles that are as close as any other pair. Parameters: A - [in] first triangle corners B - [in] second triangle corners a - [out] barycentric coordinates for triangle A b - [out] barycentric coordinates for triangle B
If ON_ClosestPointBetweenTriangles() returns true, then (a[0])*A[0] + (a[1])*A[1] + (a[2])*A[2] is the point on triangle A and (b[0])*B[0] + (b[1])*B[1] + (b[2])*B[2] is the point on triangle B. It is always the case that a[0]+a[1]+a[2] = 1, a[0]>=0, a[1]>0, a[2]>0, b[0]+b[1]+b[2] = 1, b[0]>=0, b[1]>0, b[2]>0
Returns: True if successful.
ON_DECL bool ON_ClosestPointToTriangle | ( | ON_3dPoint | A, |
ON_3dPoint | B, | ||
ON_3dPoint | C, | ||
ON_3dPoint | P, | ||
double * | a, | ||
double * | b, | ||
double * | c | ||
) |
Description: Finds the barycentric coordinates of the point on a triangle that is closest to P. Parameters: A - [in] triangle corner B - [in] triangle corner C - [in] triangle corner P - [in] point to test a - [out] barycentric coordinate b - [out] barycentric coordinate c - [out] barycentric coordinate If ON_ClosestPointToTriangle() returns true, then (*a)*A + (*b)*B + (*c)*C is the point on the triangle's plane that is closest to P. It is always the case that *a + *b + *c = 1, but this function will return negative barycentric coordinate if the point on the plane is not inside the triangle. Returns: True if the triangle is not degenerate. False if the triangle is degenerate; in this case the returned closest point is the input point that is closest to P.
ON_DECL bool ON_ClosestPointToTriangleFast | ( | const ON_3dPoint & | A, |
const ON_3dPoint & | B, | ||
const ON_3dPoint & | C, | ||
ON_3dPoint | P, | ||
double * | a, | ||
double * | b, | ||
double * | c | ||
) |
Description: Finds the barycentric coordinates of the point on a triangle that is closest to P. Parameters: A - [in] triangle corner B - [in] triangle corner C - [in] triangle corner P - [in] point to test a - [out] barycentric coordinate b - [out] barycentric coordinate c - [out] barycentric coordinate If ON_ClosestPointToTriangle() returns true, then (*a)*A + (*b)*B + (*c)*C is the point on the triangle's plane that is closest to P. It is always the case that *a + *b + *c = 1, but this function will return negative barycentric coordinate if the point on the plane is not inside the triangle. Returns: True if the triangle is not degenerate. False if the triangle is degenerate; in this case the returned closest point is the input point that is closest to P.
Description: Looks for segments that are shorter than tolerance that can be combined. For NURBS of degree greater than 1, spans are combined by removing knots. Similarly for NURBS segments of polycurves. Otherwise, crv.RemoveShortSegments() is called. Does not change the domain, but it will change the relative parameterization. Parameters: tolerance - [in] Returns: True if short segments were combined or removed. False otherwise.
|
static |
Description: Compare function for Sort and Search methods. Returns: -1 if *b < *a is true 1 if *a < *b is true 0 if neither *a < *b nor *b < *a is true Details: Use this template functions to sort ON_SimpleArray and ON_ClassArray objects into decreasing order. The elements of the arrays must be a type with an operator < defined. In particular it works with built in types like double, int and pointers. Example:
class C { public: ... bool operator<(const C&) const; }; ... ON_ClassArray<C> A; A = ...;
/ Sort A in descrasing order A.QuickSort( ON_CompareDecreasing<C> );
See Also: ON_CompareIncreasing
ON_DECL int ON_CompareDouble | ( | double | a, |
double | b | ||
) |
Returns: -1: a < b or a is not a nan and b is a nan +1: a > b or a is a nan and b is a not nan 0: a == b or both a and b are nans
ON_DECL int ON_CompareDoubleArray | ( | size_t | count, |
const double * | a, | ||
const double * | b | ||
) |
ON_DECL int ON_CompareFloat | ( | float | a, |
float | b | ||
) |
Returns: -1: a < b or a is not a nan and b is a nan +1: a > b or a is a nan and b is a not nan 0: a == b or both a and b are nans
|
static |
Description: Compare function for Sort and Search methods. Returns: -1 if *a < *b is true 1 if *b < *a is true 0 if neither *a <*b nor *b<*a is true Details: Use this template functions to sort ON_SimpleArray and ON_ClassArray objects into increasing order. The elements of the arrays must be a type with an operator < defined. In particular it works with built in types like double, int and pointers. Example:
ON_SimpleArray<int> A; A = ...;
/ Sort A in increasing order A.QuickSort( ON_CompareIncreasing<double> );
See Also: ON_CompareDecreasing
ON_DECL int ON_CompareKnotVector | ( | int | , |
int | , | ||
const double * | , | ||
int | , | ||
int | , | ||
const double * | |||
) |
ON_DECL int ON_ComparePoint | ( | int | dim, |
bool | israt, | ||
const double * | cv0, | ||
const double * | cv1 | ||
) |
dim | returns -1: first < second 0: first == second +1: first > second dim (>=0) |
israt | true for rational CVs |
cv0 | first CV |
cv1 | second CV |
ON_DECL int ON_ComparePointList | ( | int | , |
bool | , | ||
int | , | ||
int | , | ||
const double * | , | ||
int | , | ||
const double * | |||
) |
ON_DECL ON_ComponentState ON_ComponentStateFromUnsigned | ( | unsigned int | state_as_unsigned | ) |
ON_DECL ON_Mesh* ON_ControlPolygonMesh | ( | const ON_NurbsSurface & | nurbs_surface, |
bool | bCleanMesh, | ||
ON_Mesh * | input_mesh = nullptr |
||
) |
Description: Calculate a mesh representation of the NURBS surface's control polygon. Parameters: nurbs_surface - [in] bCleanMesh - [in] If true, then degenerate quads are cleaned up to be triangles. Surfaces with singular sides are a common source of degenerate qauds. input_mesh - [in] If nullptr, then the returned mesh is created by a class to new ON_Mesh(). If not null, then this mesh will be used to store the control polygon. Returns: If successful, a pointer to a mesh.
ON_DECL int ON_ConvertMSMBCPToWideChar | ( | ON__UINT32 | windows_code_page, |
const char * | sMBCS, | ||
int | sMBCS_count, | ||
wchar_t * | sWideChar, | ||
int | sWideChar_capacity, | ||
unsigned int * | error_status | ||
) |
Description: Convert a string from a Microsoft multibyte code page encoding to a wide string using UTF-8 / UTF-16 / UTF-32 encoding (depending on the size of wchar_t). This function is designed to be used to parse portions of rich text RTF in ON_TextContent, strings from outside sources with known MBCS encodings, and some user interface code.
Opennurbs assumes all other char strings are UTF-8 encoded.
If 1 = sizeof(wchar_t), then UTF-8 encoding is used for the output string.
If 2 = sizeof(wchar_t), then UTF-16 encoding is used for the output string. This is the case with current versions of Microsoft Windows.
If 4 = sizeof(wchar_t), then UTF-32 encoding is used for the output string. This is the case with current versions of Apple OSX.
Parameters: windows_code_page - [in] The windows code page specifies the encoding of the sMBCS string.
sMBCS - [in] Windows multibyte string with encoding identified by windows_code_page.
sMBCS_count - [in] If sMBCS_count >= 0, then it specifies the number of char elements (bytes) in sMBCS[] to convert.
If sMBCS_count == -1, then sMBCS must be a null terminated string and all the elements up to the first null element are converted.
sWideChar - [out] If sWideChar is not null and sWideChar_count > 0, then the output string is returned in this buffer. If there is room for the null terminator, the converted string will be null terminated. The null terminator is never included in the count of returned by this function. The converted string is in the CPU's native byte order. No byte order mark is prepended.
sWideChar_capacity - [in] If sWideChar_capacity > 0, then it specifies the number of available wchar_t elements in the sWideChar[] buffer.
If sWideChar_count == 0, then the sWideChar parameter is ignored.
error_status - [out] If error_status is not null, then bits of *error_status are set to indicate the success or failure of the conversion.
When the error_mask parameter is used to used to mask some conversion errors, multiple bits may be set. 0: Successful conversion with no errors. 1: The input parameters were invalid. This error cannot be masked. 2: The output buffer was not large enough to hold the converted string. As much conversion as possible is performed in this case and the error cannot be masked. 16: An illegal encoding sequence occurred. The illegal sequence is replaced with a single ON_wString::ReplacementCharacter in the output string and parsing continues.
Returns: If sWideChar_capacity > 0, the return value is the number of wchar_t elements written to sWideChar[]. When the return value < sWideChar_capacity, a null terminator is written to sWideChar[return value].
If sWideChar_count == 0, the return value is the minimum number of wchar_t elements that are needed to hold the converted string. The return value does not include room for a null terminator.
Increment the return value by one if you want to have an element to use for a null terminator.
ON_DECL void ON_ConvertNurbSpanToBezier | ( | int | , |
int | , | ||
int | , | ||
double * | , | ||
const double * | , | ||
double | , | ||
double | |||
) |
ON_DECL int ON_ConvertUTF16ToUTF16 | ( | int | bTestByteOrder, |
const ON__UINT16 * | sInputUTF16, | ||
int | sInputUTF16_count, | ||
ON__UINT16 * | sOutputUTF16, | ||
int | sOutputUTF16_count, | ||
unsigned int * | error_status, | ||
unsigned int | error_mask, | ||
ON__UINT32 | error_code_point, | ||
const ON__UINT16 ** | sNextInputUTF16 | ||
) |
Description: Convert a unicode string from a UTF-16 encoded ON__UINT16 array into a UTF-16 encoded ON__UINT16 array. This is not simply a copy in the case when the input has a byte order mark (BOM), different byte ordering or contains errors. This function can be used to validate UTF-16 encoded strings.
Parameters: bTestByteOrder - [in] If bTestByteOrder is true and the the input buffer is a byte order mark (BOM), then the BOM is skipped. It the value of the BOM is byte swapped, then subsequent input elements are byte swapped before being decoded. Specifically:
sInputUTF16 - [in] UTF-16 encoded string to convert.
sInputUTF16_count - [in] If sInputUTF16_count >= 0, then it specifies the number of ON__UINT16 elements in sInputUTF16[] to convert.
If sInputUTF16_count == -1, then sInputUTF16 must be a null terminated array and all the elements up to the first null element are converted.
sOutputUTF16 - [out] If sOutputUTF16 is not null and sOutputUTF16_count > 0, then the output UTF-16 encoded string is returned in this buffer. If there is room for the null terminator, the converted string will be null terminated. The null terminator is never included in the count returned by this function. No byte order mark is prepended.
sOutputUTF16_count - [in] If sOutputUTF16_count > 0, then it specifies the number of available ON__UINT16 elements in the sOutputUTF16[] buffer.
If sOutputUTF16_count == 0, then the sOutputUTF16 parameter is ignored.
error_status - [out] If error_status is not null, then bits of *error_status are set to indicate the success or failure of the conversion.
When the error_mask parameter is used to used to mask some conversion errors, multiple bits may be set. 0: Successful conversion with no errors. 1: The input parameters were invalid. This error cannot be masked. 2: The output buffer was not large enough to hold the converted string. As much conversion as possible is performed in this case and the error cannot be masked. 4: When parsing a UTF-8 or UTF-32 string, the values of two consecutive encoding sequences formed a valid UTF-16 surrogate pair.
This error is masked if 0 != (4 & m_error_mask). If the error is masked, then the surrogate pair is decoded, the value of the resulting unicode code point is used, and parsing continues. 8: An overlong UTF-8 encoding sequence was encountered and the value of the overlong sUTF-8 sequence was a valid unicode code point.
This error is masked if 0 != (8 & m_error_mask). If the error is masked, then the unicode code point is used and parsing continues. 16: An illegal UTF-8, UTF-16 or UTF-32 encoding sequence occurred or an invalid unicode code point value resulted from decoding a UTF-8 sequence. This error is masked if 0 != (16 & m_error_mask). If the error is masked and the value of error_code_point is a valid unicode code point, then error_code_point is encoded in the output string and parsing continues.
error_mask - [in] If 0 != (error_mask & 4), then type 4 errors are masked. If 0 != (error_mask & 8), then type 8 errors are masked. If 0 != (error_mask & 16) and error_code_point is a valid unicode code point value, then type 16 errors are masked.
error_code_point - [in] Unicode code point value to use in when masking type 16 errors. If 0 == (error_mask & 16), then this parameter is ignored. ON_UnicodeCodePoint::ON_ReplacementCharacter (U+FFFD) is a popular choice for the error_code_point value.
sNextInputUTF16 - [out] If sNextInputUTF16 is not null, then *sNextInputUTF16 points to the first element in the input sInputUTF16[] buffer that was not converted.
If an error occurs and is not masked, then *sNextInputUTF16 points to the element of sInputUTF16[] where the conversion failed. If no errors occur or all errors are masked, then sNextInputUTF16 points to sInputUTF16 + sInputUTF16_count.
Returns: If sOutputUTF16_count > 0, the return value is the number of ON__UINT16 elements written to sOutputUTF16[]. When the return value < sOutputUTF16_count, a null terminator is written to sOutputUTF16[return value].
If sOutputUTF16_count == 0, the return value is the minimum number of ON__UINT16 elements that are needed to hold the converted string. The return value does not include room for a null terminator.
Increment the return value by one if you want to have an element to use for a null terminator.
ON_DECL int ON_ConvertUTF16ToUTF32 | ( | int | bTestByteOrder, |
const ON__UINT16 * | sUTF16, | ||
int | sUTF16_count, | ||
unsigned int * | sUTF32, | ||
int | sUTF32_count, | ||
unsigned int * | error_status, | ||
unsigned int | error_mask, | ||
ON__UINT32 | error_code_point, | ||
const ON__UINT16 ** | sNextUTF16 | ||
) |
Description: Convert a unicode string from a UTF-16 encoded ON__UINT16 array into a UTF-32 encoded ON__UINT32 array.
Parameters: bTestByteOrder - [in] If bTestByteOrder is true and the the input buffer is a byte order mark (BOM), then the BOM is skipped. It the value of the BOM is byte swapped, then subsequent input elements are byte swapped before being decoded. Specifically:
sUTF16 - [in] UTF-16 string to convert.
If bTestByteOrder is true and the first element of sUTF16[] is 0xFEFF, then this element is skipped and it is assumed that sUTF16[] is in the CPU's native byte order.
If bTestByteOrder is true and the first element of sUTF16[] is 0xFFFE, then this element is skipped and it is assumed that sUTF16[] is not in the CPU's native byte order and bytes are swapped before characters are converted.
If bTestByteOrder is false or the first character of sUTF16[] is neither 0xFEFF nor 0xFFFE, then the sUTF16 string must match the CPU's byte order.
sUTF16_count - [in] If sUTF16_count >= 0, then it specifies the number of ON__UINT16 elements in sUTF16[] to convert.
If sUTF16_count == -1, then sUTF16 must be a null terminated string and all the elements up to the first null element are converted.
sUTF32 - [out] If sUTF32 is not null and sUTF32_count > 0, then the UTF-32 encoded string is returned in this buffer. If there is room for the null terminator, the converted string will be null terminated. The null terminator is never included in the count of returned by this function. The converted string is in the CPU's native byte order. No byte order mark is prepended.
sUTF32_count - [in] If sUTF32_count > 0, then it specifies the number of available ON__UINT32 elements in the sUTF32[] buffer.
If sUTF32_count == 0, then the sUTF32 parameter is ignored.
error_status - [out] If error_status is not null, then bits of *error_status are set to indicate the success or failure of the conversion.
When the error_mask parameter is used to used to mask some conversion errors, multiple bits may be set. 0: Successful conversion with no errors. 1: The input parameters were invalid. This error cannot be masked. 2: The output buffer was not large enough to hold the converted string. As much conversion as possible is performed in this case and the error cannot be masked. 4: When parsing a UTF-8 or UTF-32 string, the values of two consecutive encoding sequences formed a valid UTF-16 surrogate pair.
This error is masked if 0 != (4 & m_error_mask). If the error is masked, then the surrogate pair is decoded, the value of the resulting unicode code point is used, and parsing continues. 8: An overlong UTF-8 encoding sequence was encountered and the value of the overlong sUTF-8 sequence was a valid unicode code point.
This error is masked if 0 != (8 & m_error_mask). If the error is masked, then the unicode code point is used and parsing continues. 16: An illegal UTF-8, UTF-16 or UTF-32 encoding sequence occurred or an invalid unicode code point value resulted from decoding a UTF-8 sequence. This error is masked if 0 != (16 & m_error_mask). If the error is masked and the value of error_code_point is a valid unicode code point, then error_code_point is encoded in the output string and parsing continues.
error_mask - [in] If 0 != (error_mask & 4), then type 4 errors are masked. If 0 != (error_mask & 8), then type 8 errors are masked. If 0 != (error_mask & 16) and error_code_point is a valid unicode code point value, then type 16 errors are masked.
error_code_point - [in] Unicode code point value to use in when masking type 16 errors. If 0 == (error_mask & 16), then this parameter is ignored. ON_UnicodeCodePoint::ON_ReplacementCharacter (U+FFFD) is a popular choice for the error_code_point value.
sNextUTF16 - [out] If sNextUTF16 is not null, then *sNextUTF16 points to the first element in the input sUTF16[] buffer that was not converted.
If an error occurs and is not masked, then *sNextUTF16 points to the element of sUTF16[] where the conversion failed. If no errors occur or all errors are masked, then *sNextUTF16 points to sUTF16 + sUTF16_count.
Returns: If sUTF32_count > 0, the return value is the number of ON__UINT32 elements written to sUTF32[]. When the return value < sUTF32_count, a null terminator is written to sUTF32[return value].
If sUTF32_count == 0, the return value is the minimum number of ON__UINT32 elements that are needed to hold the converted string. The return value does not include room for a null terminator.
Increment the return value by one if you want to have an element to use for a null terminator.
ON_DECL int ON_ConvertUTF16ToUTF8 | ( | int | bTestByteOrder, |
const ON__UINT16 * | sUTF16, | ||
int | sUTF16_count, | ||
char * | sUTF8, | ||
int | sUTF8_count, | ||
unsigned int * | error_status, | ||
unsigned int | error_mask, | ||
ON__UINT32 | error_code_point, | ||
const ON__UINT16 ** | sNextUTF16 | ||
) |
Description: Convert a unicode string from a UTF-16 encoded ON__UINT16 array into a UTF-8 encoded char array.
Parameters: bTestByteOrder - [in] If bTestByteOrder is true and the the input buffer is a byte order mark (BOM), then the BOM is skipped. It the value of the BOM is byte swapped, then subsequent input elements are byte swapped before being decoded. Specifically:
sUTF16 - [in] UTF-16 string to convert.
If bTestByteOrder is true and the first element of sUTF16[] is 0xFEFF, then this element is skipped and it is assumed that sUTF16[] is in the CPU's native byte order.
If bTestByteOrder is true and the first element of sUTF16[] is 0xFFFE, then this element is skipped and it is assumed that sUTF16[] is not in the CPU's native byte order and bytes are swapped before characters are converted.
If bTestByteOrder is false or the first character of sUTF16[] is neither 0xFEFF nor 0xFFFE, then the sUTF16 string must match the CPU's byte order.
sUTF16_count - [in] If sUTF16_count >= 0, then it specifies the number of ON__UINT16 elements in sUTF16[] to convert.
If sUTF16_count == -1, then sUTF16 must be a null terminated string and all the elements up to the first null element are converted.
sUTF8 - [out] If sUTF8 is not null and sUTF8_count > 0, then the UTF-8 encoded string is returned in this buffer. If there is room for the null terminator, the converted string will be null terminated. The null terminator is never included in the count of returned by this function. The converted string is in the CPU's native byte order. No byte order mark is prepended.
sUTF8_count - [in] If sUTF8_count > 0, then it specifies the number of available char elements in the sUTF8[] buffer.
If sUTF8_count == 0, then the sUTF8 parameter is ignored.
error_status - [out] If error_status is not null, then bits of *error_status are set to indicate the success or failure of the conversion.
When the error_mask parameter is used to used to mask some conversion errors, multiple bits may be set. 0: Successful conversion with no errors. 1: The input parameters were invalid. This error cannot be masked. 2: The output buffer was not large enough to hold the converted string. As much conversion as possible is performed in this case and the error cannot be masked. 4: When parsing a UTF-8 or UTF-32 string, the values of two consecutive encoding sequences formed a valid UTF-16 surrogate pair.
This error is masked if 0 != (4 & m_error_mask). If the error is masked, then the surrogate pair is decoded, the value of the resulting unicode code point is used, and parsing continues. 8: An overlong UTF-8 encoding sequence was encountered and the value of the overlong sUTF-8 sequence was a valid unicode code point.
This error is masked if 0 != (8 & m_error_mask). If the error is masked, then the unicode code point is used and parsing continues. 16: An illegal UTF-8, UTF-16 or UTF-32 encoding sequence occurred or an invalid unicode code point value resulted from decoding a UTF-8 sequence. This error is masked if 0 != (16 & m_error_mask). If the error is masked and the value of error_code_point is a valid unicode code point, then error_code_point is encoded in the output string and parsing continues.
error_mask - [in] If 0 != (error_mask & 4), then type 4 errors are masked. If 0 != (error_mask & 8), then type 8 errors are masked. If 0 != (error_mask & 16) and error_code_point is a valid unicode code point value, then type 16 errors are masked.
error_code_point - [in] Unicode code point value to use in when masking type 16 errors. If 0 == (error_mask & 16), then this parameter is ignored. ON_UnicodeCodePoint::ON_ReplacementCharacter (U+FFFD) is a popular choice for the error_code_point value.
sNextUTF16 - [out] If sNextUTF16 is not null, then *sNextUTF16 points to the first element in the input sUTF16[] buffer that was not converted.
If an error occurs and is not masked, then *sNextUTF16 points to the element of sUTF16[] where the conversion failed. If no errors occur or all errors are masked, then *sNextUTF16 points to sUTF16 + sUTF16_count.
Returns: If sUTF8_count > 0, the return value is the number of char elements written to sUTF8[]. When the return value < sUTF8_count, a null terminator is written to sUTF8[return value].
If sUTF8_count == 0, the return value is the minimum number of char elements that are needed to hold the converted string. The return value does not include room for a null terminator.
Increment the return value by one if you want to have an element to use for a null terminator.
ON_DECL int ON_ConvertUTF16ToWideChar | ( | int | bTestByteOrder, |
const ON__UINT16 * | sUTF16, | ||
int | sUTF16_count, | ||
wchar_t * | sWideChar, | ||
int | sWideChar_count, | ||
unsigned int * | error_status, | ||
unsigned int | error_mask, | ||
ON__UINT32 | error_code_point, | ||
const ON__UINT16 ** | sNextUTF16 | ||
) |
Description: Convert a UTF-16 encoded string to wchar_t string using the native platform's most common encoding.
If 1 = sizeof(wchar_t), then UTF-8 encoding is used for the output string.
If 2 = sizeof(wchar_t), then UTF-16 encoding is used for the output string. This is the case with current versions of Microsoft Windows.
If 4 = sizeof(wchar_t), then UTF-32 encoding is used for the output string. This is the case with current versions of Apple OSX.
Parameters: bTestByteOrder - [in] If bTestByteOrder is true and the the input buffer is a byte order mark (BOM), then the BOM is skipped. It the value of the BOM is byte swapped, then subsequent input elements are byte swapped before being decoded. Specifically:
sUTF16 - [in] UTF-16 string to convert.
sUTF16_count - [in] If sUTF16_count >= 0, then it specifies the number of ON__UINT16 elements in sUTF16[] to convert.
If sUTF16_count == -1, then sUTF16 must be a null terminated string and all the elements up to the first null element are converted.
sWideChar - [out] If sWideChar is not null and sWideChar_count > 0, then the output string is returned in this buffer. If there is room for the null terminator, the converted string will be null terminated. The null terminator is never included in the count of returned by this function. The converted string is in the CPU's native byte order. No byte order mark is prepended.
sWideChar_count - [in] If sWideChar_count > 0, then it specifies the number of available wchar_t elements in the sWideChar[] buffer.
If sWideChar_count == 0, then the sWideChar parameter is ignored.
error_status - [out] If error_status is not null, then bits of *error_status are set to indicate the success or failure of the conversion.
When the error_mask parameter is used to used to mask some conversion errors, multiple bits may be set. 0: Successful conversion with no errors. 1: The input parameters were invalid. This error cannot be masked. 2: The output buffer was not large enough to hold the converted string. As much conversion as possible is performed in this case and the error cannot be masked. 4: When parsing a UTF-8 or UTF-32 string, the values of two consecutive encoding sequences formed a valid UTF-16 surrogate pair.
This error is masked if 0 != (4 & m_error_mask). If the error is masked, then the surrogate pair is decoded, the value of the resulting unicode code point is used, and parsing continues. 8: An overlong UTF-8 encoding sequence was encountered and the value of the overlong sUTF-8 sequence was a valid unicode code point.
This error is masked if 0 != (8 & m_error_mask). If the error is masked, then the unicode code point is used and parsing continues. 16: An illegal UTF-8, UTF-16 or UTF-32 encoding sequence occurred or an invalid unicode code point value resulted from decoding a UTF-8 sequence. This error is masked if 0 != (16 & m_error_mask). If the error is masked and the value of error_code_point is a valid unicode code point, then error_code_point is encoded in the output string and parsing continues.
error_mask - [in] If 0 != (error_mask & 4), then type 4 errors are masked. If 0 != (error_mask & 8), then type 8 errors are masked. If 0 != (error_mask & 16) and error_code_point is a valid unicode code point value, then type 16 errors are masked.
error_code_point - [in] Unicode code point value to use in when masking type 16 errors. If 0 == (error_mask & 16), then this parameter is ignored. ON_UnicodeCodePoint::ON_ReplacementCharacter (U+FFFD) is a popular choice for the error_code_point value.
sNextUTF16 - [out] If sNextUTF16 is not null, then *sNextUTF16 points to the first element in the input sUTF16[] buffer that was not converted.
If an error occurs and is not masked, then *sNextUTF8 points to the element of sUTF16[] where the conversion failed. If no errors occur or all errors are masked, then *sNextUTF16 points to sUTF16 + sUTF16_count.
Returns: If sWideChar_count > 0, the return value is the number of wchar_t elements written to sWideChar[]. When the return value < sWideChar_count, a null terminator is written to sWideChar[return value].
If sWideChar_count == 0, the return value is the minimum number of wchar_t elements that are needed to hold the converted string. The return value does not include room for a null terminator.
Increment the return value by one if you want to have an element to use for a null terminator.
ON_DECL int ON_ConvertUTF32ToUTF16 | ( | int | bTestByteOrder, |
const ON__UINT32 * | sUTF32, | ||
int | sUTF32_count, | ||
ON__UINT16 * | sUTF16, | ||
int | sUTF16_count, | ||
unsigned int * | error_status, | ||
unsigned int | error_mask, | ||
ON__UINT32 | error_code_point, | ||
const ON__UINT32 ** | sNextUTF32 | ||
) |
Description: Convert a unicode string from a UTF-32 encoded ON__UINT32 array into a UTF-16 encoded ON__UINT16 array.
Parameters: bTestByteOrder - [in] If bTestByteOrder is true and the the input buffer is a byte order mark (BOM), then the BOM is skipped. It the value of the BOM is byte swapped, then subsequent input elements are byte swapped before being decoded. Specifically:
sUTF32 - [in] UTF-32 string to convert.
If bTestByteOrder is true and the first element of sUTF32[] is 0x0000FEFF, then this element is skipped and it is assumed that sUTF32[] is in the CPU's native byte order.
If bTestByteOrder is true and the first element of sUTF32[] is 0xFFFE0000, then this element is skipped and it is assumed that sUTF32[] is not in the CPU's native byte order and bytes are swapped before characters are converted.
If bTestByteOrder is false or the first character of sUTF32[] is neither 0x0000FEFF nor 0xFFFE0000, then the sUTF32 string must match the CPU's byte order.
sUTF32_count - [in] If sUTF32_count >= 0, then it specifies the number of ON__UINT32 elements in sUTF32[] to convert.
If sUTF32_count == -1, then sUTF32 must be a null terminated string and all the elements up to the first null element are converted.
sUTF16 - [out] If sUTF16 is not null and sUTF16_count > 0, then the UTF-16 encoded string is returned in this buffer. If there is room for the null terminator, the converted string will be null terminated. The null terminator is never included in the count of returned by this function. The converted string is in the CPU's native byte order. No byte order mark is prepended.
sUTF16_count - [in] If sUTF16_count > 0, then it specifies the number of available ON__UINT16 elements in the sUTF16[] buffer.
If sUTF16_count == 0, then the sUTF16 parameter is ignored.
error_status - [out] If error_status is not null, then bits of *error_status are set to indicate the success or failure of the conversion.
When the error_mask parameter is used to used to mask some conversion errors, multiple bits may be set. 0: Successful conversion with no errors. 1: The input parameters were invalid. This error cannot be masked. 2: The output buffer was not large enough to hold the converted string. As much conversion as possible is performed in this case and the error cannot be masked. 4: When parsing a UTF-8 or UTF-32 string, the values of two consecutive encoding sequences formed a valid UTF-16 surrogate pair.
This error is masked if 0 != (4 & m_error_mask). If the error is masked, then the surrogate pair is decoded, the value of the resulting unicode code point is used, and parsing continues. 8: An overlong UTF-8 encoding sequence was encountered and the value of the overlong sUTF-8 sequence was a valid unicode code point.
This error is masked if 0 != (8 & m_error_mask). If the error is masked, then the unicode code point is used and parsing continues. 16: An illegal UTF-8, UTF-16 or UTF-32 encoding sequence occurred or an invalid unicode code point value resulted from decoding a UTF-8 sequence. This error is masked if 0 != (16 & m_error_mask). If the error is masked and the value of error_code_point is a valid unicode code point, then error_code_point is encoded in the output string and parsing continues.
error_mask - [in] If 0 != (error_mask & 4), then type 4 errors are masked. If 0 != (error_mask & 8), then type 8 errors are masked. If 0 != (error_mask & 16) and error_code_point is a valid unicode code point value, then type 16 errors are masked.
error_code_point - [in] Unicode code point value to use in when masking type 16 errors. If 0 == (error_mask & 16), then this parameter is ignored. ON_UnicodeCodePoint::ON_ReplacementCharacter (U+FFFD) is a popular choice for the error_code_point value.
sNextUnicode - [out] If sNextUnicode is not null, then *sNextUnicode points to the first byte in the input sNextUnicode[] buffer that was not converted.
If an error occurs and is not masked, then this unsigned int will be an illegal unicode code point value.
If an error does not occur, then (*sNextUnicode - sUnicode) is the number of values converted.
Returns: If sUTF16_count > 0, the return value is the number of ON__UINT16 elements written to sUTF16[]. When the return value < sUTF16_count, a null terminator is written to sUTF16[return value].
If sUTF16_count == 0, the return value is the minimum number of ON__UINT16 elements that are needed to hold the converted string. The return value does not include room for a null terminator.
Increment the return value by one if you want to have an element to use for a null terminator.
ON_DECL int ON_ConvertUTF32ToUTF32 | ( | int | bTestByteOrder, |
const ON__UINT32 * | sInputUTF32, | ||
int | sInputUTF32_count, | ||
ON__UINT32 * | sOuputUTF32, | ||
int | sOutputUTF32_count, | ||
unsigned int * | error_status, | ||
unsigned int | error_mask, | ||
ON__UINT32 | error_code_point, | ||
const ON__UINT32 ** | sNextInputUTF32 | ||
) |
Description: Convert a unicode string from a UTF-32 encoded ON__UINT32 array into a UTF-32 encoded ON__UINT32 array. This is not simply a copy in the case when the input has a byte order mark (BOM), different byte ordering or contains errors. This function can be used to validate UTF-32 encoded strings.
Parameters: bTestByteOrder - [in] If bTestByteOrder is true and the the input buffer is a byte order mark (BOM), then the BOM is skipped. It the value of the BOM is byte swapped, then subsequent input elements are byte swapped before being decoded. Specifically:
sInputUTF32 - [in] UTF-32 string to convert.
If bTestByteOrder is true and the first element of sInputUTF32[] is 0x0000FEFF, then this element is skipped and it is assumed that sInputUTF32[] is in the CPU's native byte order.
If bTestByteOrder is true and the first element of sInputUTF32[] is 0xFFFE0000, then this element is skipped and it is assumed that sInputUTF32[] is not in the CPU's native byte order and bytes are swapped before characters are converted.
If bTestByteOrder is false or the first character of sUTF32[] is neither 0x0000FEFF nor 0xFFFE0000, then the sUTF32 string must match the CPU's byte order.
sInputUTF32_count - [in] If sInputUTF32_count >= 0, then it specifies the number of ON__UINT32 elements in sInputUTF32[] to convert.
If sInputUTF32_count == -1, then sInputUTF32 must be a null terminated string and all the elements up to the first null element are converted.
sOutputUTF32 - [out] If sOutputUTF32 is not null and sOutputUTF32_count > 0, then the UTF-32 encoded string is returned in this buffer. If there is room for the null terminator, the converted string will be null terminated. The null terminator is never included in the count of returned by this function. The converted string is in the CPU's native byte order. No byte order mark is prepended.
sOutputUTF32_count - [in] If sOutputUTF32_count > 0, then it specifies the number of available ON__UINT32 elements in the sOutputUTF32[] buffer.
If sOutputUTF32_count == 0, then the sOutputUTF32 parameter is ignored. This is useful when you want to validate a UTF-32 formatted string.
error_status - [out] If error_status is not null, then bits of *error_status are set to indicate the success or failure of the conversion.
When the error_mask parameter is used to used to mask some conversion errors, multiple bits may be set. 0: Successful conversion with no errors. 1: The input parameters were invalid. This error cannot be masked. 2: The output buffer was not large enough to hold the converted string. As much conversion as possible is performed in this case and the error cannot be masked. 4: When parsing a UTF-8 or UTF-32 string, the values of two consecutive encoding sequences formed a valid UTF-16 surrogate pair.
This error is masked if 0 != (4 & m_error_mask). If the error is masked, then the surrogate pair is decoded, the value of the resulting unicode code point is used, and parsing continues. 8: An overlong UTF-8 encoding sequence was encountered and the value of the overlong sUTF-8 sequence was a valid unicode code point.
This error is masked if 0 != (8 & m_error_mask). If the error is masked, then the unicode code point is used and parsing continues. 16: An illegal UTF-8, UTF-16 or UTF-32 encoding sequence occurred or an invalid unicode code point value resulted from decoding a UTF-8 sequence. This error is masked if 0 != (16 & m_error_mask). If the error is masked and the value of error_code_point is a valid unicode code point, then error_code_point is encoded in the output string and parsing continues.
error_mask - [in] If 0 != (error_mask & 4), then type 4 errors are masked. If 0 != (error_mask & 8), then type 8 errors are masked. If 0 != (error_mask & 16) and error_code_point is a valid unicode code point value, then type 16 errors are masked.
error_code_point - [in] Unicode code point value to use in when masking type 16 errors. If 0 == (error_mask & 16), then this parameter is ignored. ON_UnicodeCodePoint::ON_ReplacementCharacter (U+FFFD) is a popular choice for the error_code_point value.
sNextInputUTF32 - [out] If sNextInputUTF32 is not null, then *sNextInputUTF32 points to the first element in the input sInputUTF32[] buffer that was not converted.
If an error occurs and is not masked, then this unsigned int will be an illegal unicode code point value.
If an error does not occur, then (*sNextInputUTF32 - sInputUTF32) is the number of values converted.
Returns: If sOutputUTF32_count > 0, the return value is the number of ON__UINT32 elements written to sOutputUTF32[].
When the return value < sOutputUTF32_count, a null terminator is written to sOutputUTF32[return value].
If sOutputUTF32_count == 0, the return value is the minimum number of ON__UINT32 elements that are needed to hold the converted string. The return value does not include room for a null terminator.
Increment the return value by one if you want to have an element to use for a null terminator.
ON_DECL int ON_ConvertUTF32ToUTF8 | ( | int | bTestByteOrder, |
const ON__UINT32 * | sUTF32, | ||
int | sUTF32_count, | ||
char * | sUTF8, | ||
int | sUTF8_count, | ||
unsigned int * | error_status, | ||
unsigned int | error_mask, | ||
ON__UINT32 | error_code_point, | ||
const ON__UINT32 ** | sNextUTF32 | ||
) |
Description: Convert a unicode string from a UTF-32 encoded ON__UINT32 array into a UTF-8 encoded char array.
Parameters: bTestByteOrder - [in] If bTestByteOrder is true and the the input buffer is a byte order mark (BOM), then the BOM is skipped. It the value of the BOM is byte swapped, then subsequent input elements are byte swapped before being decoded. Specifically:
sUTF32 - [in] UTF-32 string to convert.
If bTestByteOrder is true and the first element of sUTF32[] is 0x0000FEFF, then this element is skipped and it is assumed that sUTF32[] is in the CPU's native byte order.
If bTestByteOrder is true and the first element of sUTF32[] is 0xFFFE0000, then this element is skipped and it is assumed that sUTF32[] is not in the CPU's native byte order and bytes are swapped before characters are converted.
If bTestByteOrder is false or the first character of sUTF32[] is neither 0x0000FEFF nor 0xFFFE0000, then the sUTF32 string must match the CPU's byte order.
sUTF32_count - [in] If sUTF32_count >= 0, then it specifies the number of ON__UINT32 elements in sUTF32[] to convert.
If sUTF32_count == -1, then sUTF32 must be a null terminated string and all the elements up to the first null element are converted.
sUTF8 - [out] If sUTF8 is not null and sUTF8_count > 0, then the UTF-8 encoded string is returned in this buffer. If there is room for the null terminator, the converted string will be null terminated. The null terminator is never included in the count of returned by this function. The converted string is in the CPU's native byte order. No byte order mark is prepended.
sUTF8_count - [in] If sUTF8_count > 0, then it specifies the number of available char elements in the sUTF8[] buffer.
If sUTF8_count == 0, then the sUTF8 parameter is ignored.
error_status - [out] If error_status is not null, then bits of *error_status are set to indicate the success or failure of the conversion.
When the error_mask parameter is used to used to mask some conversion errors, multiple bits may be set. 0: Successful conversion with no errors. 1: The input parameters were invalid. This error cannot be masked. 2: The output buffer was not large enough to hold the converted string. As much conversion as possible is performed in this case and the error cannot be masked. 4: When parsing a UTF-8 or UTF-32 string, the values of two consecutive encoding sequences formed a valid UTF-16 surrogate pair.
This error is masked if 0 != (4 & m_error_mask). If the error is masked, then the surrogate pair is decoded, the value of the resulting unicode code point is used, and parsing continues. 8: An overlong UTF-8 encoding sequence was encountered and the value of the overlong sUTF-8 sequence was a valid unicode code point.
This error is masked if 0 != (8 & m_error_mask). If the error is masked, then the unicode code point is used and parsing continues. 16: An illegal UTF-8, UTF-16 or UTF-32 encoding sequence occurred or an invalid unicode code point value resulted from decoding a UTF-8 sequence. This error is masked if 0 != (16 & m_error_mask). If the error is masked and the value of error_code_point is a valid unicode code point, then error_code_point is encoded in the output string and parsing continues.
error_mask - [in] If 0 != (error_mask & 4), then type 4 errors are masked. If 0 != (error_mask & 8), then type 8 errors are masked. If 0 != (error_mask & 16) and error_code_point is a valid unicode code point value, then type 16 errors are masked.
error_code_point - [in] Unicode code point value to use in when masking type 16 errors. If 0 == (error_mask & 16), then this parameter is ignored. ON_UnicodeCodePoint::ON_ReplacementCharacter (U+FFFD) is a popular choice for the error_code_point value.
sNextUTF32 - [out] If sNextUTF32 is not null, then *sNextUTF32 points to the first element in the input sUTF32[] buffer that was not converted.
If an error occurs and is not masked, then *sNextUTF32 points to the element of sUTF32[] where the conversion failed. If no errors occur or all errors are masked, then *sNextUTF32 points to sUTF32 + sUTF32_count.
Returns: If sUTF8_count > 0, the return value is the number of char elements written to sUTF8[]. When the return value < sUTF8_count, a null terminator is written to sUTF8[return value].
If sUTF8_count == 0, the return value is the minimum number of char elements that are needed to hold the converted string. The return value does not include room for a null terminator.
Increment the return value by one if you want to have an element to use for a null terminator.
ON_DECL int ON_ConvertUTF32ToWideChar | ( | int | bTestByteOrder, |
const ON__UINT32 * | sUTF32, | ||
int | sUTF32_count, | ||
wchar_t * | sWideChar, | ||
int | sWideChar_count, | ||
unsigned int * | error_status, | ||
unsigned int | error_mask, | ||
ON__UINT32 | error_code_point, | ||
const ON__UINT32 ** | sNextUTF32 | ||
) |
Description: Convert a UTF-32 encoded string to wchar_t string using the native platform's most common encoding.
If 1 = sizeof(wchar_t), then UTF-8 encoding is used for the output string.
If 2 = sizeof(wchar_t), then UTF-16 encoding is used for the output string. This is the case with current versions of Microsoft Windows.
If 4 = sizeof(wchar_t), then UTF-32 encoding is used for the output string. This is the case with current versions of Apple OSX.
Parameters: bTestByteOrder - [in] If bTestByteOrder is true and the the input buffer is a byte order mark (BOM), then the BOM is skipped. It the value of the BOM is byte swapped, then subsequent input elements are byte swapped before being decoded. Specifically:
sUTF32 - [in] UTF-32 string to convert.
sUTF32_count - [in] If sUTF32_count >= 0, then it specifies the number of ON__UINT32 elements in sUTF32[] to convert.
If sUTF32_count == -1, then sUTF32 must be a null terminated string and all the elements up to the first null element are converted.
sWideChar - [out] If sWideChar is not null and sWideChar_count > 0, then the output string is returned in this buffer. If there is room for the null terminator, the converted string will be null terminated. The null terminator is never included in the count of returned by this function. The converted string is in the CPU's native byte order. No byte order mark is prepended.
sWideChar_count - [in] If sWideChar_count > 0, then it specifies the number of available wchar_t elements in the sWideChar[] buffer.
If sWideChar_count == 0, then the sWideChar parameter is ignored.
error_status - [out] If error_status is not null, then bits of *error_status are set to indicate the success or failure of the conversion.
When the error_mask parameter is used to used to mask some conversion errors, multiple bits may be set. 0: Successful conversion with no errors. 1: The input parameters were invalid. This error cannot be masked. 2: The output buffer was not large enough to hold the converted string. As much conversion as possible is performed in this case and the error cannot be masked. 4: When parsing a UTF-8 or UTF-32 string, the values of two consecutive encoding sequences formed a valid UTF-16 surrogate pair.
This error is masked if 0 != (4 & m_error_mask). If the error is masked, then the surrogate pair is decoded, the value of the resulting unicode code point is used, and parsing continues. 8: An overlong UTF-8 encoding sequence was encountered and the value of the overlong sUTF-8 sequence was a valid unicode code point.
This error is masked if 0 != (8 & m_error_mask). If the error is masked, then the unicode code point is used and parsing continues. 16: An illegal UTF-8, UTF-16 or UTF-32 encoding sequence occurred or an invalid unicode code point value resulted from decoding a UTF-8 sequence. This error is masked if 0 != (16 & m_error_mask). If the error is masked and the value of error_code_point is a valid unicode code point, then error_code_point is encoded in the output string and parsing continues.
error_mask - [in] If 0 != (error_mask & 4), then type 4 errors are masked. If 0 != (error_mask & 8), then type 8 errors are masked. If 0 != (error_mask & 16) and error_code_point is a valid unicode code point value, then type 16 errors are masked.
error_code_point - [in] Unicode code point value to use in when masking type 16 errors. If 0 == (error_mask & 16), then this parameter is ignored. ON_UnicodeCodePoint::ON_ReplacementCharacter (U+FFFD) is a popular choice for the error_code_point value.
sNextUTF32 - [out] If sNextUTF32 is not null, then *sNextUTF32 points to the first element in the input sUTF32[] buffer that was not converted.
If an error occurs and is not masked, then *sNextUTF8 points to the element of sUTF32[] where the conversion failed. If no errors occur or all errors are masked, then *sNextUTF32 points to sUTF32 + sUTF32_count.
Returns: If sWideChar_count > 0, the return value is the number of wchar_t elements written to sWideChar[]. When the return value < sWideChar_count, a null terminator is written to sWideChar[return value].
If sWideChar_count == 0, the return value is the minimum number of wchar_t elements that are needed to hold the converted string. The return value does not include room for a null terminator.
Increment the return value by one if you want to have an element to use for a null terminator. See Also: ON_wString::FromUnicodeCodePoints()
ON_DECL int ON_ConvertUTF8ToUTF16 | ( | int | bTestByteOrder, |
const char * | sUTF8, | ||
int | sUTF8_count, | ||
ON__UINT16 * | sUTF16, | ||
int | sUTF16_count, | ||
unsigned int * | error_status, | ||
unsigned int | error_mask, | ||
ON__UINT32 | error_code_point, | ||
const char ** | sNextUTF8 | ||
) |
Description: Convert a unicode string from a UTF-8 encoded char array into a UTF-16 encoded ON__UINT16 array.
Parameters: bTestByteOrder - [in] If bTestByteOrder is true and the the input buffer is a byte order mark (BOM), then the BOM is skipped. It the value of the BOM is byte swapped, then subsequent input elements are byte swapped before being decoded. Specifically:
sUTF8 - [in] UTF-8 string to convert.
sUTF8_count - [in] If sUTF8_count >= 0, then it specifies the number of char elements in sUTF8[] to convert.
If sUTF8_count == -1, then sUTF8 must be a null terminated string and all the elements up to the first null element are converted.
sUTF16 - [out] If sUTF16 is not null and sUTF16_count > 0, then the UTF-16 encoded string is returned in this buffer. If there is room for the null terminator, the converted string will be null terminated. The null terminator is never included in the count of returned by this function. The converted string is in the CPU's native byte order. No byte order mark is prepended.
sUTF16_count - [in] If sUTF16_count > 0, then it specifies the number of available ON__UINT16 elements in the sUTF16[] buffer.
If sUTF16_count == 0, then the sUTF16 parameter is ignored.
error_status - [out] If error_status is not null, then bits of *error_status are set to indicate the success or failure of the conversion.
When the error_mask parameter is used to used to mask some conversion errors, multiple bits may be set. 0: Successful conversion with no errors. 1: The input parameters were invalid. This error cannot be masked. 2: The output buffer was not large enough to hold the converted string. As much conversion as possible is performed in this case and the error cannot be masked. 4: When parsing a UTF-8 or UTF-32 string, the values of two consecutive encoding sequences formed a valid UTF-16 surrogate pair.
This error is masked if 0 != (4 & m_error_mask). If the error is masked, then the surrogate pair is decoded, the value of the resulting unicode code point is used, and parsing continues. 8: An overlong UTF-8 encoding sequence was encountered and the value of the overlong sUTF-8 sequence was a valid unicode code point.
This error is masked if 0 != (8 & m_error_mask). If the error is masked, then the unicode code point is used and parsing continues. 16: An illegal UTF-8, UTF-16 or UTF-32 encoding sequence occurred or an invalid unicode code point value resulted from decoding a UTF-8 sequence. This error is masked if 0 != (16 & m_error_mask). If the error is masked and the value of error_code_point is a valid unicode code point, then error_code_point is encoded in the output string and parsing continues.
error_mask - [in] If 0 != (error_mask & 4), then type 4 errors are masked. If 0 != (error_mask & 8), then type 8 errors are masked. If 0 != (error_mask & 16) and error_code_point is a valid unicode code point value, then type 16 errors are masked.
error_code_point - [in] Unicode code point value to use in when masking type 16 errors. If 0 == (error_mask & 16), then this parameter is ignored. ON_UnicodeCodePoint::ON_ReplacementCharacter (U+FFFD) is a popular choice for the error_code_point value.
sNextUTF8 - [out] If sNextUTF8 is not null, then *sNextUTF8 points to the first element in the input sUTF8[] buffer that was not converted.
If an error occurs and is not masked, then *sNextUTF8 points to the element of sUTF8[] where the conversion failed. If no errors occur or all errors are masked, then *sNextUTF8 points to sUTF8 + sUTF8_count.
Returns: If sUTF16_count > 0, the return value is the number of ON__UINT16 elements written to sUTF16[]. When the return value < sUTF16_count, a null terminator is written to sUTF16[return value].
If sUTF16_count == 0, the return value is the minimum number of ON__UINT16 elements that are needed to hold the converted string. The return value does not include room for a null terminator.
Increment the return value by one if you want to have an element to use for a null terminator.
ON_DECL int ON_ConvertUTF8ToUTF32 | ( | int | bTestByteOrder, |
const char * | sUTF8, | ||
int | sUTF8_count, | ||
ON__UINT32 * | sUTF32, | ||
int | sUTF32_count, | ||
unsigned int * | error_status, | ||
unsigned int | error_mask, | ||
ON__UINT32 | error_code_point, | ||
const char ** | sNextUTF8 | ||
) |
Description: Convert a unicode string from a UTF-8 encoded char array into a UTF-32 encoded ON__UINT32 array.
Parameters: bTestByteOrder - [in] If bTestByteOrder is true and the the input buffer is a byte order mark (BOM), then the BOM is skipped. It the value of the BOM is byte swapped, then subsequent input elements are byte swapped before being decoded. Specifically:
sUTF8 - [in] UTF-8 string to convert.
sUTF8_count - [in] If sUTF8_count >= 0, then it specifies the number of char elements in sUTF8[] to convert.
If sUTF8_count == -1, then sUTF8 must be a null terminated string and all the elements up to the first null element are converted.
sUTF32 - [out] If sUTF32 is not null and sUTF32_count > 0, then the UTF-32 encoded string is returned in this buffer. If there is room for the null terminator, the converted string will be null terminated. The null terminator is never included in the count of returned by this function. The converted string is in the CPU's native byte order. No byte order mark is prepended.
sUTF32_count - [in] If sUTF32_count > 0, then it specifies the number of available ON__UINT32 elements in the sUTF32[] buffer.
If sUTF32_count == 0, then the sUTF32 parameter is ignored.
error_status - [out] If error_status is not null, then bits of *error_status are set to indicate the success or failure of the conversion.
When the error_mask parameter is used to used to mask some conversion errors, multiple bits may be set. 0: Successful conversion with no errors. 1: The input parameters were invalid. This error cannot be masked. 2: The output buffer was not large enough to hold the converted string. As much conversion as possible is performed in this case and the error cannot be masked. 4: When parsing a UTF-8 or UTF-32 string, the values of two consecutive encoding sequences formed a valid UTF-16 surrogate pair.
This error is masked if 0 != (4 & m_error_mask). If the error is masked, then the surrogate pair is decoded, the value of the resulting unicode code point is used, and parsing continues. 8: An overlong UTF-8 encoding sequence was encountered and the value of the overlong sUTF-8 sequence was a valid unicode code point.
This error is masked if 0 != (8 & m_error_mask). If the error is masked, then the unicode code point is used and parsing continues. 16: An illegal UTF-8, UTF-16 or UTF-32 encoding sequence occurred or an invalid unicode code point value resulted from decoding a UTF-8 sequence. This error is masked if 0 != (16 & m_error_mask). If the error is masked and the value of error_code_point is a valid unicode code point, then error_code_point is encoded in the output string and parsing continues.
error_mask - [in] If 0 != (error_mask & 4), then type 4 errors are masked. If 0 != (error_mask & 8), then type 8 errors are masked. If 0 != (error_mask & 16) and error_code_point is a valid unicode code point value, then type 16 errors are masked.
error_code_point - [in] Unicode code point value to use in when masking type 16 errors. If 0 == (error_mask & 16), then this parameter is ignored. ON_UnicodeCodePoint::ON_ReplacementCharacter (U+FFFD) is a popular choice for the error_code_point value.
sNextUTF8 - [out] If sNextUTF8 is not null, then *sNextUTF8 points to the first element in the input sUTF8[] buffer that was not converted.
If an error occurs and is not masked, then *sNextUTF8 points to the element of sUTF8[] where the conversion failed. If no errors occur or all errors are masked, then *sNextUTF8 points to sUTF8 + sUTF8_count.
Returns: If sUTF32_count > 0, the return value is the number of ON__UINT32 elements written to sUTF32[]. When the return value < sUTF32_count, a null terminator is written to sUTF32[return value].
If sUTF32_count == 0, the return value is the minimum number of ON__UINT32 elements that are needed to hold the converted string. The return value does not include room for a null terminator.
Increment the return value by one if you want to have an element to use for a null terminator.
ON_DECL int ON_ConvertUTF8ToUTF8 | ( | int | bTestByteOrder, |
const char * | sInputUTF8, | ||
int | sInputUTF8_count, | ||
char * | sOutputUTF8, | ||
int | sOutputUTF8_count, | ||
unsigned int * | error_status, | ||
unsigned int | error_mask, | ||
ON__UINT32 | error_code_point, | ||
const char ** | sNextInputUTF8 | ||
) |
Description: Convert a unicode string from a UTF-8 encoded char array into a UTF-8 encoded char array. This function can be used to clean UTF-8 strings that have a leading byte-order-mark (BOM) or contain encoding errors.
Parameters: bTestByteOrder - [in] If bTestByteOrder is true and the the input buffer is a byte order mark (BOM), then the BOM is skipped. It the value of the BOM is byte swapped, then subsequent input elements are byte swapped before being decoded. Specifically:
sInputUTF8 - [in] UTF-8 encoded string to convert.
sInputUTF8_count - [in] If sInputUTF8_count >= 0, then it specifies the number of char elements in sInputUTF8[] to convert.
If sInputUTF8_count == -1, then sInputUTF8 must be a null terminated string and all the elements up to the first null element are converted.
sOutputUTF8 - [out] If sOutputUTF8 is not null and sOutputUTF8_count > 0, then the output UTF-8 encoded string is returned in this buffer. If there is room for the null terminator, the converted string will be null terminated. The null terminator is never included in the count returned by this function. No byte order mark is prepended.
sOutputUTF8_count - [in] If sOutputUTF8_count > 0, then it specifies the number of available char elements in the sOutputUTF8[] buffer.
If sOutputUTF8_count == 0, then the sOutputUTF8 parameter is ignored.
error_status - [out] If error_status is not null, then bits of *error_status are set to indicate the success or failure of the conversion.
When the error_mask parameter is used to used to mask some conversion errors, multiple bits may be set. 0: Successful conversion with no errors. 1: The input parameters were invalid. This error cannot be masked. 2: The output buffer was not large enough to hold the converted string. As much conversion as possible is performed in this case and the error cannot be masked. 4: When parsing a UTF-8 or UTF-32 string, the values of two consecutive encoding sequences formed a valid UTF-16 surrogate pair.
This error is masked if 0 != (4 & m_error_mask). If the error is masked, then the surrogate pair is decoded, the value of the resulting unicode code point is used, and parsing continues. 8: An overlong UTF-8 encoding sequence was encountered and the value of the overlong sUTF-8 sequence was a valid unicode code point.
This error is masked if 0 != (8 & m_error_mask). If the error is masked, then the unicode code point is used and parsing continues. 16: An illegal UTF-8, UTF-16 or UTF-32 encoding sequence occurred or an invalid unicode code point value resulted from decoding a UTF-8 sequence. This error is masked if 0 != (16 & m_error_mask). If the error is masked and the value of error_code_point is a valid unicode code point, then error_code_point is encoded in the output string and parsing continues.
error_mask - [in] If 0 != (error_mask & 4), then type 4 errors are masked. If 0 != (error_mask & 8), then type 8 errors are masked. If 0 != (error_mask & 16) and error_code_point is a valid unicode code point value, then type 16 errors are masked.
error_code_point - [in] Unicode code point value to use in when masking type 16 errors. If 0 == (error_mask & 16), then this parameter is ignored. ON_UnicodeCodePoint::ON_ReplacementCharacter (U+FFFD) is a popular choice for the error_code_point value.
sNextInputUTF8 - [out] If sNextInputUTF8 is not null, then *sNextInputUTF8 points to the first element in the input sInputUTF8[] buffer that was not converted.
If an error occurs and is not masked, then *sNextInputUTF8 points to the element of sInputUTF8[] where the conversion failed. If no errors occur or all errors are masked, then sNextInputUTF8 points to sInputUTF8 + sInputUTF8_count.
Returns: If sOutputUTF8_count > 0, the return value is the number of char elements written to sOutputUTF8[]. When the return value < sOutputUTF8_count, a null terminator is written to sOutputUTF8[return value].
If sOutputUTF8_count == 0, the return value is the minimum number of char elements that are needed to hold the converted string. The return value does not include room for a null terminator.
Increment the return value by one if you want to have an element to use for a null terminator.
ON_DECL int ON_ConvertUTF8ToWideChar | ( | int | bTestByteOrder, |
const char * | sUTF8, | ||
int | sUTF8_count, | ||
wchar_t * | sWideChar, | ||
int | sWideChar_count, | ||
unsigned int * | error_status, | ||
unsigned int | error_mask, | ||
ON__UINT32 | error_code_point, | ||
const char ** | sNextUTF8 | ||
) |
Description: Convert a UTF-8 encoded char string to wchar_t string using the native platform's most common encoding.
If 1 = sizeof(wchar_t), then UTF-8 encoding is used for the output string.
If 2 = sizeof(wchar_t), then UTF-16 encoding is used for the output string. This is the case with current versions of Microsoft Windows.
If 4 = sizeof(wchar_t), then UTF-32 encoding is used for the output string. This is the case with current versions of Apple OSX.
Parameters: bTestByteOrder - [in] If bTestByteOrder is true and the the input buffer is a byte order mark (BOM), then the BOM is skipped. It the value of the BOM is byte swapped, then subsequent input elements are byte swapped before being decoded. Specifically:
sUTF8 - [in] UTF-8 string to convert.
sUTF8_count - [in] If sUTF8_count >= 0, then it specifies the number of char elements in sUTF8[] to convert.
If sUTF8_count == -1, then sUTF8 must be a null terminated string and all the elements up to the first null element are converted.
sWideChar - [out] If sWideChar is not null and sWideChar_count > 0, then the output string is returned in this buffer. If there is room for the null terminator, the converted string will be null terminated. The null terminator is never included in the count of returned by this function. The converted string is in the CPU's native byte order. No byte order mark is prepended.
sWideChar_count - [in] If sWideChar_count > 0, then it specifies the number of available wchar_t elements in the sWideChar[] buffer.
If sWideChar_count == 0, then the sWideChar parameter is ignored.
error_status - [out] If error_status is not null, then bits of *error_status are set to indicate the success or failure of the conversion.
When the error_mask parameter is used to used to mask some conversion errors, multiple bits may be set. 0: Successful conversion with no errors. 1: The input parameters were invalid. This error cannot be masked. 2: The output buffer was not large enough to hold the converted string. As much conversion as possible is performed in this case and the error cannot be masked. 4: When parsing a UTF-8 or UTF-32 string, the values of two consecutive encoding sequences formed a valid UTF-16 surrogate pair.
This error is masked if 0 != (4 & m_error_mask). If the error is masked, then the surrogate pair is decoded, the value of the resulting unicode code point is used, and parsing continues. 8: An overlong UTF-8 encoding sequence was encountered and the value of the overlong sUTF-8 sequence was a valid unicode code point.
This error is masked if 0 != (8 & m_error_mask). If the error is masked, then the unicode code point is used and parsing continues. 16: An illegal UTF-8, UTF-16 or UTF-32 encoding sequence occurred or an invalid unicode code point value resulted from decoding a UTF-8 sequence. This error is masked if 0 != (16 & m_error_mask). If the error is masked and the value of error_code_point is a valid unicode code point, then error_code_point is encoded in the output string and parsing continues.
error_mask - [in] If 0 != (error_mask & 4), then type 4 errors are masked. If 0 != (error_mask & 8), then type 8 errors are masked. If 0 != (error_mask & 16) and error_code_point is a valid unicode code point value, then type 16 errors are masked.
error_code_point - [in] Unicode code point value to use in when masking type 16 errors. If 0 == (error_mask & 16), then this parameter is ignored. ON_UnicodeCodePoint::ON_ReplacementCharacter (U+FFFD) is a popular choice for the error_code_point value.
sNextUTF8 - [out] If sNextUTF8 is not null, then *sNextUTF8 points to the first element in the input sUTF8[] buffer that was not converted.
If an error occurs and is not masked, then *sNextUTF8 points to the element of sUTF8[] where the conversion failed. If no errors occur or all errors are masked, then *sNextUTF8 points to sUTF8 + sUTF8_count.
Returns: If sWideChar_count > 0, the return value is the number of wchar_t elements written to sWideChar[]. When the return value < sWideChar_count, a null terminator is written to sWideChar[return value].
If sWideChar_count == 0, the return value is the minimum number of wchar_t elements that are needed to hold the converted string. The return value does not include room for a null terminator.
Increment the return value by one if you want to have an element to use for a null terminator.
ON_DECL int ON_ConvertWideCharToMSMBCP | ( | const wchar_t * | sWideChar, |
int | sWideChar_count, | ||
ON__UINT32 | windows_code_page, | ||
char * | sMBCS, | ||
int | sMBCS_capacity, | ||
unsigned int * | error_status | ||
) |
Description: Convert a string from UTF-8/UTF=16/UTF-32 encoding (depending on size of wchar_t) to a Microsoft multibyte code page encoding.
This function is designed to be used to create strings that will be used write files that require non-UTF encoded char strings.
Opennurbs assumes all other char strings are UTF-8 encoded.
If 1 = sizeof(wchar_t), then sWideChar must be UTF-8 encoded.
If 2 = sizeof(wchar_t), then sWideChar must be UTF-16 encoded.
If 4 = sizeof(wchar_t), then sWideChar must be UTF-16 or UTF-32 encoded.
Parameters: windows_code_page - [in] THe windows code page specifies the encoding of the sMBCS string.
sWideChar - [out] The input UTF encoded string. If sWideChar_count is -1, this string must be null terminated. If sWideChar_count > 0, the string must has sWideChar_count wchar_t elements that are a UTF encoding.
sWideChar_count - [in] If sWideChar_capacity > 0, then it specifies the number of wchar_t elements in the sWideChar[] to convert.
If sWideChar_count == -1, then sWideChar must be a null terminated string and all the elements up to the first null element are converted.
sMBCS - [out] If sMBCS is not null and sMBCS_count > 0, then the output MBCS encoded string is returned in this buffer. If there is room for the null terminator, the converted string will be null terminated. The null terminator is never included in the count of returned by this function.
sMBCS_capacity - [in] If sWideChar_capacity > 0, then it specifies the number of available char elements (bytes) in the sMBCS[] buffer.
If sMBCS_capacity == 0, then the sMBCS parameter is ignored.
error_status - [out] If error_status is not null, then bits of *error_status are set to indicate the success or failure of the conversion. When the error_mask parameter is used to used to mask some conversion errors, multiple bits may be set. 0: Successful conversion with no errors. 1: The input parameters were invalid. This error cannot be masked. 2: The output buffer was not large enough to hold the converted string. As much conversion as possible is performed in this case and the error cannot be masked. 16: An illegal encoding sequence occurred or a UNICODE codepoint was encountered that cannot be encoded in the code page specified by windows_code_page. In either case, a a single question mark (?) in the output string and parsing continues.
Returns: If sMBCS_capacity > 0, the return value is the number MBCS encoded char elements written to sWideChar[]. When the return value < sMBCSChar_capacity, a null terminator is written to sWideChar[return value].
If sMBCS_count == 0, the return value is the minimum number of char elements that are needed to hold the MBCS encode string. The return value does not include room for a null terminator. Increment the return value by one if you want to have an element to use for a null terminator.
ON_DECL int ON_ConvertWideCharToUTF16 | ( | int | bTestByteOrder, |
const wchar_t * | sWideChar, | ||
int | sWideChar_count, | ||
ON__UINT16 * | sUTF16, | ||
int | sUTF16_count, | ||
unsigned int * | error_status, | ||
unsigned int | error_mask, | ||
ON__UINT32 | error_code_point, | ||
const wchar_t ** | sNextWideChar | ||
) |
Description: Convert a wchar_t string using the native platform's most common encoding into a unicode string encoded as a UTF-16 ON__UINT16 array.
If 1 = sizeof(wchar_t), then the wchar_t array is assumed to be a UTF-8 encoded string.
If 2 = sizeof(wchar_t), then the wchar_t array is assumed to be a UTF-16 encoded string. This is the case with current versions of Microsoft Windows.
If 4 = sizeof(wchar_t), then the wchar_t array is assumed to be a UTF-32 encoded string. This is the case with current versions of Apple OS X.
Parameters: bTestByteOrder - [in] If bTestByteOrder is true and the the input buffer is a byte order mark (BOM), then the BOM is skipped. It the value of the BOM is byte swapped, then subsequent input elements are byte swapped before being decoded. Specifically:
sWideChar - [in] wchar_t input string to convert.
sWideChar_count - [in] If sWideChar_count >= 0, then it specifies the number of wchar_t elements in sWideChar[] to convert.
If sWideChar_count == -1, then sWideChar must be a null terminated array and all the elements up to the first null element are converted.
sUTF16 - [out] If sUTF16 is not null and sUTF16_count > 0, then the UTF-16 encoded string is returned in this buffer. If there is room for the null terminator, the converted string will be null terminated. The null terminator is never included in the count of returned by this function. The converted string is in the CPU's native byte order. No byte order mark is prepended.
sUTF16_count - [in] If sUTF16_count > 0, then it specifies the number of available ON__UINT16 elements in the sUTF16[] buffer.
If sUTF16_count == 0, then the sUTF16 parameter is ignored.
error_status - [out] If error_status is not null, then bits of *error_status are set to indicate the success or failure of the conversion.
When the error_mask parameter is used to used to mask some conversion errors, multiple bits may be set. 0: Successful conversion with no errors. 1: The input parameters were invalid. This error cannot be masked. 2: The output buffer was not large enough to hold the converted string. As much conversion as possible is performed in this case and the error cannot be masked. 4: When parsing a UTF-8 or UTF-32 string, the values of two consecutive encoding sequences formed a valid UTF-16 surrogate pair.
This error is masked if 0 != (4 & m_error_mask). If the error is masked, then the surrogate pair is decoded, the value of the resulting unicode code point is used, and parsing continues. 8: An overlong UTF-8 encoding sequence was encountered and the value of the overlong sUTF-8 sequence was a valid unicode code point.
This error is masked if 0 != (8 & m_error_mask). If the error is masked, then the unicode code point is used and parsing continues. 16: An illegal UTF-8, UTF-16 or UTF-32 encoding sequence occurred or an invalid unicode code point value resulted from decoding a UTF-8 sequence. This error is masked if 0 != (16 & m_error_mask). If the error is masked and the value of error_code_point is a valid unicode code point, then error_code_point is encoded in the output string and parsing continues.
error_mask - [in] If 0 != (error_mask & 4), then type 4 errors are masked. If 0 != (error_mask & 8), then type 8 errors are masked. If 0 != (error_mask & 16) and error_code_point is a valid unicode code point value, then type 16 errors are masked.
error_code_point - [in] Unicode code point value to use in when masking type 16 errors. If 0 == (error_mask & 16), then this parameter is ignored. ON_UnicodeCodePoint::ON_ReplacementCharacter (U+FFFD) is a popular choice for the error_code_point value.
sNextWideChar - [out] If sNextWideChar is not null, then *sNextWideChar points to the first element in the input sWideChar[] buffer that was not converted.
If an error occurs and is not masked, then *sNextWideChar points to the element of sWideChar[] where the conversion failed. If no errors occur or all errors are masked, then *sNextWideChar points to sWideChar + sWideChar_count.
If sUTF16_count > 0, the return value is the number of ON__UINT16 elements written to sUTF16[]. When the return value < sUTF16_count, a null terminator is written to sUTF16[return value].
If sUTF16_count == 0, the return value is the minimum number of ON__UINT16 elements that are needed to hold the converted string. The return value does not include room for a null terminator.
Increment the return value by one if you want to have an element to use for a null terminator.
ON_DECL int ON_ConvertWideCharToUTF32 | ( | int | bTestByteOrder, |
const wchar_t * | sWideChar, | ||
int | sWideChar_count, | ||
ON__UINT32 * | sUTF32, | ||
int | sUTF32_count, | ||
unsigned int * | error_status, | ||
unsigned int | error_mask, | ||
ON__UINT32 | error_code_point, | ||
const wchar_t ** | sNextWideChar | ||
) |
Description: Convert a wchar_t string using the native platform's most common encoding into a unicode string encoded as a UTF-32 char array.
If 1 = sizeof(wchar_t), then the wchar_t array is assumed to be a UTF-8 encoded string.
If 2 = sizeof(wchar_t), then the wchar_t array is assumed to be a UTF-16 encoded string. This is the case with current versions of Microsoft Windows.
If 4 = sizeof(wchar_t), then the wchar_t array is assumed to be a UTF-32 encoded string. This is the case with current versions of Apple OSX.
Parameters: bTestByteOrder - [in] If bTestByteOrder is true and the the input buffer is a byte order mark (BOM), then the BOM is skipped. It the value of the BOM is byte swapped, then subsequent input elements are byte swapped before being decoded. Specifically:
sWideChar - [in] wchar_t string to convert.
sWideChar_count - [in] If sWideChar_count >= 0, then it specifies the number of wchar_t elements in sWideChar[] to convert.
If sWideChar_count == -1, then sWideChar must be a null terminated string and all the elements up to the first null element are converted.
sUTF32 - [out] If sUTF32 is not null and sUTF32_count > 0, then the UTF-32 encoded string is returned in this buffer. If there is room for the null terminator, the converted string will be null terminated. The null terminator is never included in the count of returned by this function. The converted string is in the CPU's native byte order. No byte order mark is prepended.
sUTF32_count - [in] If sUTF32_count > 0, then it specifies the number of available ON__UINT32 elements in the sUTF32[] buffer.
If sUTF32_count == 0, then the sUTF32 parameter is ignored.
error_status - [out] If error_status is not null, then bits of *error_status are set to indicate the success or failure of the conversion.
When the error_mask parameter is used to used to mask some conversion errors, multiple bits may be set. 0: Successful conversion with no errors. 1: The input parameters were invalid. This error cannot be masked. 2: The output buffer was not large enough to hold the converted string. As much conversion as possible is performed in this case and the error cannot be masked. 4: When parsing a UTF-8 or UTF-32 string, the values of two consecutive encoding sequences formed a valid UTF-16 surrogate pair.
This error is masked if 0 != (4 & m_error_mask). If the error is masked, then the surrogate pair is decoded, the value of the resulting unicode code point is used, and parsing continues. 8: An overlong UTF-8 encoding sequence was encountered and the value of the overlong sUTF-8 sequence was a valid unicode code point.
This error is masked if 0 != (8 & m_error_mask). If the error is masked, then the unicode code point is used and parsing continues. 16: An illegal UTF-8, UTF-16 or UTF-32 encoding sequence occurred or an invalid unicode code point value resulted from decoding a UTF-8 sequence. This error is masked if 0 != (16 & m_error_mask). If the error is masked and the value of error_code_point is a valid unicode code point, then error_code_point is encoded in the output string and parsing continues.
error_mask - [in] If 0 != (error_mask & 4), then type 4 errors are masked. If 0 != (error_mask & 8), then type 8 errors are masked. If 0 != (error_mask & 16) and error_code_point is a valid unicode code point value, then type 16 errors are masked.
error_code_point - [in] Unicode code point value to use in when masking type 16 errors. If 0 == (error_mask & 16), then this parameter is ignored. ON_UnicodeCodePoint::ON_ReplacementCharacter (U+FFFD) is a popular choice for the error_code_point value.
sNextWideChar - [out] If sNextWideChar is not null, then *sNextWideChar points to the first element in the input sWideChar[] buffer that was not converted.
If an error occurs and is not masked, then *sNextWideChar points to the element of sWideChar[] where the conversion failed. If no errors occur or all errors are masked, then *sNextWideChar points to sWideChar + sWideChar_count.
If sUTF32_count > 0, the return value is the number of ON__UINT32 elements written to sUTF32[]. When the return value < sUTF32_count, a null terminator is written to sUTF32[return value].
If sUTF32_count == 0, the return value is the minimum number of ON__UINT32 elements that are needed to hold the converted string. The return value does not include room for a null terminator.
Increment the return value by one if you want to have an element to use for a null terminator.
ON_DECL int ON_ConvertWideCharToUTF8 | ( | int | bTestByteOrder, |
const wchar_t * | sWideChar, | ||
int | sWideChar_count, | ||
char * | sUTF8, | ||
int | sUTF8_count, | ||
unsigned int * | error_status, | ||
unsigned int | error_mask, | ||
ON__UINT32 | error_code_point, | ||
const wchar_t ** | sNextWideChar | ||
) |
Description: Convert a wchar_t string using the native platform's most common encoding into a unicode string encoded as a UTF-8 char array.
If 1 = sizeof(wchar_t), then the wchar_t array is assumed to be a UTF-8 encoded string.
If 2 = sizeof(wchar_t), then the wchar_t array is assumed to be a UTF-16 encoded string. This is the case with current versions of Microsoft Windows.
If 4 = sizeof(wchar_t), then the wchar_t array is assumed to be a UTF-32 encoded string. This is the case with current versions of Apple OSX.
Parameters: bTestByteOrder - [in] If bTestByteOrder is true and the the input buffer is a byte order mark (BOM), then the BOM is skipped. It the value of the BOM is byte swapped, then subsequent input elements are byte swapped before being decoded. Specifically:
sWideChar - [in] wchar_t input string to convert.
sWideChar_count - [in] If sWideChar_count >= 0, then it specifies the number of wchar_t elements in sWideChar[] to convert.
If sWideChar_count == -1, then sWideChar must be a null terminated array and all the elements up to the first null element are converted.
sUTF8 - [out] If sUTF8 is not null and sUTF8_count > 0, then the UTF-8 encoded string is returned in this buffer. If there is room for the null terminator, the converted string will be null terminated. The null terminator is never included in the count of returned by this function. The converted string is in the CPU's native byte order. No byte order mark is prepended.
sUTF8_count - [in] If sUTF8_count > 0, then it specifies the number of available char elements in the sUTF8[] buffer.
If sUTF8_count == 0, then the sUTF8 parameter is ignored.
error_status - [out] If error_status is not null, then bits of *error_status are set to indicate the success or failure of the conversion.
When the error_mask parameter is used to used to mask some conversion errors, multiple bits may be set. 0: Successful conversion with no errors. 1: The input parameters were invalid. This error cannot be masked. 2: The output buffer was not large enough to hold the converted string. As much conversion as possible is performed in this case and the error cannot be masked. 4: When parsing a UTF-8 or UTF-32 string, the values of two consecutive encoding sequences formed a valid UTF-16 surrogate pair.
This error is masked if 0 != (4 & m_error_mask). If the error is masked, then the surrogate pair is decoded, the value of the resulting unicode code point is used, and parsing continues. 8: An overlong UTF-8 encoding sequence was encountered and the value of the overlong sUTF-8 sequence was a valid unicode code point.
This error is masked if 0 != (8 & m_error_mask). If the error is masked, then the unicode code point is used and parsing continues. 16: An illegal UTF-8, UTF-16 or UTF-32 encoding sequence occurred or an invalid unicode code point value resulted from decoding a UTF-8 sequence. This error is masked if 0 != (16 & m_error_mask). If the error is masked and the value of error_code_point is a valid unicode code point, then error_code_point is encoded in the output string and parsing continues.
error_mask - [in] If 0 != (error_mask & 4), then type 4 errors are masked. If 0 != (error_mask & 8), then type 8 errors are masked. If 0 != (error_mask & 16) and error_code_point is a valid unicode code point value, then type 16 errors are masked.
error_code_point - [in] Unicode code point value to use in when masking type 16 errors. If 0 == (error_mask & 16), then this parameter is ignored. ON_UnicodeCodePoint::ON_ReplacementCharacter (U+FFFD) is a popular choice for the error_code_point value.
sNextWideChar - [out] If sNextWideChar is not null, then *sNextWideChar points to the first element in the input sWideChar[] buffer that was not converted.
If an error occurs and is not masked, then *sNextWideChar points to the element of sWideChar[] where the conversion failed. If no errors occur or all errors are masked, then *sNextWideChar points to sWideChar + sWideChar_count.
If sUTF8_count > 0, the return value is the number of char elements written to sUTF8[]. When the return value < sUTF8_count, a null terminator is written to sUTF8[return value].
If sUTF8_count == 0, the return value is the minimum number of char elements that are needed to hold the converted string. The return value does not include room for a null terminator.
Increment the return value by one if you want to have an element to use for a null terminator.
ON_DECL int ON_ConvexHull2d | ( | const ON_SimpleArray< ON_2dPoint > & | Pnt, |
ON_SimpleArray< ON_2dPoint > & | Hull, | ||
ON_SimpleArray< int > * | PntInd = nullptr |
||
) |
Compute Convex hull of 2d points Parameters: Pnt - array of points. HUll - the sequence Hull[0], HUll[1]... ,*Hull.Last() == Hull[0] defines the convex hull with a positive orientation when returns 2. PntInd - optional array to be filled in so that Hull[i] = Pnt[ PntInd[i]] . Returns dimension of the convex hull 2 - Hull is 2 dimensional 1 - Hull is a line segment 0 - hull is a point <0 error
ON_DECL int ON_CorrectBase32StringTypos | ( | const char * | sBase32, |
char * | sBase32clean | ||
) |
ON_DECL int ON_CorrectBase32StringTypos | ( | const wchar_t * | sBase32, |
ON_wString & | sBase32clean | ||
) |
Description: Fixt a common typos in sBase32 string. Lower case letters are converted to upper case. The letters 'I', 'L', 'O' and 'S' are converted to '1' (one), '1' (one) '0' zero and '5' (five). Parameters: sBase32 - [in] sBase32clean - [out] (can be the same string as sBase32) Returns: If the input is valid, the length of the converted string is returned. If the input is not valid, 0 is returned.
ON_DECL int ON_CrashTest | ( | int | crash_type, |
ON_TextLog & | text_log | ||
) |
ON_BEGIN_EXTERNC ON_DECL ON__UINT16 ON_CRC16 | ( | ON__UINT16 | current_remainder, |
size_t | sizeof_buffer, | ||
const void * | buffer | ||
) |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org. Description: Continues 16 bit CRC calculation to include the buffer.
Parameters: current_remainder - [in] sizeof_buffer - [in] number of bytes in buffer buffer - [in]
Example: 16 bit CRC calculations are typically done something like this:
const ON__UINT16 crc_seed = 0; ///< or 1, or your favorite starting value
/ Compute CRC on "good" data unsigned ON__UINT16 first_crc = crc_seed; first_crc = ON_CRC16( first_crc, size1, buffer1 ); ... first_crc = ON_CRC16( first_crc, sizeN, bufferN ); unsigned char two_zero_bytes[2] = (0,0); first_crc = ON_CRC16( first_crc, 2, two_zero_bytes );
/ make sure 16 bit CRC calculation is valid ON__UINT16 check_crc_calculation = ON_CRC16( first_crc, 2, &first_crc ); if ( check_crc_calculation != 0 ) { printf("ON_CRC16() calculated a bogus 16 bit CRC\n"); }
/ Do something that may potentially change the values in / the buffers (like storing them on a faulty disk).
/ Compute CRC on "suspect" data ON__UINT16 second_crc = crc_seed; second_crc = ON_CRC16( second_crc, size1, buffer1 ); ... second_crc = ON_CRC16( second_crc, sizeN, bufferN ); if ( 0 != ON_CRC16( second_crc, 2, &first_crc ) ) { printf( "The value of at least one byte has changed.\n" ); }
ON_DECL ON__UINT32 ON_CRC32 | ( | ON__UINT32 | current_remainder, |
size_t | sizeof_buffer, | ||
const void * | buffer | ||
) |
Description: Continues 32 bit CRC calculation to include the buffer
ON_CRC32() is a slightly altered version of zlib 1.3.3's crc32() and the zlib "legal stuff" is reproduced below.
ON_CRC32() and zlib's crc32() compute the same values. ON_CRC32() was renamed so it wouldn't clash with the other crc32()'s that are out there and the argument order was switched to match that used by the legacy ON_CRC16().
Parameters: current_remainder - [in] sizeof_buffer - [in] number of bytes in buffer buffer - [in]
Example: 32 bit CRC calculations are typically done something like this:
const ON__UINT32 crc_seed = 0; ///< or 1, or your favorite starting value
/Compute CRC on "good" data ON__UINT32 first_crc = crc_seed; first_crc = ON_CRC32( first_crc, size1, buffer1 ); ... first_crc = ON_CRC32( first_crc, sizeN, bufferN );
/ Do something that may potentially change the values in / the buffers (like storing them on a faulty disk).
/ Compute CRC on "suspect" data ON__UINT32 second_crc = crc_seed; second_crc = ON_CRC32( second_crc, size1, buffer1 ); ... second_crc = ON_CRC32( second_crc, sizeN, bufferN ); if ( second_crc != first_crc ) { printf( "The value of at least one byte has changed.\n" ); }
ON_END_EXTERNC ON_DECL bool ON_CreateUuid | ( | ON_UUID & | uuid | ) |
Description: Creates a new uuid.(&a,&b) compares two uuids. Parameters: new_uuid - [out] Returns: True if successful.
ON_DECL ON_3dVector ON_CrossProduct | ( | const double * | , |
const double * | |||
) |
ON_DECL ON_3fVector ON_CrossProduct | ( | const float * | , |
const float * | |||
) |
ON_DECL ON_3dVector ON_CrossProduct | ( | const ON_2dVector & | , |
const ON_2dVector & | |||
) |
ON_DECL ON_3fVector ON_CrossProduct | ( | const ON_2fVector & | , |
const ON_2fVector & | |||
) |
ON_DECL ON_3dVector ON_CrossProduct | ( | const ON_3dVector & | , |
const ON_3dVector & | |||
) |
ON_DECL ON_3fVector ON_CrossProduct | ( | const ON_3fVector & | , |
const ON_3fVector & | |||
) |
ON_DECL ON_Quaternion ON_CrossProduct | ( | const ON_Quaternion & | p, |
const ON_Quaternion & | q | ||
) |
Returns: The vector cross product of p and q = (0,x,y,z) where (x,y,z) = ON_CrossProduct(p.Vector(),q.Vector())
This is NOT the same as the quaternion product p*q.
ON_DECL bool ON_CSXFirstOrderNecessaryConditions | ( | ON_TextLog * | text_log, |
const ON_X_EVENT & | xevent, | ||
int | end_index, | ||
const ON_Interval * | curve_domain, | ||
const ON_Interval * | surface_domain0, | ||
const ON_Interval * | surface_domain1 | ||
) |
Check First Order Necessary Conditions for CSX result Curve surface intersection solves an optimization problem. This code verifies that the solution point, either a csx_point or the end of a csx_overlap, satisfies what are called first order necessary conditions for the point being a local minimum relative to the specified problem domain Parameters: text_log - (in)optional text log.If false is returned the problem description is logged. xevent - (in)CSX event result must be a csx_point or csx_overlap event type end_index - (in)If xevent is an overlap then end_index should be 0 or 1
These are the parameters that we used to call Curve::IntersectSurface() curve_domain(in) surface_domain - (in) Return : true if the point satisfies the first order necessary conditions for this point being a local minimum
ON_DECL double ON_CurveOrientationArea | ( | const ON_Curve * | curve, |
const ON_Interval * | domain, | ||
const ON_Xform * | xform, | ||
bool | bReverseCurve | ||
) |
Description: Get a crude approximation of the signed area of the region in the x-y plane traced out by the curve. This is useful for calculating the orientation of projections of loops to planes when you have more than one curve. Parameters: curve - [in] domain - [in] optional sub-domain. (null if entire curve should be used). xform - [in] Transformation to map the curve to the xy plane. If the curve is parallel to the xy plane, you may pass nullptr. bReverseCurve - [in] Returns: 1/2 the sum of (p[i].x-p[i+1].x)*(p[i].y+p[i+1].y), where p[i] is a series of sampled points on the curve.
ON_DECL bool ON_CvxHullFromLeafBox | ( | ON_ConvexHullPoint2 & | Hull, |
const ON_SurfaceLeafBox & | leaf | ||
) |
ON_DECL unsigned int ON_DayOfGregorianYear | ( | unsigned int | year, |
unsigned int | month, | ||
unsigned int | day_of_month | ||
) |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org. Description: Get the day of the year from the year, month and day_of_month. Parameters: year - [in] >= 1582 month - [in] >= 1 and <= 12 day_of_month - [in] >= 1 and <= last valid day_of_month of the month Returns: 0: Invalid input 1 to 366: Day of Gregorian year.
ON_DECL unsigned int ON_DaysInGregorianYear | ( | unsigned int | year | ) |
Parameters: year - [in] >= 1582 Returns: 0: Invalid input 365: If the year is a common year in the Gregorian calendar 366: If the year is a leap year in the Gregorian calendar
ON_DECL unsigned int ON_DaysInMonthOfGregorianYear | ( | unsigned int | year, |
unsigned int | month | ||
) |
Description: Get the number of days in a Gregorian month. Parameters: year - [in] >= 1582 month - [in] >= 1 and <= 12 Returns: 0: Invalid input 28, 29, 30 or 31: number of days in the specified month.
ON_DECL void ON_DBL_SNAN | ( | double * | x | ) |
Description: Parameters: x - [out] returned value of x is an SNan (signalling not a number). Remarks: Any time an SNaN passes through an Intel FPU, the result is a QNaN (quiet nan) and the invalid operation exception flag is set. If this exception is not masked, then the exception handler is invoked.
double x, y; ON_DBL_SNAN(&x); y = x; ///< y = QNAN and invalid op exception occurs z = sin(x) ///< z = QNAN and invalid op exception occurs
So, if you want to reliably initialize doubles to SNaNs, you must use memcpy() or some other method that does not use the Intel FPU.
Description: ON_DebugWriteObject is a debugging utility that can be called from a debugger's evaluate expression window to dump objects for future inspection. Parameters: pObject - [in] Returns: If successful, an integer N > 0 which indicates the object was saved in a file named debug_file_XXXXX.3dm, where XXXXX is a %05d format of N. The file is in the directory named ON_DebugWriteObjectDirectory(). See Also: ON_SetDebugWriteObjectDirectory(); ON_DebugWritePoint() ON_DebugWriteObjects() ON_DebugWriteObjectArray()
ON_DECL int ON_DebugWriteObjectArray | ( | const ON_SimpleArray< const class ON_Object * > & | object_list | ) |
Description: ON_DebugWriteObjectArray is a debugging utility that can be called from C++ or from a debugger's evaluate expression window to dump objects for future inspection. Parameters: object_list - [in] object list Returns: If successful, an integer N > 0 which indicates the object was saved in a file named debug_file_XXXXX.3dm, where XXXXX is a %05d format of N. The file is in the directory named ON_DebugWriteObjectDirectory(). See Also: ON_DebugWriteObject() ON_SetDebugWriteObjectDirectory();
const ON_DECL wchar_t* ON_DebugWriteObjectDirectory | ( | ) |
Description: Get the directory where ON_DebugWriteObject() will write the .3dm file. Returns: The directory name or null if the name has not been set.
Description: ON_DebugWriteObjects is a debugging utility that can be called from C++ or from a debugger's evaluate expression window to dump objects for future inspection. Parameters: object_list_count - [in] explicit object list count object_list - [in] object list Returns: If successful, an integer N > 0 which indicates the object was saved in a file named debug_file_XXXXX.3dm, where XXXXX is a %05d format of N. The file is in the directory named ON_DebugWriteObjectDirectory(). See Also: ON_DebugWriteObject() ON_SetDebugWriteObjectDirectory();
ON_DECL int ON_DebugWritePoint | ( | const class ON_3dPoint * | p3dPoint | ) |
Description: ON_DebugWritePoint is a debugging utility that can be called from C++ or from a debugger's evaluate expression window to dump 3d points for future inspection. Parameters: p3dPoint - [in] Returns: If successful, an integer N > 0 which indicates the object was saved in a file named debug_file_XXXXX.3dm, where XXXXX is a %05d format of N. The file is in the directory named ON_DebugWriteObjectDirectory(). See Also: ON_DebugWriteObject() ON_SetDebugWriteObjectDirectory()
ON_DECL int ON_DebugWritePoints | ( | const double * | pPoint, |
int | dim, | ||
bool | is_rat, | ||
int | count | ||
) |
Description: ON_DebugWritePoints is a debugging utility that can be called from C++ or from a debugger's evaluate expression window to dump an array of points as a 3d ON_PointCloud for future inspection. Parameters: pPoint - [in] dim - [in] dimension of points must be 2 or 3 is_rat -[in] true if points are homogeneous count - [in] number of points Returns: If successful, an integer N > 0 which indicates the object was saved in a file named debug_file_XXXXX.3dm, where XXXXX is a %05d format of N. The file is in the directory named ON_DebugWriteObjectDirectory(). See Also: ON_DebugWriteObject() ON_SetDebugWriteObjectDirectory()
ON__UINT32 ON_DECL ON_DecalCRCFromNode | ( | const ON_XMLNode & | node | ) |
For internal use only.
ON_DECL double ON_DecimalHoursFromHMS | ( | int | hour, |
int | minute, | ||
int | second | ||
) |
Description: Converts a time specified as hour, minute and second to a decimal hours value. Example: hour=9, minute=30, second=0 -> result is 9.5 Parameters: hour - [in] The hour value of the time. minute - [in] The minute value of the time. second - [in] The second value of the time. Returns: The decimal hours value corresponding to the hour, minute and second.
ON_DECL void ON_DecimalHoursToHMS | ( | double | hours, |
int & | hour, | ||
int & | minute, | ||
int & | second | ||
) |
Description: Converts a time specified as decimal hours to hour, minute and second. Guaranteed to produce a valid hour, minute and second result. Example: hours=9.5 -> result is hour=9, minute=30, second=0.
Parameters: hours - [in] The decimal hours value of the time. If not in range 0..23 it will be 'unwound' to be in range. hour - [out] The hour value of the time specified by 'hours'. minute - [out] The minute value of the time specified by 'hours'. second - [out] The second value of the time specified by 'hours'.
ON_DECL void ON_DecimalHoursToHMS | ( | double | hours, |
int & | hour, | ||
int & | minute, | ||
int & | second, | ||
int & | year, | ||
int & | month, | ||
int & | day | ||
) |
Description: Converts a time specified as decimal hours to hour, minute and second. Guaranteed to produce a valid hour, minute and second result. Example: hours=9.5 -> result is hour=9, minute=30, second=0. Because of rounding, a value such as 23.99999 will come out as midnight the next day. Therefore, the year, month and day are also passed in so that they can be adjusted if necessary. Example: hours=23.99999 -> result is hour=0, minute=0, second=0 and date is incremented by one day.
Parameters: hours - [in] The decimal hours value of the time. If not in range 0..23 it will be 'unwound' to be in range. hour - [out] The hour value of the time specified by 'hours'. minute - [out] The minute value of the time specified by 'hours'. second - [out] The second value of the time specified by 'hours'. year - [in/out] The year value of the date, adjusted if necessary. month - [in/out] The month value of the date, adjusted if necessary. day - [in/out] The day value of the date, adjusted if necessary.
ON_DECL int ON_DecodeSwapByteUTF16 | ( | const ON__UINT16 * | sUTF16, |
int | sUTF16_count, | ||
struct ON_UnicodeErrorParameters * | e, | ||
ON__UINT32 * | unicode_code_point | ||
) |
Description: Decode a UTF-16 encode string whose elements have byte order opposite native byte order to get a single unicode code point. Parameters: sUTF16 - [in] UTF-16 string to convert with byte order opposite the CPU's native byte order.
sUTF16_count - [in] number of ON__UINT16 elements in sUTF16[].
e - [in/out] If e is null, errors are not masked and parsing is performed to the point where the first error occurs. If e is not null, all errors are reported by setting the appropriate e->m_error_status bits and errors are handled as described in the definition of the ON_UnicodeErrorParameters struct.
ON_UnicodeErrorParameters e = ON_UnicodeErrorParameters::MaskErrors; or ON_UnicodeErrorParameters e = ON_UnicodeErrorParameters::FailOnErrors; are good ways to initialize the input values.
unicode_code_point - [out] The unicode_code_point pointer must not be null. If a nonzero value is returned, then *unicode_code_point is a valid unicode code point value in the CPU's native byte order. Returns: Number of elements of sUTF16 that were parsed. 0: Nothing was decoded. The input value of *unicode_code_point is not changed. See e->m_error_status. 1: If no error occurred, then sUTF16[0] was decoded as a valid UTF-16 singleton. See e for masked errors. 2: If no error occurred, then sUTF16[0],sUTF16[1] was decoded as a valid UTF-16 surrogate pair. See e for masked errors. n >= 3: sUTF16[0],..,sUTF16[n-1] did not forma valid UTF-16 encoding and were parsed as reasonably as possible. See e for masked errors.
ON_DECL int ON_DecodeSwapByteUTF32 | ( | const ON__UINT32 * | sUTF32, |
int | sUTF32_count, | ||
struct ON_UnicodeErrorParameters * | e, | ||
ON__UINT32 * | unicode_code_point | ||
) |
Description: Decode a UTF-32 string whose elements have byte order opposite the native CPU's to get a single unicode code point. Parameters: sUTF32 - [in] UTF-32 string to convert with byte order opposite the CPU's native byte order.
sUTF32_count - [in] number of ON__UINT32 elements in sUTF32[].
e - [in/out] If e is null, errors are not masked and parsing is performed to the point where the first error occurs. If e is not null, all errors are reported by setting the appropriate e->m_error_status bits and errors are handled as described in the definition of the ON_UnicodeErrorParameters struct.
ON_UnicodeErrorParameters e = ON_UnicodeErrorParameters::MaskErrors; or ON_UnicodeErrorParameters e = ON_UnicodeErrorParameters::FailOnErrors; are good ways to initialize the input values.
unicode_code_point - [out] The unicode_code_point pointer must not be null. If a nonzero value is returned, then *unicode_code_point is a valid unicode code point value in the CPU's native byte order. Returns: Number of elements of sUTF32 that were parsed. 0: Nothing was decoded. The input value of *unicode_code_point is not changed. See e->m_error_status. 1: If no error occurred, then sUTF32[0] was decoded was a valid UTF-32 value. See e for masked errors. 2: sUTF32[0],sUTF32[1] had values of a valid UTF-16 surrogate pair and e indicated to mask this error. The UTF-16 code point value was returned and e was set to indicate the error occurred.
ON_DECL int ON_DecodeUTF16 | ( | const ON__UINT16 * | sUTF16, |
int | sUTF16_count, | ||
struct ON_UnicodeErrorParameters * | e, | ||
ON__UINT32 * | unicode_code_point | ||
) |
Description: Decode a UTF-16 string in native byte order to get a single unicode code point. Parameters: sUTF16 - [in] UTF-16 string in native byte order to convert.
sUTF16_count - [in] number of ON__UINT16 elements in sUTF16[].
e - [in/out] If e is null, errors are not masked and parsing is performed to the point where the first error occurs. If e is not null, all errors are reported by setting the appropriate e->m_error_status bits and errors are handled as described in the definition of the ON_UnicodeErrorParameters struct.
ON_UnicodeErrorParameters e = ON_UnicodeErrorParameters::MaskErrors; or ON_UnicodeErrorParameters e = ON_UnicodeErrorParameters::FailOnErrors; are good ways to initialize the input values.
unicode_code_point - [out] The unicode_code_point pointer must not be null. If a nonzero value is returned, then *unicode_code_point is a valid unicode code point value in the CPU's native byte order. Returns: Number of elements of sUTF16 that were parsed. 0: Nothing was decoded. The input value of *unicode_code_point is not changed. See e->m_error_status. 1: If no error occurred, then sUTF16[0] was decoded as a valid UTF-16 singleton. See e for masked errors. 2: If no error occurred, then sUTF16[0],sUTF16[1] was decoded as a valid UTF-16 surrogate pair. See e for masked errors. n >= 3: sUTF16[0],..,sUTF16[n-1] did not form a valid UTF-16 encoding and were parsed as reasonably as possible. See e for masked errors.
ON_DECL int ON_DecodeUTF16BE | ( | const ON__UINT16 * | sUTF16, |
int | sUTF16_count, | ||
struct ON_UnicodeErrorParameters * | e, | ||
ON__UINT32 * | unicode_code_point | ||
) |
Description: Decode a UTF-16 big endian byte order string to get a single unicode code point. Parameters: sUTF16 - [in] UTF-16 big endian byte order string to convert.
sUTF16_count - [in] number of ON__UINT16 elements in sUTF16[].
e - [in/out] If e is null, errors are not masked and parsing is performed to the point where the first error occurs. If e is not null, all errors are reported by setting the appropriate e->m_error_status bits and errors are handled as described in the definition of the ON_UnicodeErrorParameters struct.
ON_UnicodeErrorParameters e = ON_UnicodeErrorParameters::MaskErrors; or ON_UnicodeErrorParameters e = ON_UnicodeErrorParameters::FailOnErrors; are good ways to initialize the input values.
unicode_code_point - [out] The unicode_code_point pointer must not be null. If a nonzero value is returned, then *unicode_code_point is a valid unicode code point value in the CPU's native byte order. Returns: Number of elements of sUTF16 that were parsed. 0: Nothing was decoded. The input value of *unicode_code_point is not changed. See e->m_error_status. 1: If no error occurred, then sUTF16[0] was decoded as a valid UTF-16 singleton. See e for masked errors. 2: If no error occurred, then sUTF16[0],sUTF16[1] was decoded as a valid UTF-16 surrogate pair. See e for masked errors. n >= 3: sUTF16[0],..,sUTF16[n-1] did not form a valid UTF-16 encoding and were parsed as reasonably as possible. See e for masked errors.
ON_DECL int ON_DecodeUTF16LE | ( | const ON__UINT16 * | sUTF16, |
int | sUTF16_count, | ||
struct ON_UnicodeErrorParameters * | e, | ||
ON__UINT32 * | unicode_code_point | ||
) |
Description: Decode a UTF-16 little endian byte order string to get a single unicode code point. Parameters: sUTF16 - [in] UTF-16 little endian byte order string to convert.
sUTF16_count - [in] number of ON__UINT16 elements in sUTF16[].
e - [in/out] If e is null, errors are not masked and parsing is performed to the point where the first error occurs. If e is not null, all errors are reported by setting the appropriate e->m_error_status bits and errors are handled as described in the definition of the ON_UnicodeErrorParameters struct.
ON_UnicodeErrorParameters e = ON_UnicodeErrorParameters::MaskErrors; or ON_UnicodeErrorParameters e = ON_UnicodeErrorParameters::FailOnErrors; are good ways to initialize the input values.
unicode_code_point - [out] The unicode_code_point pointer must not be null. If a nonzero value is returned, then *unicode_code_point is a valid unicode code point value in the CPU's native byte order. Returns: Number of elements of sUTF16 that were parsed. 0: Nothing was decoded. The input value of *unicode_code_point is not changed. See e->m_error_status. 1: If no error occurred, then sUTF16[0] was decoded as a valid UTF-16 singleton. See e for masked errors. 2: If no error occurred, then sUTF16[0],sUTF16[1] was decoded as a valid UTF-16 surrogate pair. See e for masked errors. n >= 3: sUTF16[0],..,sUTF16[n-1] did not form a valid UTF-16 encoding and were parsed as reasonably as possible. See e for masked errors.
ON_DECL unsigned int ON_DecodeUTF16SurrogatePair | ( | unsigned int | u1, |
unsigned int | u2, | ||
unsigned int | error_code_point | ||
) |
Parameters: w1 - [in] w2 - in] error_code_point - [in] Value returned when (w1,w2) is not a value UTF-16 surrogate pair. Depending on what you are doing, good choices are 0, ON_UnicodeCodePoint::ON_ReplacementCharacter, and and ON_UnicodeCodePoint::ON_InvalidCodePoint Returns: If (w1,w2) is a valid UTF-16 surrogate pair, the corresponding unicode code point is returned. This value is always > 0. Otherwise, error_code_point is returned.
ON_DECL int ON_DecodeUTF32 | ( | const ON__UINT32 * | sUTF32, |
int | sUTF32_count, | ||
struct ON_UnicodeErrorParameters * | e, | ||
ON__UINT32 * | unicode_code_point | ||
) |
Description: Decode a UTF-32 native byte order string to get a single unicode code point. Parameters: sUTF32 - [in] UTF-32 native byte order string to convert.
sUTF32_count - [in] number of ON__UINT32 elements in sUTF32[].
e - [in/out] If e is null, errors are not masked and parsing is performed to the point where the first error occurs. If e is not null, all errors are reported by setting the appropriate e->m_error_status bits and errors are handled as described in the definition of the ON_UnicodeErrorParameters struct.
ON_UnicodeErrorParameters e = ON_UnicodeErrorParameters::MaskErrors; or ON_UnicodeErrorParameters e = ON_UnicodeErrorParameters::FailOnErrors; are good ways to initialize the input values.
unicode_code_point - [out] The unicode_code_point pointer must not be null. If a nonzero value is returned, then *unicode_code_point is a valid unicode code point value in the CPU's native byte order. Returns: Number of elements of sUTF32 that were parsed. 0: Nothing was decoded. The input value of *unicode_code_point is not changed. See e->m_error_status. 1: If no error occurred, then sUTF32[0] was decoded was a valid UTF-32 value. See e for masked errors. 2: sUTF32[0],sUTF32[1] had values of a valid UTF-16 surrogate pair and e indicated to mask this error. The UTF-16 code point value was returned and e was set to indicate the error occurred.
ON_DECL int ON_DecodeUTF32BE | ( | const ON__UINT32 * | sUTF32, |
int | sUTF32_count, | ||
struct ON_UnicodeErrorParameters * | e, | ||
ON__UINT32 * | unicode_code_point | ||
) |
Description: Decode a UTF-32 big endian byte order string to get a single unicode code point. Parameters: sUTF32 - [in] UTF-32 big byte order string to convert.
sUTF32_count - [in] number of ON__UINT32 elements in sUTF32[].
e - [in/out] If e is null, errors are not masked and parsing is performed to the point where the first error occurs. If e is not null, all errors are reported by setting the appropriate e->m_error_status bits and errors are handled as described in the definition of the ON_UnicodeErrorParameters struct.
ON_UnicodeErrorParameters e = ON_UnicodeErrorParameters::MaskErrors; or ON_UnicodeErrorParameters e = ON_UnicodeErrorParameters::FailOnErrors; are good ways to initialize the input values.
unicode_code_point - [out] The unicode_code_point pointer must not be null. If a nonzero value is returned, then *unicode_code_point is a valid unicode code point value in the CPU's native byte order. Returns: Number of elements of sUTF32 that were parsed. 0: Nothing was decoded. The input value of *unicode_code_point is not changed. See e->m_error_status. 1: If no error occurred, then sUTF32[0] was decoded was a valid UTF-32 value. See e for masked errors. 2: sUTF32[0],sUTF32[1] had values of a valid UTF-16 surrogate pair and e indicated to mask this error. The UTF-16 code point value was returned and e was set to indicate the error occurred.
ON_DECL int ON_DecodeUTF32LE | ( | const ON__UINT32 * | sUTF32, |
int | sUTF32_count, | ||
struct ON_UnicodeErrorParameters * | e, | ||
ON__UINT32 * | unicode_code_point | ||
) |
Description: Decode a UTF-32 little endian byte order string to get a single unicode code point. Parameters: sUTF32 - [in] UTF-32 little byte order string to convert.
sUTF32_count - [in] number of ON__UINT32 elements in sUTF32[].
e - [in/out] If e is null, errors are not masked and parsing is performed to the point where the first error occurs. If e is not null, all errors are reported by setting the appropriate e->m_error_status bits and errors are handled as described in the definition of the ON_UnicodeErrorParameters struct.
ON_UnicodeErrorParameters e = ON_UnicodeErrorParameters::MaskErrors; or ON_UnicodeErrorParameters e = ON_UnicodeErrorParameters::FailOnErrors; are good ways to initialize the input values.
unicode_code_point - [out] The unicode_code_point pointer must not be null. If a nonzero value is returned, then *unicode_code_point is a valid unicode code point value in the CPU's native byte order. Returns: Number of elements of sUTF32 that were parsed. 0: Nothing was decoded. The input value of *unicode_code_point is not changed. See e->m_error_status. 1: If no error occurred, then sUTF32[0] was decoded was a valid UTF-32 value. See e for masked errors. 2: sUTF32[0],sUTF32[1] had values of a valid UTF-16 surrogate pair and e indicated to mask this error. The UTF-16 code point value was returned and e was set to indicate the error occurred.
ON_DECL int ON_DecodeUTF8 | ( | const char * | sUTF8, |
int | sUTF8_count, | ||
struct ON_UnicodeErrorParameters * | e, | ||
ON__UINT32 * | unicode_code_point | ||
) |
Description: Decode a UTF-8 encode string to get a single unicode code point. Parameters: sUTF8 - [in] UTF-8 string to convert.
sUTF8_count - [in] number of char elements in sUTF8[].
e - [in/out] If e is null, errors are not masked and parsing is performed to the point where the first error occurs. If e is not null, all errors are reported by setting the appropriate e->m_error_status bits and errors are handled as described in the definition of the ON_UnicodeErrorParameters struct.
ON_UnicodeErrorParameters e = ON_UnicodeErrorParameters::MaskErrors; or ON_UnicodeErrorParameters e = ON_UnicodeErrorParameters::FailOnErrors; are good ways to initialize the input values.
unicode_code_point - [out] The unicode_code_point pointer must not be null. If a nonzero value is returned, then *unicode_code_point is a valid unicode code point value. Returns: Number of elements of sUTF8 that were parsed. 0 indicates failure.
ON_DECL int ON_DecodeWideChar | ( | const wchar_t * | sWideChar, |
int | sWideChar_count, | ||
struct ON_UnicodeErrorParameters * | e, | ||
ON__UINT32 * | unicode_code_point | ||
) |
Description: Decode a UTF-16 encode string whose elements have byte order opposite the native CPU's to get a single unicode code point. Parameters: sWideChar - [in] wchar_t string to convert.
sWideChar_count - [in] number of wchar_t elements in sWideChar[].
e - [in/out] If e is null, errors are not masked and parsing is performed to the point where the first error occurs. If e is not null, all errors are reported by setting the appropriate e->m_error_status bits and errors are handled as described in the definition of the ON_UnicodeErrorParameters struct.
ON_UnicodeErrorParameters e = ON_UnicodeErrorParameters::MaskErrors; or ON_UnicodeErrorParameters e = ON_UnicodeErrorParameters::FailOnErrors; are good ways to initialize the input values.
unicode_code_point - [out] The unicode_code_point pointer must not be null. If a nonzero value is returned, then *unicode_code_point is a valid unicode code point value in the CPU's native byte order. Returns: Number of elements of sUTF16 that were parsed. 0: Nothing was decoded. The input value of *unicode_code_point is not changed. See e->m_error_status. 1: If no error occurred, then sWideChar[0] was decoded as a valid wchar_t singleton. See e for masked errors. n>=2: If no error occurred, then sWideChar[0],..,sWideChar[n-1] was decoded as a valid wchar_t multi-element encoding. Typically, UTF-16 surrogate pair or UTF-8 multi-byte sequence. See e for masked errors.
ON_DECL int ON_DecomposeVector | ( | const ON_3dVector & | V, |
const ON_3dVector & | A, | ||
const ON_3dVector & | B, | ||
double * | x, | ||
double * | y | ||
) |
Description: Finds scalars x and y so that the component of V in the plane of A and B is x*A + y*B. Parameters: V - [in] A - [in] nonzero and not parallel to B B - [in] nonzero and not parallel to A x - [out] y - [out] Returns: 1 - The rank of the problem is 2. The decomposition is unique. 0 - The rank less than 2. Either there is no solution or there are infinitely many solutions.
See Also: ON_Solve2x2
ON_DECL double ON_DegreesFromRadians | ( | double | angle_in_radians | ) |
Parameters: angle_in_radians - [in] Angle measure in radians Returns: Angle measure in degrees
ON_DECL void ON_Disableonmalloc | ( | ) |
ON_DECL bool ON_DollyExtents | ( | const ON_Viewport & | current_vp, |
ON_BoundingBox | camcoord_bbox, | ||
ON_Viewport & | zoomed_vp | ||
) |
Dolly the camera location and so that the view frustum contains camcoord_bbox and the volume of camcoord_bbox fills the frustum. If the projection is perspective, the camera angle is not changed. Parameters: current_vp - [in] Current projection, must be valid. camcoord_bbox - [in] Valid bounding box in current_vp camera coordinates. zoomed_vp - [out] Can be the same as current_vp projection. Returns: True if successful.
ON_DECL double ON_DomainTolerance | ( | double | , |
double | |||
) |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org.
ON_DECL double ON_DotProduct | ( | const ON_2dVector & | , |
const ON_2dVector & | |||
) |
ON_2dVector utilities
ON_DECL float ON_DotProduct | ( | const ON_2fVector & | , |
const ON_2fVector & | |||
) |
ON_2fVector utilities
ON_DECL double ON_DotProduct | ( | const ON_3dVector & | , |
const ON_3dVector & | |||
) |
ON_3dVector utilities
ON_DECL float ON_DotProduct | ( | const ON_3fVector & | , |
const ON_3fVector & | |||
) |
ON_3fVector utilities
ON_DECL double ON_DoubleFromFloat | ( | float | x | ) |
Returns: ON_UNSET_VALUE, if x = ON_UNSET_FLOAT. ON_UNSET_POSITIVE_VALUE, if x = ON_UNSET_POSITIVE_FLOAT. (double)x, otherwise.
ON_DECL void ON_DumpSquishInfoText | ( | const ON_Geometry * | squished_geometry, |
ON_TextLog & | text_log, | ||
const wchar_t * | objid_locale_str, | ||
const wchar_t * | meshcount_locale_str | ||
) |
ON_DECL ON_CurveTreeBezier* ON_DuplicateCurveTreeBezier | ( | const ON_CurveTreeBezier & | src | ) |
ON_DECL ON_SurfaceTreeBezier* ON_DuplicateSurfaceTreeBezier | ( | const ON_SurfaceTreeBezier & | src | ) |
ON_DECL double ON_EigenvectorPrecision | ( | const unsigned int | N, |
const double *const * | M, | ||
bool | bTransposeM, | ||
double | lambda, | ||
const double * | eigenvector | ||
) |
ON_DECL void ON_EnableDebugBreak | ( | int | bEnableDebugBreak | ) |
ON_DECL void ON_EnableDebugBreakOnFirstError | ( | int | bEnableDebugBreak | ) |
ON_DECL void ON_EnableDebugErrorMessage | ( | int | bEnableDebugErrorMessage | ) |
ON_DECL int ON_EncodeUTF16 | ( | ON__UINT32 | unicode_code_point, |
ON__UINT16 | sUTF16[2] | ||
) |
Description: Convert a 4 byte unicode code point value to its UTF-16 form. Parameters: unicode_code_point - [in] 4 byte unicode code point value in the CPU's native byte order. Valid values are in the interval [0,0xD7FF] or the interval [0xE000,0x10FFFF]. sUTF16 - [out] sUTF16 is buffer of 2 ON__UINT16 elements. If the UTF-16 form is a single value, it is returned in sUTF16[0]. If the UTF-16 is a surrogate pair, the first code unit (high surrogate) is returned sUTF16[0] and the second unit (low surrogate) is returned in sUTF16[1]. The returned values are in the CPU's native byte order. Returns: 0: u is not a valid Unicode code point. No changes are made to the sUTF16[] values. 1: u is a valid Unicode code point with a UTF-16 form consisting of the single value returned in sUTF16[0]. 2: u is a valid Unicode code point with a UTF-16 form consisting of a surrogate pair returned in sUTF16[0] and sUTF16[1].
ON_DECL int ON_EncodeUTF8 | ( | ON__UINT32 | u, |
char | sUTF8[6] | ||
) |
Description: Convert valid unicode code point values to its UTF-8 form and use the same encoding calculation for other integers with values <= 0x7FFFFFFF. When strict UTF-8 encoding is desired, the caller is responsible for insuring the value of u is a valid unicode codepoint. Parameters: u - [in] Integer in the CPU's native byte order in the interval [0,2147483647]. sUTF8 - [out] sUTF8 is a buffer of 6 char elements and the UTF-8 form is returned in sUTF8[]. The returned value specifies how many elements of sUTF8[] are set. Returns: 0: u is too large (>=2^31) to be encode. No changes are made to the sUTF8[] values. 1: the UTF-8 form of u is 1 byte returned in sUTF8[0]. 2: the UTF-8 form of u is 2 bytes returned in sUTF8[0],sUTF8[1]. 3: the UTF-8 form of u is 3 bytes returned in sUTF8[0],sUTF8[1],sUTF8[2]. 4: the UTF-8 form of u is 4 bytes returned in sUTF8[0],sUTF8[1],sUTF8[2],sUTF8[3]. Note: The maximum valid unicode codepoint is 0x10FFFF. Values of u > 0x10FFFF and u <= 0x1FFFFF are encoded to 4 bytes using the same algorithm. 5: the Universal Character Set form of u is 5 bytes returned in sUTF8[0],sUTF8[1],sUTF8[2],sUTF8[3],sUTF8[4]. 6: the Universal Character Set form of u is 6 bytes returned in sUTF8[0],sUTF8[1],sUTF8[2],sUTF8[3],sUTF8[4],sUTF8[5]. For return values requiring less than 6 bytes, no changes are made to the unused bytes in sUTF8[]. Remarks: Any integer in the range 0 to 2^31 - 1 can be encoded. When a unicode string is being encoded take steps to ensure that u is a valid unicode code point value.
The function ON_IsValidUnicodeCodePoint() can be used to determine if u is a valid unicode code point value.
ON_DECL int ON_EncodeWideChar | ( | ON__UINT32 | code_point, |
size_t | w_capacity, | ||
wchar_t * | w | ||
) |
Description: Convert unicode code point values to its wide char form. Parameters: code_point - [in] Unicode code point in the CPU's native byte order. w_capacity - [in] If the platform wchar_t encoding is UTF-32, then w_capacity >= 1 is sufficient. If the platform wchar_t encoding is UTF-16, then w_capacity >= 2 is sufficient. If the platform wchar_t encoding is UTF-8, then w_capacity >= 6 is sufficient. w - [out] w is a buffer of w_capacity wchar_t elements and the wide char encoding of code_point is returned in w[]. The returned value specifies how many elements of w[] are set. When w_capacity > the returned value, the encoding is null terminated. Returns: 0: Invalid input (code_point is not a valid Unicode code point or w is nullptr). No changes are made to the w[] values. 1: the wchar_t encoding of code_point is 1 wchar_t element returned in w[0]. 2: the wchar_t encoding form of code_point is 2 wchar_t element returned in w[0],w[1]. 3: the UTF-8 wchar_t encoding form of code_point is 3 wchar_t element returned in w[0],w[1],w[2]. 4: the UTF-8 wchar_t encoding form of code_point is 4 wchar_t element returned in w[0],w[1],w[2],w[3]. 5: the UTF-8 wchar_t encoding form of code_point is 5 wchar_t element returned in w[0],w[1],w[2],w[3],w[4]. 6: the UTF-8 wchar_t encoding form of code_point is 6 wchar_t element returned in w[0],w[1],w[2],w[3],w[4],w[5].
ON_DECL void ON_VARGS_FUNC_CDECL ON_Error | ( | const char * | file_name, |
int | line_number, | ||
const char * | format, | ||
... | |||
) |
ON_DECL void ON_VARGS_FUNC_CDECL ON_ErrorEx | ( | const char * | file_name, |
int | line_number, | ||
const char * | function_name, | ||
const char * | format, | ||
... | |||
) |
ON_BEGIN_EXTERNC ON_DECL void ON_ErrorMessage | ( | int | , |
const char * | |||
) |
/ All error/warning messages are sent to ON_ErrorMessage(). Replace the / default handler (defined in opennurbs_error_message.cpp) with something / that is appropriate for debugging your application.
ON_DECL double ON_EvaluateBernsteinBasis | ( | int | , |
int | , | ||
double | |||
) |
ON_DECL bool ON_EvaluateBezier | ( | int | , |
bool | , | ||
int | , | ||
int | , | ||
const double * | , | ||
double | , | ||
double | , | ||
int | , | ||
double | , | ||
int | , | ||
double * | |||
) |
ON_DECL void ON_EvaluatedeCasteljau | ( | int | , |
int | , | ||
int | , | ||
int | , | ||
double * | , | ||
double | |||
) |
ON_DECL bool ON_EvaluateNurbsBasis | ( | int | order, |
const double * | knot, | ||
double | t, | ||
double * | N | ||
) |
Description: Evaluate B-spline basis functions
Parameters: order - [in] order >= 1 d = degree = order - 1 knot - [in] array of length 2*d.
Generally, knot[0] <= ... <= knot[d-1] < knot[d] <= ... <= knot[2*d-1]. These are the knots that are active for the span being evaluated. t - [in] Evaluation parameter. Typically knot[d-1] <= t <= knot[d]. In general t may be outside the interval knot[d-1],knot[d]. This can happen when some type of extrapolation is being used and is almost always a bad idea in practical situations.
N - [out] double array with capacity order*order. The returned values are:
If "N" were declared as double N[order][order], then
k
N[d-k][i] = N (t) = value of i-th degree k basis function at t. i where 0 <= k <= d and k <= i <= d.
In particular, N[0], ..., N[d] - values of degree d basis functions. The "lower left" triangle is not initialized.
Actually, the above is true when knot[d-1] <= t < knot[d]. Otherwise, the value returned is the value of the polynomial that agrees with N_i^k on the half open domain [ knot[d-1], knot[d] )
COMMENTS: If a degree d NURBS has n control points, then the OpenNURBS knot vector for the entire NURBS curve has length d+n-1. The knot[] parameter to this function points to the 2*d knots active for the span being evaluated.
Most literature, including DeBoor and The NURBS Book, duplicate the Opennurbs start and end knot values and have knot vectors of length d+n+1. The extra two knot values are completely superfluous when degree >= 1.
Assume C is a B-spline of degree d (order=d+1) with n control vertices (n>=d+1) and knot[] is its knot vector. Then
C(t) = Sum( 0 <= i < n, N_{i}(t) * C_{i} )
where N_{i} are the degree d b-spline basis functions and C_{i} are the control vertices. The knot[] array length d+n-1 and satisfies
knot[0] <= ... <= knot[d-1] < knot[d] knot[n-2] < knot[n-1] <= ... <= knot[n+d-2] knot[i] < knot[d+i] for 0 <= i < n-1 knot[i] <= knot[i+1] for 0 <= i < n+d-2
The domain of C is [ knot[d-1], knot[n-1] ].
The support of N_{i} is [ knot[i-1], knot[i+d] ).
If d-1 <= k < n-1 and knot[k] <= t < knot[k+1], then N_{i}(t) = 0 if i <= k-d = 0 if i >= k+2 = B[i-k+d-1] if k-d+1 <= i <= k+1, where B[] is computed by the call ON_EvaluateNurbsBasis( d+1, knot+k-d+1, t, B );
If 0 <= j < n-d, 0 <= m <= d, knot[j+d-1] <= t < knot[j+d], and B[] is computed by the call ON_EvaluateNurbsBasis( d+1, knot+j, t, B ), then N_{j+m}(t) = B[m].
ON_DECL bool ON_EvaluateNurbsBasisDerivatives | ( | int | order, |
const double * | knot, | ||
int | der_count, | ||
double * | N | ||
) |
Description: Calculate derivatives of B-spline basis functions. INPUT: order - [in] order >= 1 d = degree = order - 1 knot - [in] array of length 2*d.
Generally, knot[0] <= ... <= knot[d-1] < knot[d] <= ... <= knot[2*d-1]. These are the knots that are active for the span being evaluated. der_count - [in] 1 <= der_count < order Number of derivatives. Note all B-spline basis derivatives with der_count >= order are identically zero.
N - [in] The input value of N[] should be the results of the call ON_EvaluateNurbsBasis( order, knot, t, N );
N - [out] If "N" were declared as double N[order][order], then
d
N[d-k][i] = k-th derivative of N (t) i
where 0 <= k <= d and 0 <= i <= d.
In particular, N[0], ..., N[d] - values of degree d basis functions. N[order], ..., N[order_d] - values of first derivative.
ON_DECL bool ON_EvaluateNurbsBlossom | ( | int | , |
int | , | ||
int | , | ||
const double * | , | ||
const double * | , | ||
const double * | , | ||
double * | |||
) |
ON_DECL bool ON_EvaluateNurbsCageSpan | ( | int | dim, |
bool | is_rat, | ||
int | order0, | ||
int | order1, | ||
int | order2, | ||
const double * | knot0, | ||
const double * | knot1, | ||
const double * | knot2, | ||
int | cv_stride0, | ||
int | cv_stride1, | ||
int | cv_stride2, | ||
const double * | cv, | ||
int | der_count, | ||
double | t0, | ||
double | t1, | ||
double | t2, | ||
int | v_stride, | ||
double * | v | ||
) |
Description: Evaluate a NURBS cage trispan. Parameters: dim - [in] >0 is_rat - [in] true of false order0 - [in] >= 2 order1 - [in] >= 2 order2 - [in] >= 2 knot0 - [in] NURBS knot vector with 2*(order0-1) knots, knot0[order0-2] != knot0[order0-1] knot1 - [in] NURBS knot vector with 2*(order1-1) knots, knot1[order1-2] != knot1[order1-1] knot2 - [in] NURBS knot vector with 2*(order1-1) knots, knot2[order2-2] != knot2[order2-1] cv_stride0 - [in] cv_stride1 - [in] cv_stride2 - [in] cv - [in] For 0 <= i < order0, 0 <= j < order1, and 0 <= k < order2, the (i,j,k)-th control vertex is
cv[n],...,cv[n+(is_rat?dim:dim+1)],
where n = i*cv_stride0 + j*cv_stride1 *k*cv_stride2.
If is_rat is true the cv is in homogeneous form.
der_count - [in] (>=0) r - [in] s - [in] t - [in] (r,s,t) is the evaluation parameter v_stride - [in] (>=dim) v - [out] An array of length v_stride*(der_count+1)*(der_count+2)*(der_count+3)/6. The evaluation results are stored in this array.
P = v[0],...,v[m_dim-1] Dr = v[v_stride],... Ds = v[2*v_stride],... Dt = v[3*v_stride],... Drr = v[4*v_stride],... Drs = v[5*v_stride],... Drt = v[6*v_stride],... Dss = v[7*v_stride],... Dst = v[8*v_stride],... Dtt = v[9*v_stride],...
In general, Dr^i Ds^j Dt^k is returned in v[n],...,v[n+dim-1], where
d = (i+j+k) n = v_stride*( d*(d+1)*(d+2)/6 + (j+k)*(j+k+1)/2 + k)
Returns: True if successful. See Also: ON_NurbsCage::Evaluate ON_EvaluateNurbsSpan ON_EvaluateNurbsSurfaceSpan
ON_DECL bool ON_EvaluateNurbsDeBoor | ( | int | , |
int | , | ||
int | , | ||
double * | , | ||
const double * | , | ||
int | , | ||
double | , | ||
double | |||
) |
ON_DECL bool ON_EvaluateNurbsSpan | ( | int | dim, |
bool | is_rat, | ||
int | order, | ||
const double * | knot, | ||
int | cv_stride, | ||
const double * | cv, | ||
int | der_count, | ||
double | t, | ||
int | v_stride, | ||
double * | v | ||
) |
Description: Evaluate a NURBS curve span. Parameters: dim - [in] dimension (> 0). is_rat - [in] true or false. order - [in] order=degree+1 (order>=2) knot - [in] NURBS knot vector. NURBS knot vector with 2*(order-1) knots, knot[order-2] != knot[order-1] cv_stride - [in] cv - [in] For 0 <= i < order the i-th control vertex is
cv[n],...,cv[n+(is_rat?dim:dim+1)],
where n = i*cv_stride. If is_rat is true the cv is in homogeneous form. der_count - [in] number of derivatives to evaluate (>=0) t - [in] evaluation parameter v_stride - [in] v - [out] An array of length v_stride*(der_count+1). The evaluation results are returned in this array.
P = v[0],...,v[m_dim-1] Dt = v[v_stride],... Dtt = v[2*v_stride],... ... In general, Dt^i returned in v[n],...,v[n+m_dim-1], where n = v_stride*i.
Returns: True if successful. See Also: ON_NurbsCurve::Evaluate ON_EvaluateNurbsSurfaceSpan ON_EvaluateNurbsCageSpan
ON_DECL bool ON_EvaluateNurbsSurfaceSpan | ( | int | dim, |
bool | is_rat, | ||
int | order0, | ||
int | order1, | ||
const double * | knot0, | ||
const double * | knot1, | ||
int | cv_stride0, | ||
int | cv_stride1, | ||
const double * | cv, | ||
int | der_count, | ||
double | s, | ||
double | t, | ||
int | v_stride, | ||
double * | v | ||
) |
Description: Evaluate a NURBS surface bispan. Parameters: dim - [in] >0 is_rat - [in] true of false order0 - [in] >= 2 order1 - [in] >= 2 knot0 - [in] NURBS knot vector with 2*(order0-1) knots, knot0[order0-2] != knot0[order0-1] knot1 - [in] NURBS knot vector with 2*(order1-1) knots, knot1[order1-2] != knot1[order1-1] cv_stride0 - [in] cv_stride1 - [in] cv - [in] For 0 <= i < order0 and 0 <= j < order1, the (i,j) control vertex is
cv[n],...,cv[n+(is_rat?dim:dim+1)],
where n = i*cv_stride0 + j*cv_stride1. If is_rat is true the cv is in homogeneous form.
der_count - [in] (>=0) s - [in] t - [in] (s,t) is the evaluation parameter v_stride - [in] (>=dim) v - [out] An array of length v_stride*(der_count+1)*(der_count+2)/2. The evaluation results are stored in this array.
P = v[0],...,v[m_dim-1] Ds = v[v_stride],... Dt = v[2*v_stride],... Dss = v[3*v_stride],... Dst = v[4*v_stride],... Dtt = v[5*v_stride],...
In general, Ds^i Dt^j is returned in v[n],...,v[n+m_dim-1], where
n = v_stride*( (i+j)*(i+j+1)/2 + j).
Returns: True if successful. See Also: ON_NurbsSurface::Evaluate ON_EvaluateNurbsSpan ON_EvaluateNurbsCageSpan
ON_DECL bool ON_EvaluateQuotientRule | ( | int | dim, |
int | der_count, | ||
int | v_stride, | ||
double * | v | ||
) |
Description: Use the quotient rule to compute derivatives of a one parameter rational function F(t) = X(t)/W(t), where W is a scalar and F and X are vectors of dimension dim. Parameters: dim - [in] der_count - [in] number of derivative (>=0) v_stride - [in] (>= dim+1) v - [in/out] v[] is an array of length (der_count+1)*v_stride. The input v[] array contains derivatives of the numerator and denominator functions in the order (X, W), (Xt, Wt), (Xtt, Wtt), ... In general, the (dim+1) coordinates of the d-th derivative are in (v[n],...,v[n+dim]) where n = d*v_stride. In the output v[] array the derivatives of X are replaced with the derivatives of F and the derivatives of W are divided by w = v[dim]. Returns: True if input is valid; i.e., v[dim] != 0. See Also: ON_EvaluateQuotientRule2 ON_EvaluateQuotientRule3
ON_DECL bool ON_EvaluateQuotientRule2 | ( | int | dim, |
int | der_count, | ||
int | v_stride, | ||
double * | v | ||
) |
Description: Use the quotient rule to compute partial derivatives of a two parameter rational function F(s,t) = X(s,t)/W(s,t), where W is a scalar and F and X are vectors of dimension dim. Parameters: dim - [in] der_count - [in] number of derivative (>=0) v_stride - [in] (>= dim+1) v - [in/out] v[] is an array of length (der_count+2)*(der_count+1)*v_stride. The input array contains derivatives of the numerator and denominator functions in the order X, W, Xs, Ws, Xt, Wt, Xss, Wss, Xst, Wst, Xtt, Wtt, ... In general, the (i,j)-th derivatives are in the (dim+1) entries of v[] v[k], ..., answer[k+dim], where k = ((i+j)*(i+j+1)/2 + j)*v_stride. In the output v[] array the derivatives of X are replaced with the derivatives of F and the derivatives of W are divided by w = v[dim]. Returns: True if input is valid; i.e., v[dim] != 0. See Also: ON_EvaluateQuotientRule ON_EvaluateQuotientRule3
ON_DECL bool ON_EvaluateQuotientRule3 | ( | int | dim, |
int | der_count, | ||
int | v_stride, | ||
double * | v | ||
) |
Description: Use the quotient rule to compute partial derivatives of a 3 parameter rational function F(r,s,t) = X(r,s,t)/W(r,s,t), where W is a scalar and F and X are vectors of dimension dim. Parameters: dim - [in] der_count - [in] number of derivative (>=0) v_stride - [in] (>= dim+1) v - [in/out] v[] is an array of length v_stride*(der_count+1)*(der_count+2)*(der_count+3)/6. The input v[] array contains derivatives of the numerator and denominator functions in the order (X, W), (Xr, Wr), (Xs, Ws), (Xt, Wt), (Xrr, Wrr), (Xrs, Wrs), (Xrt, Wrt), (Xss, Wss), (Xst, Wst), (Xtt, Wtt), ... In general, the (dim+1) coordinates of the derivative (Dr^i Ds^j Dt^k, i+j+k=d) are at v[n], ..., v[n+dim] where n = v_stride*( d*(d+1)*(d+2)/6 + (d-i)*(d-i+1)/2 + k ). In the output v[] array the derivatives of X are replaced with the derivatives of F and the derivatives of W are divided by w = v[dim]. Returns: True if input is valid; i.e., v[dim] != 0. See Also: ON_EvaluateQuotientRule ON_EvaluateQuotientRule2
ON_DECL void ON_EvaluateSurfaceSectionalCurvature | ( | const class ON_Surface * | surface, |
const class ON_SectionAnalysisAppearance & | appearance, | ||
ON_PlaneEquation | plane_eqn, | ||
unsigned int | uv_point_count, | ||
size_t | uv_point_stride, | ||
const double * | uv_points, | ||
ON_SimpleArray< ON_3dPoint > & | points, | ||
ON_SimpleArray< ON_3dVector > & | curvatures, | ||
ON_SimpleArray< ON_2dPoint > * | refined_uv_points | ||
) |
Description: Evaluate the surface to set the ps.m_points[] and ps.m_curvatures[] values.
ON_DECL bool ON_EvCurvature | ( | const ON_3dVector & | , |
const ON_3dVector & | , | ||
ON_3dVector & | , | ||
ON_3dVector & | |||
) |
returns false if first derivative is zero
ON_DECL bool ON_EvCurvature1Der | ( | const ON_3dVector & | D1, |
const ON_3dVector & | D2, | ||
const ON_3dVector & | D3, | ||
ON_3dVector & | T, | ||
ON_3dVector & | K, | ||
double * | kprime, | ||
double * | torsion | ||
) |
torsion
Compute derivative of curvature as well as curvature and torsion. Returns false if either kprime or torsion are not well defined.
D1 | first derivative of curve |
D2 | second derivative of curve |
D3 | third derivative of curve |
T | Unit tangent returned here |
K | curvature vector(k*N). curvature k = K.Length() and Normal N=K.Unitize() |
kprime | first derivative of k |
ON_DECL bool ON_EvJacobian | ( | double | , |
double | , | ||
double | , | ||
double * | |||
) |
return false if determinant is (nearly) singular
ON_DECL bool ON_EvJerk | ( | ON_3dVector | D1, |
ON_3dVector | D2, | ||
ON_3dVector | D3, | ||
ON_3dVector & | T, | ||
ON_3dVector & | K, | ||
ON_3dVector & | J | ||
) |
Description: Evaluate the tangent, curvature and jerk from the first three curve derivatives. Parameters: D1 - [in] first derivative D2 - [in] second derivative D3 - [in] third derivative T - [out] unit tangent K - [out] curvature J - [out] jerk Returns: True if D1 is not zero and T,K,J can be properly calculated False if D1 is zero. Remarks: K = dT/ds = derivative of unit tangent with respect to arc length parameterization J = dK/ds = derivative of curvature with with respect to arc length parameterization
ON_DECL bool ON_EvNormal | ( | int | , |
const ON_3dVector & | , | ||
const ON_3dVector & | , | ||
const ON_3dVector & | , | ||
const ON_3dVector & | , | ||
const ON_3dVector & | , | ||
ON_3dVector & | |||
) |
ON_DECL bool ON_EvNormalPartials | ( | const ON_3dVector & | ds, |
const ON_3dVector & | dt, | ||
const ON_3dVector & | dss, | ||
const ON_3dVector & | dst, | ||
const ON_3dVector & | dtt, | ||
ON_3dVector & | ns, | ||
ON_3dVector & | nt | ||
) |
Description: Evaluate partial derivatives of surface unit normal Parameters: ds - [in] dt - [in] surface first partial derivatives dss - [in] dst - [in] dtt - [in] surface second partial derivatives ns - [out] nt - [out] First partial derivatives of surface unit normal (If the Jacobian is degenerate, ns and nt are set to zero.) Returns: true if Jacobian is nondegenerate false if Jacobian is degenerate
ON_DECL int ON_EvNormalYank | ( | const ON_Surface & | srf, |
double | u, | ||
double | v, | ||
ON_3dVector | srfDirection, | ||
ON_3dVector & | T, | ||
ON_3dVector & | K, | ||
ON_3dVector & | J, | ||
ON_3dVector & | Y | ||
) |
Description: Evaluate the normal tangent, curvature, jerk, and yank to a surface at a given parameter. Parameters: srf - [in] surface u - [in] surface parameter v - [in] surface parameter srfDirection - [in] a nonzero 3d vector that is not perpendicular to srf at (u,v) T - [out] unit tangent to surface (in the direction of the projection of srfDirection to the tangent plane at (u,v)). K - [out] normal curvature in direction of T J - [out] normal jerk Y - [out] normal yank Returns: 1 if T,K,J,Y can be properly calculated. 0 for failure -1 if srf is singular at u,v
ON_DECL bool ON_EvPrincipalCurvatures | ( | const ON_3dVector & | , |
const ON_3dVector & | , | ||
const ON_3dVector & | , | ||
const ON_3dVector & | , | ||
const ON_3dVector & | , | ||
const ON_3dVector & | , | ||
double * | , | ||
double * | , | ||
double * | , | ||
double * | , | ||
ON_3dVector & | , | ||
ON_3dVector & | |||
) |
ON_DECL bool ON_EvPrincipalCurvatures | ( | const ON_3dVector & | , |
const ON_3dVector & | , | ||
double | l, | ||
double | m, | ||
double | n, | ||
const ON_3dVector & | , | ||
double * | , | ||
double * | , | ||
double * | , | ||
double * | , | ||
ON_3dVector & | , | ||
ON_3dVector & | |||
) |
l | Dss*N Second fundamental form coefficients |
m | Dst*N, |
n | Dtt*N, |
ON_DECL bool ON_EvSectionalCurvature | ( | const ON_3dVector & | S10, |
const ON_3dVector & | S01, | ||
const ON_3dVector & | S20, | ||
const ON_3dVector & | S11, | ||
const ON_3dVector & | S02, | ||
const ON_3dVector & | planeNormal, | ||
ON_3dVector & | K | ||
) |
Description: Evaluate sectional curvature from surface derivatives and section plane normal. Parameters: S10, S01 - [in] surface 1st partial derivatives S20, S11, S02 - [in] surface 2nd partial derivatives planeNormal - [in] unit normal to section plane K - [out] Sectional curvature Curvature of the intersection curve of the surface and plane through the surface point where the partial derivatives were evaluated. Returns: True if successful. False if first partials are not linearly independent, in which case the K is set to zero.
ON_DECL bool ON_EvTangent | ( | const ON_3dVector & | , |
const ON_3dVector & | , | ||
ON_3dVector & | |||
) |
returns false if the returned tangent is zero
ON_DECL bool ON_EvYank | ( | ON_3dVector | D1, |
ON_3dVector | D2, | ||
ON_3dVector | D3, | ||
ON_3dVector | D4, | ||
ON_3dVector & | T, | ||
ON_3dVector & | K, | ||
ON_3dVector & | J, | ||
ON_3dVector & | Y | ||
) |
Description: Evaluate the tangent, curvature, jerk, and yank from the first four curve derivatives. Parameters: D1 - [in] first derivative D2 - [in] second derivative D3 - [in] third derivative D3 - [in] forth derivative T - [out] unit tangent K - [out] curvature J - [out] jerk Y - [out] yank Returns: True if D1 is not zero and T,K,J,Y can be properly calculated False if D1 is zero. Remarks: K = dT/ds = derivative of unit tangent with respect to arc length parameterization J = dK/ds = derivative of curvature with respect to arc length parameterization Y = dJ/ds = derivative of jerk with respect to arc length parameterization
int ON_FindLocalMinimum | ( | int(*)(void *, double, double *, double *) | , |
void * | , | ||
double | , | ||
double | , | ||
double | , | ||
double | , | ||
double | , | ||
int | , | ||
double * | |||
) |
find a local minimum of a 1 parameter function
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org.
ON_DECL bool ON_FindMeshMeshIntersectionSets | ( | ON_SimpleArray< ON_MMX_POINT > & | pArray, |
double | tol | ||
) |
This function is soon going to be deprecated. It always uses the old code.
Fix problems found in ON_ValidateBrepLoop. Returns true if something changed. If bCompact is true and something has changed, the result will be compacted. NOTE: This may add to B.m_L, so any refs or pointers to loops should be reset. Any added loops will go to the end of the array, so indices of existing loops, other than loop_id, will still be valid.
ON_DECL bool ON_FixBrepLoops | ( | ON_Brep & | B, |
ON_SimpleArray< int > * | loop_ids = 0 |
||
) |
Repair problems found in ON_ValidateBrepLoops(). Returns true if something changed. If loop_ids !=0, it is the list of loops to fix (they will not be checked first). Otherwise, all loops will be checked and repaired
ON_DECL void ON_FixNurbsSurfacePole | ( | ON_NurbsSurface & | srf, |
int | side, | ||
const ON_3dPoint * | pPole | ||
) |
ON_DECL void ON_FixNurbsSurfaceSeam | ( | ON_NurbsSurface & | srf, |
int | dir, | ||
bool | bMakeG1 | ||
) |
ON_DECL float ON_FloatCeil | ( | double | x | ) |
Description: Convert a double x to the smallest float f such that the mathematical value of f is at least the value of x. Parameters: x - [in] Returns The smallest float f such that the mathematical value of f is at least the value of x.
ON_DECL float ON_FloatFloor | ( | double | x | ) |
Description: Convert a double x to the largest float f such that the mathematical value of f is at most the value of x. Parameters: x - [in] Returns The largest float f such that the mathematical value of f is at most the value of x.
ON_DECL float ON_FloatFromDouble | ( | double | x | ) |
Returns: ON_UNSET_FLOAT, if x = ON_UNSET_VALUE. ON_UNSET_POSITIVE_FLOAT, if x = ON_UNSET_POSITIVE_VALUE. (float)x, otherwise.
ON_DECL void ON_FLT_SNAN | ( | float * | x | ) |
Description: Move ends of curves to a common point. Neither curve can be closed or an ON_CurveProxy. If one is an arc or polycurve with arc at end to change, and the other is not, then the arc is left unchanged and the other curve is moved to the arc endpoint. Otherwise, both are moved to the midpoint of the segment between the ends. Parameters: Crv0 - [in] first curve to modify. [out] with one endpoint possibly changed. end0 - [in] if 0, change start of Crv0. Otherwise change end. Crv1 - [in] second curve to modify. [out] with one endpoint possibly changed. end1 - [in] if 0, change start of Crv1. Otherwise change end. Returns: true if the endpoints match. False otherwise,
ON_DECL bool ON_FPU_AfterDotNetJITUse | ( | void | ) |
Description: The .NET JIT (just in-time compiler) has a bug that causes a floating point overflow exception if there is any double constant that whose absolute value is greater than 3.402823466e+38 (=FLT_MAX).
The following .NET C# program demonstrates the bug in the Microsoft JIT compiler.
class Program { static bool IsBigDouble(double x) {
/ Note: 3.402823466e+38 is the maximum value of a 32 bit IEEE float /return x == 3.402823466e+38; ///< JIT does not generate overflow exception /return x == 3.5e+38; ///< JIT generates overflow exception return x == double.MaxValue; ///< JIT generates overflow exception } static void Main(string[] args) { double x = 1.0; / When the JIT compiles IsBigDouble(), it will generate / an FPU overflow exception if the constant in IsBigDouble() / is larger than the maximum 32 bit IEEE float. bool rc = IsBigDouble(x); if ( rc ) System.Console.WriteLine("{0} is a big double.",x); else System.Console.WriteLine("{0} is not a big double.",x); } }
If you are getting warnings that code that makes calls into .NET code is generating FPU overflow exceptions, then bracket the call to code that may call the .NET JIT with calls to ON_FPU_BeforeSloppyCall()/ON_FPU_AfterDotNetJITUse(). Returns: ON_FPU_AfterDotNetJITUse() returns true if the FPU stayed clean except for an overflow exception since the last call to ON_FPU_BeforeSloppyCall(). Remarks: These functions should be used only in extreme situations and there should be a verbose comment in the code explaining why the programmer resorted to using these functions.
Microsoft is aware of this bug and claims it is "by design". http://connect.microsoft.com:80/VisualStudio/feedback/ViewFeedback.aspx?FeedbackID=100718 ... So in summary this behavior is by Design. In the ECMA spec for IL it states that IL floating point operations never throw exceptions. The way to detect floating point overflow is to use the ckfinite IL instruction after each floating point operation that could produce an overflow. ... Microsoft could easily fix this bug by 1) saving the FPU CTRL state before running their JIT 2) clearing the FPU STAT register and restoring the CTRL state after running their JIT This amounts to 3 lines of C and less than 10 lines of assembly code and is what I would expect them to do.
ON_DECL bool ON_FPU_AfterSloppyCall | ( | void | ) |
ON_DECL bool ON_FPU_BeforeSloppyCall | ( | void | ) |
Description: Sometimes it is impossible to avoid calling code that performs invalid floating point operations or rudely changes the FPU control settings. We have found dozens of cases in Windows core DLLs,3rd party DLLs, OpenGL drivers, and the .NET JIT conmpiler where the FPU CTRL setting is changed or floating point exceptions are generated. When these cases are discovered, we bracket the code that is abusing the FPU with ON_FPU_BeforeSloppyCall(); ... call that abuses the FPU ON_FPU_AfterSloppyCall(); so we don't lose any information about exceptions in our own code and we don't get pestered about exceptions we can't do anything about. If you are calling something that may run the .NET JIT, then use ON_FPU_AfterDotNetJITUse() instead of ON_FPU_AfterSloppyCall(). Returns: ON_FPU_BeforeSloppyCall() returns true if the FPU is "clean" at the time of the call. ON_FPU_AfterSloppyCall() returns true if the FPU stayed clean since the last call to ON_FPU_BeforeSloppyCall(). Remarks: These functions should be used only in extreme situations and there should be a verbose comment in the code explaining why the programmer resorted to using these functions.
ON_DECL bool ON_FPU_Check | ( | bool | bCheckExceptionStatus, |
bool | bCheckControl, | ||
bool | bCall_ON_Error | ||
) |
Description: Check the FPU status or control. Parameters: bCheckExceptionStatus - [in] If true, the FPU exception status is checked to see if any exceptions have happened. bCheckControl - [in] If true, the FPU control settings are checked to see if they have the expected values. bCall_ON_Error - [in] If true and and exception has occurred or the control settings have been changed, then ON_Error() is called. Returns: true: The FPU status indicates no exceptions have occurred and the control settings match the expected values. false: The FPU status indicates exceptions have occurred or the FPU control settings have unexpected values.
ON_DECL void ON_FPU_ClearExceptionStatus | ( | ) |
FPU functions Description: Clear FPU exception and busy flags (Intel assembly fnclex). See Also: ON_FPU_ExceptionStatus
ON_DECL ON__UINT32 ON_FPU_ControlWord | ( | ) |
Description: Returns the FPU control word.
ON_DECL bool ON_FPU_EnableInvalidStatusCheck | ( | bool | bEnableInvalidStatusCheck | ) |
Description: WPF uses NaNs for .NET properties that are not initialized and intentionally passes these NaNs into the FPU at various times. This sets the FPU's invalid operation status bit. Prior to November 2014, we used to alert developers that their code had done something wrong when the FPU's invalid status bit was set. Because we have almost no control over when .NET will set the invalid status bit, we can no longer assume that we have a bug in our code when the bit is set.
By default, we now treat the setting of invalid status bit the same we we treat the inexact bit, namely it is a common and expected situation.
If you are attempting to test or debug scientific computing code and you want to be told when something really bad happens on the FPU, then call ON_FPU_EnableInvalidStatusCheck(true) before you run your tests.
Returns: The value of ON_FPU_EnableInvalidStatusCheckEnabled() before it was set to bEnableInvalidStatusCheck.
ON_DECL ON__UINT32 ON_FPU_ExceptionStatus | ( | ) |
Returns Current FPU exception flags (Intel assembly fnstsw).
Use the ON_FPU_SW_* defines to interpret the returned value. Example: ON_FPU_ClearExceptionStatus();
... do some calculations ...
ON_UINT32 status = ON_FPU_ExceptionStatus(); if ( 0 != (status & ON_FPU_SW_BAD ) ) { ... The results of the calculations are suspect. } See Also: ON_FPU_ClearExceptionStatus ON_FPU_BadExceptionStatusMask
ON_DECL ON__UINT32 ON_FPU_Init | ( | void | ) |
Description: Set the FPU control bits to the Microsoft's preferred defaults. These are the same as the Intel FPU fninit defaults, except for 32-bit executable mantisaa precision. Microsoft's default is 53-bit mantissas and Intel's is 64-bit mantissas. Rhino and OpenNURBS code works best with these settings.
ON_DECL ON__UINT32 ON_FPU_InitControlWord | ( | void | ) |
Returns: Control word used by the FPU. Except when exception debugging is enabled, the value will be FPU_CW_DEFAULT. See Also: ON_FPU_DebugExceptions
ON_DECL bool ON_FPU_InvalidStatusCheckEnabled | ( | ) |
ON_DECL bool ON_FPU_UnmaskExceptions | ( | ON__UINT32 | unmasked_ex | ) |
Description: A DEBUGGING tool to unmask FPU exception handling. Do not call this function in released code. Parameters: unmasked_ex - [in] Use the ON_FPU_EX_* defines to set the bits of the exceptions you want to unmask. Example: #if defined(ON_DEBUG) / crash on divide by zero, overflow, and invalid ON_FPU_UnmaskExceptions(ON_FPU_EX_OVERFLOW|ON_FPU_EX_ZERODIVIDE|ON_FPU_EX_INVALID); #endif
... do suspect calculations
#if defined(ON_DEBUG) / Mask all exceptions (default) ON_FPU_UnmaskExceptions(0); #endif Remarks: By default floating point exceptions are "masked". This means nothing serious happens when an exception, like dividing by zero, occurs. When a floating point exception is "unmasked" it means the application will crash when that floating point exception occurs. Unmasking exceptions is a useful debugging technique. Never unmask exceptions in release code.
Returns: True if the input was valid and the call worked.
ON_DECL int ON_Get3dConvexHull | ( | const ON_SimpleArray< ON_3dPoint > & | points, |
ON_SimpleArray< ON_PlaneEquation > & | hull | ||
) |
Description: Get a convex hull of a set of 3d points. Parameters: points - [in] List of points. This function can handle tens of points but is too slow for hundreds of points. hull -[out] Equations of the sides of the convex hull are appended to this list.
A point P is inside the hull if hull[i].ValueAt(P) <= 0 for every plane equation. Returns: Number of equations appended to hull[] array. If 0, then the points are coincident or collinear. If 2, then the points are coplanar and the returned planes are parallel. If >= 4, then the points are in a 3d convex hull.
ON_DECL int ON_GetBase32Digits | ( | const ON_SimpleArray< unsigned char > & | x, |
ON_SimpleArray< unsigned char > & | base32_digits | ||
) |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org. Description: Convert a number into base32 digits. Parameters: x - [in] x_count - [in] x[] is an array of length x_count and represents the value x[0]*2^(8*(x_count-1)) + ... + x[x_count-2]*256 + x[x_count-1]. base32_digits - [out] When base32_digits is not a dynamic array, base32_digits[] must a be an array of length at least ((8*x_count)/5) + (((8*x_count)%5)?1:0) or 1, whichever is greater.
The base32_digits[] array will be filled in with base32 digit values (0 to 31) so that the value b[0]*32^(b_count-1) + ... + b[b_count-2]*32 + b[b_count-1] is the same as that defined by the x[] array. Returns The number of base 32 digits in the base32_digits[] array. If 0 is returned, the input is not valid.
ON_DECL int ON_GetBase32Digits | ( | const unsigned char * | x, |
int | x_count, | ||
unsigned char * | base32_digits | ||
) |
ON_DECL bool ON_GetCageXform | ( | const ON_NurbsCage & | cage, |
ON_Xform & | cage_xform | ||
) |
ON_DECL bool ON_GetClosestPointInPointList | ( | int | point_count, |
const ON_3dPoint * | point_list, | ||
ON_3dPoint | P, | ||
int * | closest_point_index | ||
) |
Description: Find the index of the point in the point_list that is closest to P. Parameters: point_count - [in] point_list - [in] P - [in] closest_point_index - [out] Returns: True if successful and *closest_point_index is set. False if input is not valid, in which case *closest_point_index is undefined.
ON_DECL bool ON_GetClosestPointOnTriangle | ( | const double | A[3], |
const double | B[3], | ||
const double | C[3], | ||
const double | N[3], | ||
const double | test_point[3], | ||
double | triangle_bc[3] | ||
) |
Description: Find the point on the triangle that is closest to test_point. Parameters: A - [in] B - [in] C - [in] triangle corners. N - [in] null pointer or a nonzero unit vector perpendicular to the plane of the triangle. N may have either orientation (+N and -N work equally as well). This pointer can be the address of the "a" parameter of an ON_TrianglePlane calculated from this triangle. If a unit length normal is not available, pass null and the necessary information will be calculated in this function. test_point - [in] triangle_bc - [out] The barycentric coordinates of the point on the triangle that is closest to test_point. Specifically, triangle_bc[0] >= 0, triangle_bc[1] >= 0, triangle_bc[2] >= 0 1 = triangle_bc[0] + triangle_bc[1] + triangle_bc[2], and (triangle_bc[0]*A + triangle_bc[1]*B + triangle_bc[2]*C) is the point on the triangle that is closest to test_point. Returns: Zero if the triangle is degenerate. In this case, valid barycentric coordinates of a point are returned, but there may be multiple answers. Non-zero if the triangle is not degenerate and triangle_bc[] are the barycentric coordinates of the point on the triangle closest to test_point. The returned value reports the region of the triangles plane test_point projects to. If test_point projects to the interior of the triangle, 1 is returned. If test point projects to an edge or vertex of the triangle, 2 is returned. If test_point projects to a point outside the triangle, 3 is returned Remarks: This function is designed to be as precise as possible, robustly handles points that are not on the triangle, and it handles degenerate cases. If speed is paramount, use ...
ON_DECL bool ON_GetClosestPointOnTriangle | ( | const float | A[3], |
const float | B[3], | ||
const float | C[3], | ||
const float | N[3], | ||
const double | test_point[3], | ||
double | triangle_bc[3] | ||
) |
ON_DECL bool ON_GetConicEquationThrough6Points | ( | int | stride, |
const double * | points2d, | ||
double | conic[6], | ||
double * | max_pivot, | ||
double * | min_pivot, | ||
double * | zero_pivot | ||
) |
Description: Find the equation of the parabola, ellipse or hyperbola (non-degenerate conic) that passes through six distinct points. Parameters: stride - [in] (>=2) points array stride points2d - [in] (>=2) i-th point is (points[i*stride],points[i*stride+1]) conic - [out] Coefficients of the conic equation. The points on the conic satisfy the equation 0 = conic[0]*x^2 + conic[1]*xy + conic[2]*y^2
ON_DECL int ON_GetDebugBreak | ( | void | ) |
ON_DECL int ON_GetDebugBreakOnFirstError | ( | void | ) |
ON_DECL int ON_GetDebugErrorMessage | ( | void | ) |
ON_DECL unsigned int ON_GetEigenvectors | ( | const unsigned int | N, |
const double *const * | M, | ||
bool | bTransposeM, | ||
double | lambda, | ||
unsigned int | lambda_multiplicity, | ||
const double * | termination_tolerances, | ||
double ** | eigenvectors, | ||
double * | eigenprecision, | ||
double * | eigenpivots | ||
) |
Parameters: N - [in] >= 1 M - [in] M is an NxN matrix
bTransposeM - [in] If true, the eigenvectors of the transpose of M are calculated. Put another way, if bTransposeM is false, then the "right" eigenvectors are calculated; if bTransposeM is true, then the "left" eigenvectors are calculated.
lambda - [in] known eigenvalue of M
lambda_multiplicity - [in] > 0: known algebraic multiplicity of lambda 0: algebraic multiplicity is unknown.
termination_tolerances - [in] An array of three tolerances that control when the calculation will stop searching for eigenvectors. If you do not understand what pivot values are, then pass nullptr and the values (1.0e-12, 1.0e-3, 1.0e4) will be used. If termination_tolerances[0] is not strictly positive, then 1.0e-12 is used. If termination_tolerances[1] is not strictly positive, then 1.0e-3 is used. If termination_tolerances[2] is not strictly positive, then 1.0e4 is used.
The search for eigenvectors will continue if condition 1, and condition 2, and condition 3a or 3b is true.
1) The number of found eigenvectors is < lambda_multiplicity. 2) eigenpivots[0] >= eigenpivots[1] > eigenpivots[2] >= 0. 3a) eigenpivots[1]/eigenpivots[0] < termination_tolerance[0]. 3b) eigenpivots[1]/eigenpivots[0] > termination_tolerance[1] or eigenpivots[0] - eigenpivots[1] <= termination_tolerance[2]*eigenpivots[1].
eigenvectors - [out] eigenvectors[0,...,eigendim-1][0,...,N-1] a basis for the lambda eigenspace. The eigenvectors are generally neither normalized nor orthogonal.
eigenprecision - [out] eigenprecision[i] = maximum value of fabs(lambda*E[j] = E[j])/length(E) 0 <= j < N, where E = eigenvectors[i]. If eigenprecision[i] is not "small" compared to nonzero coefficients in M and E, then E is not precise.
eigenpivots - [out] eigenpivots[0] = maximum nonzero pivot eigenpivots[1] = minimum nonzero pivot eigenpivots[2] = maximum "zero" pivot When eigenpivots[2] s not "small" compared to eigenpivots[1], the answer is suspect.
Returns: Number of eigenvectors found. In stable cases, this is the geometric multiplicity of the eigenvalue.
ON_DECL bool ON_GetEllipseConicEquation | ( | double | a, |
double | b, | ||
double | x0, | ||
double | y0, | ||
double | alpha, | ||
double | conic[6] | ||
) |
Description: Get the conic equation of an ellipse. Parameters: a - [in] (a>0) b - [in] (b>0) a and b are the lengths of the axes. Either one may be largest and they can be equal. x0 - [in] y0 - [in] (x0,y0) is the enter of the ellipse. alpha - [in] (angle in radians) When alpha is 0, a corresponds to the x-axis and b corresponds to the y axis. If alpha is non-zero it specifies the rotation of these axes. conic - [out] Coefficients of the conic equation. The points on the conic satisfy the equation 0 = conic[0]*x^2 + conic[1]*xy + conic[2]*y^2
double t = ellipse parameter in radians; double x = a*cos(t); double y = b*sin(t); ON_2dPoint ellipse_point; ellipse_point.x = x0 + x*cos(alpha) + y*sin(alpha); ellipse_point.y = y0 - x*sin(alpha) + y*cos(alpha);
Returns: True if the input is valid and conic[] was filled in. Falis if the input is not valid. In this case the values in conic[] are not changed.
ON_DECL bool ON_GetEndCapTransformation | ( | ON_3dPoint | P, |
ON_3dVector | T, | ||
ON_3dVector | U, | ||
const ON_3dVector * | Normal, | ||
ON_Xform & | xform, | ||
ON_Xform * | scale2d, | ||
ON_Xform * | rot2d | ||
) |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org. Description: Get the transformation that maps the ON_Extrusion 2d xy profile to 3d world space. Parameters: P - [in] start or end of path T - [in] unit tangent to path U - [in] unit up vector perpendicular to T Normal - [in] optional unit vector with Normal->z > 0 that defines the unit normal to the miter plane. xform - [out] transformation that maps the profile curve to 3d world space scale2d - [out] If not nullptr, this is the scale part of the transformation. If there is no mitering, then this is the identity. rot2d - [out] If not null, this is the part of the transformation that rotates the xy plane into its 3d world location. Returns: true if successful.
xform | = rot3d*scale2d |
ON_DECL int ON_GetErrorCount | ( | void | ) |
Returns: Number of opennurbs errors since program started.
ON_DECL double ON_GetFittingTolerance | ( | const class ON_SurfaceTreeNode * | snodeA, |
const class ON_SurfaceTreeNode * | snodeB, | ||
double | intersection_tolerance, | ||
double | fitting_tolerance | ||
) |
ON_DECL bool ON_GetFunctionRoot | ( | void(*)(void *, double, double *, double *) | func, |
void * | funcarg, | ||
double | t0, | ||
double | t1, | ||
double * | root | ||
) |
ON_GetFunctionRoot() searches for a root of a C1 function. ON_GetFunctionRoot() returns true if it finds a root and false if it fails to find a root. In all cases, it returns the "best" candidate for a root that it can find. The algorithm is Newton-Raphson and works best if the function is a monotone function. However you can use any function as long as it is C1 and f(t0)*f(t1) <= 0.0.
t0 | domain to search for root = [t0, t1] |
t1 | f(t0)*f(t1) <= 0.0 |
root | value of root |
ON_DECL bool ON_GetGregorianMonthAndDayOfMonth | ( | unsigned int | year, |
unsigned int | day_of_year, | ||
unsigned int * | month, | ||
unsigned int * | day_of_month | ||
) |
Description: Get the month and day_of_month from the year and day of year. Parameters: year - [in] >= 1582 day_of_year >= 1 and <= (ON_IsGregorianLeapYear(year) ? 366 : 365) month - [out] >= 1 and <= 12, when input parameters are valid, otherwise 0. day_of_month - [out] >= 1 and <= ON_DaysInMonthOfGregorianYear(year,month), when input parameters are valid, otherwise 0. Returns: true: month and day_of_month returned. false: invalid input. Output values are zero.
ON_DECL bool ON_GetGrevilleAbcissae | ( | int | , |
int | , | ||
const double * | , | ||
bool | , | ||
double * | |||
) |
ON_DECL bool ON_GetGrevilleKnotVector | ( | int | , |
const double * | , | ||
bool | , | ||
int | , | ||
int | , | ||
double * | |||
) |
ON_DECL bool ON_GetHighCurvatureSpans | ( | const ON_Curve & | crv, |
double | tolerance, | ||
ON_SimpleArray< int > * | span_indices | ||
) |
Find spans of a curve that have high curvature.
INPUT: crv tolerance - Look for spans with max curvature greater than tolerance.
OUTPUT: span_indices - If non-nullptr, this will be the list of all found spans. If nullptr, then function will return as soon as a high curvature span is hit.
Returns - True if there are spans with high curvature.
ON_DECL bool ON_GetKnotVectorDomain | ( | int | , |
int | , | ||
const double * | , | ||
double * | , | ||
double * | |||
) |
ON_DECL bool ON_GetKnotVectorSpanVector | ( | int | , |
int | , | ||
const double * | , | ||
double * | |||
) |
ON_DECL int ON_GetMathErrorCount | ( | void | ) |
Returns: Number of math library or floating point errors that have been handled since program started.
ON_DECL bool ON_GetMatrixSVD | ( | int | row_count, |
int | col_count, | ||
double const *const * | A, | ||
double **& | U, | ||
double *& | W, | ||
double **& | V | ||
) |
Description: Calculate the singular value decomposition of a matrix.
Parameters: row_count - [in] number of rows in matrix A col_count - [in] number of columns in matrix A A - [in] Matrix for which you want the singular value decomposition. A[0][0] = coefficient in the first row and first column. A[row_count-1][col_count-1] = coefficient in the last row and last column. U - [out] The singular value decomposition of A is U*Diag(W)*Transpose(V), where U has the same size as A, Diag(W) is a col_count X col_count diagonal matrix with (W[0],...,W[col_count-1]) on the diagonal and V is a col_count X col_count matrix. U and A may be the same pointer. If the input value of U is null, heap storage will be allocated using onmalloc() and the calling function must call onfree(U). If the input value of U is not null, U[i] must point to an array of col_count doubles.
W - [out] If the input value W is null, then heap storage will be allocated using onmalloc() and the calling function must call onfree(W). If the input value of W is not null, then W must point to an array of col_count doubles. V - [out] If the input value V is null, then heap storage will be allocated using onmalloc() and the calling function must call onfree(V). If the input value of V is not null, then V[i] must point to an array of col_count doubles.
Example:
int m = row_count; int n = col_count; ON_Matrix A(m,n); for (i = 0; i < m; i++ ) for ( j = 0; j < n; j++ ) { A[i][j] = ...; } ON_Matrix U(m,n); double* W = 0; ///< ON_GetMatrixSVD() will allocate W ON_Matrix V(n,n); bool rc = ON_GetMatrixSVD(m,n,A.m,U.m,W,V.m); ... onfree(W); ///< W allocated in ON_GetMatrixSVD()
Returns: True if the singular value decomposition was calculated. False if the algorithm failed to converge.
ON_DECL bool ON_GetMeshMeshClosestPoint | ( | const ON_Mesh & | MeshA, |
const ON_Mesh & | MeshB, | ||
double | max_dist, | ||
bool | bUseMultipleThreads, | ||
int * | fidA, | ||
double | a[4], | ||
int * | fidB, | ||
double | b[4] | ||
) |
Description: Finds a the closest points on a pair of meshes. Parameters: MeshA - [in] First mesh MeshB - [in] Second mesh max_dist - [in] Do not search for point pairs further apart than max_dist bUseMultipleThreads - [in] Pass true if you want the calculation to use multiple threads. fidA - [out] index of closest face of MeshA a - [out] barycentric coordinates of closest point on MeshA.m_F[*fidA] fidB - [out] index of closest face of MeshB b - [out] barycentric coordinates of closest point on MeshB.m_F[*fidB] Returns: true if points A and B could be found with distance from A to B no greater than max_dist and as close together as any other pair. A is the sum of a[i]*VA[i], B is the sum of b[i]*VB[i], where VA and VB are the vertices of MeshA.m_F[*fidA] and MeshB.m_F[*fidB]. Note that if the face is a triangle, the 4th barycentric coordinate will be 0, and 3 is a valid index for the mesh face vertex array.
Description: Expert user function to get the value of ON_ClassId::m_uuid of the last instance of ON_ClassId to call ON_ClassId::Create(). This function was created to support Rhino's .NET SDK. This function returns the value of a static id in opennurbs_object.cpp and is NOT thread safe. Returns: Value of ON_ClassId::m_uuid of the instance of ON_ClassId that most recently called ON_ClassId::Create().
ON_DECL bool ON_GetNextCurveSpan | ( | const ON_Curve & | crv, |
double | t0, | ||
double | t1, | ||
double | tolerance, | ||
bool(*)(const ON_Curve &, double, double, double) | check, | ||
ON_Interval * | seg_dom, | ||
int * | span_index | ||
) |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org. Find the first span of a curve that satisfies a property given by a check function
INPUT: crv t0, t1 - Must be increasing. Search subdomain tolerance - Used by the check function check - function that takes the above parameters
OUTPUT: seg_dom - If Non-nullptr on input, Subdomain of the span that passes check. span_index - If Non-nullptr on input, the index of the span.
Returns true if a span is found for which check returns true.
check | Test function for subdom given by first two doubles. Third is a tolerance |
ON_DECL bool ON_GetParameterTolerance | ( | double | , |
double | , | ||
double | , | ||
double * | , | ||
double * | |||
) |
ON_DECL bool ON_GetPointGridBoundingBox | ( | int | dim, |
bool | is_rat, | ||
int | point_count0, | ||
int | point_count1, | ||
int | point_stride0, | ||
int | point_stride1, | ||
const double * | point_grid, | ||
double * | boxmin, | ||
double * | boxmax, | ||
int | bGrowBox | ||
) |
boxmin | min[dim] |
boxmax | max[dim] |
ON_DECL bool ON_GetPointListBoundingBox | ( | int | dim, |
bool | is_rat, | ||
int | count, | ||
int | stride, | ||
const double * | point_list, | ||
double * | boxmin, | ||
double * | boxmax, | ||
int | bGrowBox | ||
) |
boxmin | min[dim] |
boxmax | max[dim] |
ON_DECL bool ON_GetPointListBoundingBox | ( | int | dim, |
bool | is_rat, | ||
int | count, | ||
int | stride, | ||
const double * | point_list, | ||
ON_BoundingBox & | bbox, | ||
int | bGrowBox = false , |
||
const ON_Xform * | xform = 0 |
||
) |
Description: Get a tight bounding box that contains the points. Parameters: dim - [in] (>=1) is_rat - [in] true if points are rational count - [in] number of points stride - [in] stride between points point_list - [in] bbox - [in/out] bGrowBox - [in] (default = false) If the input bbox is valid and bGrowBox is true, then the output bbox is the union of the input bbox and the bounding box of the point list. xform - [in] (default = nullptr) If not null, the bounding box of the transformed points is calculated. The points are not modified. Returns: True if the output bbox is valid.
ON_DECL bool ON_GetPointListBoundingBox | ( | int | dim, |
bool | is_rat, | ||
int | count, | ||
int | stride, | ||
const float * | point_list, | ||
float * | boxmin, | ||
float * | boxmax, | ||
int | bGrowBox | ||
) |
boxmin | min[dim] |
boxmax | max[dim] |
ON_DECL bool ON_GetPointListBoundingBox | ( | int | dim, |
bool | is_rat, | ||
int | count, | ||
int | stride, | ||
const float * | point_list, | ||
ON_BoundingBox & | bbox, | ||
int | bGrowBox = false , |
||
const ON_Xform * | xform = 0 |
||
) |
ON_DECL unsigned int* ON_GetPointLocationIds | ( | size_t | point_count, |
const class ON_2dPoint * | points, | ||
unsigned int | first_point_id, | ||
unsigned int * | point_ids, | ||
unsigned int * | point_id_map | ||
) |
ON_DECL unsigned int* ON_GetPointLocationIds | ( | size_t | point_count, |
const class ON_2fPoint * | points, | ||
unsigned int | first_point_id, | ||
unsigned int * | point_ids, | ||
unsigned int * | point_id_map | ||
) |
ON_DECL unsigned int* ON_GetPointLocationIds | ( | size_t | point_count, |
const class ON_3dPoint * | points, | ||
unsigned int | first_point_id, | ||
unsigned int * | point_ids, | ||
unsigned int * | point_id_map | ||
) |
ON_DECL unsigned int* ON_GetPointLocationIds | ( | size_t | point_count, |
const class ON_3fPoint * | points, | ||
unsigned int | first_point_id, | ||
unsigned int * | point_ids, | ||
unsigned int * | point_id_map | ||
) |
ON_DECL unsigned int* ON_GetPointLocationIds | ( | size_t | point_dim, |
size_t | point_count, | ||
size_t | point_stride, | ||
const double * | points, | ||
unsigned int | first_point_id, | ||
unsigned int * | point_ids, | ||
unsigned int * | point_id_map | ||
) |
ON_DECL unsigned int* ON_GetPointLocationIds | ( | size_t | point_dim, |
size_t | point_count, | ||
size_t | point_stride, | ||
const float * | points, | ||
unsigned int | first_point_id, | ||
unsigned int * | point_ids, | ||
unsigned int * | point_id_map | ||
) |
Description: Assign a unique id to each point location. Coincident points get the same id. Parameters: point_dim - [in] 2 or 3 point_count - [in] >= 1 point_stride - [in] number of coordinates to skip between points >= point_dim points - [in] The first coordinate of the i-th point is points[i*point_stride] first_point_id - [in] Initial point id. Typically 1 or 0. point_ids - [out] If not null, then point_ids[] must be an array of length point_count and the ids are returned in this array. point_ids[0] = first_point_id. point_id_map - [out] If point_id_index is not null, then it must have length point_count. The returned values are a permutation of (0,1,...,point_count-1) such that (point_ids[point_id_map[0]], ..., point_ids[point_id_map[point_count-1]]) is an increasing list of values and point_id_map[0] = 0. Returns: If input is valid, then an array of point_count point location ids is returned. The i-th and j-th values in the returned array are equal if and only if the i-th and j-th points have the same location. If the input point_ids pointer was null, then the array memory is allocated on the heap by calling onmalloc(). If input is not valid, nullptr is returned. Remarks: The ids are invariant under invertable transformations.
Specifically, if one point point set is a rotation of another, then the assigned ids will be the same.
ON_DECL bool ON_GetPolylineLength | ( | int | , |
bool | , | ||
int | , | ||
int | , | ||
const double * | , | ||
double * | |||
) |
ON_DECL bool ON_GetShortSpans | ( | const ON_Curve & | crv, |
double | tolerance, | ||
ON_SimpleArray< int > * | span_indices | ||
) |
Find short spans of a curve.
INPUT: crv tolerance - Any span with arclength (approximated) less than tolerance is short
OUTPUT: span_indices - If non-nullptr, this will be the list of all short spans. If nullptr, then function will return as soon as a short span is hit.
Returns - True if there are short spans.
ON_DECL int ON_GetSpanIndices | ( | int | order, |
int | cv_count, | ||
const double * | knot, | ||
int * | |||
) |
order | returns span count, which is one less than length of span_indices[] |
ON_DECL bool ON_GetTrianglePlaneEquation | ( | const ON_3dPoint & | A, |
const ON_3dPoint & | B, | ||
const ON_3dPoint & | C, | ||
double * | a, | ||
double * | b, | ||
double * | c, | ||
double * | d, | ||
double * | evaluation_tol | ||
) |
Description: Finds the unit normal to the triangle Parameters: A - [in] triangle corner B - [in] triangle corner C - [in] triangle corner a - [out] must not be null b - [out] must not be null c - [out] must not be null d - [out] must not be null The equation of the plane is a*x + b*y + c*z + d = 0 ev_tol - [out] If ev_tol is not null, then it is the maximum absolute value of the plane equation evaluated at A,B,C. Mathematically, ev_tol is zero. Since these computations are performed with finite precision doubles, ev_tol is generally not zero. Returns: Unit normal
ON_DECL unsigned int ON_GetVersionQuartet | ( | unsigned int | major_version, |
unsigned int | minor_version, | ||
unsigned int | year, | ||
unsigned int | month, | ||
unsigned int | day_of_month, | ||
unsigned int | hour, | ||
unsigned int | minute, | ||
unsigned int | branch, | ||
unsigned short | quartet_values[4] | ||
) |
Parameters: major_version - [in] major_version >= 0 and major_version <= 63
minor_version - [in] minor_version >= 0 and minor_version <= 127
year - [in] year >= 2000 and year <= 2099
month - [in] month >= 1 and month <= 12
day_of_month - [in] day_of_month >= 1 and day_of_month <= ON_DaysInMonthOfGregorianYear(year,month)
hour - [in] hour >= 0 and hour <= 23
minute - [in] minute >= 0 and minute <= 59
branch - [in] branch >= 0 and branch <= 3 0: developer build 1: build system trunk branch build 2: build system release candidate build 3: build system release build
quartet_values - [out] quartet_values[0] = major_version quartet_values[1] = minor_version quartet_values[2] = (year-2000)*1000 + ON_DayOfGregorianYear(year,month,day_of_month) quartet_values[3] = hour*1000 + minute*100 + branch
Returns: 0: failure because input is not valid >0: value of ON_VersionNumberConstruct(major_version,minor_version,year,month,day_of_month,branch)
ON_DECL unsigned int ON_GetVersionString | ( | unsigned int | major_version, |
unsigned int | minor_version, | ||
unsigned int | year, | ||
unsigned int | month, | ||
unsigned int | day_of_month, | ||
unsigned int | hour, | ||
unsigned int | minute, | ||
unsigned int | branch, | ||
size_t | string_buffer_capacity, | ||
char * | string_buffer | ||
) |
Description: Get a null terminated string that describes the version information as "major.,minor.yyddd.hhmmb". Parameters: major_version - [in] major_version >= 0 and major_version <= 63
minor_version - [in] minor_version >= 0 and minor_version <= 127
year - [in] year >= 2000 and year <= 2099
month - [in] month >= 1 and month <= 12
day_of_month - [in] day_of_month >= 1 and day_of_month <= ON_DaysInMonthOfGregorianYear(year,month)
hour - [in] hour >= 0 and hour <= 23
minute - [in] minute >= 0 and minute <= 59
branch - [in] branch >= 0 and branch <= 3 0: developer build 1: build system trunk branch build 2: build system release candidate build 3: build system release build
string_buffer_capacity - [in] Number of available char elements in string_buffer[]
string_buffer - [out] If 0 == string_buffer_capacity or nullptr == string_buffer, then the number of char elements in the version number as a string, not including a null terminator, is returned and no changes are made to string_buffer.
If string_buffer_capacity > 0 && nullptr != string_buffer, then the version number as a string is returned in string_buffer. All string_buffer[] elements after the version number string are set to zero. (This is a safe and secure string function.) Returns: 0: failure because input is not valid >0: The number of char elements, not including a null terminator, in the version number as a string.
ON_DECL unsigned int ON_GetVersionWideString | ( | unsigned int | major_version, |
unsigned int | minor_version, | ||
unsigned int | year, | ||
unsigned int | month, | ||
unsigned int | day_of_month, | ||
unsigned int | hour, | ||
unsigned int | minute, | ||
unsigned int | branch, | ||
size_t | string_buffer_capacity, | ||
wchar_t * | string_buffer | ||
) |
Description: Get a null terminated wide character string that describes the version information as "major.minor.yyddd.hhmmb". Parameters: major_version - [in] major_version >= 0 and major_version <= 63
minor_version - [in] minor_version >= 0 and minor_version <= 127
year - [in] year >= 2000 and year <= 2099
month - [in] month >= 1 and month <= 12
day_of_month - [in] day_of_month >= 1 and day_of_month <= ON_DaysInMonthOfGregorianYear(year,month)
hour - [in] hour >= 0 and hour <= 23
minute - [in] minute >= 0 and minute <= 59
branch - [in] branch >= 0 and branch <= 3 0: developer build 1: build system trunk branch build 2: build system release candidate build 3: build system release build
string_buffer_capacity - [in] Number of available char elements in string_buffer[]
string_buffer - [out] If 0 == string_buffer_capacity or nullptr == string_buffer, then the number of wchar_t elements in the version number as a string, not including a null terminator, is returned and no changes are made to string_buffer.
If string_buffer_capacity > 0 && nullptr != string_buffer, then the version number as a string is returned in string_buffer. All string_buffer[] elements after the version number string are set to zero. (This is a safe and secure string function.) Returns: 0: failure because input is not valid >0: The number of char elements, not including a null terminator, in the version number as a string.
ON_DECL bool ON_GetViewportRotationAngles | ( | const ON_3dVector & | , |
const ON_3dVector & | , | ||
const ON_3dVector & | , | ||
double * | , | ||
double * | , | ||
double * | |||
) |
ON_DECL int ON_GetWarningCount | ( | void | ) |
Returns: Number of opennurbs warnings since program started.
void ON_GL | ( | const int | , |
const int | , | ||
const double * | , | ||
GLfloat * | , | ||
int | = 0 , |
||
double * | = nullptr |
||
) |
Use ON_GL( order, cv_count, knot, bPermitScaling, glknot ) to create knot vectors suitable for GL NURBS rendering.
void ON_GL | ( | const ON_3dPoint & | ) |
must be bracketed by calls to glBegin(GL_POINTS) / glEnd()
void ON_GL | ( | const ON_Brep & | , |
GLUnurbsObj * | |||
) |
Use ON_GL( const ON_Brep&, ...) to render OpenNURBS b-reps.
void ON_GL | ( | const ON_BrepFace & | , |
GLUnurbsObj * | |||
) |
Use ON_GL( const ON_BrepFace&, nobj ) to render the trimmed NURBS surface that defines a ON_Brep face's geometry. The call to ON_GL( const ON_BrepFace&, nobj ) should appear inside of a gluBeginSurface( nobj )/gluEndSurface( nobj ) pair.
void ON_GL | ( | const ON_Color & | , |
double | , | ||
GLfloat | [4] | ||
) |
void ON_GL | ( | const ON_Color & | , |
GLfloat | [4] | ||
) |
Use ON_GL( const ON_Color ...) to set GL color to OpenNURBS color.
void ON_GL | ( | const ON_Curve & | , |
GLUnurbsObj * | , | ||
GLenum | = 0 , |
||
double | [][4] = nullptr |
||
) |
void ON_GL | ( | const ON_Light & | , |
GLenum | |||
) |
void ON_GL | ( | const ON_Light * | , |
GLenum | |||
) |
Use ON_GL( const ON_Light, ...) to add OpenNURBS spotlights to GL lighting model
void ON_GL | ( | const ON_Material & | ) |
Use ON_GL( const ON_Material ...) to set GL material to OpenNURBS material.
void ON_GL | ( | const ON_Material * | ) |
void ON_GL | ( | const ON_Mesh & | ) |
Use ON_GL( const ON_Mesh&, ...) to render OpenNURBS meshes.
void ON_GL | ( | const ON_NurbsCurve & | , |
GLUnurbsObj * | , | ||
GLenum | = 0 , |
||
int | = 1 , |
||
double * | = nullptr , |
||
double | [][4] = nullptr |
||
) |
Use ON_GL( const ON_NurbsCurve&,...) in place of gluNurbsCurve(). See your system's gluNurbsCurve() documentation for details. In particular, for 3d curves the call to ON_GL( const ON_NurbsCurve&, nobj,...) should appear inside of a gluBeginCurve( nobj )/gluEndCurve( nobj ) pair. Generally, the GL "type" should be set using the formula ON_NurbsCurve:IsRational() ? GL_MAP1_VERTEX_4 : GL_MAP1_VERTEX_3;
void ON_GL | ( | const ON_NurbsSurface & | , |
GLUnurbsObj * | , | ||
GLenum | = 0 , |
||
int | = 1 , |
||
double * | = nullptr , |
||
double * | = nullptr |
||
) |
Use ON_GL( const ON_NurbsSurface&,...) in place of gluNurbsSurface(). See your system's gluNurbsSurface() documentation for details. In particular, the call to ON_GL( const ON_NurbsSurface&, nobj, ...) should appear inside of a gluBeginSurface( nobj )/gluEndSurface( nobj ) pair. Generally, the GL "type" should be set using the formula ON_NurbsSurface:IsRational() ? GL_MAP2_VERTEX_4 : GL_MAP2_VERTEX_3;
void ON_GL | ( | const ON_Point & | ) |
Use ON_GL( const ON_Point, ...) to render single points.
void ON_GL | ( | const ON_PointCloud & | ) |
Use ON_GL( const ON_PointCloud, ...) to render Rhino point sets.
void ON_GL | ( | const ON_Surface & | , |
GLUnurbsObj * | |||
) |
must be bracketed by calls to gluBeginSurface( nobj )/gluEndSurface( nobj )
void ON_GL | ( | const ON_Viewport & | ) |
Use ON_GL( ON_Viewport& ) to load the GL model view matrix (world to camera transformation).
void ON_GL | ( | int | , |
int | , | ||
int | , | ||
int | , | ||
const double * | , | ||
int | , | ||
const double * | , | ||
GLUnurbsObj * | , | ||
GLenum | = 0 , |
||
int | = 1 , |
||
double * | = nullptr , |
||
double | [][4] = nullptr |
||
) |
void ON_GL | ( | ON_Viewport & | , |
int | , | ||
int | , | ||
int | , | ||
int | |||
) |
Use ON_GL( ON_Viewport& ... ) to set the GL projections to match those used in the OpenNURBS viewport. Use ON_GL( ON_Viewport&, in, int, int, int ) to specify the size of the GL window and loads the GL projection matrix (camera to clip transformation). If the aspect ratio of the GL window and ON_Viewport's frustum do not match, the viewport's frustum is adjusted to get things back to 1:1.
For systems where the upper left corner of a window has coordinates (0,0) use: port_left = 0 port_right = width-1 port_bottom = height-1 port_top = 0
ON_DECL unsigned ON_GreatestCommonDivisor | ( | unsigned | a, |
unsigned | b | ||
) |
a | |
b |
ON_DECL double ON_GrevilleAbcissa | ( | int | , |
const double * | |||
) |
ON_DECL double ON_HairlinePrintWidth | ( | ) |
Description: Return a width in millimeters that is a valid hairline width in rhino
ON_DECL void ON_hsort | ( | void * | base, |
size_t | count, | ||
size_t | sizeof_element, | ||
int(*)(const void *, const void *) | compare | ||
) |
Description: Various sorts. When in doubt, use ON_qsort(). ON_qsort - quick sort. ON_hsort = hearp sort. Parameters base - [in] array of count elements count - [in] number of elements in the index[] and base[] arrays sizeof_element - [in] number of bytes between consecutive elements in the base[] array. compare - [in] Comparison function a la qsort(). The context parameter is pass as the third argument. context - [in] pointer passed as the third argument to compare(). Remarks: As a rule, use quick sort unless extensive tests in your case prove that heap sort is faster.
This implementation of quick sort is generally faster than heap sort, even when the input arrays are nearly sorted. The only common case when heap sort is faster occurs when the arrays are strictly "chevron" (3,2,1,2,3) or "carat" (1,2,3,2,1) ordered, and in these cases heap sort is about 50% faster. If the "chevron" or "caret" ordered arrays have a little randomness added, the two algorithms have the same speed.
ON_DECL void ON_hsort | ( | void * | base, |
size_t | count, | ||
size_t | sizeof_element, | ||
int(*)(void *, const void *, const void *) | compare, | ||
void * | context | ||
) |
void ON_HSORT_FNAME | ( | ON_SORT_TEMPLATE_TYPE * | base, |
size_t | nel | ||
) |
const ON_DECL ON_wString ON_IdToString | ( | ON_UUID | id | ) |
ON_DECL bool ON_IncreaseBezierDegree | ( | int | , |
bool | , | ||
int | , | ||
int | , | ||
double * | |||
) |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org.
ON_DECL ON__UINT64 ON_IndexFromNotUniqueId | ( | ON_UUID | not_unique_id | ) |
Description: This function is used for in testing situations when an ON_UUID value needs to be repeatable. Parameter: not_unique_id - [in] A not unique id created by ON_NotUniqueIdFromIndex() or ON_NextNotUniqueId(). Returns: If not_unique_id was created by on of the NotUniqueId functions, then the index of that id is returned. Otherwise, 0 is return if not_unique_id is nil and 0xFFFF00000000 is returned in all other cases.
ON_DECL int ON_InsertKnot | ( | double | , |
int | , | ||
int | , | ||
int | , | ||
int | , | ||
int | , | ||
double * | , | ||
double * | , | ||
int * | |||
) |
Returns: Number of knots added.
ON_DECL double ON_Integrate | ( | const class ON_Curve & | curve, |
double(*)(ON__UINT_PTR context, int limit_direction, double t) | f, | ||
ON__UINT_PTR | f_context, | ||
ON_Interval | integration_limit, | ||
double | relative_tolerance, | ||
double | absolute_tolerance, | ||
double * | error_bound | ||
) |
Calculates the definite integral of a smooth (C-infinity) function of one variable using a Rhomberg integration technique and returns returns Integral(f(t)*|curve'(t)|*dt). The C-infinity requirement is used by the Rhomberg algorithm when estimating error bounds and convergence. If you choose to pass a C2 function, you are likely to converge while getting less accurate results and incorrect error bound estimates. Using a C0 or C1 fucntion will ofter return nonsense.
curve | The integration is performed over the C-infinity spans of the curve and |curve'(t)| is automatically included in the integrand. The integrand must be C-infinity on the intesection each curve span with the interval (limits[0],limits[1]). The curve may have any dimension. |
f | The integrand function is double f(ON__UINT_PTR context, int limit_direction, double t) and returns the value of the integrand at t. The limit_direction parameter will be -1, 0, or +1 and specifies which limit direction should be used in the evaluation. If limit_direction = 1, then the integrand may not be C-infinity at t and should be evaluated using the limit from above. If limit_direction = -1, then the integrand may not be C-infinity at t and should be evaluated using the limit from below. If limit_direction = 0, then the integrand is C-infinity at t and may and evaluation from above and below will return the same answer. |
f_context | First parameter passed into the integrand function. |
integration_limit | If integration_limit if is not valid (ON_Interval::Nan or ON_Interval::EmptyInterval), then the integration is performed over the entire domain of the curve. Otherwise the integration is peformed over the intersection of integration_limit with each curve span. |
relative_tolerance | Desired relative tolerance. If I = mathematical value and N = numerical integration value, then the algorithm will terminate when |I - N| <= relative_tolerance*|I|. For example, if you want to know the answer with 5 digits of accuracy, then pass 1e-5. |
absolute_tolerance | Desired absolute tolerance. If I = mathematical value and N = numerical integration value, then the algorithm will terminate when |I - N| <= absolute_tolerance. |
error_bound | If error_bound is not nullptr, then the returned value is upper bound on the error in the calculation. If I = mathematical value and N = returned value, then |I - N| <= *error_bound; |
ON_DECL double ON_Integrate | ( | const class ON_Surface & | surface, |
double(*)(ON__UINT_PTR context, int limit_direction, double s, double t) | f, | ||
ON__UINT_PTR | f_context, | ||
ON_Interval | integration_limit1, | ||
ON_Interval | integration_limit2, | ||
double | relative_tolerance, | ||
double | absolute_tolerance, | ||
double * | error_bound | ||
) |
Calculates the definite integral of a smooth (C-infinity) function of two variables using a Rhomberg integration technique and returns returns Integral(f(s,t)*|dS/ds(s,t) x dS/dt(s,t)|*ds*dt), where dS/ds and dS/dt are the surface's first partial derivatives. The C-infinity requirement is used by the Rhomberg algorithm when estimating error bounds and convergence. If you choose to pass a C2 function, you are likely to converge while getting less accurate results and incorrect error bound estimates. Using a C0 or C1 fucntion will ofter return nonsense.
surface | The integration is performed over the C-infinity bispans of the surface and |dS/ds(s,t) x dS/dt(s,t)| is automatically included in the integrand. The integrand must be C-infinity on the intesection each surface bispan with the interval (limits[0]xlimits[1]). The surface must be 2 or 3 dimensional (surface.Dimension() = 2 or 3). |
f | The integrand function is double f(ON__UINT_PTR context, int limit_direction, double t) and returns the value of the integrand at t. The limit_direction parameter will be -1, 0, or +1 and specifies which limit direction should be used in the evaluation. If limit_direction = 1, then the integrand may not be C-infinity at t and should be evaluated using the limit from above. If limit_direction = -1, then the integrand may not be C-infinity at t and should be evaluated using the limit from below. If limit_direction = 0, then the integrand is C-infinity at t and may and evaluation from above and below will return the same answer. |
f_context | First parameter passed into the integrand function. |
integration_limit1 | If integration_limit1 if is not valid (ON_Interval::Nan or ON_Interval::EmptyInterval), then the integration is performed over the entire domain of the first surface parameter. Otherwise the integration is peformed over the intersection of integration_limit1 with each surface bispan. |
integration_limit2 | If integration_limit2 if is not valid (ON_Interval::Nan or ON_Interval::EmptyInterval), then the integration is performed over the entire domain of the second surface parameter. Otherwise the integration is peformed over the intersection of integration_limit2 with each surface bispan. |
relative_tolerance | Desired relative tolerance. If I = mathematical value and N = numerical integration value, then the algorithm will terminate when |I - N| <= relative_tolerance*|I|. For example, if you want to know the answer with 5 digits of accuracy, then pass 1e-5. |
absolute_tolerance | Desired absolute tolerance. If I = mathematical value and N = numerical integration value, then the algorithm will terminate when |I - N| <= absolute_tolerance. |
error_bound | If error_bound is not nullptr, then the returned value is upper bound on the error in the calculation. If I = mathematical value and N = returned value, then |I - N| <= *error_bound; |
ON_DECL double ON_Integrate | ( | double(*)(ON__UINT_PTR context, int limit_direction, double s, double t) | f, |
ON__UINT_PTR | f_context, | ||
const ON_SimpleArray< double > & | limits1, | ||
const ON_SimpleArray< double > & | limits2, | ||
double | relative_tolerance, | ||
double | absolute_tolerance, | ||
double * | error_bound | ||
) |
Calculates the definite integral of a piecewise smooth (C-infinity) function of two variables using a Rhomberg integration technique. The C-infinity requirement is used by the Rhomberg algorithm when estimating error bounds and convergence. If you choose to pass a C2 function, you are likely to converge while getting less accurate results and incorrect error bound estimates. Using a C0 or C1 fucntion will ofter return nonsense.
f | The integrand function is double f(ON__UINT_PTR context, int limit_direction, double s, double t) and returns the value of the integrand at (s, t). The limit_direction parameter is a bit field that specifies which limit directions should be used in the evaluation. If limit_direction = 1, then the integrand may not be C-infinity at (s,t) and should be evaluated using the limit from above for s and above for t. If limit_direction = 2, then the integrand may not be C-infinity at (s,t) and should be evaluated using the limit from below for s and above for t. If limit_direction = 3, then the integrand may not be C-infinity at (s,t) and should be evaluated using the limit from below for s and below for t. If limit_direction = 4, then the integrand may not be C-infinity at (s,t) and should be evaluated using the limit from above for s and below for t. If limit_direction = 0, then the integrand is C-infinity at t and may and evaluation from above and below will return the same answer. |
f_context | First parameter passed into the integrand function. |
limits1 | limits1[] must have at least 2 elements and specifies the integration limits for the first integration parameter. On each domain rectangle (limits1[i],limits1[i+1])x(limits2[j],limits2[j+1]), the integrand must be a C-infinity function. For example, when integrating over an ON_Surface, pass surface.SpanVector(0) as limits1 and surface.SpanVector(1) as limits2. |
limits2 | limits2[] must have at least 2 elements and specifies the integration limits for the second integration parameter. On each domain rectangle (limits1[i],limits1[i+1])x(limits2[j],limits2[j+1]), the integrand must be a C-infinity function. For example, when integrating over an ON_Surface, pass surface.SpanVector(0) as limits1 and surface.SpanVector(1) as limits2. |
relative_tolerance | Desired relative tolerance. If I = mathematical value and N = numerical integration value, then the algorithm will terminate when |I - N| <= relative_tolerance*|I|. For example, if you want to know the answer with 5 digits of accuracy, then pass 1e-5. |
absolute_tolerance | Desired absolute tolerance. If I = mathematical value and N = numerical integration value, then the algorithm will terminate when |I - N| <= absolute_tolerance. |
error_bound | If error_bound is not nullptr, then the returned value is upper bound on the error in the calculation. If I = mathematical value and N = returned value, then |I - N| <= *error_bound; |
ON_DECL double ON_Integrate | ( | double(*)(ON__UINT_PTR context, int limit_direction, double s, double t) | f, |
ON__UINT_PTR | f_context, | ||
ON_Interval | limits1, | ||
ON_Interval | limits2, | ||
double | relative_tolerance, | ||
double | absolute_tolerance, | ||
double * | error_bound | ||
) |
Calculates the definite integral of a smooth (C-infinity) function of two variables using a Rhomberg integration technique. The C-infinity requirement is used by the Rhomberg algorithm when estimating error bounds and convergence. If you choose to pass a C2 function, you are likely to converge while getting less accurate results and incorrect error bound estimates. Using a C0 or C1 fucntion will ofter return nonsense.
///
f | The integrand function is double f(ON__UINT_PTR context, int limit_direction, double s, double t) and returns the value of the integrand at (s, t). The limit_direction parameter is a bit field that specifies which limit directions should be used in the evaluation. If limit_direction = 1, then the integrand may not be C-infinity at (s,t) and should be evaluated using the limit from above for s and above for t. If limit_direction = 2, then the integrand may not be C-infinity at (s,t) and should be evaluated using the limit from below for s and above for t. If limit_direction = 3, then the integrand may not be C-infinity at (s,t) and should be evaluated using the limit from below for s and below for t. If limit_direction = 4, then the integrand may not be C-infinity at (s,t) and should be evaluated using the limit from above for s and below for t. If limit_direction = 0, then the integrand is C-infinity at t and may and evaluation from above and below will return the same answer. |
f_context | First parameter passed into the integrand function. |
limits1 | limits of integration for the first integration parameter. The integrand must be C-infinity on domain rectangle limits1 x limits2. |
limits2 | limits of integration for the second integration parameter. The integrand must be C-infinity on domain rectangle limits1 x limits2. |
relative_tolerance | Desired relative tolerance. If I = mathematical value and N = numerical integration value, then the algorithm will terminate when |I - N| <= relative_tolerance*|I|. For example, if you want to know the answer with 5 digits of accuracy, then pass 1e-5. |
absolute_tolerance | Desired absolute tolerance. If I = mathematical value and N = numerical integration value, then the algorithm will terminate when |I - N| <= absolute_tolerance. |
error_bound | If error_bound is not nullptr, then the returned value is upper bound on the error in the calculation. If I = mathematical value and N = returned value, then |I - N| <= *error_bound; |
ON_DECL double ON_Integrate | ( | double(*)(ON__UINT_PTR context, int limit_direction, double t) | f, |
ON__UINT_PTR | f_context, | ||
const ON_SimpleArray< double > & | limits, | ||
double | relative_tolerance, | ||
double | absolute_tolerance, | ||
double * | error_bound | ||
) |
Calculates the definite integral of a piecewise smooth (C-infinity) function of one variable using a Rhomberg integration technique and returns returns Integral(f(t)dt). The C-infinity requirement is used by the Rhomberg algorithm when estimating error bounds and convergence. If you choose to pass a C2 function, you are likely to converge while getting less accurate results and incorrect error bound estimates. Using a C0 or C1 fucntion will ofter return nonsense.
f | The integrand function is double f(ON__UINT_PTR context, int limit_direction, double t) and returns the value of the integrand at t. The limit_direction parameter will be -1, 0, or +1 and specifies which limit direction should be used in the evaluation. If limit_direction = 1, then the integrand may not be C-infinity at t and should be evaluated using the limit from above. If limit_direction = -1, then the integrand may not be C-infinity at t and should be evaluated using the limit from below. If limit_direction = 0, then the integrand is C-infinity at t and may and evaluation from above and below will return the same answer. |
f_context | FIrst parameter passed into the integrand function. |
limits | limits[] must have at least 2 elements and specifies the limits of integration. The integrand must be C-infinity on each interval (limits[i],limits[i+1). For example, when integrating over an ON_Curve, pass curve.SpanVector(). |
relative_tolerance | Desired relative tolerance. If I = mathematical value and N = numerical integration value, then the algorithm will terminate when |I - N| <= relative_tolerance*|I|. For example, if you want to know the answer with 5 digits of accuracy, then pass 1e-5. |
absolute_tolerance | Desired absolute tolerance. If I = mathematical value and N = numerical integration value, then the algorithm will terminate when |I - N| <= absolute_tolerance. |
error_bound | If error_bound is not nullptr, then the returned value is upper bound on the error in the calculation. If I = mathematical value and N = returned value, then |I - N| <= *error_bound; |
ON_DECL double ON_Integrate | ( | double(*)(ON__UINT_PTR context, int limit_direction, double t) | f, |
ON__UINT_PTR | f_context, | ||
ON_Interval | limits, | ||
double | relative_tolerance, | ||
double | absolute_tolerance, | ||
double * | error_bound | ||
) |
Calculates the definite integral of a smooth (C-infinity) function of one variable using a Rhomberg integration technique and returns returns Integral(f(t)dt). The C-infinity requirement is used by the Rhomberg algorithm when estimating error bounds and convergence. If you choose to pass a C2 function, you are likely to converge while getting less accurate results and incorrect error bound estimates. Using a C0 or C1 fucntion will ofter return nonsense.
f | The integrand function is double f(ON__UINT_PTR context, int limit_direction, double t) and returns the value of the integrand at t. The limit_direction parameter will be -1, 0, or +1 and specifies which limit direction should be used in the evaluation. If limit_direction = 1, then the integrand may not be C-infinity at t and should be evaluated using the limit from above. If limit_direction = -1, then the integrand may not be C-infinity at t and should be evaluated using the limit from below. If limit_direction = 0, then the integrand is C-infinity at t and may and evaluation from above and below will return the same answer. |
f_context | First parameter passed into the integrand function. |
limits | limits of integration. The integrand must be C-infinity on each interval (limits[0],limits[1]). |
relative_tolerance | Desired relative tolerance. If I = mathematical value and N = numerical integration value, then the algorithm will terminate when |I - N| <= relative_tolerance*|I|. For example, if you want to know the answer with 5 digits of accuracy, then pass 1e-5. |
absolute_tolerance | Desired absolute tolerance. If I = mathematical value and N = numerical integration value, then the algorithm will terminate when |I - N| <= absolute_tolerance. |
error_bound | If error_bound is not nullptr, then the returned value is upper bound on the error in the calculation. If I = mathematical value and N = returned value, then |I - N| <= *error_bound; |
void* ON_Internal_CompareExchangePointer | ( | void *volatile * | dest, |
void * | exchange, | ||
void * | comparand | ||
) |
ON_DECL int ON_Intersect | ( | const ON_Arc & | arc0, |
const ON_Arc & | arc1, | ||
ON_3dPoint & | point0, | ||
ON_3dPoint & | point1 | ||
) |
Description: Intersect a pair of arcs, note either arc could be a full circle Parameters: arc0 - [in] arc1 - [in] point0 - [out] first intersection point point1 - [out] second intersection point Returns: 0 No intersection 1 One intersection at point0 2 Two intersections at point0 and point1. 3 arcs are cocircular and overlap
ON_DECL bool ON_Intersect | ( | const ON_BoundingBox & | bbox, |
const ON_Line & | line, | ||
double | tolerance, | ||
ON_Interval * | line_parameters | ||
) |
Description: Intersect an infinite line and an axis aligned bounding box. Parameters: bbox - [in] line - [in] tolerance - [in] If tolerance > 0.0, then the intersection is performed against a box that has each side moved out by tolerance. line_parameters - [out] Pass null if you do not need the parameters. If true is returned and line.from != line.to, then the chord from line.PointAt(line_parameters[0]) to line.PointAt(line_parameters[1]) is the intersection. If true is returned and line.from = line.to, then line.from is in the box and the interval (0.0,0.0) is returned. If false is returned, the input value of line_parameters is not changed. Returns: True if the line intersects the box and false otherwise.
ON_DECL int ON_Intersect | ( | const ON_Circle & | c0, |
const ON_Circle & | c1, | ||
ON_3dPoint & | point0, | ||
ON_3dPoint & | point1 | ||
) |
Description: Intersect a pair of circles Parameters: circle0 - [in] circle11 - [in] point0 - [out] first intersection point point1 - [out] second intersection point Returns: 0 No intersection 1 One intersection at point0 2 Two intersections at point0 and point1. 3 Circles are identical
ON_DECL int ON_Intersect | ( | const ON_Line & | , |
const ON_Cylinder & | , | ||
ON_3dPoint & | , | ||
ON_3dPoint & | |||
) |
Description: Intersect an infinite line and a cylinder. Parameters: line - [in] cylinder - [in] pointA - [out] pointB - [out] Returns: 0: no intersection pointA is the point on line closest to cylinder, pointB is the point on cylinder closest to line. 1: intersection is a single point pointA is obtained by evaluating the line pointB is obtained by evaluating the cylinder 2: 2 distinct intersection points 3: line lies on cylinder Remarks: The value of cylinder.IsFinite() determines if the intersection is performed on the finite or infinite cylinder.
These simple intersectors are fast and detect transverse intersections. If the intersection is not a simple transverse case, then they return false and you will have to use one of the slower but fancier models. Description: Find the unique closest-points pair between two infinite lines, if it exists. Parameters: lineA - [in] lineB - [in] double* a - [out] double* b - [out] The shortest distance between the lines is the chord from lineA.PointAt(*a) to lineB.PointAt(*b). Returns: True if points are found and false if the lines are numerically parallel. Numerically parallel means the 2x2 matrix
AoA -AoB -AoB BoB
is numerically singular, where A = lineA.to-lineA.from and B = lineB.to-lineB.from. See Also: ON_IntersectLineLine
Description: Finds the intersection point of a line and plane, if it exists. Parameters: line - [in] plane - [in] line_parameter - [out] If the returned parameter is < 0 or > 1, then the line segment between line.from and line.to does not intersect the plane. Returns: true if the intersection is a single point, and false otherwise.
ON_DECL int ON_Intersect | ( | const ON_Line & | , |
const ON_Sphere & | , | ||
ON_3dPoint & | , | ||
ON_3dPoint & | |||
) |
Description: Intersect an infinite line and a sphere. Parameters: line - [in] sphere - [in] pointA - [out] First intersection point is returned here. pointB - [out] Second intersection point is returned here. Returns: 0: no intersection pointA is the point on line closest to sphere, pointB is the point on sphere closest to line. 1: intersection is a single point pointA is obtained by evaluating the line pointB is obtained by evaluating the sphere 2: 2 distinct intersection points
ON_DECL int ON_Intersect | ( | const ON_Line & | line, |
const ON_Arc & | arc, | ||
double * | line_t0, | ||
ON_3dPoint & | arc_point0, | ||
double * | line_t1, | ||
ON_3dPoint & | arc_point1 | ||
) |
Description: Intersect a infinite line and arc. Parameters: line - [in] arc - [in] line_t0 - [out] line parameter of first intersection point arc_point0 - [out] first intersection point on arc line_t1 - [out] line parameter of second intersection point arc_point1 - [out] second intersection point on arc Returns: 0 No intersection 1 One intersection at line.PointAt(*line_t0) 2 Two intersections at line.PointAt(*line_t0) and line.PointAt(*line_t1).
ON_DECL int ON_Intersect | ( | const ON_Line & | line, |
const ON_Circle & | circle, | ||
double * | line_t0, | ||
ON_3dPoint & | circle_point0, | ||
double * | line_t1, | ||
ON_3dPoint & | circle_point1 | ||
) |
Description: Intersect an infinite line and circle. Parameters: line - [in] circle - [in] line_t0 - [out] line parameter of first intersection point circle_point0 - [out] first intersection point on circle line_t1 - [out] line parameter of second intersection point circle_point1 - [out] second intersection point on circle Returns: 0 No intersection 1 One intersection at line.PointAt(*line_t0) 2 Two intersections at line.PointAt(*line_t0) and line.PointAt(*line_t1).
ON_DECL bool ON_Intersect | ( | const ON_Line & | line, |
const ON_PlaneEquation & | plane_equation, | ||
double * | line_parameter | ||
) |
Description: Finds the intersection point of a line and plane, if it exists. Parameters: line - [in] plane_equation - [in] line_parameter - [out] If the returned parameter is < 0 or > 1, then the line segment between line.from and line.to does not intersect the plane. Returns: true if the intersection is a single point, and false otherwise.
ON_DECL bool ON_Intersect | ( | const ON_Plane & | , |
const ON_Plane & | , | ||
const ON_Plane & | , | ||
ON_3dPoint & | |||
) |
Description: Finds the intersection point of three planes, if it exists. Parameters: planeA - [in] planeB - [in] planeC - [in] point_out - [out] Intersection point is returned here. Returns: true if the intersection is a single point, and false otherwise.
Description: Finds the intersection line between two planes, if it exists. Parameters: planeA - [in] planeB - [in] line_out - [out] Intersection line is returned here. Returns: true if the intersection is a single line, and false otherwise.
Description: Intersect a plane and a sphere. Parameters: plane - [in] sphere - [in] circle - [out] Intersection circle is returned here. Returns: 0: no intersection circle radius = 0, and circle origin = point on the plane closest to the sphere. 1: intersection is a single point circle radius = 0, and circle origin = tangent point on the plane. 2: intersection is a circle circle radius > 0.
ON_DECL int ON_Intersect | ( | const ON_Plane & | plane, |
const ON_Arc & | arc, | ||
ON_3dPoint & | point0, | ||
ON_3dPoint & | point1 | ||
) |
Description: Intersect a plane and an arc. Parameters: plane - [in] arc - [in] point0 - [out] first intersection point point1 - [out] second intersection point Returns: 0 No intersection 1 One intersection at point0 2 Two intersections at point0 and point1. 3 Arc lies on plane
ON_DECL int ON_Intersect | ( | const ON_Plane & | plane, |
const ON_Circle & | circle, | ||
ON_3dPoint & | point0, | ||
ON_3dPoint & | point1 | ||
) |
Description: Intersect a plane and a circle. Parameters: plane - [in] circle - [in] point0 - [out] first intersection point point1 - [out] second intersection point Returns: 0 No intersection 1 One intersection at point0 2 Two intersections at point0 and point1. 3 Circle lies on plane
ON_DECL int ON_Intersect | ( | const ON_Sphere & | sphere0, |
const ON_Sphere & | sphere1, | ||
ON_Circle & | circle | ||
) |
Description: Intersect two spheres using exact calculations. Parameters: sphere0 - [in] sphere1 - [in] circle - [out] If intersection is a point, then that point will be the center, radius 0. Returns: 0 if no intersection, 1 if a single point, 2 if a circle, 3 if the spheres are the same.
ON_DECL unsigned int ON_IntersectCoplanarLineAndTriangle | ( | const double | A[3], |
const double | B[3], | ||
const double | C[3], | ||
const double | N[3], | ||
const double | P[3], | ||
const double | Q[3], | ||
double | line_t[2], | ||
double | triangle_bc[2][3] | ||
) |
Parameters: A - [in] B - [in] C - [in] triangle corners. N - [in] null pointer or a nonzero unit vector perpendicular to the plane of the triangle. N may have either orientation (+N and -N work equally as well). This pointer can be the address of the "a" parameter of an ON_TrianglePlane calculated from this triangle. If a unit length normal is not available, pass null and the necessary information will be calculated in this function. P - [in] Q - [in] line segment ends. line_t - [out] The parameters of the intersection point(s) on the line segment. triangle_bc - [out] The barycentric coordinates of the intersection point(s) on the triangle. Returns: 0: no intersection 1: single point of intersection 2: overlap intersection
ON_DECL unsigned int ON_IntersectLineAndTriangle | ( | const double | A[3], |
const double | B[3], | ||
const double | C[3], | ||
const ON_TrianglePlane * | tri_plane, | ||
const double | P[3], | ||
const double | Q[3], | ||
double | tolerance, | ||
double | line_t[2], | ||
double | triangle_bc[2][3] | ||
) |
Parameters: A - [in] B - [in] C - [in] triangle corners. tri_plane - [in] null pointer or a valid triangle plane. P - [in] Q - [in] line segment ends. tolerance - [in] intersection tolerance. Values > zero are not perfectly handled. line_t - [out] The parameters of the intersection point(s) on the line segment. triangle_bc - [out] The barycentric coordinates of the intersection point(s) on the triangle. Returns: 0: no intersection line_t and triangle_bc values are not set. 1: single point of intersection line_t[0] and triangle_bc[0] values are set. line_t[1] and triangle_bc[1] values are not set 2: overlap intersection All line_t and triangle_bc values are set and line_t[0] < line_t[1].
ON_DECL bool ON_IntersectLineLine | ( | const ON_Line & | lineA, |
const ON_Line & | lineB, | ||
double * | a, | ||
double * | b, | ||
double | tolerance, | ||
bool | bIntersectSegments | ||
) |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org. These simple intersectors are fast and detect transverse intersections. If the intersection is not a simple transverse case, then they return false and you will have to use one of the slower but fancier models. Description: Intersect two lines. Parameters: lineA - [in] lineB - [in] double* a - [out] double* b - [out] The shortest distance between the lines is the chord from lineA.PointAt(*a) to lineB.PointAt(*b). tolerance - [in] If > 0.0, then an intersection is reported only if the distance between the points is <= tolerance. If <= 0.0, then the closest point between the lines is reported. bIntersectSegments - [in] if true, the input lines are treated as finite segments. If false, the input lines are treated as infinite lines. Returns: True if a closest point can be calculated and the result passes the tolerance parameter test. See Also: ON_Intersect( const ON_Line& lineA, const ON_Line& line B) Remarks: If the lines are exactly parallel, meaning the system of equations used to find a and b has no numerical solution, then false is returned. If the lines are nearly parallel, which is often numerically true even if you think the lines look exactly parallel, then the closest points are found and true is returned. So, if you care about weeding out "parallel" lines, then you need to do something like the following.
bool rc = ON_IntersectLineLine(lineA,lineB, &a,&b, tolerance, bIntersectSegments); if (rc) { double angle_tolerance_radians = 0.5*ON_PI/180.0; ///< or whatever double parallel_tol = cos(angle_tolerance_radians); if ( fabs(lineA.Tangent()*lineB.Tangent()) >= parallel_tol ) { ... do whatever you think is appropriate } }
ON_DECL bool ON_IntersectMeshRay | ( | const ON_Mesh * | mesh, |
const ON_3dRay & | ray, | ||
double | tolerance, | ||
ON_SimpleArray< double > & | ray_ts | ||
) |
Finds intersections between a mesh and a semi-infinite, oriented ray. Inputs: mesh [in] - a mesh. ray [in] - the ray. tolerance [in] - a small, positive value that is used to tell overlaps and perforations apart. ray_ts [in] - an array that will be filled with new values Outputs: true if successful. There may not be intersections in this case.
ON_DECL bool ON_IntersectViewFrustumPlane | ( | const ON_Viewport & | vp, |
const ON_PlaneEquation & | plane_equation, | ||
ON_SimpleArray< ON_3dPoint > & | points | ||
) |
Description: Calculate the corners of the polygon that is the intersection of a view frustum with and infinite plane. Parameters: vp - [in] defines view frustum plane_equation - [in] defined infinite plane points - [out] corners of the polygon. If true is returned and points.Count() is zero, then the plane missed the frustum. Note that the start/end point is not duplicated in the list. Returns: True if input was valid, false otherwise. Note that even when true is returned, the returned points.Count() may be zero if the plane and frustum do not intersect.
ON_DECL int ON_InvertSVDW | ( | int | count, |
const double * | W, | ||
double *& | invW | ||
) |
Description: Invert the diagonal matrix in a the singular value decomposition. Parameters: count - [in] number of elements in W W - [in] diagonal values in the singular value decomposition. invW - [out] The inverted diagonal is returned here. invW may be the same pointer as W. If the input value of invW is not null, it must point to an array of count doubles. If the input value of invW is null, heap storage will be allocated using onmalloc() and the calling function must call onfree(invW). Remarks: If the singular value decomposition were mathematically perfect, then this function would be: for (i = 0; i < count; i++) invW[i] = (W[i] != 0.0) ? 1.0/W[i] : 0.0; Because the double precision arithmetic is not mathematically perfect, very small values of W[i] may well be zero and this function makes a reasonable guess as to when W[i] should be treated as zero.
Returns: Number of non-zero elements in invW, which, in a mathematically perfect situation, is the rank of Diag(W).
ON_DECL bool ON_Is2dPatternSquished | ( | const ON_Geometry * | geometry | ) |
ON_DECL bool ON_IsConicEquationAnEllipse | ( | const double | conic[6], |
ON_2dPoint & | center, | ||
ON_2dVector & | major_axis, | ||
ON_2dVector & | minor_axis, | ||
double * | major_radius, | ||
double * | minor_radius | ||
) |
Description: Test a conic equation to see if it defines and ellipse. If so, return the center and axes of the ellipse. Parameters: conic - [in] Coefficients of the conic equation. The points on the conic satisfy the equation 0 = conic[0]*x^2 + conic[1]*xy + conic[2]*y^2
ON_DECL bool ON_IsContinuous | ( | ON::continuity | c, |
ON_3dPoint | Pa, | ||
ON_3dVector | D1a, | ||
ON_3dVector | D2a, | ||
ON_3dPoint | Pb, | ||
ON_3dVector | D1b, | ||
ON_3dVector | D2b, | ||
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 |
||
) |
Description: Test curve continuity from derivative values. Parameters: c - [in] type of continuity to test for. Read ON::continuity comments for details. Pa - [in] point on curve A. D1a - [in] first derivative of curve A. D2a - [in] second derivative of curve A. Pb - [in] point on curve B. D1b - [in] first derivative of curve B. D3b - [in] second derivative of curve B. point_tolerance - [in] if the distance between two points is greater than point_tolerance, then the curve is not C0. d1_tolerance - [in] if the difference between two first derivatives is greater than d1_tolerance, then the curve is not C1. d2_tolerance - [in] if the difference between two second derivatives is greater than d2_tolerance, then the curve is not C2. cos_angle_tolerance - [in] default = cos(1 degree) Used only when c is ON::continuity::G1_continuous or ON::continuity::G2_continuous. If the cosine of the angle between two tangent vectors is <= cos_angle_tolerance, then a G1 discontinuity is reported. curvature_tolerance - [in] (default = ON_SQRT_EPSILON) Used only when c is ON::continuity::G2_continuous. If K0 and K1 are curvatures evaluated from above and below and |K0 - K1| > curvature_tolerance, then a curvature discontinuity is reported. Returns: true if the curve has at least the c type continuity at the parameter t.
ON_DECL bool ON_IsConvexPolyline | ( | const ON_SimpleArray< ON_3dPoint > & | points, |
bool | bStrictlyConvex | ||
) |
Description: Determine if a polyline is convex. Parameters: points - [in] If points.Count() >= 4 and the first and last points are equal, then the zero length segment between those points is ignored. bStrictlyConvex - [in] If false, colinear segments are considered convex.
Returns True if the polyline is convex.
ON_DECL bool ON_IsConvexPolyline | ( | size_t | point_dim, |
size_t | point_count, | ||
const double * | points, | ||
size_t | point_stride, | ||
bool | bStrictlyConvex | ||
) |
Description: Determine if a polyline is convex. Parameters: point_dim - [in] 2 or 3 point_count - [in] points - [in] If point_count >= 4 and the first and last points are equal, then the zero length segment between those points is ignored. point_stride - [in] number of doubles between points (>=point_dim) bStrictlyConvex - [in] If false, colinear segments are considered convex.
Returns True if the polyline is convex.
ON_DECL bool ON_IsCurvatureDiscontinuity | ( | const ON_3dVector | Km, |
const ON_3dVector | Kp, | ||
double | cos_angle_tolerance, | ||
double | curvature_tolerance, | ||
double | zero_curvature, | ||
double | radius_tolerance | ||
) |
ON_DECL bool ON_IsCurvatureDiscontinuity | ( | const ON_3dVector | Km, |
const ON_3dVector | Kp, | ||
double | cos_angle_tolerance, | ||
double | curvature_tolerance, | ||
double | zero_curvature, | ||
double | radius_tolerance, | ||
double | relative_tolerance | ||
) |
Description: Determine if two curvatures are different enough to qualify as a curvature discontinuity. Parameters: Km - [in] Kp - [in] Km and Kp should be curvatures evaluated at the same parameters using limits from below (minus) and above (plus). The assumption is that you have already compared the points and tangents and consider to curve to be G1 at the point in question. cos_angle_tolerance - [in] If the input value of cos_angle_tolerance >= -1.0 and cos_angle_tolerance <= 1.0 and Km o Kp < cos_angle_tolerance*|Km|*|Kp|, then true is returned. Otherwise it is assumed Km and Kp are parallel. If the curve being tested is nonplanar, then use something like cos(2*tangent angle tolerance) for this parameter. If the curve being tested is planar, then 0.0 will work fine. curvature_tolerance - [in] If |Kp-Km| <= curvature_tolerance, then false is returned, otherwise other tests are used to determine continuity. zero_curvature - in If |K| <= zero_curvature, then K is treated as zero. When in doubt, use ON_ZERO_CURVATURE_TOLERANCE. radius_tolerance - [in] If radius_tolerance >= 0.0 and the difference between the radii of curvature is >= radius_tolerance, then true is returned. relative_tolerance - [in] If relative_tolerance > 0 and |(|Km| - |Kp|)|/max(|Km|,|Kp|) > relative_tolerance, then true is returned. Note that if the curvatures are nonzero and rm and rp are the radii of curvature, then |(|Km| - |Kp|)|/max(|Km|,|Kp|) = |rm-rp|/max(rm,rp). This means the relative_tolerance insures both the scalar curvature and the radii of curvature agree to the specified number of decimal places. When in doubt, use ON_RELATIVE_CURVATURE_TOLERANCE, which is currently 0.05. Returns: False if the curvatures should be considered G2. True if the curvatures are different enough that the curve should be considered not G2.
In addition to the tests described under the curvature_tolerance and radius_tolerance checks, other heuristic tests are used.
void ON_DECL ON_IsG1Closed | ( | const ON_Surface & | Srf, |
bool | closed[2] | ||
) |
Sets closed[di] if Surface if G1-closed in the di direction, i.e no G1-discontinuities on the interior or the seam.
ON_DECL bool ON_IsG2CurvatureContinuous | ( | const ON_3dVector | Km, |
const ON_3dVector | Kp, | ||
double | cos_angle_tolerance, | ||
double | curvature_tolerance | ||
) |
Description: This function is used to test curvature continuity in IsContinuous and GetNextDiscontinuity functions when the continuity parameter is ON::continuity::G2_continuous. Parameters: Km - [in] Curve's vector curvature evaluated from below Kp - [in] Curve's vector curvature evaluated from below Returns: True if the change from Km to Kp should be considered G2 continuous.
ON_DECL bool ON_IsGregorianLeapYear | ( | unsigned int | year | ) |
Parameters: year - [in] Returns: true if the year is a leap year in the Gregorian calendar.
ON_DECL bool ON_IsGsmoothCurvatureContinuous | ( | const ON_3dVector | Km, |
const ON_3dVector | Kp, | ||
double | cos_angle_tolerance, | ||
double | curvature_tolerance | ||
) |
Description: This function is used to test curvature continuity in IsContinuous and GetNextDiscontinuity functions when the continuity parameter is ON::continuity::Gsmooth_continuous. Parameters: Km - [in] Curve's vector curvature evaluated from below Kp - [in] Curve's vector curvature evaluated from below Returns: True if the change from Km to Kp should be considered Gsmooth continuous.
ON_DECL bool ON_IsHairlinePrintWidth | ( | double | width_mm | ) |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org. Description: Determine if a line width is deemed to be a "hairline width" in Rhino Any width that is >0 and < 0.001 mm is a hairline width for printing Parameters: width_mm: [in] the width to examine in millimeters Returns: true if this is a hairline width
ON_DECL bool ON_IsKnotVectorClamped | ( | int | order, |
int | cv_count, | ||
const double * | knot, | ||
int | = 2 |
||
) |
ON_DECL bool ON_IsKnotVectorPeriodic | ( | int | order, |
int | cv_count, | ||
const double * | knot | ||
) |
ON_DECL bool ON_IsKnotVectorUniform | ( | int | order, |
int | cv_count, | ||
const double * | knot | ||
) |
bool ON_IsLongChunkTypecode | ( | ON__UINT32 | typecode | ) |
ON_DECL bool ON_IsNaNd | ( | double | x | ) |
ON_DECL bool ON_IsNaNf | ( | float | x | ) |
ON_DECL bool ON_IsNotValid | ( | ) |
Description: When ON_Object::IsValid() fails and returns false, ON_IsNotValid() is called. This way, a developer can put a breakpoint in ON_IsNotValid() and stop execution at the exact place IsValid() fails. Returns: false;
ON_DECL bool ON_IsNullPtr | ( | const ON__INT_PTR | ptr | ) |
ON_DECL bool ON_IsNullPtr | ( | const ON__UINT_PTR | ptr | ) |
ON_DECL bool ON_IsNullPtr | ( | const void * | ptr | ) |
Description: Determine if an id is an opennurbs application id. Parameters: id - [in] id to test Returns: 0: id is not an opennurbs application id N: id == ON_opennurbsN_id, where "N" = 4,5,6,...
ON_DECL bool ON_IsOrthogonalFrame | ( | const ON_2dVector & | , |
const ON_2dVector & | |||
) |
ON_DECL bool ON_IsOrthogonalFrame | ( | const ON_2fVector & | , |
const ON_2fVector & | |||
) |
ON_DECL bool ON_IsOrthogonalFrame | ( | const ON_3dVector & | , |
const ON_3dVector & | , | ||
const ON_3dVector & | |||
) |
ON_DECL bool ON_IsOrthogonalFrame | ( | const ON_3fVector & | , |
const ON_3fVector & | , | ||
const ON_3fVector & | |||
) |
ON_DECL bool ON_IsOrthonormalFrame | ( | const ON_2dVector & | , |
const ON_2dVector & | |||
) |
ON_DECL bool ON_IsOrthonormalFrame | ( | const ON_2fVector & | , |
const ON_2fVector & | |||
) |
ON_DECL bool ON_IsOrthonormalFrame | ( | const ON_3dVector & | , |
const ON_3dVector & | , | ||
const ON_3dVector & | |||
) |
ON_DECL bool ON_IsOrthonormalFrame | ( | const ON_3fVector & | , |
const ON_3fVector & | , | ||
const ON_3fVector & | |||
) |
ON_DECL bool ON_IsPointGridClosed | ( | int | , |
bool | , | ||
int | , | ||
int | , | ||
int | , | ||
int | , | ||
const double * | , | ||
int | |||
) |
ON_DECL bool ON_IsPointListClosed | ( | int | , |
bool | , | ||
int | , | ||
int | , | ||
const double * | |||
) |
ON_DECL int ON_IsPointListPlanar | ( | bool | bRational, |
int | count, | ||
int | stride, | ||
const double * | points, | ||
const double * | boxMin, | ||
const double * | boxMax, | ||
double | tolerance, | ||
ON_PlaneEquation * | plane_equation | ||
) |
Description: Determine if a list of points is planar. Parameters: bRational - [in] false if the points are euclidean (x,y,z) true if the points are homogeneous rational (x,y,z,w) point_count - [in] number of points point_stride - [in] number of doubles between point x coordinates first point's x coordinate = points[0], second point's x coordinate = points[point_stride],... points - [in] point coordinates (3d or 4d homogeneous rational) boxMin - [in] boxMax - [in] optional 3d bounding box - pass nulls if not readily available tolerance - [in] >= 0.0 plane_equation0 - [in] If you want to test for planarity in a specific plane, pass the plane equation in here. If you want to find a plane containing the points, pass null here. plane_equation - [out] If this point is not null, then the equation of the plane containing the points is returned here. Returns: 0 - points are not coplanar to the specified tolerance 1 - points are coplanar to the specified tolerance 2 - points are collinear to the specified tolerance (in this case, plane_equation is not a unique answer) 3 - points are coincident to the specified tolerance (in this case, plane_equation is not a unique answer)
bool ON_IsPotentialWindowsCodePage932DoubleByteEncoding | ( | ON__UINT32 | lead_byte, |
ON__UINT32 | trailing_byte | ||
) |
bool ON_IsPotentialWindowsCodePage932SingleByteEncoding | ( | ON__UINT32 | x | ) |
Code page 932
bool ON_IsPotentialWindowsCodePage949DoubleByteEncoding | ( | ON__UINT32 | lead_byte, |
ON__UINT32 | trailing_byte | ||
) |
bool ON_IsPotentialWindowsCodePage949SingleByteEncoding | ( | ON__UINT32 | x | ) |
Code page 949
ON_DECL bool ON_IsPrivateUseUnicodeCodePoint | ( | ON__UINT32 | unicode_code_point | ) |
Description: Test a value to determine if it is a Unicode code point reserved for private use (can be user defined). Parameters: unicode_code_point - [in] value to test Returns: If unicode_code_point is a private use Unicode code point, then true is returned. Otherwise false is returned.
ON_DECL bool ON_IsProjectedPointOnTriangleBoundary | ( | const double | A[3], |
const double | B[3], | ||
const double | C[3], | ||
const double | N[3], | ||
const double | test_point[3] | ||
) |
Description: Determine if a projection of a point to a triangle's plane is on the boundary of the triangle. Parameters: A - [in] B - [in] C - [in] triangle corners. N - [in] null pointer or a nonzero unit vector perpendicular to the plane of the triangle. N may have either orientation (+N and -N work equally as well). This pointer can be the address of the "a" parameter of an ON_TrianglePlane calculated from this triangle. If a unit length normal is not available, pass null and the necessary information will be calculated in this function. test_point - [in] Returns: True if the projection of a point to a triangle's plane is on and edge or vertex of the triangle.
ON_DECL bool ON_IsProjectedPointOnTriangleBoundary | ( | const float | A[3], |
const float | B[3], | ||
const float | C[3], | ||
const float | N[3], | ||
const double | test_point[3] | ||
) |
ON_DECL bool ON_IsQNaNd | ( | double | x | ) |
ON_DECL bool ON_IsQNaNf | ( | float | x | ) |
Description: Determine if an id is a Rhino application id. Parameters: id - [in] id to test Returns: 0: id is not a Rhino application id N: id == ON_rhinoN_id, where "N" = 2,3,4,5,6,...
ON_DECL bool ON_IsRightHandFrame | ( | const ON_2dVector & | , |
const ON_2dVector & | |||
) |
ON_DECL bool ON_IsRightHandFrame | ( | const ON_2fVector & | , |
const ON_2fVector & | |||
) |
ON_DECL bool ON_IsRightHandFrame | ( | const ON_3dVector & | , |
const ON_3dVector & | , | ||
const ON_3dVector & | |||
) |
ON_DECL bool ON_IsRightHandFrame | ( | const ON_3fVector & | , |
const ON_3fVector & | , | ||
const ON_3fVector & | |||
) |
bool ON_IsShortChunkTypecode | ( | ON__UINT32 | typecode | ) |
ON_DECL bool ON_IsSNaNd | ( | double | x | ) |
ON_DECL bool ON_IsSNaNf | ( | float | x | ) |
ON_DECL bool ON_IsStandardUnicodeCodePoint | ( | ON__UINT32 | unicode_code_point | ) |
Description: Test a value to determine if it is a standard Unicode code point. Parameters: unicode_code_point - [in] value to test Returns: If unicode_code_point is a valid Unicode code point that is not reserved for private use and not the Unicode byte order mark (U+FFFE), then true is returned. Otherwise false is returned.
ON_DECL int ON_IsUnicodeC1ControlCodePoint | ( | ON__UINT32 | u | ) |
Returns: True if u >= U+0080 and u <= U+009F. Remarks: Additional space code points may be added in the future. The goal is to detect code points that separate words.
ON_DECL bool ON_IsUnicodeControlCodePoint | ( | ON__UINT32 | code_point, |
bool | bNullReturnValue | ||
) |
Parameters: code_point - [in] value to test bNullReturnValue value to return if 0 == code_point Returns: true if the code_point is a control code point (> 0 && < U+0020) or ( >= U+007F && <= U+00A0) or ( == U+00AD) or ...
ON_DECL int ON_IsUnicodeSpaceCodePoint | ( | ON__UINT32 | u | ) |
Returns: True if u is ON_UnicodeCodePoint::ON_Space, or a space character U+2000 - u+200B. Remarks: Additional space code points may be added in the future. The goal is to detect code points that separate words.
ON_DECL int ON_IsUnicodeSpaceOrControlCodePoint | ( | ON__UINT32 | u | ) |
Returns: True if u is some type of space or control code point. Examples include C0 code points ( <= u+001F ), ON_UnicodeCodePoint::ON_Space, ON_UnicodeCodePoint::ON_Delete, ON_UnicodeCodePoint::ON_NoBreakSpace, ON_UnicodeCodePoint::ON_NarrowNoBreakSpace,
ON_UnicodeCodePoint::ON_ZeroWidthSpace, and C1 code points. Remarks: Additional space code points may be added in the future. The goal is to detect code points that should be used as separators when isolating text tokens in a string.
Ligatures (ZWNJ U+200C, ZWJ U+200D) return false because they control formatting in a token.
ON_DECL enum ON_UnicodeEncoding ON_IsUTFByteOrderMark | ( | const void * | buffer, |
size_t | sizeof_buffer | ||
) |
Description: Determine if the buffer has the values of a UTF BOM (byte order mark) Parameters: buffer - [in] buffer to test sizeof_buffer - [in] number of bytes that can be examined in the buffer Returns: ON_UTF_unset (0) buffer is not a UTF BOM ON_UTF_8 sizeof_buffer >= 3 and the values fo the first three bytes are 0xEF, 0xBB, 0xBF. ON_UTF_16BE sizeof_buffer >= 2 and the values of the first two bytes are 0xFE, 0xFF and, if sizeof_buffer >= 4, the value of one of the third or forth byte is not zero. ON_UTF_16LE sizeof_buffer >= 2 and the values of the first two bytes are 0xFE, 0xFF ON_UTF_32BE sizeof_buffer >= 4 and the values of the first four bytes are 0x00, 0x00, 0xFE, 0xFF. ON_UTF_32LE sizeof_buffer >= 4 and the values of the first four bytes are 0xFF, 0xFE, 0x00, 0x00.
ON_DECL bool ON_IsValid | ( | double | x | ) |
Description: Test a double to make sure it is a valid number. Returns: (x > ON_UNSET_VALUE && x < ON_UNSET_POSITIVE_VALUE)
ON_DECL bool ON_IsValidFloat | ( | float | x | ) |
ON_DECL bool ON_IsValidKnotVector | ( | int | order, |
int | cv_count, | ||
const double * | knot, | ||
ON_TextLog * | text_log = 0 |
||
) |
ON_DECL bool ON_IsValidNegativeNumber | ( | double | x | ) |
Returns: (x > ON_UNSET_VALUE && x < 0.0));
ON_DECL bool ON_IsValidPointGrid | ( | int | , |
bool | , | ||
int | , | ||
int | , | ||
int | , | ||
int | , | ||
const double * | |||
) |
ON_DECL bool ON_IsValidPointList | ( | int | , |
bool | , | ||
int | , | ||
int | , | ||
const double * | |||
) |
ON_DECL bool ON_IsValidPointList | ( | int | , |
bool | , | ||
int | , | ||
int | , | ||
const float * | |||
) |
ON_DECL bool ON_IsValidPositiveNumber | ( | double | x | ) |
Returns: (x > 0.0 && x < ON_UNSET_POSITIVE_VALUE);
ON_DECL int ON_IsValidSingleByteUTF8CharValue | ( | char | c | ) |
ON_DEPRECATED.
ON_DECL int ON_IsValidSingleElementUTF16Value | ( | ON__UINT32 | c | ) |
ON_DEPRECATED.
ON_DECL int ON_IsValidSingleElementUTF8Value | ( | ON__UINT32 | c | ) |
ON_DEPRECATED.
ON_DECL int ON_IsValidSingleElementWideCharValue | ( | wchar_t | w | ) |
Description: Test a value to determine if it is a valid unicode code point value. Parameters: w - [in] value to test Returns: true: w is a valid single wchar_t value false: w is not a valid single wchar_t value. It may be a completely invalid value for a string. When sizeof(w) < 4, is may also b a value used in a multiple element encoding like a surrogate pair value. Remarks: Valid 1 byte wchar_t UTF-8 unicode code points are (0 <= w && w <= 0x7F) Valid 2 byte wchar_t UTF-16 unicode code points are (0 <= w && w <= 0xD7FF) || (0xE000 <= w && w <= 0xFFFF) Valid 4 bytes wchar_t UTF-32 unicode code points are (0 <= u && u <= 0xD7FF) || (0xE000 <= u && u <= 0x10FFFF)
ON_DECL int ON_IsValidUnicodeCodePoint | ( | ON__UINT32 | unicode_code_point | ) |
Description: Test a value to determine if it is a valid Unicode code point value. Parameters: u - [in] value to test Returns: If u is valid Unicode code point, then true is returned. Otherwise false is returned. Remarks: This function returns true for the Unicode byte order mark U+FFFE.
ON_DECL int ON_IsValidUTF16Singleton | ( | ON__UINT32 | c | ) |
Description: Test a value to determine if it is a valid single element UTF-16 value. Parameters: c - [in] value to test Returns: true: c is a valid single wchar_t unicode code point false: c is not a valid unicode code point w is not a valid single element UTF-16 value. It may be a completely invalid value or it may be a value used in a surrogate pair. Remarks: Valid single element UTF-16 values are (0 <= c && c <= 0xD7FF) || (0xE000 <= c && c <= 0xFFFF)
ON_DECL int ON_IsValidUTF16SurrogatePair | ( | unsigned int | w1, |
unsigned int | w2 | ||
) |
ON_DECL int ON_IsValidUTF32Value | ( | ON__UINT32 | c | ) |
Description: Test a value to determine if it is a valid UTF-32 value. Parameters: c - [in] value to test Returns: true: c is a valid UTF-32 value false: c is not a valid UTF-32 value Remarks: Valid single element UTF-32 values are (0 <= u && u <= 0xD7FF) || (0xE000 <= u && u <= 0x10FFFF)
ON_DECL int ON_IsValidUTF8Singleton | ( | ON__UINT32 | c | ) |
Description: Test a value to determine if it is a valid single byte UTF-8 value. Parameters: c - [in] value to test Returns: true: c is a valid single byte UTF-8 value false: c is not a valid single byte UTF-8 value Remarks: Valid single byte UTF-8 values are (0 <= c && c <= 0x7F)
ON_DECL int ON_IsValidUTF8SingletonChar | ( | char | c | ) |
Description: Test a value to determine if it is a valid single byte UTF-8 value. Parameters: c - [in] value to test Returns: true: c is a valid single byte UTF-8 value false: c is not a valid single byte UTF-8 value Remarks: Valid single byte UTF-8 values are (0 <= w && w <= 0x7F)
ON_DECL int ON_JoinCurves | ( | const ON_SimpleArray< const ON_Curve * > & | InCurves, |
ON_SimpleArray< ON_Curve * > & | OutCurves, | ||
double | join_tol, | ||
bool | bPreserveDirection = false , |
||
ON_SimpleArray< int > * | key = 0 |
||
) |
OBSOLETE. Use int ON_JoinCurves(const ON_SimpleArray<const ON_Curve*>& InCurves, ON_SimpleArray<ON_Curve*>& OutCurves, double join_tol, double kink_tol, bool bPreserveDirection = false, ON_SimpleArray<int>* key = 0 );
Description: Join all contiguous curves of an array of ON_Curves. Parameters: InCurves - [in] Array of curves to be joined (not modified) OutCurves - [out] Resulting joined curves and copies of curves that were not joined to anything are appended. join_tol - [in] Distance tolerance used to decide if endpoints are close enough bPreserveDirection - [in] If true, curve endpoints will be compared to curve startpoints. If false, all start and endpoints will be compared, and copies of input curves may be reversed in output. key - [out] if key is not null, InCurves[i] was joined into OutCurves[key[i]]. Returns: Number of curves added to Outcurves Remarks: Closed curves are copied to OutCurves. Curves that cannot be joined to others are copied to OutCurves. When curves are joined, the results are ON_PolyCurves. All members of InCurves must have same dimension, at most 3.
ON_DECL int ON_JoinCurves | ( | const ON_SimpleArray< const ON_Curve * > & | InCurves, |
ON_SimpleArray< ON_Curve * > & | OutCurves, | ||
double | join_tol, | ||
double | kink_tol, | ||
bool | bUseTanAngle, | ||
bool | bPreserveDirection = false , |
||
ON_SimpleArray< int > * | key = 0 |
||
) |
Description: Join all contiguous curves of an array of ON_Curves. Parameters: InCurves - [in] Array of curves to be joined (not modified) OutCurves - [out] Resulting joined curves and copies of curves that were not joined to anything are appended. join_tol - [in] Distance tolerance used to decide if endpoints are close enough kink_tol - [in] Angle in radians. If > 0.0, then curves within join_tol will only be joined if the angle between them is less than kink_tol. If <= 0, then the angle will be ignored and only join_tol will be used. bUseTanAngle - [in] If true, choose the best match using angle between tangents.
If false, best match is the closest. This is used whether or not kink_tol is positive. bPreserveDirection - [in] If true, curve endpoints will be compared to curve startpoints. If false, all start and endpoints will be compared, and copies of input curves may be reversed in output. key - [out] if key is not null, InCurves[i] was joined into OutCurves[key[i]]. Returns: Number of curves added to Outcurves Remarks: Closed curves are copied to OutCurves. Curves that cannot be joined to others are copied to OutCurves. When curves are joined, the results are ON_PolyCurves. All members of InCurves must have same dimension, at most 3.
ON_DECL int ON_JoinCurvesOld | ( | const ON_SimpleArray< const ON_Curve * > & | InCurves, |
ON_SimpleArray< ON_Curve * > & | OutCurves, | ||
double | join_tol, | ||
bool | bPreserveDirection, | ||
ON_SimpleArray< int > * | key | ||
) |
Description: Join all contiguous curves of an array of ON_Curves using an older sort algorithm. Unless this older version is necessary, use ON_JoinCurves instead. Parameters: InCurves - [in] Array of curves to be joined (not modified) OutCurves - [out] Resulting joined curves and copies of curves that were not joined to anything are appended. join_tol - [in] Distance tolerance used to decide if endpoints are close enough bPreserveDirection - [in] If true, curve endpoints will be compared to curve startpoints. If false, all start and endpoints will be compared, and copies of input curves may be reversed in output. key - [out] if key is not null, InCurves[i] was joined into OutCurves[key[i]]. Returns: Number of curves added to Outcurves Remarks: Closed curves are copied to OutCurves. Curves that cannot be joined to others are copied to OutCurves. When curves are joined, the results are ON_PolyCurves. All members of InCurves must have same dimension, at most 3.
bPreserveDirection | = false |
key | =0 |
ON_DECL int ON_JoinLines | ( | const ON_SimpleArray< ON_Line > & | InLines, |
ON_ClassArray< ON_Polyline > & | OutPolylines, | ||
double | tolerance, | ||
bool | bPreserveDirection, | ||
ON_SimpleArray< int > * | pKey | ||
) |
Description: Join an array of lines into one or more polylines. Parameters: InLines - [in] Array of lines to be joined (not modified) OutPolylines - [out] Array of resulting joined polylines. tolerance - [in] Distance tolerance used to decide if end points are close enough. Lines with length less than join_tol are NOT collapsed and can cause problems when end points do not match exactly. bPreserveDirection - [in] If true, line end points will be compared to line start points. If false, all start and end points will be compared, and copies of input curves may be reversed in output. key - [out] if key is not nullptr, InLines[i] was joined into OutPolylines[key[i]]. Returns: Number of polylines added to OutPolylines
ON_DECL int ON_JoinPolylines | ( | const ON_SimpleArray< const ON_Polyline * > & | InPlines, |
ON_SimpleArray< ON_Polyline * > & | OutPlines, | ||
double | join_tol, | ||
double | kink_tol, | ||
bool | bUseTanAngle, | ||
bool | bPreserveDirection = false , |
||
ON_SimpleArray< int > * | key = 0 |
||
) |
Description: Join all contiguous polylines of an array of ON_Polylines. Parameters: InPlines - [in] Array of polylines to be joined (not modified) OutPlines - [out] Resulting joined polylines and copies of polylines that were not joined to anything are appended. join_tol - [in] Distance tolerance used to decide if endpoints are close enough. Curves or segments with length less than join_tol are NOT collapsed and can cause problems when endpoints do not match exactly. kink_tol - [in] Angle in radians. If > 0.0, then curves within join_tol will only be joined if the angle between them is less than kink_tol. If <= 0, then the angle will be ignored and only join_tol will be used. bUseTanAngle - [in] If true, choose the best match using angle between tangents.
If false, best match is the closest. This is used whether or not kink_tol is positive. bPreserveDirection - [in] If true, polylines endpoints will be compared to polylines startpoints. If false, all start and endpoints will be compared, and copies of input curves may be reversed in output. key - [out] if key is not null, InPlines[i] was joined into OutPlines[key[i]]. Returns: Number of polylines added to OutPlines Remarks: Closed polylines are copied to OutPlines. Plines that cannot be joined to others are copied to OutPlines.
ON_DECL int ON_KnotCount | ( | int | , |
int | |||
) |
ON_DECL int ON_KnotMultiplicity | ( | int | , |
int | , | ||
const double * | , | ||
int | |||
) |
ON_DECL double ON_KnotTolerance | ( | int | , |
int | , | ||
const double * | , | ||
int | |||
) |
ON_DECL bool ON_KnotVectorHasBezierSpans | ( | int | order, |
int | cv_count, | ||
const double * | knot | ||
) |
returns true if all knots have multiplicity = degree
ON_DECL int ON_KnotVectorSpanCount | ( | int | , |
int | , | ||
const double * | |||
) |
ON_DECL ON::knot_style ON_KnotVectorStyle | ( | int | order, |
int | cv_count, | ||
const double * | knot | ||
) |
ON_DECL unsigned ON_LeastCommonMultiple | ( | unsigned | a, |
unsigned | b | ||
) |
The least common multiple of a and b is (a/gcd)*(b/gcd)*(gcd), where gcd = greatest common divisor of and b.
a | |
b |
ON_DECL double ON_Length2d | ( | double | x, |
double | y | ||
) |
Description: Return the length of a 2d vector (x,y) Returns: sqrt(x^2 + y^2) calculated in as precisely and safely as possible.
ON_DECL double ON_Length2dSquared | ( | double | x, |
double | y | ||
) |
Description: Return the squared length of a 2d vector (x,y) Returns: (x^2 + y^2)
ON_DECL double ON_Length3d | ( | double | x, |
double | y, | ||
double | z | ||
) |
Description: Return the length of a 3d vector (x,y,z) Returns: sqrt(x^2 + y^2 + z^2) calculated in as precisely and safely as possible.
ON_DECL double ON_Length3dSquared | ( | double | x, |
double | y, | ||
double | z | ||
) |
Description: Return the squared length of a 3d vector (x,y,z) Returns: (x^2 + y^2 + z^2)
ON_2dPoint ON_DECL ON_LiftInverse | ( | ON_2dPoint | P, |
ON_Interval | dom[2], | ||
bool | closed[2] | ||
) |
LiftInverse is the projection map that inverts ON_LiftToCover Parameters P -[in] A point in the domain covering space. Returns a point in dom.
ON_DECL ON_SimpleArray<ON_2dPoint> ON_LiftToCover | ( | const ON_SimpleArray< ON_2dPoint > & | in, |
const ON_Interval | dom[2], | ||
bool | closed[2], | ||
double | normband = 1.0/3.0 |
||
) |
Lift a sequence of surface points to the covering space.
If a surface is closed in the u-direction (or v respectively), a curve on the surface that crosses the seam will not have a continuous pull back to parameter space. However, if we extend the surface domain in the u-coordinates and allow the surface to cover itself periodiclly then we we can pull back the curve to the covering space (-inf,inf) x dom[1]. Parameters in - [in] surface parameter points in dom[0] x dom[1] dom -[in] surface domain closed -[in] closed[0] is true if the surface is closed in u direction (similarly for 1 and v) normband - [in] 0<normband<.5 is a normalized coordinate defining a band on each side of the seam. The point sequence crosses the seam if consecutive points are in opposite bands along the seam. Returns A sequence out with out[0] = in[0] and out.Count()==in.Count()
ON_DECL double ON_LinearInterpolation | ( | double | t, |
double | x, | ||
double | y | ||
) |
Description: Calculate the value of (1.0-t)*x + t*y so that, if 0.0 <= t <= 1.0, then the result is between x and y and if x == y and t is a valid double, the result is x. Returns: (1.0-t)*x + t*y
ON_DECL int ON_LineTriangleIntersect | ( | const ON_3dPoint & | A, |
const ON_3dPoint & | B, | ||
const ON_3dPoint & | C, | ||
const ON_3dPoint & | P, | ||
const ON_3dPoint & | Q, | ||
double | abc[2][3], | ||
double | t[2], | ||
double | tol | ||
) |
Description: Finds the intersection between a line segment an a triangle. Parameters: A - [in] triangle corner B - [in] triangle corner C - [in] triangle corner P - [in] start of line segment Q - [in] end of line segment abc - [out] barycentric coordinates of intersection point(s) t - [out] line coordinate of intersection point(s) Returns: 0 - no intersection 1 - one intersection point 2 - intersection segment
ON_DECL bool ON_MakeClampedUniformKnotVector | ( | int | order, |
int | cv_count, | ||
double * | knot, | ||
double | delta = 1.0 |
||
) |
Description: Fill in knot values for a clamped uniform knot vector. Parameters: order - [in] (>=2) order (degree+1) of the NURBS cv_count - [in] (>=order) total number of control points in the NURBS. knot - [in/out] Input is an array with room for ON_KnotCount(order,cv_count) doubles. Output is a clamped uniform knot vector with domain (0, (1+cv_count-order)*delta). delta - in spacing between knots. Returns: true if successful See Also: ON_NurbsCurve::MakeClampedUniformKnotVector
ON_DECL bool ON_MakeKnotVectorPeriodic | ( | int | , |
int | , | ||
double * | |||
) |
ON_DECL bool ON_MakePeriodicUniformKnotVector | ( | int | order, |
int | cv_count, | ||
double * | knot, | ||
double | delta = 1.0 |
||
) |
Description: Fill in knot values for a clamped uniform knot vector. Parameters: order - [in] (>=2) order (degree+1) of the NURBS cv_count - [in] (>=order) total number of control points in the NURBS. knot - [in/out] Input is an array with room for ON_KnotCount(order,cv_count) doubles. Output is a periodic uniform knot vector with domain (0, (1+cv_count-order)*delta). delta - in spacing between knots. Returns: true if successful See Also: ON_NurbsCurve::MakePeriodicUniformKnotVector
ON_DECL ON__UINT32 ON_MapMSSBCPToUnicode | ( | ON__UINT32 | code_page, |
ON__UINT32 | code_page_single_byte_encoding | ||
) |
Description: Convert a Microsoft single byte code page value to a UNICODE code point. Values 0x20 to 0x7E are the same as the ASCII encoding.
Parameters: code_page - [in] A Microsoft single byte code page value. (1252, 10000, etc) code_page_single_byte_encoding - [in] A single byte encoding of the desired glyph.
Returns: If cod page and code_page_single_byte_encoding are valid, then the best fit unicode code point is returned. Otherwise ON_UnicodeCodePoint::ON_ReplacementCharacter ( 0xFFFD ) is returned.
ON_DECL ON__UINT32 ON_MapRTFcharsetToWindowsCodePage | ( | ON__UINT32 | rtf_charset, |
ON__UINT32 | default_code_page | ||
) |
Description: Convert an RFT charset value to a Windows code page. This conversion is part of the process to get a UNICODE encoding of strings in RTF files.
Parameters: rtf_charset - [in] The RTF charset specified by /fcharsetN in the RTF font table. default_code_page - [out] Value to return if none is associated with the input rtf_charset value.
Returns: code page
Example:
The RTF: ... {\fonttbl ... {\f2\fcharset129 Malgun Gothic;} ... } ... {\f2 {\ltrch \'c7\'d1\'b1\'db...} ...
Uses RTF charset 129 which maps to Windows code page 949. This means {0xC7,0xD1,0xB1,0xBD, ... } needs to be parsed as a code page 949 multibyte encoding. The function ON_MapWindowsCodePage949ToUnicode() can be used to convert Windows code page 949 values to UNICODE code point values.
code page 949 0xC7D1 -> U+D55C #HANGUL SYLLABLE HIEUH A NIEUN code page 949 0xB1BD -> U+AD75 #HANGUL SYLLABLE KIYEOK U RIEULKIYEOK
NOTE WELL: The Windows code page 949 encoding uses both single and double byte encodings. When the initial byte has a value < 0x80, it is a single byte encoding. When the initial byte has a value > 0x80, it is a double byte encoding.
Remarks: Conversions are based on the Rich Text Format (RTF) Specification Version 1.9.1
ON_DECL ON__UINT32 ON_MapUnicodeToMSSBCP | ( | ON__UINT32 | code_page, |
ON__UINT32 | unicode_code_point | ||
) |
Description: Convert a Unicode code point to a Microsoft code page 1252 character value. Windows code page 1252 is a single byte encoding. Values 0x20 to 0x7E are the same as the ASCII encoding.
This function is used to find fonts where glyphs are identified by code page 1252 values.
Parameters: code_page - [in] A Microsoft single byte code page value. (1252, 10000, etc) unicode_code_point - [in] UNICODE code point
Returns: If unicode_code_point has a corresponding single byte encoding on the specified code page, then the single byte encoding is returned. Otherwise 0xFFFFFFFF is returned.
int ON_MapWindowsCodePage932ToUnicode | ( | ON__UINT32 | code_page_932_character_value, |
ON__UINT32 * | unicode_code_point | ||
) |
Description: Convert a Windows code page 932 encoded value to a UNICODE code point. This code page is often used for Japanese glyphs.
Parameters: code_page_932_character_value - [in] Valid values are 0 to 0xFDFE with some exceptions in that range. unicode_code_point - [out] ON_UnicodeCodePoint::ON_ReplacementCharacter is returned when code_page_932_character_value is not valid.
Returns: 1: if code_page_932_character_value and the corresponding UNICODE code point is returned in *unicode_code_point. 0: otherwise and *unicode_code_point = ON_UnicodeCodePoint::ON_ReplacementCharacter.
Remarks: Windows code page 932: https://msdn.microsoft.com/en-us/library/cc194887.aspx Conversions to Unicode are based on the Unicode.org mapping of Shift JIS ftp://ftp.unicode.org/Public/MAPPINGS/OBSOLETE/EASTASIA/JIS/SHIFTJIS.TXT
int ON_MapWindowsCodePage949ToUnicode | ( | ON__UINT32 | code_page_949_character_value, |
ON__UINT32 * | unicode_code_point | ||
) |
Description: Convert a Windows code page 949 encoded value to a UNICODE code point. This code page is often used for Korean glyphs.
Parameters: code_page_949_character_value - [in] Valid values are 0 to 0xFDFE with some exceptions in that range. unicode_code_point - [out] ON_UnicodeCodePoint::ON_ReplacementCharacter is returned when code_page_949_character_value is not valid.
Returns: 1: if code_page_949_character_value and the corresponding UNICODE code point is returned in *unicode_code_point. 0: otherwise and *unicode_code_point = ON_UnicodeCodePoint::ON_ReplacementCharacter.
Remarks: Windows code page 949: https://msdn.microsoft.com/en-us/library/cc194941.aspx Conversions to Unicode are based on the Unicode.org mapping of Windows-949 ftp://ftp.unicode.org/Public/MAPPINGS/VENDORS/MICSFT/WINDOWS/CP949.TXT
ON_DECL void ON_MathError | ( | const char * | , |
const char * | , | ||
const char * | |||
) |
ON_DECL double ON_MatrixSolutionPrecision | ( | const unsigned int | N, |
const double *const * | M, | ||
bool | bTransposeM, | ||
double | lambda, | ||
const double * | X, | ||
const double * | B | ||
) |
Returns: Maximum of fabs( ((M-lambda*I)*X)[i] - B[i] ) for 0 <= i < N Pass lambda = 0.0 if you're not testing some type of generalized eigenvalue.
ON_DECL double ON_Max | ( | double | a, |
double | b | ||
) |
If performance is important, then you are better off using ((b<a)?a:b)
ON_DECL float ON_Max | ( | float | a, |
float | b | ||
) |
If performance is important, then you are better off using ((b<a)?a:b)
ON_DECL int ON_Max | ( | int | a, |
int | b | ||
) |
If performance is important, then you are better off using ((b<a)?a:b)
ON_DECL double ON_MaximumCoordinate | ( | const double * | data, |
int | dim, | ||
bool | is_rat, | ||
int | count | ||
) |
Find the largest absolute value of coordinates from an array of points (possibly homogeneous).
ON_DECL double ON_MaximumCoordinate | ( | const double * | data, |
int | dim, | ||
bool | is_rat, | ||
int | count, | ||
int | stride | ||
) |
stride>=dim+is_rat
ON_DECL ON_memory_error_handler ON_memory_error_register_handler | ( | ON_memory_error_handler | ) |
ON_DECL int ON_memory_error_test_handler | ( | int | error_code | ) |
Description: Your app can call ON_memory_error_text_out_of_memory_handler() to trigger a call to the handler you registered with ON_memory_error_register_handler(). The parameter error_code is passed to your handler. Parameters: error_code - [in] Passed as the parameter to the registered ON_memory_error_handler function. 0: malloc/calloc/realloc request returned nullptr 1: invalid pointer passed to realloc() 2: invalid pointer passed to free() 3: msize query returned zero or 0xFFFFFFFF Returns: The value returned by the registered ON_memory_error_handler function.
ON_DECL void ON_MemoryManagerBegin | ( | void | ) |
ON_DECL void ON_MemoryManagerEnd | ( | void | ) |
ON_DECL size_t ON_MemoryPageSize | ( | ) |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org.
Description: Merges two breps into a single brep. The result may be non-manifold or have multiple connected components. Parameters: brep0 - [in] brep1 - [in] tolerance - [in] Returns: Merged brep or nullptr if calculation failed.
ON_DECL bool ON_Mesh2dPolygon | ( | int | point_count, |
int | point_stride, | ||
const double * | P, | ||
int | tri_stride, | ||
int * | triangle | ||
) |
Description: Triangulate a 2D simple closed polygon. Parameters: point_count - [in] number of points in polygon ( >= 3 ) point_stride - [in] P - [in] i-th point = (P[i*point_stride], P[i*point_stride+1]) tri_stride - [in] triangle - [out] array of (point_count-2)*tri_stride integers Returns: True if successful. In this case, the polygon is trianglulated into point_count-2 triangles. The indices of the 3 points that are the corner of the i-th (0<= i < point_count-2) triangle are (triangle[i*tri_stride], triangle[i*tri_stride+1], triangle[i*tri_stride+2]). Remarks: Do NOT duplicate the start/end point; i.e., a triangle will have a point count of 3 and P will specify 3 distinct non-collinear points.
ON_DECL int ON_Mesh2dRegion | ( | int | point_count, |
int | point_stride, | ||
const double * | points, | ||
int | edge_count, | ||
int | edge_stride, | ||
const int * | edges, | ||
const int * | edge_side, | ||
ON_SimpleArray< ON_3dex > & | triangles | ||
) |
Fill in a 2d region with triangles.
point_count | Number of 2d points. There must be at least 3 points. |
point_stride | Double offset for 2d points. i-th 2d point = (points[j],points[j+1]), where j = i*point_stride. |
points | 2d point locations. It is ok to include points that are inside the region but not at the end of any input edge. Duplicate points are not permitted. |
edge_count | Number of edges in the edges[] array. If edge_count = 0, then the convex hull of points[] will be the boundary. If edge_count = point_count, edge_stride = 0, edges = nullptr, and edge_side_stride = 0 then the input list of points must from a closed polyline and will be the outer boundary of the region to be meshed. Note this polyline does not have to be convex. |
edge_stride | i-th edge connects points (edges[j],edges[j+1]) where j = i*edge_stride. |
edges | indices of edge ends. If any edges intersect, then the intersection points are returned in new_points[]. |
edge_side | If not nullptr, then edge_side[i] determines which side(s) of the edge should be meshed. 0 = Automatically determined edge orientation. This is the best choice for all edges that are not inner boundary edges. 1 = left side only - boundary edge with a triangle on the left side. This is a good choice for clockwise inner boundary edges. 2 = right side only - boundary edge with a triangle on the right side. This is a good choice for counter-clockwise inner boundary edges. If edge_side = nullptr, the 0 is used for all edges. If all edges have the same edge_side value, then setting edge_side_stride = 0 and passing the address of char with that value saves having to create an array where every element has the same value. |
triangles | triangles are appended to this list. If you are reusing triangles[] for a collection of DISTINCT meshes, the call triangles.SetCount(0) before each call to ON_Mesh2dRegion(). If you are using multiple calls to ON_Mesh2dRegion() to create a single mesh, say your tesselatiing a sequence of glyphs into a single mesh, then you typically need to adjust the indices in the appended elements accordingly. The (i,j,k) values are vertex indices. If a triangle vertex index is 0 >= i < point_count, then the corresponding 2d point is (points[i*point_stride], points[i*point_stride+1]). If a triangle vertex index is i >= point_count, then the corresponding 2d point is new_points[i-point_count]. |
ON_DECL int ON_Mesh2dRegion | ( | unsigned int | point_count, |
unsigned int | point_stride, | ||
const double * | points, | ||
unsigned int | edge_count, | ||
unsigned int | edge_stride, | ||
const unsigned int * | edges, | ||
unsigned int | edge_side_stride, | ||
const unsigned char * | edge_side, | ||
bool | bOuterBoundaryIsConvexHull, | ||
bool | bPermitVertexAdditions, | ||
bool | bPermitEdgeSplitting, | ||
ON_SimpleArray< ON_3dex > & | triangles, | ||
ON_SimpleArray< ON_2dPoint > & | new_points | ||
) |
Fill in a 2d region with triangles.
point_count | Number of 2d points. There must be at least 3 points. |
point_stride | Double offset for 2d points. i-th 2d point = (points[j],points[j+1]), where j = i*point_stride. |
points | 2d point locations. It is ok to include points that are inside the region but not at the end of any input edge. Duplicate points are not permitted. |
edge_count | Number of edges in the edges[] array. If edge_count = 0, then the convex hull of points[] will be the boundary. If edge_count = point_count, edge_stride = 0, edges = nullptr, and edge_side_stride = 0 then the input list of points must from a closed polyline and will be the outer boundary of the region to be meshed. Note this polyline does not have to be convex. |
edge_stride | i-th edge connects points (edges[j],edges[j+1]) where j = i*edge_stride. |
edges | indices of edge ends. If any edges intersect, then the intersection points are returned in new_points[]. |
edge_side_stride | If edge_side is not nullptr, then the edge_side for the i-th edge is edge_side[i*edge_side_stride]. If you're calling from code where you have edge_side[] values stored in ints, you may pass a pointer to the least significant bit of the int and set edge_side_stride = sizeof(int). |
edge_side | If not nullptr, then edge_side[i] determines which side(s) of the edge should be meshed. 0 = Automatically determined edge orientation. This is the best choice for all edges that are not inner boundary edges. 1 = left side only - boundary edge with a triangle on the left side. This is a good choice for clockwise inner boundary edges. 2 = right side only - boundary edge with a triangle on the right side. This is a good choice for counter-clockwise inner boundary edges. If edge_side = nullptr, the 0 is used for all edges. If all edges have the same edge_side value, then setting edge_side_stride = 0 and passing the address of char with that value saves having to create an array where every element has the same value. |
bOuterBoundaryIsConvexHull | If edges[] contains one or more outer boundaries, then pass false. Otherwise pass true; the outer boundary of the returned mesh will be the convex hull of points[] and any edges that are not part of the convex hull will be inside the mesh. |
bPermitVertexAdditions | If true, then additional interior points may be added to improve the quality of the mesh. The additional points are returned in new_points[]. |
bPermitEdgeSplitting | If true, then intersection edges are split and other edges may be split edges may be split to improve mesh quality. The additional points are returned in new_points[]. |
triangles | triangles are appended to this list. If you are reusing triangles[] for a collection of DISTINCT meshes, the call triangles.SetCount(0) before each call to ON_Mesh2dRegion(). If you are using multiple calls to ON_Mesh2dRegion() to create a single mesh, say your tesselatiing a sequence of glyphs into a single mesh, then you typically need to adjust the indices in the appended elements accordingly. The (i,j,k) values are vertex indices. If a triangle vertex index is 0 >= i < point_count, then the corresponding 2d point is (points[i*point_stride], points[i*point_stride+1]). If a triangle vertex index is i >= point_count, then the corresponding 2d point is new_points[i-point_count]. |
new_points | If the returned new_points[] has count = 0, then no points were added. If the returned new_points[] has count > 0, then new points were added. If the edges intersect, then the intersection points are added to new_points[]. If bPermitVertexAdditions is true, then any those additions are added to new_points[]. |
ON_DECL int ON_Mesh2dRegion | ( | unsigned int | point_count, |
unsigned int | point_stride, | ||
const double * | points, | ||
unsigned int | edge_count, | ||
unsigned int | edge_stride, | ||
const unsigned int * | edges, | ||
unsigned int | edge_side_stride, | ||
const unsigned char * | edge_side, | ||
bool | bPermitVertexAdditions, | ||
bool | bPermitEdgeSplitting, | ||
ON_SimpleArray< ON_3dex > & | triangles, | ||
ON_SimpleArray< ON_2dPoint > & | new_points | ||
) |
Fill in a 2d region with triangles.
point_count | Number of 2d points. There must be at least 3 points. |
point_stride | Double offset for 2d points. i-th 2d point = (points[j],points[j+1]), where j = i*point_stride. |
points | 2d point locations. It is ok to include points that are inside the region but not at the end of any input edge. Duplicate points are not permitted. |
edge_count | Number of edges in the edges[] array. If edge_count = 0, then the convex hull of points[] will be the boundary. If edge_count = point_count, edge_stride = 0, edges = nullptr, and edge_side_stride = 0 then the input list of points must from a closed polyline and will be the outer boundary of the region to be meshed. Note this polyline does not have to be convex. |
edge_stride | i-th edge connects points (edges[j],edges[j+1]) where j = i*edge_stride. |
edges | indices of edge ends. If any edges intersect, then the intersection points are returned in new_points[]. |
edge_side_stride | If edge_side is not nullptr, then the edge_side for the i-th edge is edge_side[i*edge_side_stride]. If you're calling from code where you have edge_side[] values stored in ints, you may pass a pointer to the least significant bit of the int and set edge_side_stride = sizeof(int). |
edge_side | If not nullptr, then edge_side[i] determines which side(s) of the edge should be meshed. 0 = Automatically determined edge orientation. This is the best choice for all edges that are not inner boundary edges. 1 = left side only - boundary edge with a triangle on the left side. This is a good choice for clockwise inner boundary edges. 2 = right side only - boundary edge with a triangle on the right side. This is a good choice for counter-clockwise inner boundary edges. If edge_side = nullptr, the 0 is used for all edges. If all edges have the same edge_side value, then setting edge_side_stride = 0 and passing the address of char with that value saves having to create an array where every element has the same value. |
bPermitVertexAdditions | If true, then additional interior points may be added to improve the quality of the mesh. The additional points are returned in new_points[]. |
bPermitEdgeSplitting | If true, then intersection edges are split and other edges may be split edges may be split to improve mesh quality. The additional points are returned in new_points[]. |
triangles | triangles are appended to this list. If you are reusing triangles[] for a collection of DISTINCT meshes, the call triangles.SetCount(0) before each call to ON_Mesh2dRegion(). If you are using multiple calls to ON_Mesh2dRegion() to create a single mesh, say your tesselatiing a sequence of glyphs into a single mesh, then you typically need to adjust the indices in the appended elements accordingly. The (i,j,k) values are vertex indices. If a triangle vertex index is 0 >= i < point_count, then the corresponding 2d point is (points[i*point_stride], points[i*point_stride+1]). If a triangle vertex index is i >= point_count, then the corresponding 2d point is new_points[i-point_count]. |
new_points | If the returned new_points[] has count = 0, then no points were added. If the returned new_points[] has count > 0, then new points were added. If the edges intersect, then the intersection points are added to new_points[]. If bPermitVertexAdditions is true, then any those additions are added to new_points[]. |
ON_DECL int ON_Mesh2dRegion | ( | unsigned int | point_count, |
unsigned int | point_stride, | ||
const double * | points, | ||
unsigned int | edge_count, | ||
unsigned int | edge_stride, | ||
const unsigned int * | edges, | ||
unsigned int | edge_side_stride, | ||
const unsigned char * | edge_side, | ||
ON_SimpleArray< ON_3dex > & | triangles, | ||
ON_SimpleArray< ON_2dPoint > & | new_points | ||
) |
Fill in a 2d region with triangles.
point_count | Number of 2d points. There must be at least 3 points. |
point_stride | Double offset for 2d points. i-th 2d point = (points[j],points[j+1]), where j = i*point_stride. |
points | 2d point locations. It is ok to include points that are inside the region but not at the end of any input edge. Duplicate points are not permitted. |
edge_count | Number of edges in the edges[] array. If edge_count = 0, then the convex hull of points[] will be the boundary. If edge_count = point_count, edge_stride = 0, edges = nullptr, and edge_side_stride = 0 then the input list of points must from a closed polyline and will be the outer boundary of the region to be meshed. Note this polyline does not have to be convex. |
edge_stride | i-th edge connects points (edges[j],edges[j+1]) where j = i*edge_stride. |
edges | indices of edge ends. If any edges intersect, then the intersection points are returned in new_points[]. |
edge_side_stride | If edge_side is not nullptr, then the edge_side for the i-th edge is edge_side[i*edge_side_stride]. If you're calling from code where you have edge_side[] values stored in ints, you may pass a pointer to the least significant bit of the int and set edge_side_stride = sizeof(int). |
edge_side | If not nullptr, then edge_side[i] determines which side(s) of the edge should be meshed. 0 = Automatically determined edge orientation. This is the best choice for all edges that are not inner boundary edges. 1 = left side only - boundary edge with a triangle on the left side. This is a good choice for clockwise inner boundary edges. 2 = right side only - boundary edge with a triangle on the right side. This is a good choice for counter-clockwise inner boundary edges. If edge_side = nullptr, the 0 is used for all edges. If all edges have the same edge_side value, then setting edge_side_stride = 0 and passing the address of char with that value saves having to create an array where every element has the same value. |
triangles | triangles are appended to this list. If you are reusing triangles[] for a collection of DISTINCT meshes, the call triangles.SetCount(0) before each call to ON_Mesh2dRegion(). If you are using multiple calls to ON_Mesh2dRegion() to create a single mesh, say your tesselatiing a sequence of glyphs into a single mesh, then you typically need to adjust the indices in the appended elements accordingly. The (i,j,k) values are vertex indices. If a triangle vertex index is 0 >= i < point_count, then the corresponding 2d point is (points[i*point_stride], points[i*point_stride+1]). If a triangle vertex index is i >= point_count, then the corresponding 2d point is new_points[i-point_count]. |
new_points | If the edges intersect, then the intersection points are added to new_points[]./// |
ON_DECL int ON_MeshClashSearch | ( | int | mesh_listA_count, |
const ON_Mesh *const * | mesh_listA, | ||
int | mesh_listB_count, | ||
const ON_Mesh *const * | mesh_listB, | ||
double | distance, | ||
bool | bUseMultipleThreads, | ||
int | max_event_count, | ||
ON_SimpleArray< class ON_ClashEvent > & | clash_events | ||
) |
Description: Search for locations where the distance from a mesh in mesh_listA[] to a mesh in mesh_listB[] is <= distance. Parameters: mesh_listA_count - [in] length of mesh_listA[] array mesh_listA - [in] array of mesh pointers mesh_listB_count - [in] length of mesh_listB[] array mesh_listB - [in] array of mesh pointers distance - [in] (valid input are >= 0). bUseMultipleThreads - [in] Pass true if you want the calculation to use multiple threads. max_event_count - [in] If max_event_count > 0, then the search for clashes stops after max_event_count elements have been appended to clash_events[]. clash_events - [out] clash events are appended to this array. ON_ClashEvent.m_index[0] is a mesh_listA[] index and ON_ClashEvent.m_index[1] is a mesh_listB[] index. Returns: Number of events appended to clash_events[].
ON_DECL int ON_MeshFaceClashSearch | ( | const class ON_Mesh * | meshA, |
const class ON_RTree * | meshAtree, | ||
const class ON_Mesh * | meshB, | ||
const class ON_RTree * | meshBtree, | ||
double | distance, | ||
bool | bUseMultipleThreads, | ||
int | max_event_count, | ||
ON_SimpleArray< class ON_ClashEvent > & | clash_events | ||
) |
Description: Search for locations where the distance from a mesh in mesh_listA[] to a mesh in mesh_listB[] is <= distance. Parameters: meshA - [in] meshAtree - [in] nullptr or an ON_RTree created by calling CreateMeshFaceTree(meshA). meshB - [in] meshBtree - [in] nullptr or an ON_RTree created by calling CreateMeshFaceTree(meshB). distance - [in] (valid input are >= 0). bUseMultipleThreads - [in] Pass true if you want the calculation to use multiple threads. max_event_count - [in] If max_event_count > 0, then the search for clashes stops after max_event_count elements have been appended to clash_events[]. clash_events - [out] clash events are appended to this array. ON_ClashEvent.m_index[0] is a meshA->m_F[] index and ON_ClashEvent.m_index[1] is a meshB->m_F[] index. meshA_face_indices - [out] meshB_face_indices - [out] Returns: Number of events appended to clash_events[].
ON_DECL void ON_MeshFaceClashSearch | ( | const class ON_Mesh * | meshA, |
const class ON_RTree * | meshAtree, | ||
const class ON_Mesh * | meshB, | ||
const class ON_RTree * | meshBtree, | ||
double | distance, | ||
bool | bUseMultipleThreads, | ||
int | max_event_count, | ||
ON_SimpleArray< int > & | meshA_face_indices, | ||
ON_SimpleArray< int > & | meshB_face_indices | ||
) |
Description: Search for locations where the distance from a mesh in mesh_listA[] to a mesh in mesh_listB[] is <= distance. Parameters: meshA - [in] meshAtree - [in] nullptr or an ON_RTree created by calling CreateMeshFaceTree(meshA). meshB - [in] meshBtree - [in] nullptr or an ON_RTree created by calling CreateMeshFaceTree(meshB). distance - [in] (valid input are >= 0). bUseMultipleThreads - [in] Pass true if you want the calculation to use multiple threads. max_event_count - [in] If max_event_count > 0, then the search for clashes stops after max_event_count elements have been appended to clash_events[]. meshA_face_indices - [out] meshB_face_indices - [out] Returns: Number of events appended to clash_events[].
ON_DECL bool ON_MeshGetClosestPoint | ( | const ON_Mesh * | mesh, |
ON_3dPoint | P, | ||
ON_MESH_POINT * | t, | ||
double | distance_tolerance = 0.0 |
||
) |
ON_DECL bool ON_MeshMeshIntersect | ( | const ON_Mesh * | meshA, |
const ON_Mesh * | meshB, | ||
ON_ClassArray< ON_MMX_Polyline > & | plines, | ||
ON_ClassArray< ON_MMX_Polyline > & | overlapplines, | ||
double | intersection_tolerance = 0.0 , |
||
double | overlap_tolerance = 0.0 , |
||
bool | bDebug = false |
||
) |
This function is soon going to be deprecated. It always uses the old code.
ON_DECL bool ON_MeshMeshIntersectOldCompliant | ( | const ON_Mesh * | meshA, |
const ON_Mesh * | meshB, | ||
ON_ClassArray< ON_Polyline > & | plines, | ||
ON_ClassArray< ON_Polyline > & | overlapplines, | ||
double | intersection_tolerance = 0.0 , |
||
double | overlap_tolerance = 0.0 , |
||
bool | bDebug = false |
||
) |
This function intersects two meshes. Consider using the more advanced methods of the ON_Mesh class: IntersectArray, GetSelfIntersections, etc...
ON_DECL ON_Mesh* ON_MeshSurface | ( | const ON_Surface & | surface, |
int | mesh_density = 0 , |
||
ON_Mesh * | mesh = 0 |
||
) |
Description: Calculate a quick and dirty polygon mesh approximation of a surface. Parameters: surface - [in] mesh_density - [in] If <= 10, this number controls the relative polygon count. If > 10, this number specifies a target number of polygons. mesh - [in] if not nullptr, the polygon mesh will be put on this mesh. Returns: A polygon mesh approximation of the surface or nullptr if the surface could not be meshed.
ON_DECL ON_Mesh* ON_MeshSurface | ( | const ON_Surface & | surface, |
int | u_count, | ||
const double * | u, | ||
int | v_count, | ||
const double * | v, | ||
bool | bDoublePrecisionMesh, | ||
ON_Mesh * | mesh | ||
) |
ON_DECL ON_Mesh* ON_MeshSurface | ( | const ON_Surface & | surface, |
int | u_count, | ||
const double * | u, | ||
int | v_count, | ||
const double * | v, | ||
ON_Mesh * | mesh = 0 |
||
) |
Description: Calculate a quick and dirty polygon mesh approximation of a surface. Parameters: surface - [in] u_count - [in] >= 2 Number of "u" parameters in u[] array. u - [in] u parameters v_count - [in] >= 2 Number of "v" parameters in v[] array. v - [in] v parameters mesh - [in] if not nullptr, the polygon mesh will be put on this mesh. Returns: A polygon mesh approximation of the surface or nullptr if the surface could not be meshed.
ON_DECL double ON_Min | ( | double | a, |
double | b | ||
) |
If performance is important, then you are better off using ((a<b)?a:b)
ON_DECL float ON_Min | ( | float | a, |
float | b | ||
) |
If performance is important, then you are better off using ((a<b)?a:b)
ON_DECL int ON_Min | ( | int | a, |
int | b | ||
) |
If performance is important, then you are better off using ((a<b)?a:b)
ON_DECL double ON_Minimize | ( | unsigned | n, |
double(*)(ON__UINT_PTR context, const double *t, double *grad) | f, | ||
ON__UINT_PTR | f_context, | ||
const ON_Interval | search_domain[], | ||
const double | t0[], | ||
double | terminate_value, | ||
double | relative_tolerance, | ||
double | zero_tolerance, | ||
unsigned | maximum_iterations, | ||
double | t[], | ||
bool * | bConverged | ||
) |
Find a local minimum of the object function f(t[]) of n independent variables. The function must be C2 on the search domain. The search begins at t0[].
n | n >= 1 and is the number of variables the functiont f(). |
f | The objective function f(f_context, t, grad) is a function of n independent variables that returns the value of f() at (t[0], t[1], ..., t[n-1]). Calling f() should return grad = gradient of f at t. If the evaluation cannot be performed, return ON_DBL_QNAN and the seach will terminate. |
f_context | The first argument passed to the f() function. |
search_domain | If the interval search_domain[i] is valid, then t[i] is constrained to be in that interval. Otwerwise t[i] can have any value. |
t0 | t0[] is an input array of n evaluation parameters that specify where the search begins. You are permitted to pass the same array for the input array t0[] and the output array t[], provided it is properly initialized to the paramters where the search should begin. |
terminate_value | The search for a minimum will terminate and return t[] if f(t) <= terminate_value. If you don't have a terminate_value, then pass ON_DBL_QNAN. |
relative_tolerance | relative_tolerance > 0. The search for a minimum will terminate when 2*|f(t + delta) - f(t)| <= relative_tolerance*(|f(t + delta)| + |f(t)|) + zero_tolerance. For example, set relative_tolerance = 1e-6 if you want to find a t[] where the first 6 significant digits of f(t) have stabilized during the search. When in doubt, try 1e-6 and generally avoid values >= 1e-4. Always avoid values < 1e-16. |
zero_tolerance | zero_tolerance > 0. See the description of the relative_tolerance parameter for the use of the zero_tolerance parameter. When in doubt, pass something around 1e-16. |
maximum_iterations | The local minimum is found by iterating from the starting parameters t0[] to a local minimum. Tha maximum_iterations parameter specifies the masimum number of iterations to try before giving up. When in doubt, pass something around 200 for efficient evaluators and smaller vaules for slow evaluators. In some situations, there may be significantly more evaluations than maximum_iterations (from the line search step in each iteration). |
t | t[] is an output array of n evaluation parameters that specify where the search ended. You are permitted to pass the same array for the input array t0[] and the output array t[], provided it is properly initialized to the paramters where the search should begin. |
bConverged | If bConverged is not nullptr, then *bConvertged will be true if the search terminated because of the conditions controlled by terminate_value, relative_tolerance and relative_tolerance. Otherwise *bConverged will be false. |
const ON_DECL ON__UINT32* ON_MSSBCP_0x80_0xFF_Unicode | ( | ON__UINT32 | code_page | ) |
Description: Get a pointer to an array of 128 UNICODE code point values that are the best fit for Microsoft single byte code page encodings of 0x80 to 0xFF inclusive.
Parameters: code_page - [in] A Microsoft single byte code page value. (1252, 10000, etc) Returns: If code_page identifies a supported single byte code page, then an array of 128 UNICODE code points sorted by single byte encoding is returned. If a the single byte encoding is not defined, the corresponding element Otherwise nullptr is returned.
Example:
const ON__UINT32 code_page = ...; ON__UINT32 cp_encoding = ...; const ON__UINT32* cp_to_unicode = ON_MSSBCP_0x80_0xFF_Unicode(code_page); ON__UINT32 unicode_code_point = (nullptr != cp_to_unicode && cp_encoding >= 0x80 && cp_encoding <= 0xFF) ? cp_to_unicode[cp_encoding - 0x80] : ON_UnicodeCodePoint::ON_ReplacementCharacter;
ON_DECL int on_MultiByteToWideChar | ( | const char * | , |
int | , | ||
wchar_t * | , | ||
int | |||
) |
Description: Calls ON_ConvertUTF8ToWideChar()
ON_DECL bool ON_MX_GetUseNewCode | ( | ) |
Gets a value indicating if mesh booleans and intersections use the new code.
ON_DECL void ON_MX_SetUseNewCode | ( | bool | value | ) |
Determines if mesh booleans and intersections use the new code.
ON_DECL ON_CurveTreeBezier* ON_NewCurveTreeBezier | ( | const ON_BezierCurve & | bez | ) |
ON_DECL ON_CurveTreeBezier* ON_NewCurveTreeBezier | ( | int | dim, |
bool | is_rat, | ||
int | order | ||
) |
ON_DECL ON_SurfaceTreeBezier* ON_NewSurfaceTreeBezier | ( | const ON_BezierSurface & | bez | ) |
ON_DECL ON_SurfaceTreeBezier* ON_NewSurfaceTreeBezier | ( | int | dim, |
bool | is_rat, | ||
int | order0, | ||
int | order1 | ||
) |
ON__UINT64 ON_NextContentSerialNumber | ( | ) |
Returns: A nonzero runtime unsigned that is incremented every call to ON_NextContentSerialNumber(). This value is useful as a "content serial number" that can be used to detect when the content of an object has changed.
Description: This function is used for in testing situations when an ON_UUID value needs to be repeatable. Parameter: not_unique_id - [in] A not unique id created by ON_NotUniqueIdFromIndex() or ON_NextNotUniqueId(). Returns: If not_unique_id was created by on of the NotUniqueId functions, then a ON_UUID with the value xxxxxxxx-yyyy-11dc-9885-001372C33878 where xxxxxxxxyyyy = the hexadecimal representation of the int id's index + 1 is returned. Otherwise, NO_nil_uuid is returned. The returned id is not unique.
ON_DECL int ON_NextNurbsSpanIndex | ( | int | order, |
int | cv_count, | ||
const double * | knot, | ||
int | |||
) |
order | returns 0: input span_index < 0 cv_count-order: input span_index = cv_count-order -1: input span_index > cv_count-order; otherwise next span index |
ON_DECL ON_3dVector ON_NormalCurvature | ( | const ON_3dVector & | , |
const ON_3dVector & | , | ||
const ON_3dVector & | , | ||
const ON_3dVector & | , | ||
const ON_3dVector & | , | ||
const ON_3dVector & | , | ||
const ON_3dVector & | |||
) |
ON_DECL ON_UUID ON_NotUniqueIdFromIndex | ( | ON__UINT32 | index_32_bit | ) |
Description: This function is used for in testing situations when an ON_UUID value needs to be repeatable. Parameter: index_32_bit - [in] index_32_bit > 0. Calling this function with the same index will create an ON_UUID with the same value. Returns: If index_32_bit = 0, then ON_nil_uuid is returned. Otherwise, a ON_UUID with the value xxxxxxxx-yyyy-11dc-9885-001372C33878 where xxxxxxxxyyyy = the hexadecimal representation of index_32_bit. The returned id is not unique.
ON_DECL ON_UUID ON_NotUniqueIdFromIndex | ( | ON__UINT64 | index_64_bit | ) |
Description: This function is used for in testing situations when an ON_UUID value needs to be repeatable. Parameter: index_64_bit - [in] index_64_bit > 0 and index_64_bit <= 0X0000FFFFFFFFFFFF. Calling this function with the same index will create an ON_UUID with the same value. Returns: If index_64_bit = 0 or >0X0000FFFFFFFFFFFF, then ON_nil_uuid is returned. Otherwise, a ON_UUID with the value xxxxxxxx-yyyy-11dc-9885-001372C33878 where xxxxxxxxyyyy = the hexadecimal representation of index_64_bit. The returned id is not unique.
ON_DECL int ON_NurbsSpanIndex | ( | int | order, |
int | cv_count, | ||
const double * | knot, | ||
double | t, | ||
int | side, | ||
int | hint | ||
) |
Description: Given an evaluation parameter t in the domain of a NURBS curve, ON_NurbsSpanIndex(order,cv_count,knot,t,0,0) returns the integer i such that (knot[i],...,knot[i+2*degree-1]), and (cv[i],...,cv[i+degree]) are the knots and control points that define the span of the NURBS that are used for evaluation at t. Parameters: order - [in] order >= 2 cv_count - [in] cv_count >= order knot - [in] valid knot vector t - [in] evaluation parameter side - [in] determines which span is used when t is at a knot value; side = 0 for the default (from above), side = -1 means from below, and side = +1 means from above. hint - [in] Search hint, or 0 if not hint is available. Returns: Returns the index described above.
ON_DECL ON_NurbsSurface* ON_NurbsSurfaceQuadrilateral | ( | const ON_3dPoint & | P, |
const ON_3dPoint & | Q, | ||
const ON_3dPoint & | R, | ||
const ON_3dPoint & | S, | ||
ON_NurbsSurface * | nurbs_surface = nullptr |
||
) |
Description: Get an ON_NurbsSurface definition of a quadrilateral. Parameters: P - [in] Q - [in] R - [in] S - [in] corners in counter clockwise layer nurbs_surface - [in] if this pointer is not nullptr, then this ON_NurbsSurface is used to return the quadrilateral. Returns: An ON_NurbsSurface representation of the quadrilateral.
ON_DECL bool ON_OrderEdgesAroundVertex | ( | const ON_Brep & | B, |
int | vid, | ||
ON_2dex * | trim_ends, | ||
bool & | bClosed | ||
) |
Description: Very low level utility. Order edges around a vertex. Parameters: B - [in] vid - [in] trim_ends - [out] trim_ends[a].i is a trim index, trim_ends[a].j is 0 for start or 1 for end. The nth is B.m_T[trim_ends[n].i].Edge(). If bClosed is false, then the first and last edges will be naked. Must have at least as many ON2dex as the vertex has edges. bClosed - [out] If true, then all edges at the vertex have exactly two trims Returns: True if the order can be found. If any edge at the vertex is non-manifold, or if more than two are naked, then false. NOTE: If you don't know how many edges are at the vertex, call the version that takes an ON_SimpleArray.
trim_ends | Must be at as big as the edge count at the vertex |
ON_DECL bool ON_OrderEdgesAroundVertex | ( | const ON_Brep & | B, |
int | vid, | ||
ON_SimpleArray< ON_2dex > & | trim_ends, | ||
bool & | bClosed | ||
) |
Description: Very low level utility. Order edges around a vertex. Parameters: B - [in] vid - [in] trim_ends - [out] trim_ends[a].i is a trim index, trim_ends[a].j is 0 for start or 1 for end. The nth is B.m_T[trim_ends[n].i].Edge(). If bClosed is false, then the first and last edges will be naked. bClosed - [out] If true, then all edges at the vertex have exactly two trims Returns: True if the order can be found. If any edge at the vertex is non-manifold, or if more than two are naked, then false.
ON_DECL bool ON_PackTextureRectangles | ( | class ON_PackedTextureRectangle * | rectangle_list, |
const class ON_PackTextureRectanglesParameters * | packing_parameters | ||
) |
Description: Pack a collection of rectangles into a rectangle. Parameters: rectangle_list - [in] a linked list of rectangles defined by the m_next pointers. The last item in the list must have a null m_next pointer.
or
rectangle_count - [in] rectangle_array - [in] an array of rectangle_count rectangles to pack. The m_next pointers will be set so the array is a linked list.
or
rectangle_array - [in] A simple dynamic array of rectangles. The m_next pointers will be set so the array is a linked list.
ON_DECL bool ON_PackTextureRectangles | ( | ON_SimpleArray< ON_PackedTextureRectangle > & | rectangle_array, |
const class ON_PackTextureRectanglesParameters * | packing_parameters | ||
) |
ON_DECL bool ON_PackTextureRectangles | ( | size_t | rectangle_count, |
class ON_PackedTextureRectangle * | rectangle_array, | ||
const class ON_PackTextureRectanglesParameters * | packing_parameters | ||
) |
ON_DECL int ON_ParseAngleArcDegreesExpression | ( | const wchar_t * | str, |
int | str_count, | ||
ON::AngleUnitSystem | default_str_angle_unit_system, | ||
double * | angle_value_in_arc_degrees | ||
) |
Description: Parses str to determine if it specifies a angle value.
Parameters: str - [in]
str_count - [in] str[] and str_count specify the string to parse. If str_count >= 0. it specifies the maximum number of elements in str[] that may be parsed. If str_count = -1, then the string must contain a character that terminates angle parsing.
default_str_angle_unit_system - [in] If an angle unit system is not specified in the parsed string, then default_str_angle_units determines what unit system will be used. If default_str_angle_units is ON::AngleUnitSystem::None, then ON::radians will be used.
angle_value_in_radians - [out] The value of the parsed angle, converted to arc degrees, is returned here.
Returns: Number of elements of str that were parsed. A return value of 0 indicates that str could not be parsed as a angle value.
Remarks: This function uses ON_ParseAngleExpression() with the angle_value_unit_system parameter set to ON::AngleUnitSystem::Degrees to parse the string. If you need more control over parsing options, then use ON_ParseAngleExpression().
ON_DECL int ON_ParseAngleExpression | ( | const wchar_t * | str, |
int | str_count, | ||
ON_ParseSettings | parse_settings, | ||
const ON::AngleUnitSystem | angle_value_unit_system, | ||
double * | angle_value, | ||
ON_ParseSettings * | parse_results, | ||
ON::AngleUnitSystem * | str_angle_unit_system | ||
) |
ON_DECL int ON_ParseAngleExpression | ( | const wchar_t * | str, |
int | str_count, | ||
ON_ParseSettings | parse_settings, | ||
double * | angle_value, | ||
ON_ParseSettings * | parse_results, | ||
ON::AngleUnitSystem * | str_angle_unit_system | ||
) |
Description: Parses str to determine if it specifies a angle value.
Parameters: str - [in]
str_count - [in] str[] and str_count specify the string to parse. If str_count >= 0. it specifies the maximum number of elements in str[] that may be parsed. If str_count = -1, then the string must contain a character that terminates angle parsing.
parse_settings - [in] The input parse_settings parameter controls what input may be parsed and how it is parsed. Use ON_ParseSettings::DefaultSettings for common parsing tasks.
angle_value_unit_system - [in] Angle unit system for the returned value.
For example, if you want the returned value to be in degrees, you would specify ON::AngleUnitSystem::Degrees here.
angle_value - [out] The value of the parsed angle.
parse_results - [out] (input pointer can be null) The output parse_results parameter reports what was parsed.
str_angle_unit_system - [out] (input pointer can be null) angle unit in the parsed string. When the angle_value_unit_system specifies an angle unit system and a a different angle unit system is parsed, the number returned in angle_value is always converted to the angle unit system specified by the angle_value_unit_system parameter. If needed, you can inspect str_angle_unit_system to determine if the angle unit system scaling was applied.
Returns: Number of elements of str that were parsed. A return value of 0 indicates that str could not be parsed as a angle value.
ON_DECL int ON_ParseAngleRadiansExpression | ( | const wchar_t * | str, |
int | str_count, | ||
ON::AngleUnitSystem | default_str_angle_unit_system, | ||
double * | angle_value_in_radians | ||
) |
Description: Parses str to determine if it specifies a angle value.
Parameters: str - [in]
str_count - [in] str[] and str_count specify the string to parse. If str_count >= 0. it specifies the maximum number of elements in str[] that may be parsed. If str_count = -1, then the string must contain a character that terminates angle parsing.
default_str_angle_unit_system - [in] If an angle unit system is not specified in the parsed string, then default_str_angle_units determines what unit system will be used. If default_str_angle_units is ON::AngleUnitSystem::None, then ON::radians will be used.
angle_value_in_radians - [out] The value of the parsed angle, converted to radians, is returned here.
Returns: Number of elements of str that were parsed. A return value of 0 indicates that str could not be parsed as a angle value.
Remarks: This function uses ON_ParseAngleExpression() with the angle_value_unit_system parameter set to ON::radians to parse the string. If you need more control over parsing options, then use ON_ParseAngleExpression().
ON_DECL int ON_ParseAngleUnitName | ( | const wchar_t * | str, |
int | str_count, | ||
int | prefered_locale_id, | ||
ON::AngleUnitSystem * | angle_unit_system | ||
) |
Description: Parses str if it is a recognized angle unit system name or abbreviation.
Parameters: str - [in]
str_count - [in] str[] and str_count specify the string to parse. If str_count >= 0. it specifies the maximum number of elements in str[] that may be parsed. If str_count = -1, then the string must contain a character that terminates angle unit system name parsing.
This character can be a null, digit, punctuation, arithmetic operator, or a unicode code point <= 0x0020 (0x0020 = space = 32 decimal).
prefered_locale_id - [in] If the parsed angle unit name identifies different angle unit systems in different locales, then this value is used to resolve the ambiguity. A list of Microsoft locale id values can be found at http://msdn.microsoft.com/en-us/library/ms912047(v=winembedded.10). For example, "Grad" identifies ON::degrees in German and ON::gradians in US English.
bParseLeadingWhitespace - [in] If true, leading white space will be parsed. If false, the unit name must begin with element str[0].
angle_unit_system - [out] (can be null) If angle_unit_system is not null, it is set to the identify the angle unit system specified by str. If str does not identify a known angle unit system, then *angle_unit_system is set to ON::AngleUnitSystem::None.
Returns: Number of elements of str that were parsed. A return value of 0 indicates that str did not match know unit system names or abbreviations.
Remarks: Currently common names and abbreviations for radians, turns, gradians, arc degrees, arc minutes and arc seconds are supported in Czech (cs-*), English (en-*), French (fr-*), German (de-*), Portuguese (pt-*) and Spanish (es-*).
If the first element of str is quotation mark (double quote), unicode code point 0x0022, the string is parsed as arc seconds. If the first element of str is apostrophe, unicode code point 0x0027, the string is parsed as arc minutes.
ON_DECL int ON_ParseAngleUnitName | ( | const wchar_t * | str, |
int | str_count, | ||
ON_ParseSettings | parse_settings, | ||
ON::AngleUnitSystem * | angle_unit_system | ||
) |
ON_DECL int ON_ParseLengthExpression | ( | const wchar_t * | str, |
int | str_count, | ||
ON::AngleUnitSystem | default_str_angle_unit_system, | ||
const ON_UnitSystem & | length_value_unit_system, | ||
double * | length_value | ||
) |
ON_DECL int ON_ParseLengthExpression | ( | const wchar_t * | str, |
int | str_count, | ||
ON::AngleUnitSystem | default_str_angle_unit_system, | ||
ON::LengthUnitSystem | length_value_unit_system, | ||
double * | length_value | ||
) |
ON_DECL int ON_ParseLengthExpression | ( | const wchar_t * | str, |
int | str_count, | ||
ON_ParseSettings | parse_settings, | ||
const ON_UnitSystem & | length_value_unit_system, | ||
double * | length_value, | ||
ON_ParseSettings * | parse_results, | ||
ON::LengthUnitSystem * | str_length_unit_system | ||
) |
ON_DECL int ON_ParseLengthExpression | ( | const wchar_t * | str, |
int | str_count, | ||
ON_ParseSettings | parse_settings, | ||
double * | length_value, | ||
ON_ParseSettings * | parse_results, | ||
ON::LengthUnitSystem * | str_length_unit_system | ||
) |
Description: Parses str to determine if it specifies a length value.
Parameters: str - [in]
str_count - [in] str[] and str_count specify the string to parse. If str_count >= 0, it specifies the maximum number of elements in str[] that may be parsed. If str_count = -1, then the string must contain a character that terminates length parsing.
parse_settings - [in] The input parse_settings parameter controls what input may be parsed and how it is parsed. Use ON_ParseSettings::DefaultSettings for common parsing tasks.
length_value_unit_system - [in] Length unit system for the returned value.
For example, if you want the returned value to be in meters, you would specify ON::LengthUnitSystem::Meters here. If you want to use custom units, you must use the override with the ON_UnitSystem parameter.
length_value - [out] The value of the parsed length.
parse_results - [out] (input pointer can be null) The output parse_results parameter reports what was parsed.
str_length_unit_system - [out] (input pointer can be null) length unit in the parsed string. When the length_value_unit_system specifies a unit system and a a different length unit system is parsed, the number returned in length_value is always converted to the unit system specified by the length_value_unit_system parameter. If needed, you can inspect str_length_unit_system to determine if the length unit system scaling was applied.
Returns: Number of elements of str that were parsed. A return value of 0 indicates that str could not be parsed as a length value.
ON_DECL int ON_ParseLengthExpression | ( | const wchar_t * | str, |
int | str_count, | ||
ON_ParseSettings | parse_settings, | ||
ON::LengthUnitSystem | length_value_unit_system, | ||
double * | length_value, | ||
ON_ParseSettings * | parse_results, | ||
ON::LengthUnitSystem * | str_length_unit_system | ||
) |
ON_DECL int ON_ParseLengthUnitName | ( | const wchar_t * | str, |
int | str_count, | ||
int | prefered_locale_id, | ||
ON::LengthUnitSystem * | length_unit_system | ||
) |
Description: Parses str if it is a recognized length unit system name or abbreviation.
Parameters: str - [in]
str_count - [in] str[] and str_count specify the string to parse. If str_count >= 0. it specifies the maximum number of elements in str[] that may be parsed. If str_count = -1, then the string must contain a character that terminates unit system name parsing. This character can be a null, digit, punctuation, arithmetic operator, or a unicode code point <= 0x0020 (0x0020 = space = 32 decimal).
prefered_locale_id - [in] If the parsed length unit name identifies different length unit systems in different locales, then this value is used to resolve the ambiguity. A list of Microsoft locale id values can be found at http://msdn.microsoft.com/en-us/library/ms912047(v=winembedded.10).
bParseLeadingWhitespace - [in] If true, leading white space will be parsed. If false, the unit name must begin with element str[0].
length_unit_system - [out] (can be null) If length_unit_system is not null, it is set to identify the unit system specified by str. If str does not identify a known unit system, then *length_unit_system is set to ON::LengthUnitSystem::None.
Returns: Number of elements of str that were parsed. A return value of 0 indicates that str did not match know unit system names or abbreviations.
Remarks: Currently common names and abbreviations for millimeters, centimeters, meters and kilometers are supported in Czech (cs-*), English (en-*), French (fr-*), German (de-*), Portuguese (pt-*) and Spanish (es-*).
Common names and abbreviations for the following United States customary length units are supported in United States English (en-US). If the first element of str is quotation mark (double quote), unicode code point 0x0022, the string is parsed as United States customary inch. If the first element of str is apostrophe, unicode code point 0x0027, the string is parsed as United States customary foot. All conversions to meters are exact. microinch = 2.54e-8 meters (1.0e-6 inches) mil = 2.54e-5 meters (0.001 inches) inch = 0.0254 meters (1/12 foot) foot = 0.3048 meters (12 inches) yard = 0.9144 meters (36 inches) mile = 1609.344 meters (5280 feet) (US statue or land mile)
ON_DECL int ON_ParseLengthUnitName | ( | const wchar_t * | str, |
int | str_count, | ||
ON_ParseSettings | parse_settings, | ||
ON::LengthUnitSystem * | length_unit_system | ||
) |
ON_DECL int ON_ParseNumber | ( | const wchar_t * | str, |
int | str_count, | ||
ON_ParseSettings | parse_settings, | ||
ON_ParseSettings * | parse_results, | ||
double * | value | ||
) |
Description: Parses str to determine if it specifies a number.
Parameters: str - [in]
str_count - [in] str[] and str_count specify the string to parse. If str_count >= 0. it specifies the maximum number of elements in str[] that may be parsed. If str_count = -1, then the string must contain a character that terminates number parsing. This character can be a null, arithmetic operator, or a unicode code point <= 0x0020 (0x0020 = space = 32 decimal).
parse_settings - [in] The value of parse_settings controls what input may be parsed. Use one of the predefined ON_ParseSettings::DefaultSettings ON_ParseSettings::IntegerNumberSettings ON_ParseSettings::RationalNumberSettings ON_ParseSettings::RealNumberSettings for common parsing tasks.
parse_results - [out] The value of parse_results reports what was parsed.
value - [out] The value of the parsed number.
Returns: Number of elements of str[] that were parsed. A return value of 0 indicates that str[] could not be parsed as a number.
See Also: ON_ParseNumberExpression ON_ParseLengthExpression ON_ParseAngleExpression
ON_DECL int ON_ParseNumberExpression | ( | const wchar_t * | str, |
int | str_count, | ||
ON_ParseSettings | parse_settings, | ||
ON_ParseSettings * | parse_results, | ||
double * | value | ||
) |
Description: Parses str to determine if it specifies a number. Expression parsing includes support for parsing in-line multiplication, in-line division, automatic multiplication by pi, and formula parsing.
Parameters: str - [in]
str_count - [in] str[] and str_count specify the string to parse. If str_count >= 0. it specifies the maximum number of elements in str[] that may be parsed. If str_count = -1, then the string must contain a character that terminates number parsing. This character can be a null, arithmetic operator, or a unicode code point <= 0x0020 (0x0020 = space = 32 decimal).
parse_settings - [in] The value of parse_settings controls what input may be parsed. Use one of the predefined ON_ParseSettings::DefaultSettings ON_ParseSettings::IntegerNumberSettings ON_ParseSettings::RationalNumberSettings ON_ParseSettings::RealNumberSettings for common parsing tasks.
parse_results - [out] The value of parse_results reports what was parsed.
value - [out] The value of the parsed number.
Returns: Number of elements of str[] that were parsed. A return value of 0 indicates that str[] could not be parsed as a number.
See Also: ON_ParseNumber ON_ParseLengthExpression ON_ParseAngleExpression
ON_DECL int ON_ParsePointExpression | ( | const wchar_t * | str, |
int | str_count, | ||
ON::AngleUnitSystem | default_str_angle_unit_system, | ||
const ON_UnitSystem & | point_value_unit_system, | ||
ON_3dPoint * | point_value | ||
) |
ON_DECL int ON_ParsePointExpression | ( | const wchar_t * | str, |
int | str_count, | ||
ON::AngleUnitSystem | default_str_angle_unit_system, | ||
ON::LengthUnitSystem | point_value_unit_system, | ||
ON_3dPoint * | point_value | ||
) |
Description: Parses str to determine if it specifies a point value.
Parameters: str - [in]
str_count - [in] str[] and str_count specify the string to parse. If str_count >= 0. it specifies the maximum number of elements in str[] that may be parsed. If str_count = -1, then the string must contain a character that terminates length parsing.
default_str_angle_unit_system - [in] If an angle unit system is not specified in the parsed string, then default_str_angle_units determines what unit system will be used. If default_str_angle_units is ON::AngleUnitSystem::None, then ON::radians will be used.
parse_settings - [in] The input parse_settings parameter controls what input may be parsed and how it is parsed. Use ON_ParseSettings::DefaultSettings for common parsing tasks.
point_value_unit_system - [in] Coordinate unit system for the returned point value.
For example, if you want the returned point coordinates to be in meters, you would specify ON::LengthUnitSystem::Meters here. If you want to use custom units, you must use the override with the ON_UnitSystem parameter.
point_value - [out] The value of the parsed point.
parse_results - [out] (input pointer can be null) The output parse_results parameter reports what was parsed.
Returns: Number of elements of str that were parsed. A return value of 0 indicates that str could not be parsed as a length value.
ON_DECL int ON_ParsePointExpression | ( | const wchar_t * | str, |
int | str_count, | ||
ON_ParseSettings | parse_settings, | ||
const ON_UnitSystem & | point_value_unit_system, | ||
ON_3dPoint * | point_value, | ||
ON_ParseSettings * | parse_results | ||
) |
ON_DECL int ON_ParsePointExpression | ( | const wchar_t * | str, |
int | str_count, | ||
ON_ParseSettings | parse_settings, | ||
ON::LengthUnitSystem | point_value_unit_system, | ||
ON_3dPoint * | point_value, | ||
ON_ParseSettings * | parse_results | ||
) |
Description: Parses a string like "85a08515-f383-11d3-bfe7-0010830122f0" and returns the value as a uuid. Hyphens can appear anywhere and are ignored. Parsing stops at any character that is not a hexadecimal digit or hyphen. Parsing stops after 32 hexadecimal digits are read; Parameters: sUuid - [in] uuid - [out] Returns: null Parsing failed and uuid is set to ON_nil_uuid. non null Parsing succeeded and uuid is set to the parsed value. The returned pointer is the character in sUUID immediately after the last parsed character.
ON_DECL bool ON_PassesNanTest | ( | ) |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org. Returns: True (1) if nan compares and arithmetic agree with IEEE-754. (nan != nan) is true. (nan op x) and (x op nan) is false for op ==, <, >, <=, and >=. (nan op x) and (x op nan) is nan for op == +, -, *, and /. False (0) otherwise.
ON_DECL ON_BoundingBox ON_PointGridBoundingBox | ( | int | dim, |
bool | is_rat, | ||
int | point_count0, | ||
int | point_count1, | ||
int | point_stride0, | ||
int | point_stride1, | ||
const double * | point_grid | ||
) |
ON_DECL ON_BoundingBox ON_PointListBoundingBox | ( | int | dim, |
bool | is_rat, | ||
int | count, | ||
int | stride, | ||
const double * | point_list | ||
) |
ON_DECL ON_BoundingBox ON_PointListBoundingBox | ( | int | dim, |
bool | is_rat, | ||
int | count, | ||
int | stride, | ||
const float * | point_list | ||
) |
dim | low level workhorse function |
ON_DECL bool ON_PointsAreCoincident | ( | const ON_3dPoint & | , |
const ON_3dPoint & | |||
) |
ON_DECL bool ON_PointsAreCoincident | ( | int | dim, |
bool | is_rat, | ||
const double * | pointA, | ||
const double * | pointB | ||
) |
Parameters: dim - [in] >= 1 is_rat - [in] true if the points are rational and points[dim] is the "weight" pointA - [in] pointB - [in] point coordinates Returns: True if the input is valid and for each coordinate pair, |a-b| <= ON_ZERO_TOLERANCE or |a-b| <= (fabs(a)+fabs(b))*ON_RELATIVE_TOLERANCE. False otherwise.
ON_DECL bool ON_PointsAreCoincident | ( | int | dim, |
bool | is_rat, | ||
int | point_count, | ||
int | point_stride, | ||
const double * | points | ||
) |
Description See ON_PointsAreCoincident() for a description of when opennurbs considers two points to be coincident. Parameters: dim - [in] >= 1 is_rat - [in] true if the points are rational and points[dim] is the "weight" point_count - [in] number of points >= 2 point_stride - [in] >= (0 != is_rat) ? (dim+1) : dim points - [in] point coordinates Returns: True if the first and last points are coincident and all other points in the list are coincident with the previous point. False if there are points that are not coincident or point_count < 2 or other input parameters are invalid.
const ON_DECL wchar_t* ON_PostEffectTypeString | ( | ON_PostEffect::Types | type | ) |
Helper function to get the type of a post effect as a string.
ON_DECL bool ON_Pullback3dVector | ( | const ON_3dVector & | , |
double | , | ||
const ON_3dVector & | , | ||
const ON_3dVector & | , | ||
const ON_3dVector & | , | ||
const ON_3dVector & | , | ||
const ON_3dVector & | , | ||
ON_2dVector & | |||
) |
ON_DECL void ON_qsort | ( | void * | base, |
size_t | count, | ||
size_t | sizeof_element, | ||
int(*)(const void *, const void *) | compare | ||
) |
ON_DECL void ON_qsort | ( | void * | base, |
size_t | count, | ||
size_t | sizeof_element, | ||
int(*)(void *, const void *, const void *) | compare, | ||
void * | context | ||
) |
|
static |
Note: in assertions below, i and j are always inside original bound of array to sort.
A[i] <= A[j] for i <= j, j > hi
A[i] <= A[max] for lo <= i < p
A[i] <= A[max] for lo <= i <= p
A[i] <= A[max] for lo <= i <= hi
A[i] <= A[hi] for i <= hi, so A[i] <= A[j] for i <= j, j >= hi
A[i] <= A[j] for i <= j, j > hi, loop top condition established
A[i] <= A[j] for i <= j, j > lo, which implies A[i] <= A[j] for i < j, so array is sorted
void ON_quacksort | ( | BASETYPE * | base, |
size_t | nel, | ||
size_t | width, | ||
int(*)(const void *, const void *) | compar | ||
) |
implementation of quick sort with minimum swaps for partition sizes 4 and less
#if defined(ON_SORT_TEMPLATE_TYPE) && !defined(ON_SORT_TEMPLATE_USE_SWAP) ON_SORT_TEMPLATE_TYPE m_tmp; endif
When width is a multiple of 8 or 4 (with most arrays it probably is), use faster integer swappers instead of byte swapper
Uses local quick and dirty pseudorandom number generator to give a fuzzy answer to avoid having the data be arranged in a way that mechanically always picking the pivot the same way affects the speed. Mostly affects chevron etc. patterns.
Totally random pivot would guarantee O(nlogn) worst case, but does not perform as well on sorted or nearly sorted sets.
< 1/2
< +1/8
< -1/16
< -1/32
use minimum compares and swaps for 2 to 4 items
partition range
move pivot to left end
move =< pivot to left, and > pivot to right
find next first item > pivot
find next last item =< pivot
< to quickly exit a nested loop
move pivot to final place
avoid overhead when not likely that there are multiple items == pivot
the whole range is less or equal than pivot check if there are values == pivot left of it. Speeds up sorting arrays with all or lots of equal items.
limit max recursion depth to log(nel) by only recursing shorter part
lower part is shorter
upper part is shorter
ON_DECL ON_Quaternion ON_QuaternionProduct | ( | const ON_Quaternion & | p, |
const ON_Quaternion & | q | ||
) |
Returns: The quaternion product of p and q. This is the same value as p*q.
ON_DECL double ON_RadiansFromDegrees | ( | double | angle_in_degrees | ) |
Parameters: angle_in_degrees - [in] Angle measure in degrees Returns: Angle measure in radians
ON__UINT32 on_rand | ( | void | ) |
Description: Get a random number. Returns: A random number. Remarks: on_rand() is not thread safe. It used static global memory that is modified by on_srand() and on_rand().
ON__UINT32 on_random_number | ( | struct ON_RANDOM_NUMBER_CONTEXT * | rand_context | ) |
Description: Get a random number. Parameters: rand_context - [in/out] random number context. The first time rand_context is used it must be either initialized by calling on_random_number_seed() or rand_context->mti must be set to 0xFFFFFFFF. Otherwise do not modify randcontext between calls to on_random_number. Returns: A random number. Remarks: on_random_number() does not use any static memory. Example: ON_RAND_CONTEXT rand_context;
ON__UINT seed = 123; on_random_number_seed( seed, &rand_context );
ON__UINT32 r1 = on_random_number( &rand_context ); ON__UINT32 r2 = on_random_number( &rand_context ); ON__UINT32 r3 = on_random_number( &rand_context );
void on_random_number_seed | ( | ON__UINT32 | s, |
struct ON_RANDOM_NUMBER_CONTEXT * | rand_context | ||
) |
Description: Seed a context for on_random_number(). Parameters: s - [in] rand_context - [out] context to seed.
Remarks: on_random_number_seed() does not use any static memory. Example: ON_RAND_CONTEXT rand_context;
ON__UINT seed = 123; on_random_number_seed( seed, &rand_context );
ON__UINT32 r1 = on_random_number( &rand_context ); ON__UINT32 r2 = on_random_number( &rand_context ); ON__UINT32 r3 = on_random_number( &rand_context );
ON_DECL void ON_VARGS_FUNC_CDECL ON_REMOVE_ASAP_AssertEx | ( | int | , |
const char * | file_name, | ||
int | line_number, | ||
const char * | function_name, | ||
const char * | format, | ||
... | |||
) |
Ideally - these "assert" functions will be deleted when the SDK can be changed.
ON_DECL bool ON_RemoveBezierSingAt0 | ( | int | , |
int | , | ||
int | , | ||
double * | |||
) |
ON_DECL bool ON_RemoveBezierSingAt1 | ( | int | , |
int | , | ||
int | , | ||
double * | |||
) |
const ON_DECL ON_wString ON_RemoveIdPrefixFromString | ( | const ON_UUID | id, |
const wchar_t * | separator, | ||
const wchar_t * | source | ||
) |
const ON_DECL ON_wString ON_RemoveIdSuffixFromString | ( | const wchar_t * | source, |
const wchar_t * | separator, | ||
const ON_UUID | id | ||
) |
ON_DECL bool ON_ReparameterizeRationalBezierCurve | ( | double | c, |
int | dim, | ||
int | order, | ||
int | cvstride, | ||
double * | cv | ||
) |
Description: Reparameterize a rational Bezier curve. Parameters: c - [in] reparameterization constant (generally speaking, c should be > 0). The control points are adjusted so that output_bezier(t) = input_bezier(lambda(t)), where lambda(t) = c*t/( (c-1)*t + 1 ). Note that lambda(0) = 0, lambda(1) = 1, lambda'(t) > 0, lambda'(0) = c and lambda'(1) = 1/c. dim - [in] order - [in] cvstride - [in] (>= dim+1) cv - [in/out] homogeneous rational control points Returns: The cv values are changed so that output_bezier(t) = input_bezier(lambda(t)).
ON_DECL bool ON_ReparameterizeRationalNurbsCurve | ( | double | c, |
int | dim, | ||
int | order, | ||
int | cv_count, | ||
int | cvstride, | ||
double * | cv, | ||
double * | knot | ||
) |
Description: Reparameterize a rational NURBS curve. Parameters: c - [in] reparameterization constant (generally speaking, c should be > 0). The control points and knots are adjusted so that output_nurbs(t) = input_nurbs(lambda(t)), where lambda(t) = c*t/( (c-1)*t + 1 ). Note that lambda(0) = 0, lambda(1) = 1, lambda'(t) > 0, lambda'(0) = c and lambda'(1) = 1/c. dim - [in] order - [in] cvstride - [in] (>=dim+1) cv - [in/out] homogeneous rational control points knot - [in/out] NURBS curve knots Returns: The cv values are changed so that output_bezier(t) = input_bezier(lambda(t)). See Also: ON_ChangeRationalNurbsCurveEndWeights
ON_DECL bool ON_ReverseKnotVector | ( | int | , |
int | , | ||
double * | |||
) |
ON_DECL bool ON_ReversePointGrid | ( | int | , |
bool | , | ||
int | , | ||
int | , | ||
int | , | ||
int | , | ||
double * | , | ||
int | |||
) |
ON_DECL bool ON_ReversePointList | ( | int | , |
bool | , | ||
int | , | ||
int | , | ||
double * | |||
) |
ON_DECL int ON_Round | ( | double | x | ) |
Do not call ON_Round() in any opennurbs code, tl code or any other code that does critical calculations or when there is any possibility that x is invalid or fabs(x)>2147483647. Use floor(x+0.5) instead.
ON_DECL int ON_RowReduce | ( | int | row_count, |
int | col_count, | ||
double | zero_pivot, | ||
double ** | A, | ||
double ** | B, | ||
double | pivots[2] | ||
) |
Description: Perform simple row reduction on a matrix. If A is square, positive definite, and really really nice, then the returned B is the inverse of A. If A is not positive definite and really really nice, then it is probably a waste of time to call this function. Parameters: row_count - [in] col_count - [in] zero_pivot - [in] absolute values <= zero_pivot are considered to be zero A - [in/out] A row_count X col_count matrix. Input is the matrix to be row reduced. The calculation destroys A, so output A is garbage. B - [out] A a row_count X row_count matrix. That records the row reduction. pivots - [out] minimum and maximum absolute values of pivots. Returns: Rank of A. If the returned value < min(row_count,col_count), then a zero pivot was encountered. If C = input value of A, then B*C = (I,*)
ON_DECL unsigned int ON_RowReduce | ( | unsigned int | row_count, |
unsigned | col_count, | ||
double | zero_pivot_tolerance, | ||
const double *const * | constA, | ||
bool | bInitializeB, | ||
bool | bInitializeColumnPermutation, | ||
double ** | A, | ||
double ** | B, | ||
unsigned int * | column_permutation, | ||
double | pivots[3] | ||
) |
Description: Calculate a row reduction matrix so that R*M = upper triangular matrixPerform simple row reduction on a matrix. If A is square, positive definite, and really really nice, then the returned B is the inverse of A. If A is not positive definite and really really nice, then it is probably a waste of time to call this function. Parameters: row_count - [in] col_count - [in] zero_pivot - [in] absolute values <= zero_pivot_tolerance are considered to be zero constA - [in] nullptr or a row_count x col_count matrix. bInitializeB - [in] If true, then B is set to the rox_count x row_count identity before the calculation begins. bInitializeColumnPermutation - [in] If true and nullptr != column_permutation, then column_permutation[] is initialized to (0, 1, ..., col_count-1) before the calculation begins. A - [in/out] A row_count X col_count matrix.
If constA is not null, then A can be null or is the workspace used to row reduce. If constA is null, then the input A must not be null and must be initialized. In all cases, the calculation destroys the contents of A and output A contains garbage. B - [in/out] A a row_count X row_count matrix The row operations applied to A are also applied to B.
If the input B is the identity, then R*(input A) would have zeros below the diagonal. column_permutation - [in/out] The permutation applied to the columns of A is also applied to the column_permutation[] array. pivots - [out] pivots[0] = maximum nonzero pivot pivots[1] = minimum nonzero pivot pivots[2] = largest pivot that was treated as zero Returns: Rank of A. If the returned value < min(row_count,col_count), then a zero pivot was encountered. If C = input value of A, then B*C = (I,*)
ON_DECL bool ON_RunXMLTests | ( | const wchar_t * | test_folder | ) |
const ON_DECL ON_String ON_SdkVersionNumberToString | ( | unsigned int | sdk_version_number, |
unsigned int | sdk_service_release_number | ||
) |
const ON_DECL ON_wString ON_SdkVersionNumberToWideString | ( | unsigned int | sdk_version_number, |
unsigned int | sdk_service_release_number | ||
) |
ON_DECL int ON_SearchMonotoneArray | ( | const double * | , |
int | , | ||
double | |||
) |
ON_DECL ON__UINT64 ON_SecondsSinceJanOne1970UTC | ( | ) |
ON_DECL void ON_SendLogMessageToCloud | ( | ON_LogMessageType | msg_type, |
const wchar_t * | wszClass, | ||
const wchar_t * | wszEventDesc, | ||
const wchar_t * | wszMessage | ||
) |
void ON_SetBinaryArchiveOpenNURBSVersion | ( | class ON_BinaryArchive & | , |
unsigned int | |||
) |
Used int ON_3dmProperties::Read() to set ON_BinaryArchive.m_3dm_opennurbs_version Do not call directly.
ON_DECL bool ON_SetCurveCurveIntersectionDir | ( | ON_3dVector | N, |
int | xcount, | ||
ON_X_EVENT * | xevent, | ||
double | a0, | ||
double | a1, | ||
double | b0, | ||
double | b1 | ||
) |
Description: Sets ON_X_EVENT m_dirA[] and m_dirB[] flags for in intersection of coplanar curves. For each m_dirA[]/m_dirB[] flag that is set to ON_X_EVENT, the curve geometry at the intersection is examined to set the flags. Parameters: N [in] normal to the plane xcount - [in] number of intersection events xevent - [in] array of xcount intersection events a0 - [in] a1 - [in] (a0,a1) = curveA intersection domain b0 - [in] b1 - [in] (b0,b1) = curveB intersection domain See Also: ON_Curve::IntersectCurve ON_SetCurveSurfaceIntersectionDir
ON_DECL bool ON_SetCurveSurfaceIntersectionDir | ( | int | xcount, |
ON_X_EVENT * | xevent, | ||
double | t0, | ||
double | t1, | ||
double | u0, | ||
double | u1, | ||
double | v0, | ||
double | v1 | ||
) |
Description: Sets ON_X_EVENT m_dirA[] and m_dirB[] flags for a curve surface intersection. For each m_dirA[]/m_dirB[] flag that is set to ON_X_EVENT, the curve and surface geometry at the intersection is examined to set the flags. Parameters: xcount - [in] number of intersection events xevent - [in] array of xcount intersection events t0 - [in] t1 - [in] (t0,t1) = curveA intersection domain u0 - [in] u1 - [in] (u0,u1) = surfaceB u intersection domain v0 - [in] v1 - [in] (v0,v1) = surfaceB v intersection domain Returns: << TODO: Add return codes here >> See Also: ON_Curve::IntersectSurface ON_SetCurveCurveIntersectionDir
ON_DECL bool ON_SetCVFromDerivative | ( | int | end, |
int | d, | ||
const double * | D, | ||
ON_BezierCurve & | bezier_curve | ||
) |
Description: Given the first (d-1) CVs and a value for the d-th derivative, this sets the d-th CV. If bezier_curve is rational, then all the weights must be set. The weights are not changed. Parameters: end - [in] 0 start of curve (first d-1 CVs are input and the) 1 end of curve (last d-1 CVs are set) d - [in] derivative to set (>=0 and < bezier_curve.m_order) D - [in] Value of the d-th derivative. (D[] has length bezier_curve.m_dim.) bezier_curve - [in/out] If bezier_curve is rational, all the weights must be set and the weights are not changed. When end=0, the input curve must have the first d-1 CVs set and the output curve will have the d-th CV set so that the d-th derivative at 0.0 is D. When end=1, the input curve must have the lastt d-1 CVs set and the output curve will have the (order-1-d)-th CV set so that the d-th derivative at 1.0 is D. Returns: True if successful.
ON_DECL void ON_SetDebugWriteObjectDirectory | ( | const wchar_t * | directory_name | ) |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org. Description: Set the directory where ON_DebugWriteObject() will write the .3dm file. Parameters: directory_name - [in] Remarks: This function is not thread safe. It stores directory_name in a static array.
ON_DECL bool ON_SetKnotVectorDomain | ( | int | order, |
int | cv_count, | ||
double * | knot, | ||
double | t0, | ||
double | t1 | ||
) |
Description: Set the domain of a knot vector. Parameters: order - [in] order >= 2 cv_count - [in] cv_count >= order knot - [in/out] input existing knots and returns knots with new domain. t0 - [in] t1 - [in] New domain will be the interval (t0,t1). Returns: True if input is valid and the returned knot vector has the requested domain. False if the input is invalid, in which case the input knot vector is not changed.
ON_DECL void ON_SetSendLogMessageToCloudProc | ( | ON_SSLMTC_PROC | ) |
ON_DECL ON__UINT64 ON_SetWorkerThreadContext | ( | void(*)(ON__UINT_PTR) | fTerminateThreadFunction, |
ON__UINT_PTR | function_parameter | ||
) |
Description: Set the worker thread context. ON_SetWorkerThreadContext() is used to register the callback function that will be called during every memory allocation event. In order for this function to be called, you must call ON_WorkerThreadEnableTerminateRequest() after calling ON_SetWorkerThreadContext(). Parameters: m_platform_thread_id - [in] Cannot be zero. fTerminateThreadFunction - [in] Function to call to terminate thread. Cannot be null function_parameter - [in] fTerminateThreadFunction() parameter value Returns: 0: A context is already set, or the input parameter is null. >0: Serial number of the new context.
void ON_SHA1_Accumulate2dPointArray | ( | class ON_SHA1 & | sha1, |
const class ON_SimpleArray< ON_2dPoint > & | a | ||
) |
void ON_SHA1_Accumulate2dVectorArray | ( | class ON_SHA1 & | sha1, |
const class ON_SimpleArray< ON_2dVector > & | a | ||
) |
void ON_SHA1_Accumulate2fPointArray | ( | class ON_SHA1 & | sha1, |
const class ON_SimpleArray< ON_2fPoint > & | a | ||
) |
void ON_SHA1_Accumulate2fVectorArray | ( | class ON_SHA1 & | sha1, |
const class ON_SimpleArray< ON_2fVector > & | a | ||
) |
void ON_SHA1_Accumulate3dPointArray | ( | class ON_SHA1 & | sha1, |
const class ON_SimpleArray< ON_3dPoint > & | a | ||
) |
void ON_SHA1_Accumulate3dVectorArray | ( | class ON_SHA1 & | sha1, |
const class ON_SimpleArray< ON_3dVector > & | a | ||
) |
void ON_SHA1_Accumulate3fPointArray | ( | class ON_SHA1 & | sha1, |
const class ON_SimpleArray< ON_3fPoint > & | a | ||
) |
void ON_SHA1_Accumulate3fVectorArray | ( | class ON_SHA1 & | sha1, |
const class ON_SimpleArray< ON_3fVector > & | a | ||
) |
void ON_SHA1_Accumulate4dPointArray | ( | class ON_SHA1 & | sha1, |
const class ON_SimpleArray< ON_4dPoint > & | a | ||
) |
void ON_SHA1_Accumulate4fPointArray | ( | class ON_SHA1 & | sha1, |
const class ON_SimpleArray< ON_4fPoint > & | a | ||
) |
ON_DECL int ON_SimpleQuadraticMinimize | ( | int(*)(void *, double, double *) | f, |
void * | f_arg, | ||
double | ax, | ||
double | bx, | ||
double | cx, | ||
double | desired_min, | ||
double | stop_tol, | ||
int | max_it, | ||
double * | t_addr = 0 , |
||
double * | min_f = 0 |
||
) |
Find a local minimum of a one parameter function using a quadratic approximation algorithm. This algorithm does not use derivative information.
INPUT: ax, bx, cx a bracketed minimum satisfying conditions 1 and 2. 1) ax < bx < cx. 2) f(bx) < f(ax) and f(bx) < f(cx). farg pointer passed to function f() f evaluation function with prototype int f(void* farg,double t,double* ft) f(farg,t,&ft) should compute ft = value of function at t -1: failure 0: success 1: |f(x)| is small enough - will return *t_addr = x and the return code 1. desired_min - once a function value this small is found, stop. stop_tol - once it is determined that a min exists in an interval of this size, stop max_it ( >= 2) maximum number of iterations to permit (when in doubt use 100)
OUTPUT: *t_addr abcissa of a local minimum between ax and cx. ON_SimpleQuadraticMinimize() 0: successful 1: The search for a minimum was stopped because the function f() returned a 1 indicating that the current value of t was small enough. 2: After max_iteration_cnt iterations the tolerance restrictions where not satisfied. Try increasing max_it, or use the value of (*t_addr) with extreme caution. -1: failure
ON_DECL int ON_Solve2x2 | ( | double | , |
double | , | ||
double | , | ||
double | , | ||
double | , | ||
double | , | ||
double * | , | ||
double * | , | ||
double * | |||
) |
returns rank - if rank != 2, system is under determined If rank = 2, then solution to
a00*x0 + a01*x1 = b0, a10*x0 + a11*x1 = b1
is returned
ON_DECL int ON_Solve3x2 | ( | const double | [3], |
const double | [3], | ||
double | , | ||
double | , | ||
double | , | ||
double * | , | ||
double * | , | ||
double * | , | ||
double * | |||
) |
Description: Solves a system of 3 linear equations and 2 unknowns.
x*col0[0] + y*col1[0] = d0 x*col0[1] + y*col1[1] = d0 x*col0[2] + y*col1[2] = d0
Parameters: col0 - [in] coefficients for "x" unknown col1 - [in] coefficients for "y" unknown d0 - [in] constants d1 - [in] d2 - [in] x - [out] y - [out] error - [out] pivot_ratio - [out]
Returns: rank of the system.
If rank != 2, system is under determined If rank = 2, then the solution is
(*x)*[col0] + (*y)*[col1] + (*error)*((col0 X col1)/|col0 X col1|) = (d0,d1,d2).
ON_DECL int ON_Solve3x3 | ( | const double | row0[3], |
const double | row1[3], | ||
const double | row2[3], | ||
double | d0, | ||
double | d1, | ||
double | d2, | ||
double * | x_addr, | ||
double * | y_addr, | ||
double * | z_addr, | ||
double * | pivot_ratio | ||
) |
Description: Use Gauss-Jordan elimination with full pivoting to solve a system of 3 linear equations and 3 unknowns(x,y,z)
x*row0[0] + y*row0[1] + z*row0[2] = d0 x*row1[0] + y*row1[1] + z*row1[2] = d1 x*row2[0] + y*row2[1] + z*row2[2] = d2
Parameters: row0 - [in] first row of 3x3 matrix row1 - [in] second row of 3x3 matrix row2 - [in] third row of 3x3 matrix d0 - [in] d1 - [in] d2 - [in] (d0,d1,d2) right hand column of system x_addr - [in] first unknown y_addr - [in] second unknown z_addr - [in] third unknown pivot_ratio - [out] if not nullptr, the pivot ration is returned here. If the pivot ratio is "small", then the matrix may be singular or ill conditioned. You should test the results before you use them. "Small" depends on the precision of the input coefficients and the use of the solution. If you can't figure out what "small" means in your case, then you must check the solution before you use it.
Returns: The rank of the 3x3 matrix (0,1,2, or 3) If ON_Solve3x3() is successful (returns 3), then the solution is returned in (*x_addr, *y_addr, *z_addr) and *pivot_ratio = min(|pivots|)/max(|pivots|). If the return code is < 3, then (0,0,0) is returned as the "solution".
See Also: ON_Solve2x2 ON_Solve3x2 ON_Solve4x4
ON_DECL int ON_Solve4x4 | ( | const double | row0[4], |
const double | row1[4], | ||
const double | row2[4], | ||
const double | row3[4], | ||
double | d0, | ||
double | d1, | ||
double | d2, | ||
double | d3, | ||
double * | x_addr, | ||
double * | y_addr, | ||
double * | z_addr, | ||
double * | w_addr, | ||
double * | pivot_ratio | ||
) |
Description: Use Gauss-Jordan elimination with full pivoting to solve a system of 4 linear equations and 4 unknowns(x,y,z,w)
x*row0[0] + y*row0[1] + z*row0[2] + w*row0[3] = d0 x*row1[0] + y*row1[1] + z*row1[2] + w*row1[3] = d1 x*row2[0] + y*row2[1] + z*row2[2] + w*row2[3] = d2 x*row3[0] + y*row3[1] + z*row3[2] + w*row3[2] = d3
Parameters: row0 - [in] first row of 4x4 matrix row1 - [in] second row of 4x4 matrix row2 - [in] third row of 4x4 matrix row3 - [in] forth row of 4x4 matrix d0 - [in] d1 - [in] d2 - [in] d3 - [in] (d0,d1,d2,d3) right hand column of system x_addr - [in] first unknown y_addr - [in] second unknown z_addr - [in] third unknown w_addr - [in] forth unknown pivot_ratio - [out] if not nullptr, the pivot ration is returned here. If the pivot ratio is "small", then the matrix may be singular or ill conditioned. You should test the results before you use them. "Small" depends on the precision of the input coefficients and the use of the solution. If you can't figure out what "small" means in your case, then you must check the solution before you use it.
Returns: The rank of the 4x4 matrix (0,1,2,3, or 4) If ON_Solve4x4() is successful (returns 4), then the solution is returned in (*x_addr, *y_addr, *z_addr, *w_addr) and *pivot_ratio = min(|pivots|)/max(|pivots|). If the return code is < 4, then, it a solution exists, on is returned. However YOU MUST CHECK THE SOLUTION IF THE RETURN CODE IS < 4.
See Also: ON_Solve2x2 ON_Solve3x2 ON_Solve3x3
ON_DECL int ON_SolveCubicEquation | ( | double | a, |
double | b, | ||
double | c, | ||
double | d, | ||
double * | r1, | ||
double * | r2, | ||
double * | r3 | ||
) |
Description: Solve the cubic equation a*X^3 + b*X^2 + c*X + d = 0. Inputs: a,b,c,d, polynomial coefficients ( if a==b==c== 0) then failure is returned Returns: number of real roots stored with multiplicity. specifically -1: failure (a == b == c== 0.0 case) 0: no real roots ( a==0 and b!=0) two complex conjugate roots (r1 +/- (r2)*sqrt(-1)) 1: one real root (r1). Either ( a==b==0.0) or else( a!=0) and two complex conjugate roots (r2 +/- (r3)*sqrt(-1)) 2: two real roots (a==0.0, b!=0.0) *r1 <= *r2 3: three real roots (a!=0.0) *r1 <= *r2 <= *r3
ON_DECL double ON_SolveNxN | ( | bool | bFullPivot, |
bool | bNormalize, | ||
int | n, | ||
double * | M[], | ||
double | B[], | ||
double | X[] | ||
) |
Description: Use Gauss-Jordan elimination to find a numerical solution to M*X = B where M is a n x n matrix, B is a known n-dimensional vector and X is an unknown. Parameters: bFullPivot - [in] if true, full pivoting is used, otherwise partial pivoting is used. In rare cases full pivoting can produce a more accurate answer and never produces a less accurate answer. However full pivoting is slower. If speed is an issue, then experiment with bFullPivot=false and see if it makes a difference. Otherwise, set it to true. bNormalize - [in] If bNormalize is true, then the rows of the matrix are scaled so the sum of their squares is one. This doesn't make the solution more accurate but in some cases it makes the pivot ratio more meaningful. Set bNormalize to false unless you have a reason for setting it to true. n - [in] size of the matrix and vectors. M - [in] n x n matrix. The values in M are changed as the solution is calculated. If you need to preserve M for future use, pass in a copy. B - [in] n-dimensional vector. The values in B are changed as the solution is calculated. If you need to preserve B for future use, pass in a copy. X - [out] solution to M*X = B. Returns: If the returned value is <= 0.0, the input matrix has rank < n and no solution is returned in X. If the returned value is > 0.0, then a solution is returned in X and the returned value is the ratio (minimum pivot)/(maximum pivot). This value is called the pivot ratio and will be denoted "pr" the discussion below. If pr <= 1e-15, then M was nearly degenerate and the solution should be used with caution. If an accurate solution is critical, then check the solution anytime pr <= 1e-10 In general, the difference between M*X and B will be reasonably small. However, when the pr is small there tend to be vector E, substantially different from zero, such that M*(X+E) - B is also reasonably small. See Also: ON_Solve2x2 ON_Solve3x3 ON_Solve4x4 ON_Solve3x2
ON_DECL int ON_SolveQuadraticEquation | ( | double | , |
double | , | ||
double | , | ||
double * | , | ||
double * | |||
) |
ON_DECL bool ON_SolveSVD | ( | int | row_count, |
int | col_count, | ||
double const *const * | U, | ||
const double * | invW, | ||
double const *const * | V, | ||
const double * | B, | ||
double *& | X | ||
) |
Description: Solve a linear system of equations using the singular value decomposition. Parameters: row_count - [in] number of rows in matrix U col_count - [in] number of columns in matrix U U - [in] row_count X col_count matrix. See the remarks section for the definition of U. invW - [in] inverted DVD diagonal. See the remarks section for the definition of invW. V - [in] col_count X col_count matrix. See the remarks section for the definition of V. B - [in] An array of row_count values. X - [out] The solution array of col_count values is returned here. If the input value of X is not null, it must point to an array of col_count doubles. If the input value of X is null, heap storage will be allocated using onmalloc() and the calling function must call onfree(X). Remarks: If A*X = B is an m X n system of equations (m = row_count, n = col_count) and A = U*Diag(W)*Transpose(V) is the singular value decomposition of A, then a solution is X = V*Diag(1/W)*Transpose(U). Example:
int m = row_count; int n = col_count; ON_Matrix A(m,n); for (i = 0; i < m; i++ ) for ( j = 0; j < n; j++ ) { A[i][j] = ...; } ON_SimpleArray<double> B(m); for (i = 0; i < m; i++ ) { B[i] = ...; } ON_SimpleArray<double> X; ///< solution returned here. { double** U = 0; double* W = 0; double** V = 0; if ( ON_GetMatrixSVD(m,n,A.m,U,W,V) ) { double* invW = 0; int rankW = ON_InvertSVDW(n,W,W); ///< save invW into W X.Reserve(n); if ( ON_SolveSVD(m,n,U,W,V,B,X.Array()) ) X.SetCount(n); } onfree(U); ///< U allocated in ON_GetMatrixSVD() onfree(W); ///< W allocated in ON_GetMatrixSVD() onfree(V); ///< V allocated in ON_GetMatrixSVD() } if ( n == X.Count() ) { ... use solution }
Returns: True if input is valid and X[] was calculated. False if input is not valid.
ON_DECL int ON_SolveTriDiagonal | ( | int | , |
int | , | ||
double * | , | ||
const double * | , | ||
double * | , | ||
const double * | , | ||
double * | |||
) |
Returns: 0: success <0: failure
ON_DECL void ON_Sort | ( | ON::sort_algorithm | method, |
int * | index, | ||
const void * | base, | ||
size_t | count, | ||
size_t | sizeof_element, | ||
int(*)(const void *, const void *) | compare | ||
) |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org. Description: Sort an index array. Parameters method - [in] ON::sort_algorithm::quick_sort (best in general) or ON::sort_algorithm::heap_sort. Use ON::sort_algorithm::heap_sort only after doing meaningful performance testing using optimized release builds that demonstrate ON::sort_algorithm::heap_sort is significantly better. index - [out] Pass in an array of count integers. The returned index[] is a permutation of (0,1,..,count-1) such that compare(B[index[i]],B[index[i+1]) <= 0 where B[i] = base + i*sizeof_element base - [in] array of count elements count - [in] number of elements in the index[] and base[] arrays sizeof_element - [in] number of bytes between consecutive elements in the base[] array. compare - [in] Comparison function a la qsort().
compare | int compar(const void*,const void*) |
ON_DECL void ON_Sort | ( | ON::sort_algorithm | method, |
int * | index, | ||
const void * | base, | ||
size_t | count, | ||
size_t | sizeof_element, | ||
int(*)(const void *, const void *, void *) | compare, | ||
void * | context | ||
) |
Description: Sort an index array using a compare function that takes an additional pointer that can be used to pass extra information. Parameters method - [in] ON::sort_algorithm::quick_sort (best in general) or ON::sort_algorithm::heap_sort. Use ON::sort_algorithm::heap_sort only after doing meaningful performance testing using optimized release builds that demonstrate ON::sort_algorithm::heap_sort is significantly better. index - [out] Pass in an array of count integers. The returned index[] is a permutation of (0,1,..,count-1) such that compare(B[index[i]],B[index[i+1]) <= 0 where B[i] = base + i*sizeof_element base - [in] array of count elements count - [in] number of elements in the index[] and base[] arrays sizeof_element - [in] number of bytes between consecutive elements in the base[] array. compare - [in] Comparison function a la qsort(). The context parameter is pass as the third argument. context - [in] pointer passed as the third argument to compare().
compare | int compar(const void* a,const void* b, void* ptr) |
ON_DECL void ON_Sort | ( | ON::sort_algorithm | method, |
unsigned int * | index, | ||
const void * | base, | ||
size_t | count, | ||
size_t | sizeof_element, | ||
int(*)(const void *, const void *) | compare | ||
) |
compare | int compar(const void*,const void*) |
ON_DECL void ON_Sort | ( | ON::sort_algorithm | method, |
unsigned int * | index, | ||
const void * | base, | ||
size_t | count, | ||
size_t | sizeof_element, | ||
int(*)(const void *, const void *, void *) | compare, | ||
void * | context | ||
) |
compare | int compar(const void* a,const void* b, void* ptr) |
ON_DECL bool ON_SortCurves | ( | const ON_SimpleArray< const ON_Curve * > & | curves, |
ON_SimpleArray< int > & | index, | ||
ON_SimpleArray< bool > & | bReverse | ||
) |
Description: Sort a list of curves so end of a curve matches the start of the next curve. Parameters: curve - [in] array of curves to sort. The curves themselves are not modified. index - [out] The input index[] is an array of curve_count unused integers. The returned index[] is a permutation of {0,1,...,curve_count-1} so that the list of curves is in end-to-end order. bReverse - [out] The input bReverse[] is an array of curve_count unused bools. If the returned value of bReverse[j] is true, then curve[index[j]] needs to be reversed. Returns: True if successful, false if not.
ON_DECL bool ON_SortCurves | ( | const ON_SimpleArray< ON_Curve * > & | curves, |
ON_SimpleArray< int > & | index, | ||
ON_SimpleArray< bool > & | bReverse | ||
) |
Description: Sort a list of curves so end of a curve matches the start of the next curve. Parameters: curve_count - [in] number of curves curve - [in] array of curve pointers index - [out] The input index[] is an array of curve_count unused integers. The returned index[] is a permutation of {0,1,...,curve_count-1} so that the list of curves is in end-to-end order. bReverse - [out] The input bReverse[] is an array of curve_count unused bools. If the returned value of bReverse[j] is true, then curve[index[j]] needs to be reversed. Returns: True if successful, false if not.
ON_DECL bool ON_SortCurves | ( | int | curve_count, |
const ON_Curve *const * | curve_list, | ||
int * | index, | ||
bool * | bReverse | ||
) |
Description: Sort a list of open curves so end of a curve matches the start of the next curve. Parameters: curve_count - [in] number of curves curve_list - [in] array of curve pointers index - [out] The input index[] is an array of curve_count unused integers. The returned index[] is a permutation of {0,1,...,curve_count-1} so that the list of curves is in end-to-end order. bReverse - [out] The input bReverse[] is an array of curve_count unused bools. If the returned value of bReverse[j] is true, then curve_list[index[j]] needs to be reversed. Returns: True if successful, false if not.
ON_DECL void ON_SortDoubleArray | ( | ON::sort_algorithm | sort_algorithm, |
double * | a, | ||
size_t | nel | ||
) |
Description: Sort an array of doubles in increasing order in place. Parameters: sort_algorithm - [in] ON::sort_algorithm::quick_sort (best in general) or ON::sort_algorithm::heap_sort Use ON::sort_algorithm::heap_sort only if you have done extensive testing with optimized release builds and are confident heap sort is significantly faster in your case. a - [in / out] The values in a[] are sorted so that a[i] <= a[i+1]. a[] cannot contain NaNs. nel - [in] length of array a[]
ON_DECL void ON_SortDoubleArrayDecreasing | ( | double * | a, |
size_t | nel | ||
) |
Description: Sort an array of doubles in increasing order in place. Parameters: a - [in / out] The values in a[] are sorted so that a[i] >= a[i+1]. a[] cannot contain NaNs. nel - [in] length of array a[]
ON_DECL void ON_SortDoubleArrayIncreasing | ( | double * | a, |
size_t | nel | ||
) |
Description: Sort an array of doubles in increasing order in place. Parameters: a - [in / out] The values in a[] are sorted so that a[i] <= a[i+1]. a[] cannot contain NaNs. nel - [in] length of array a[]
ON_DECL void ON_SortIntArray | ( | ON::sort_algorithm | sort_algorithm, |
int * | a, | ||
size_t | nel | ||
) |
Description: Sort an array of ints in place. Parameters: sort_algorithm - [in] ON::sort_algorithm::quick_sort (best in general) or ON::sort_algorithm::heap_sort Use ON::sort_algorithm::heap_sort only if you have done extensive testing with optimized release builds and are confident heap sort is significantly faster in your case. a - [in / out] The values in a[] are sorted so that a[i] <= a[i+1]. nel - [in] length of array a[]
ON_DECL bool ON_SortLines | ( | const ON_SimpleArray< ON_Line > & | line_list, |
int * | index, | ||
bool * | bReverse | ||
) |
Description: Sort a list of lines so they are geometrically continuous. Parameters: line_list - [in] array of lines index - [out] The input index[] is an array of line_count unused integers. The returned index[] is a permutation of {0,1,...,line_count-1} so that the list of lines is in end-to-end order. bReverse - [out] The input bReverse[] is an array of line_count unused bools. If the returned value of bReverse[j] is true, then line_list[index[j]] needs to be reversed. Returns: True if successful, false if not.
ON_DECL bool ON_SortLines | ( | int | line_count, |
const ON_Line * | line_list, | ||
int * | index, | ||
bool * | bReverse | ||
) |
Description: Sort a list of lines so they are geometrically continuous. Parameters: line_count - [in] number of lines line_list - [in] array of lines index - [out] The input index[] is an array of line_count unused integers. The returned index[] is a permutation of {0,1,...,line_count-1} so that the list of lines is in end-to-end order. bReverse - [out] The input bReverse[] is an array of line_count unused bools. If the returned value of bReverse[j] is true, then line_list[index[j]] needs to be reversed. Returns: True if successful, false if not.
ON_DECL void ON_SortStringArray | ( | ON::sort_algorithm | sort_algorithm, |
char ** | a, | ||
size_t | nel | ||
) |
Description: Sort an array of unsigned null terminated char strings in place. Parameters: sort_algorithm - [in] ON::sort_algorithm::quick_sort (best in general) or ON::sort_algorithm::heap_sort Use ON::sort_algorithm::heap_sort only if you have done extensive testing with optimized release builds and are confident heap sort is significantly faster in your case. a - [in / out] The values in a[] are sorted so that strcmp(a[i],a[i+1]) <= 0. nel - [in] length of array a[]
ON_DECL void ON_SortUINT64Array | ( | ON::sort_algorithm | sort_algorithm, |
ON__UINT64 * | a, | ||
size_t | nel | ||
) |
Description: Sort an array of unsigned 64-bit ints in place. Parameters: sort_algorithm - [in] ON::sort_algorithm::quick_sort (best in general) or ON::sort_algorithm::heap_sort Use ON::sort_algorithm::heap_sort only if you have done extensive testing with optimized release builds and are confident heap sort is significantly faster in your case. a - [in / out] The values in a[] are sorted so that a[i] <= a[i+1]. nel - [in] length of array a[]
ON_DECL void ON_SortUnsignedIntArray | ( | ON::sort_algorithm | sort_algorithm, |
unsigned int * | a, | ||
size_t | nel | ||
) |
Description: Sort an array of unsigned ints in place. Parameters: sort_algorithm - [in] ON::sort_algorithm::quick_sort (best in general) or ON::sort_algorithm::heap_sort Use ON::sort_algorithm::heap_sort only if you have done extensive testing with optimized release builds and are confident heap sort is significantly faster in your case. a - [in / out] The values in a[] are sorted so that a[i] <= a[i+1]. nel - [in] length of array a[]
ON_DECL double ON_SpanTolerance | ( | int | , |
int | , | ||
const double * | , | ||
int | |||
) |
ON_DECL void on_splitpath | ( | const char * | path, |
const char ** | volume, | ||
const char ** | dir, | ||
const char ** | fname, | ||
const char ** | ext | ||
) |
Description: Find the locations in a path the specify the drive, directory, file name and file extension. Parameters: path - [in] UTF-8 encoded string that is a legitimate path to a file. volume - [out] (pass null if you don't need the volume) If volume is not null and the path parameter begins with a Windows volum specification, the value of *volume will equal the input value of path. Otherwise *volume will be nullptr.
A Windows volume specification can be either a single A-Z or a-z letter followed by a colon ( C: ) or a Windows UNC host name (\MY_SERVER). dir - [out] (pass null if you don't need the directory) If dir is not null and the path parameter contains a directory specification, then the returned value of *dir will point to the character in path where the directory specification begins. fname - [out] (pass null if you don't need the file name) If fname is not null and the path parameter contains a file name specification, then the returned value of *fname will point to the character in path where the file name specification begins. ext - [out] (pass null if you don't need the extension) If ext is not null and the path parameter contains a file extension specification, then the returned value of ext will point to the '.' character in path where the file extension specification begins. Remarks: This function will treat a front slash ( / ) and a back slash ( \ ) as directory separators. Because this function parses file names store in .3dm files and the .3dm file may have been written on a Windows computer and then read on a another computer, it looks for a volume specification even when the operating system is not Windows. This function will not return an directory that does not end with a trailing slash. This function will not return an empty filename and a non-empty extension. This function parses the path string according to these rules. It does not check the actual file system to see if the answer is correct. See Also: ON_String::SplitPath
ON_DECL bool ON_SquishBack2dMarks | ( | const ON_Geometry * | squished_geometry, |
const ON_SimpleArray< const ON_Geometry * > * | marks, | ||
ON_SimpleArray< ON_Geometry * > * | squished_marks | ||
) |
Description: Maps geometry from a squished geometry back to the original mesh or surface. Parameters: squished_geometry - [in] the geometry resulting from a call to SquishMesh or SquishSurface 3d surface to flatten. squish_parameters - [in] parameters used to calculate the 2d result. squished_brep - [in] optional parameter that can be used to specify where the 2d result should be saved. marks - [in] a list of ON_Point, ON_TextDot, ON_PointCloud, and ON_Curve objects to be squished squishedback_marks - [out] The results of mapping the marks back to the 3d unsquished surface. A failure produces a null entry in the array. It is the responsibility of the caller to delete the geometry in squished_marks Returns: If successful, a flattened brep. Null if not successful.
ON_DECL ON_Mesh* ON_SquishMesh | ( | const ON_Mesh * | mesh, |
const ON_SquishParameters * | squish_parameters, | ||
const ON_SquishConstraints * | squish_constraints, | ||
const ON_SimpleArray< const ON_Geometry * > * | marks, | ||
ON_SimpleArray< ON_Geometry * > * | squished_marks, | ||
ON_Mesh * | squished_mesh | ||
) |
Description: Use to flatten a mesh. Parameters: mesh - [in] 3d mesh to flatten. squish_parameters - [in] parameters used to calculate the 2d result. squish_constraints - [in] UNUSED AT THIS TIME squished_mesh - [in] optional parameter that can be used to specify where the 2d result should be saved. marks - [in] a list of ON_Point, ON_TextDot, ON_PointCloud, and ON_Curve objects to be squished squished_marks - [out] The results of ma;pping the marks back to the 3d unsquished surface. A failure produces a null entry in the array. It is the responsibility of the caller to delete the geometry in squished_marks squished_mesh - [in] optional parameter that can be used to specify where the 2d result should be saved. Returns: If successful, a flattened mesh. Null if not successful.
ON_DECL ON_Mesh* ON_SquishMesh | ( | const ON_Mesh * | mesh, |
const ON_SquishParameters * | squish_parameters, | ||
const ON_SquishConstraints * | squish_constraints, | ||
ON_Mesh * | squished_mesh | ||
) |
Description: Use to flatten a mesh. Parameters: mesh - [in] 3d mesh to flatten. squish_parameters - [in] parameters used to calculate the 2d result. squish_constraints - [in] UNUSED AT THIS TIME squished_mesh - [in] optional parameter that can be used to specify where the 2d result should be saved. Returns: If successful, a flattened mesh. Null if not successful.
ON_DECL ON_Brep* ON_SquishSurface | ( | const ON_Surface * | surface, |
const ON_SquishParameters * | squish_parameters, | ||
const ON_SimpleArray< const ON_Geometry * > * | marks, | ||
ON_SimpleArray< ON_Geometry * > * | squished_marks, | ||
ON_Brep * | squished_brep | ||
) |
Description: Use to flatten a mesh. Parameters: surface - [in] 3d surface to flatten. squish_parameters - [in] parameters used to calculate the 2d result. squished_brep - [in] optional parameter that can be used to specify where the 2d result should be saved. marks - [in] a list of ON_Point, ON_TextDot, ON_PointCloud, and ON_Curve objects to be squished squished_marks - [out] The results of ma;pping the marks back to the 3d unsquished surface. A failure produces a null entry in the array. It is the responsibility of the caller to delete the geometry in squished_marks Returns: If successful, a flattened brep. Null if not successful.
ON_DECL ON_Brep* ON_SquishSurface | ( | const ON_Surface * | surface, |
const ON_SquishParameters * | squish_parameters, | ||
ON_Brep * | squished_brep | ||
) |
Description: Use to flatten a mesh. Parameters: surface - [in] 3d surface to flatten. squish_parameters - [in] parameters used to calculate the 2d result. squished_brep - [in] optional parameter that can be used to specify where the 2d result should be saved. Returns: If successful, a flattened brep. Null if not successful.
void on_srand | ( | ON__UINT32 | s | ) |
Description: Seed the random number generator used by on_rand(). Parameters: s - [in] Remarks: on_srand() is not thread safe. It used static global memory that is modified by on_srand() and on_rand().
ON_STATIC_ASSERT | ( | sizeof(ON__INT16) | = =2 | ) |
ON_STATIC_ASSERT | ( | sizeof(ON__INT32) | = =4 | ) |
ON_STATIC_ASSERT | ( | sizeof(ON__INT64) | = =8 | ) |
ON_STATIC_ASSERT | ( | sizeof(ON__INT8) | = =1 | ) |
ON_STATIC_ASSERT | ( | sizeof(ON__UINT16) | = =2 | ) |
ON_STATIC_ASSERT | ( | sizeof(ON__UINT32) | = =4 | ) |
ON_STATIC_ASSERT | ( | sizeof(ON__UINT64) | = =8 | ) |
ON_STATIC_ASSERT | ( | sizeof(ON__UINT8) | = =1 | ) |
ON_STATIC_ASSERT_MSG | ( | ON_SIZEOF_POINTER | = =sizeof(void *) , |
"ON_SIZEOF_POINTER must be equal to sizeof(void*)" | |||
) |
ON_STATIC_ASSERT_MSG | ( | sizeof(ON__INT_PTR) | = =sizeof(void *) | ) |
ON_STATIC_ASSERT_MSG | ( | sizeof(ON__UINT_PTR) | = =sizeof(void *) | ) |
ON_DECL std::string ON_VARGS_FUNC_CDECL ON_std_string_format | ( | const char * | format, |
... | |||
) |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org. When the predecessor of opennurbs was released in 1995, there was no robust corss platform support for dynamic string classes. In order to provide robust dynamic string support, openNURBS had to implement ON_String and ON_wString.
It's now 2013 and current C++ compilers from the GNU Project (gcc 4.7), Microsoft (Visual C++ 11 (2012)), Google (Android NDK r8e) and Apple (LLVM 4.2) provide reasonable support for much of the C++11 standard and provide working implementations std::basic_string, std:string and std::wstring classes.
Over time, opennurbs will transition from using ON_String and ON_wString to using std::string and std::wstring.
The tools in the opennurbs_std_string*.* files provide support for string formatting and UTF conversion that are not available from the standard C++ string classes.
These implementations assume the compiler has solid support for std:basic_string, std::string, std::wstring, std::u16string, std::u32string and for using rvalue references to efficient return dynamic strings.
ON_DECL std::wstring ON_VARGS_FUNC_CDECL ON_std_wstring_format | ( | const wchar_t * | format, |
... | |||
) |
ON_DECL int on_stricmp | ( | const char * | , |
const char * | |||
) |
on_stricmp() is a wrapper for case insensitive string compare and calls one of _stricmp(), stricmp(), or strcasecmp() depending on OS.
ON_DECL int ON_StringCompareOrdinalUTF16 | ( | const ON__UINT16 * | string1, |
int | element_count1, | ||
const ON__UINT16 * | string2, | ||
int | element_count2, | ||
bool | bOrdinalIgnoreCase | ||
) |
Description: Compare of UTF-16 encoded ON__UINT16 strings element by element. Parameters: string1 - [in] element_count1 - [in] If element_count1 < 0, then string1 must be null terminated and element_count1 will be set to the length of string1. If element_count1 >= 0, then that number of elements are compared in string1[]. string2 - [in] element_count2 - [in] If element_count2 < 0, then string2 must be null terminated and element_count2 will be set to the length of string2. If element_count2 >= 0, then that number of elements are compared in string2[]. bOrdinalIgnoreCase - [in] If bOrdinalIgnoreCase, then letters with a capital and small codepoint value <= 127 are compared using the smallest codepoint value. This amounts to converting the letters a-z to A-Z before comparing. Returns: 0: the strings are the same <0: string1 < string2 >0: string1 > string2 Remarks: 1) If linguistic issues are important, then this function is not appropriate. 2) nullptr values are handled. 3) There are lists of Unicode code point values such that the results of ON_StringCompareOrdinalUTF8, ON_StringCompareOrdinalUTF16 and ON_StringCompareOrdinalUTF32 are different when applied to UTF-8, UTF-16 and UTF-32 encodings. 4) This function does not compare Unicode code point values if the strings have any surrogate pairs.
ON_DECL int ON_StringCompareOrdinalUTF32 | ( | const ON__UINT32 * | string1, |
int | element_count1, | ||
const ON__UINT32 * | string2, | ||
int | element_count2, | ||
bool | bOrdinalIgnoreCase | ||
) |
Description: Compare of UTF-32 encoded ON__UINT32 strings element by element. Parameters: string1 - [in] element_count1 - [in] If element_count1 < 0, then string1 must be null terminated and element_count1 will be set to the length of string1. If element_count1 >= 0, then that number of elements are compared in string1[]. string2 - [in] element_count2 - [in] If element_count2 < 0, then string2 must be null terminated and element_count2 will be set to the length of string2. If element_count2 >= 0, then that number of elements are compared in string2[]. bOrdinalIgnoreCase - [in] If bOrdinalIgnoreCase, then letters with a capital and small codepoint value <= 127 are compared using the smallest codepoint value. This amounts to converting the letters a-z to A-Z before comparing. Returns: 0: the strings are the same <0: string1 < string2 >0: string1 > string2 Remarks: 1) If linguistic issues are important, then this function is not appropriate. 2) nullptr values are handled. 3) There are lists of Unicode code point values such that the results of ON_StringCompareOrdinalUTF8, ON_StringCompareOrdinalUTF16 and ON_StringCompareOrdinalUTF32 are different when applied to UTF-8, UTF-16 and UTF-32 encodings.
ON_DECL int ON_StringCompareOrdinalUTF8 | ( | const char * | string1, |
int | element_count1, | ||
const char * | string2, | ||
int | element_count2, | ||
bool | bOrdinalIgnoreCase | ||
) |
Description: Compare of UTF-8 encoded char strings element by element. Parameters: string1 - [in] element_count1 - [in] If element_count1 < 0, then string1 must be null terminated and element_count1 will be set to the length of string1. If element_count1 >= 0, then that number of elements are compared in string1[]. string2 - [in] element_count2 - [in] If element_count2 < 0, then string2 must be null terminated and element_count2 will be set to the length of string2. If element_count2 >= 0, then that number of elements are compared in string2[]. bOrdinalIgnoreCase - [in] If bOrdinalIgnoreCase, then letters with a capital and small codepoint value <= 127 are compared using the smallest codepoint value. This amounts to converting the letters a-z to A-Z before comparing. Returns: 0: the strings are the same <0: string1 < string2 >0: string1 > string2 Remarks: 1) If linguistic issues are important, then this function is not appropriate. 2) nullptr values are handled. 3) There are lists of Unicode code point values such that the results of ON_StringCompareOrdinalUTF8, ON_StringCompareOrdinalUTF16 and ON_StringCompareOrdinalUTF32 are different when applied to UTF-8, UTF-16 and UTF-32 encodings. 4) This function does not compare Unicode code point values the strings have eny elements with values > 127.
ON_DECL int ON_StringCompareOrdinalWideChar | ( | const wchar_t * | string1, |
int | element_count1, | ||
const wchar_t * | string2, | ||
int | element_count2, | ||
bool | bOrdinalIgnoreCase | ||
) |
Description: Compare wchar_t strings element by element. Parameters: string1 - [in] element_count1 - [in] If element_count1 < 0, then string1 must be null terminated and element_count1 will be set to the length of string1. If element_count1 >= 0, then that number of elements are compared in string1[]. string2 - [in] element_count2 - [in] If element_count2 < 0, then string2 must be null terminated and element_count2 will be set to the length of string2. If element_count2 >= 0, then that number of elements are compared in string2[]. bOrdinalIgnoreCase - [in] If bOrdinalIgnoreCase, then letters with a capital and small codepoint value <= 127 are compared using the smallest codepoint value. This amounts to converting the letters a-z to A-Z before comparing. Returns: 0: the strings are the same <0: string1 < string2 >0: string1 > string2 Remarks: 1) If linguistic issues are important, then this function is not appropriate. 2) nullptr values are handled. 3) There are lists of Unicode code point values such that the results of ON_StringCompareOrdinalUTF8, ON_StringCompareOrdinalUTF16 and ON_StringCompareOrdinalUTF32 are different when applied to UTF-8, UTF-16 and UTF-32 encodings. 4) This function assumes the sizeof(wchar_t) is 1, 2 or 4, that 1 bytes wchar_t strings are UTF-8 encoded, 2 byte wchar_t strings are UTF-16 encoded and 4 bytes wchar_t strings are UTF-32 encoded.
const ON_SHA1_Hash ON_StringContentHash | ( | const char * | sUTF8, |
int | element_count, | ||
ON_StringMapOrdinalType | mapping | ||
) |
Parameters: sUTF8 - [in] pointer to a UTF-8 encoded string. element_count - [in] number of char elements to parse. if element_count < 0, then sUTF8 must be null terminated mapping - [in] mapping to apply to unicode code points Returns: A SHA-1 value of the sequence of unicode code points. This value is independent of platform endian or UTF encoding.
const ON_SHA1_Hash ON_StringContentHash | ( | const wchar_t * | sWideString, |
int | element_count, | ||
ON_StringMapOrdinalType | mapping | ||
) |
Parameters: sUTF8 - [in] pointer to a UTF-8 encoded string. element_count - [in] number of char elements to parse. if element_count < 0, then sUTF8 must be null terminated mapping - [in] mapping to apply to unicode code points Returns: A SHA-1 value of the sequence of unicode code points. This value is independent of platform endian or UTF encoding.
ON_DECL int ON_StringLengthUTF16 | ( | const ON__UINT16 * | string | ) |
Description: Get the length of a UTF-16 encoded ON__UINT16 string. Parameters: string - [in] null terminated ON__UINT16 string. Returns: Number of nonzero ON__UINT16 elements before the null terminator. If string is nullptr, then 0 is returned.
ON_DECL int ON_StringLengthUTF16 | ( | const ON__UINT16 * | string, |
size_t | string_capacity | ||
) |
Description: Get the length of a UTF-16 encoded ON__UINT16 string. Parameters: string - [in] null terminated ON__UINT16 string. string_capacity - [in] maximum number of string[] elements to test. Returns: If string is nullptr or string_capacity <=0, then 0 is returned. If a null terminator is not found, then string_capacity is returned. Otherwise, the number of nonzero char elements before the null terminator is returned.
ON_DECL int ON_StringLengthUTF32 | ( | const ON__UINT32 * | string | ) |
Description: Get the length of a UTF-32 encoded ON__UINT32 string. Parameters: string - [in] null terminated ON__UINT32 string. Returns: Number of nonzero ON__UINT32 elements before the null terminator. If string is nullptr, then 0 is returned.
ON_DECL int ON_StringLengthUTF32 | ( | const ON__UINT32 * | string, |
size_t | string_capacity | ||
) |
Description: Get the length of a UTF-32 encoded ON__UINT32 string. Parameters: string - [in] null terminated ON__UINT32 string. string_capacity - [in] maximum number of string[] elements to test. Returns: If string is nullptr or string_capacity <=0, then 0 is returned. If a null terminator is not found, then string_capacity is returned. Otherwise, the number of nonzero char elements before the null terminator is returned.
ON_DECL int ON_StringLengthUTF8 | ( | const char * | string | ) |
Description: Get the length of a UTF-8 encoded char string. Parameters: string - [in] null terminated char string. Returns: Number of nonzero char elements before the null terminator. If string is nullptr, then 0 is returned.
ON_DECL int ON_StringLengthUTF8 | ( | const char * | string, |
size_t | string_capacity | ||
) |
Description: Get the length of a UTF-8 encoded char string. Parameters: string - [in] null terminated char string. string_capacity - [in] maximum number of string[] elements to test. Returns: If string is nullptr or string_capacity <=0, then 0 is returned. If a null terminator is not found, then string_capacity is returned. Otherwise, the number of nonzero char elements before the null terminator is returned.
ON_DECL int ON_StringLengthWideChar | ( | const wchar_t * | string | ) |
Description: Get the length of a wchar_t string. Parameters: string - [in] null terminated wchar_t string. Returns: Number of nonzero wchar_t elements before the null terminator. If string is nullptr, then 0 is returned.
ON_DECL int ON_StringLengthWideChar | ( | const wchar_t * | string, |
size_t | string_capacity | ||
) |
Description: Get the length of a wchar_t string. Parameters: string - [in] null terminated wchar_t string. string_capacity - [in] maximum number of string[] elements to test. Returns: If string is nullptr or string_capacity <=0, then 0 is returned. If a null terminator is not found, then string_capacity is returned. Otherwise, the number of nonzero char elements before the null terminator is returned.
ON_DECL ON_StringMapOrdinalType ON_StringMapOrdinalTypeFromStringMapType | ( | ON_StringMapType | map_type | ) |
summary> ON_ChainDirection is used to specify directions when building chains of components like edges or faces. /summary>
ON_DECL int ON_StringToBase32 | ( | const char * | sBase32, |
unsigned char * | base32_digits | ||
) |
ON_DECL int ON_StringToBase32 | ( | const ON_String & | sBase32, |
ON_SimpleArray< unsigned char > & | base32_digits | ||
) |
ON_DECL int ON_StringToBase32 | ( | const ON_wString & | sBase32, |
ON_SimpleArray< unsigned char > & | base32_digits | ||
) |
Description: Convert a null terminate string containing the 32 symbols
0 1 2 3 4 5 6 7 8 9 A B C D E F G H J K M N P Q R T U V W X Y Z
(I,L,O and S are missing) into a list of base 32 digits. Parameters: sBase32 - [in] String with base 32 digits base32_digits - [out] base32_digits[] is an array of length strlen(sBase32). The returned array, element will be in the range 0 to 31. sBase32[] must be an array of length base32_digit_count+1 or 2, whichever is greater. The string representation of the base 32 number will be put in this string. A hash mark symbol (#) is used to indicate an error in the input value. The returned string is null terminated. Returns True if the input is valid. False if the input is not valid, in which case hash marks indicate the invalid entries.
ON_DECL char* on_strlwr | ( | char * | ) |
on_strlwr() calls _strlwr() or strlwr() depending on OS
ON_DECL int on_strnicmp | ( | const char * | s1, |
const char * | s2, | ||
int | n | ||
) |
on_stricmp() is a wrapper for case insensitive string compare and calls one of _strnicmp() or strncasecmp() depending on OS.
ON_DECL char* on_strrev | ( | char * | ) |
on_strrev() calls _strrev() or strrev() depending on OS
ON_DECL char* on_strupr | ( | char * | ) |
on_strupr() calls _strupr() or strupr() depending on OS
ON_SubDComponentLocation ON_SubDComponentLocationFromUnsigned | ( | unsigned int | loc_as_unsigned | ) |
bool ON_SubDComponentRegionBreakpoint | ( | const class ON_SubDComponentRegion * | component_region | ) |
ON_DECL ON_SubDEndCapStyle ON_SubDEndCapStyleFromUnsigned | ( | unsigned int | subd_cap_style_as_unsigned | ) |
Convert an integer value to an ON_SubDEndCapStyle enum value.
subd_cap_style_as_unsigned |
If subd_cap_style_as_unsigned is not valid, then ON_SubDEndCapStyle::Unset is returned.
const ON_DECL ON_wString ON_SubDEndCapStyleToString | ( | ON_SubDEndCapStyle | subd_cap_style | ) |
Convert subd_cap_style to a string description.
subd_cap_style |
bool ON_SubDFaceRegionBreakpoint | ( | unsigned int | level0_face_id, |
const class ON_SubDComponentRegionIndex & | region_index | ||
) |
ON_DECL ON_SubDHashType ON_SubDHashTypeFromUnsigned | ( | unsigned int | subd_hash_type_as_unsigned | ) |
const ON_DECL ON_wString ON_SubDHashTypeToString | ( | ON_SubDHashType | subd_hash_type, |
bool | bVerbose | ||
) |
ON_DECL double ON_SuperfluousKnot | ( | int | order, |
int | cv_count, | ||
const double * | knot, | ||
int | |||
) |
ON_DECL bool ON_SwapPointGridCoordinates | ( | int | , |
int | , | ||
int | , | ||
int | , | ||
double * | , | ||
int | , | ||
int | |||
) |
ON_DECL bool ON_SwapPointListCoordinates | ( | int | , |
int | , | ||
double * | , | ||
int | , | ||
int | |||
) |
ON_DECL bool ON_SwapPointListCoordinates | ( | int | , |
int | , | ||
float * | , | ||
int | , | ||
int | |||
) |
ON_DECL bool ON_Sym3x3EigenSolver | ( | double | A, |
double | B, | ||
double | C, | ||
double | D, | ||
double | E, | ||
double | F, | ||
double * | e1, | ||
ON_3dVector & | E1, | ||
double * | e2, | ||
ON_3dVector & | E2, | ||
double * | e3, | ||
ON_3dVector & | E3 | ||
) |
Description: Find the eigen values and eigen vectors of a real symmetric 3x3 matrix
A D F D B E F E C
Parameters: A - [in] matrix entry B - [in] matrix entry C - [in] matrix entry D - [in] matrix entry E - [in] matrix entry F - [in] matrix entry e1 - [out] eigen value E1 - [out] eigen vector with eigen value e1 e2 - [out] eigen value E2 - [out] eigen vector with eigen value e2 e3 - [out] eigen value E3 - [out] eigen vector with eigen value e3 Returns: True if successful.
ON_DECL bool ON_Test_MSSBCP | ( | bool | bWindowsAPITest, |
ON_TextLog & | text_log | ||
) |
ON_DECL bool ON_Test_MSSBCP | ( | const ON__UINT32 | code_page, |
bool | bWindowsAPITest, | ||
ON_TextLog & | text_log | ||
) |
ON_END_EXTERNC ON_DECL ON__UINT32 ON_Test_MSSBCP | ( | const ON__UINT32 | code_page, |
const ON__UINT32 | char_encoding, | ||
bool | bWindowsAPITest, | ||
ON_TextLog & | text_log | ||
) |
ON_DECL bool ON_Test_PrintPlatformMSSBCPToUnicodeTable | ( | const ON__UINT32 | code_page, |
ON__UINT32 | char_encoding0, | ||
ON__UINT32 | char_encoding1, | ||
ON_TextLog & | text_log | ||
) |
ON_DECL void ON_TestHashSpeed | ( | size_t | byte_count, |
bool | bTestCRC16, | ||
bool | bTestCRC32, | ||
bool | bTestMD5, | ||
bool | bTestSHA1, | ||
ON_TextLog & | text_log | ||
) |
Description: Test speeds of various hash algorithms and use text_log to print the results. Parameters: byte_count - [in] Number of bytes to hash. This number is rounded up to the nearest multiple of 1024. bCRC16 - [in] True to test 16 bit CRC hashing speed. bCRC32 - [in] True to test 32 bit CRC hashing speed. bMD5 - [in] True to test MD5 hashing speed. bSHA1 - [in] True to test SHA-1 hashing speed. text_log - [in] Test results are printed using text_log.
ON_DECL void ON_TestHashSpeed | ( | size_t | byte_count, |
ON__UINT16 * | crc16, | ||
ON__UINT32 * | crc32, | ||
ON_MD5_Hash * | md5_hash, | ||
ON_SHA1_Hash * | sha1_hash, | ||
double | elapsed_time_in_seconds[4] | ||
) |
Description: Test speeds of various hash algorithms. Parameters: byte_count - [in] Number of bytes to hash. This number is rounded up to the nearest multiple of 1024. crc16 - [in/out] If crc16 is not nullptr, then 16 bit CRC hashing is tested using function ON_CRC16(). crc32 - [in/out] If crc32 is not nullptr, then 32 bit CRC hashing is tested using function ON_CRC32(). md5_hash - [in/out] If md5_hash is not nullptr, then MD5 hashing is tested using class ON_MD5. sha1_hash - [in/out] If sha1_hash is not nullptr, then SHA-1 hashing is tested class ON_SHA1. elapsed_time_in_seconds - [out] elapsed_time_in_seconds[0] = 16 bit CRC hash time in seconds. elapsed_time_in_seconds[1] = 32 bit CRC hash time in seconds. elapsed_time_in_seconds[2] = MD5 hash time in seconds. elapsed_time_in_seconds[3] = SHA-1 hash time in seconds. If a hash was tested, then number of seconds it took to compute the hash is returned. Otherwise ON_DBL_QNAN is returned.
ON_DECL void ON_TestHashSpeed | ( | size_t | byte_count, |
ON_TextLog & | text_log | ||
) |
ON_DECL double ON_TestMathFunction | ( | int | function_index, |
double | x, | ||
double | y | ||
) |
Description: Test math library functions. Parameters: function_index - [in] Determines which math library function is called.
1: z = x+y 2: z = x-y 3: z = x*y 4: z = x/y 5: z = fabs(x) 6: z = exp(x) 7: z = log(x) 8: z = logb(x) 9: z = log10(x) 10: z = pow(x,y) 11: z = sqrt(x) 12: z = sin(x) 13: z = cos(x) 14: z = tan(x) 15: z = sinh(x) 16: z = cosh(x) 17: z = tanh(x) 18: z = asin(x) 19: z = acos(x) 20: z = atan(x) 21: z = atan2(y,x) 22: z = fmod(x,y) 23: z = modf(x,&y) 24: z = frexp(x,&y)
double x - [in] double y - [in] Returns: Returns the "z" value listed in the function_index parameter description. Remarks: This function is used to test the results of class floating point functions. It is primarily used to see what happens when opennurbs is used as a DLL and illegal operations are performed.
ON_DECL bool ON_TestVersionNumber | ( | unsigned int | major, |
unsigned int | minor, | ||
unsigned int | year, | ||
unsigned int | month, | ||
unsigned int | day_of_month, | ||
unsigned int | platform_branch, | ||
unsigned int | version_as_unsigned_number | ||
) |
Description: A tool to validate version information and to test opennurbs version number encoding and parsing. Parameters: major A value between 1 and ON::VersionMajorMaximum(). minor, A value between 0 and ON::VersionMinorMaximum(). year A value between 2000 and 2099 month A value between 1 and 12 day_of_month A value between 1 and ON_DaysInMonthOfGregorianYear(year, month). platform_branch 0: developer build >= 1: some type of build system build version_as_unsigned_number Either 0 or the encoded version number to test against the previous parameters. Returns: true Input parameters are valid and testing internal version number utilities passed. false Input parameters are not valid or a bug was detected in internal version number utilities.
ON_DECL bool ON_TransformBrepComponents | ( | ON_Brep * | brep, |
int | brep_component_count, | ||
const ON_COMPONENT_INDEX * | brep_components, | ||
ON_Xform | xform, | ||
double | tolerance, | ||
double | time_limit, | ||
bool | bUseMultipleThreads | ||
) |
Description: Transform a list of brep components, bend neighbors to match, and leave the rest fixed. Parameters: brep - [in] brep to modify brep_component_count - [in] Length of brep_components[] array brep_components - [in] components to transform. xform - [in] transformation to apply to components tolerance - [in] Desired fitting tolerance to use when bending faces that share edges with both fixed and transformed components. time_limit - [in] If the deformation is extreme, it can take a long time to calculate the result. If time_limit > 0, then the value specifies the maximum amount of time in seconds you want to spend before giving up. bUseMultipleThreads - [in] True if multiple threads can be used. Returns: True if successful.
ON_DECL bool ON_TransformPointGrid | ( | int | , |
bool | , | ||
int | , | ||
int | , | ||
int | , | ||
int | , | ||
double * | , | ||
const ON_Xform & | |||
) |
ON_DECL double ON_TriangleArea2d | ( | ON_2dPoint | A, |
ON_2dPoint | B, | ||
ON_2dPoint | C | ||
) |
Description: Get the area of a 2d triangle. Parameters: A - [in] B - [in] C - [in] Triangle corners Returns: Area of a 2d triangle with corners at A, B, C.
ON_DECL double ON_TriangleArea3d | ( | ON_3dPoint | A, |
ON_3dPoint | B, | ||
ON_3dPoint | C | ||
) |
Description: Get the area of a 3d triangle. Parameters: A - [in] B - [in] C - [in] Triangle corners Returns: Area of a 3d triangle with corners at A, B, C.
ON_DECL ON_3dVector ON_TriangleNormal | ( | const ON_3dPoint & | A, |
const ON_3dPoint & | B, | ||
const ON_3dPoint & | C | ||
) |
Description: Finds the unit normal to the triangle Parameters: A - [in] triangle corner B - [in] triangle corner C - [in] triangle corner Returns: Unit normal
ON_DECL ON_Curve* ON_TrimCurve | ( | const ON_Curve & | curve, |
ON_Interval | trim_parameters | ||
) |
Description: Trim a curve. Parameters: curve - [in] curve to trim (not modified) trim_parameters - [in] trimming parameters If curve is open, then trim_parameters must be an increasing interval.If curve is closed, and trim_parameters ins a decreasing interval, then the portion of the curve across the start/end is returned. Returns: trimmed curve or nullptr if input is invalid.
ON_DECL double ON_TrinomialCoefficient | ( | int | i, |
int | j, | ||
int | k | ||
) |
Description: Compute a trinomial coefficient. Parameters: i - [in] j - [in] k - [in] Returns: (i+j+k)!/(i!j!k!), if 0 <= i, 0 <= j and 0<= k, and 0 otherwise. See Also: ON_BinomialCoefficient() Remarks: The trinomial coefficient is computed using the formula
(i+j+k)! (i+j+k)! (j+k)! -------- = -------- * ------- i! j! k! i! (j+k)! j! k! = ON_BinomialCoefficient(i,j+k)*ON_BinomialCoefficient(j,k)
ON_DECL double ON_TripleProduct | ( | const double * | , |
const double * | , | ||
const double * | |||
) |
ON_DECL float ON_TripleProduct | ( | const float * | , |
const float * | , | ||
const float * | |||
) |
ON_DECL double ON_TripleProduct | ( | const ON_3dVector & | , |
const ON_3dVector & | , | ||
const ON_3dVector & | |||
) |
ON_DECL float ON_TripleProduct | ( | const ON_3fVector & | , |
const ON_3fVector & | , | ||
const ON_3fVector & | |||
) |
ON_DECL bool ON_TuneupEvaluationParameter | ( | int | side, |
double | s0, | ||
double | s1, | ||
double * | s | ||
) |
s1 | segment domain |
s | segment parameter |
ON_DECL bool ON_UnclampKnotVectorForExperts | ( | int | cv_dim, |
int | order, | ||
int | cv_count, | ||
int | cv_stride, | ||
double * | cv, | ||
double * | knot, | ||
int | end | ||
) |
Description: Unclamp end knots.
Does not modify the curve location or parameterization, but typically modifies knots and control vertices near the ends. Parameters: cv_dim - [in] = (dim + is_rat) end - [in] 0 = unclamp start, 1 = unclamp end, 2 = unclamp start and end Returns: true if successful Remarks: Degree 1 NURBS curves cannot be unclampled. See Also: SetUnclampedTagForExperts
ON_DECL size_t ON_UncompressBuffer | ( | size_t | sizeof_compressed_buffer, |
const void * | compressed_buffer, | ||
size_t | sizeof_uncompressed_buffer, | ||
void * | uncompressed_buffer | ||
) |
Description: Simple tool for uncompressing a buffer when the output buffer size is known. Parameters: sizeof_compressed_buffer - [in] byte count compressed_buffer - [in] sizeof_uncompressed_buffer byte count uncompressed_buffer - [out] Returns: Number of bytes written to uncompressed_buffer.
ON_DECL ON__UINT32 ON_UnicodeMapCodePoint | ( | const ON_Locale & | locale, |
ON_StringMapType | map_type, | ||
ON__UINT32 | unicode_code_point | ||
) |
ON_DECL ON__UINT32 ON_UnicodeMapCodePointOrdinal | ( | ON_StringMapOrdinalType | map_type, |
ON__UINT32 | unicode_code_point | ||
) |
ON_DECL enum ON_UnicodeEncoding ON_UnicodeNativeCPU_UTF16 | ( | ) |
Returns: ON_UTF_16BE The byte order on where the function was run is big endian. ON_UTF_16L The byte order on where the function was run is little endian.
ON_DECL enum ON_UnicodeEncoding ON_UnicodeNativeCPU_UTF32 | ( | ) |
Returns: ON_UTF_32BE The byte order on where the function was run is big endian. ON_UTF_32LE The byte order on where the function was run is little endian.
ON_DECL unsigned ON_UnicodeSubcriptFromCodePoint | ( | unsigned | cp, |
unsigned | no_subscript_cp | ||
) |
When possible, converts a code point to a subscript code point. Note that many common fonts typecast the Unicode digit subscripts as vulgar fraction denominators rather than a proper subscript.
cp | Unicode code point for which a subscript is desired. |
no_subscript_cp | When in doubt, pass cp. |
ON_DECL unsigned ON_UnicodeSubscriptFromDigit | ( | unsigned | decimal_digit | ) |
Get the Unicode code point for a decimal digit subscript.
decimal_digit | 0 <= decimal_digit <= 9 |
ON_DECL unsigned ON_UnicodeSuperscriptFromCodePoint | ( | unsigned | cp, |
unsigned | no_superscript_cp | ||
) |
When possible, converts a code point to a superscript code point. Note that many common fonts typecast the Unicode digit superscripts as vulgar fraction numerators rather than a proper superscript.
cp | Unicode code point for which a superscript is desired. |
no_superscript_cp | When in doubt, pass cp. |
ON_DECL unsigned ON_UnicodeSuperscriptFromDigit | ( | unsigned | decimal_digit | ) |
Get the Unicode code point for a decimal digit superscript.
decimal_digit | 0 <= decimal_digit <= 9 |
ON_DECL std::string ON_UTF16_to_std_string | ( | int | bTestByteOrder, |
const ON__UINT16 * | sInputUTF, | ||
int | sInputUTF_count, | ||
unsigned int * | error_status, | ||
unsigned int | error_mask, | ||
ON__UINT32 | error_code_point, | ||
const ON__UINT16 ** | sEndElement | ||
) |
Description: Convert a UTF-16 encoded ON__UINT16 string to a UTF-8 encoded std:string. This function removes byte order marks (BOM) and can repair encoding errors.
Parameters: bTestByteOrder - [in] If bTestByteOrder is true and the the input buffer is a byte order mark (BOM), then the BOM is skipped. It the value of the BOM is byte swapped, then subsequent input elements are byte swapped before being decoded. Specifically:
sInputUTF - [in] UTF-16 encoded ON__UINT16 string to convert.
sInputUTF_count - [in] If sInputUTF_count >= 0, then it specifies the number of elements in sInputUTF[] to convert.
If sInputUTF_count == -1, then sInputUTF must be a zero terminated array and all the elements up to the first zero element are converted.
sUTF8 - [out] If sUTF8 is not null and sUTF8_count > 0, then the UTF-8 encoded string is returned in this buffer. If there is room for the null terminator, the converted string will be null terminated. The null terminator is never included in the count of returned by this function. The converted string is in the CPU's native byte order. No byte order mark is prepended.
sUTF8_count - [in] If sUTF8_count > 0, then it specifies the number of available ON__UINT8 elements in the sUTF8[] buffer.
If sUTF8_count == 0, then the sUTF8 parameter is ignored.
error_status - [out] If error_status is not null, then bits of *error_status are set to indicate the success or failure of the conversion.
When the error_mask parameter is used to used to mask some conversion errors, multiple bits may be set. 0: Successful conversion with no errors. 1: The input parameters were invalid. This error cannot be masked. 2: The output buffer was not large enough to hold the converted string. As much conversion as possible is performed in this case and the error cannot be masked. 4: When parsing a UTF-8 or UTF-32 string, the values of two consecutive encoding sequences formed a valid UTF-16 surrogate pair.
This error is masked if 0 != (4 & m_error_mask). If the error is masked, then the surrogate pair is decoded, the value of the resulting unicode code point is used, and parsing continues. 8: An overlong UTF-8 encoding sequence was encountered and the value of the overlong sUTF-8 sequence was a valid unicode code point.
This error is masked if 0 != (8 & m_error_mask). If the error is masked, then the unicode code point is used and parsing continues. 16: An illegal UTF-8, UTF-16 or UTF-32 encoding sequence occurred or an invalid unicode code point value resulted from decoding a UTF-8 sequence. This error is masked if 0 != (16 & m_error_mask). If the error is masked and the value of error_code_point is a valid unicode code point, then error_code_point is encoded in the output string and parsing continues.
error_mask - [in] If 0 != (error_mask & 4), then type 4 errors are masked. If 0 != (error_mask & 8), then type 8 errors are masked. If 0 != (error_mask & 16) and error_code_point is a valid unicode code point value, then type 16 errors are masked.
error_code_point - [in] Unicode code point value to use in when masking type 16 errors. If 0 == (error_mask & 16), then this parameter is ignored. 0xFFFD is a popular choice for the error_code_point value.
sEndElement - [out] If sEndElement is not null, then *sEndElement points to the element of sInputUTF[] were conversion stopped.
If an error occurred and was not masked, then *sEndElement points to the element of sInputUTF[] where the conversion failed.
If no errors occurred or all errors were masked, then sEndElement = sInputUTF + sInputUTF_count or points to the zero terminator in sInputUTF[], depending on the input value of sInputUTF_count.
Returns: A UTF-8 encoded std::string. The returned string does not have a byte order mark (BOM).
ON_DECL std::wstring ON_UTF16_to_std_wstring | ( | int | bTestByteOrder, |
const ON__UINT16 * | sInputUTF, | ||
int | sInputUTF_count, | ||
unsigned int * | error_status, | ||
unsigned int | error_mask, | ||
ON__UINT32 | error_code_point, | ||
const ON__UINT16 ** | sEndElement | ||
) |
Description: Convert a UTF-16 encoded ON__UINT16 string to a UTF-XX encoded std::wstring. This function removes byte order marks (BOM) and can repair encoding errors.
The value of sizeof(wchar_t) determines which UTF-XX encoding is used. sizeof(wchar_t) UTF-XX 1 UTF-8 2 UTF-16 4 UTF-32
Parameters: bTestByteOrder - [in] If bTestByteOrder is true and the the input buffer is a byte order mark (BOM), then the BOM is skipped. It the value of the BOM is byte swapped, then subsequent input elements are byte swapped before being decoded. Specifically:
sInputUTF - [in] UTF-16 encoded ON__UINT16 string to convert.
sInputUTF_count - [in] If sInputUTF_count >= 0, then it specifies the number of elements in sInputUTF[] to convert.
If sInputUTF_count == -1, then sInputUTF must be a zero terminated array and all the elements up to the first zero element are converted.
sUTF8 - [out] If sUTF8 is not null and sUTF8_count > 0, then the UTF-8 encoded string is returned in this buffer. If there is room for the null terminator, the converted string will be null terminated. The null terminator is never included in the count of returned by this function. The converted string is in the CPU's native byte order. No byte order mark is prepended.
sUTF8_count - [in] If sUTF8_count > 0, then it specifies the number of available ON__UINT8 elements in the sUTF8[] buffer.
If sUTF8_count == 0, then the sUTF8 parameter is ignored.
error_status - [out] If error_status is not null, then bits of *error_status are set to indicate the success or failure of the conversion.
When the error_mask parameter is used to used to mask some conversion errors, multiple bits may be set. 0: Successful conversion with no errors. 1: The input parameters were invalid. This error cannot be masked. 2: The output buffer was not large enough to hold the converted string. As much conversion as possible is performed in this case and the error cannot be masked. 4: When parsing a UTF-8 or UTF-32 string, the values of two consecutive encoding sequences formed a valid UTF-16 surrogate pair.
This error is masked if 0 != (4 & m_error_mask). If the error is masked, then the surrogate pair is decoded, the value of the resulting unicode code point is used, and parsing continues. 8: An overlong UTF-8 encoding sequence was encountered and the value of the overlong sUTF-8 sequence was a valid unicode code point.
This error is masked if 0 != (8 & m_error_mask). If the error is masked, then the unicode code point is used and parsing continues. 16: An illegal UTF-8, UTF-16 or UTF-32 encoding sequence occurred or an invalid unicode code point value resulted from decoding a UTF-8 sequence. This error is masked if 0 != (16 & m_error_mask). If the error is masked and the value of error_code_point is a valid unicode code point, then error_code_point is encoded in the output string and parsing continues.
error_mask - [in] If 0 != (error_mask & 4), then type 4 errors are masked. If 0 != (error_mask & 8), then type 8 errors are masked. If 0 != (error_mask & 16) and error_code_point is a valid unicode code point value, then type 16 errors are masked.
error_code_point - [in] Unicode code point value to use in when masking type 16 errors. If 0 == (error_mask & 16), then this parameter is ignored. 0xFFFD is a popular choice for the error_code_point value.
sEndElement - [out] If sEndElement is not null, then *sEndElement points to the element of sInputUTF[] were conversion stopped.
If an error occurred and was not masked, then *sEndElement points to the element of sInputUTF[] where the conversion failed.
If no errors occurred or all errors were masked, then sEndElement = sInputUTF + sInputUTF_count or points to the zero terminator in sInputUTF[], depending on the input value of sInputUTF_count.
Returns: A UTF-XX encoded std::wstring. The returned string does not have a byte order mark (BOM).
ON_DECL std::string ON_UTF32_to_std_string | ( | int | bTestByteOrder, |
const ON__UINT32 * | sInputUTF, | ||
int | sInputUTF_count, | ||
unsigned int * | error_status, | ||
unsigned int | error_mask, | ||
ON__UINT32 | error_code_point, | ||
const ON__UINT32 ** | sEndElement | ||
) |
Description: Convert a UTF-32 encoded ON__UINT16 string to a UTF-8 encoded std:string. This function removes byte order marks (BOM) and can repair encoding errors.
Parameters: bTestByteOrder - [in] If bTestByteOrder is true and the the input buffer is a byte order mark (BOM), then the BOM is skipped. It the value of the BOM is byte swapped, then subsequent input elements are byte swapped before being decoded. Specifically:
sInputUTF - [in] UTF-32 encoded ON__UINT32 string to convert.
sInputUTF_count - [in] If sInputUTF_count >= 0, then it specifies the number of elements in sInputUTF[] to convert.
If sInputUTF_count == -1, then sInputUTF must be a zero terminated array and all the elements up to the first zero element are converted.
error_status - [out] If error_status is not null, then bits of *error_status are set to indicate the success or failure of the conversion.
When the error_mask parameter is used to used to mask some conversion errors, multiple bits may be set. 0: Successful conversion with no errors. 1: The input parameters were invalid. This error cannot be masked. 2: The output buffer was not large enough to hold the converted string. As much conversion as possible is performed in this case and the error cannot be masked. 4: When parsing a UTF-8 or UTF-32 string, the values of two consecutive encoding sequences formed a valid UTF-16 surrogate pair.
This error is masked if 0 != (4 & m_error_mask). If the error is masked, then the surrogate pair is decoded, the value of the resulting unicode code point is used, and parsing continues. 8: An overlong UTF-8 encoding sequence was encountered and the value of the overlong sUTF-8 sequence was a valid unicode code point.
This error is masked if 0 != (8 & m_error_mask). If the error is masked, then the unicode code point is used and parsing continues. 16: An illegal UTF-8, UTF-16 or UTF-32 encoding sequence occurred or an invalid unicode code point value resulted from decoding a UTF-8 sequence. This error is masked if 0 != (16 & m_error_mask). If the error is masked and the value of error_code_point is a valid unicode code point, then error_code_point is encoded in the output string and parsing continues.
error_mask - [in] If 0 != (error_mask & 4), then type 4 errors are masked. If 0 != (error_mask & 8), then type 8 errors are masked. If 0 != (error_mask & 16) and error_code_point is a valid unicode code point value, then type 16 errors are masked.
error_code_point - [in] Unicode code point value to use in when masking type 16 errors. If 0 == (error_mask & 16), then this parameter is ignored. 0xFFFD is a popular choice for the error_code_point value.
sEndElement - [out] If sEndElement is not null, then *sEndElement points to the element of sInputUTF[] were conversion stopped.
If an error occurred and was not masked, then *sEndElement points to the element of sInputUTF[] where the conversion failed.
If no errors occurred or all errors were masked, then sEndElement = sInputUTF + sInputUTF_count or points to the zero terminator in sInputUTF[], depending on the input value of sInputUTF_count.
Returns: A UTF-8 encoded std::string. The returned string does not have a byte order mark (BOM).
ON_DECL std::wstring ON_UTF32_to_std_wstring | ( | int | bTestByteOrder, |
const ON__UINT32 * | sInputUTF, | ||
int | sInputUTF_count, | ||
unsigned int * | error_status, | ||
unsigned int | error_mask, | ||
ON__UINT32 | error_code_point, | ||
const ON__UINT32 ** | sEndElement | ||
) |
Description: Convert a UTF-32 encoded ON__UINT32 string to a UTF-XX encoded std::wstring. This function removes byte order marks (BOM) and can repair encoding errors.
The value of sizeof(wchar_t) determines which UTF-XX encoding is used. sizeof(wchar_t) UTF-XX 1 UTF-8 2 UTF-16 4 UTF-32
Parameters: bTestByteOrder - [in] If bTestByteOrder is true and the the input buffer is a byte order mark (BOM), then the BOM is skipped. It the value of the BOM is byte swapped, then subsequent input elements are byte swapped before being decoded. Specifically:
sInputUTF - [in] UTF-32 encoded ON__UINT32 string to convert.
sInputUTF_count - [in] If sInputUTF_count >= 0, then it specifies the number of elements in sInputUTF[] to convert.
If sInputUTF_count == -1, then sInputUTF must be a zero terminated array and all the elements up to the first zero element are converted.
error_status - [out] If error_status is not null, then bits of *error_status are set to indicate the success or failure of the conversion.
When the error_mask parameter is used to used to mask some conversion errors, multiple bits may be set. 0: Successful conversion with no errors. 1: The input parameters were invalid. This error cannot be masked. 2: The output buffer was not large enough to hold the converted string. As much conversion as possible is performed in this case and the error cannot be masked. 4: When parsing a UTF-8 or UTF-32 string, the values of two consecutive encoding sequences formed a valid UTF-16 surrogate pair.
This error is masked if 0 != (4 & m_error_mask). If the error is masked, then the surrogate pair is decoded, the value of the resulting unicode code point is used, and parsing continues. 8: An overlong UTF-8 encoding sequence was encountered and the value of the overlong sUTF-8 sequence was a valid unicode code point.
This error is masked if 0 != (8 & m_error_mask). If the error is masked, then the unicode code point is used and parsing continues. 16: An illegal UTF-8, UTF-16 or UTF-32 encoding sequence occurred or an invalid unicode code point value resulted from decoding a UTF-8 sequence. This error is masked if 0 != (16 & m_error_mask). If the error is masked and the value of error_code_point is a valid unicode code point, then error_code_point is encoded in the output string and parsing continues.
error_mask - [in] If 0 != (error_mask & 4), then type 4 errors are masked. If 0 != (error_mask & 8), then type 8 errors are masked. If 0 != (error_mask & 16) and error_code_point is a valid unicode code point value, then type 16 errors are masked.
error_code_point - [in] Unicode code point value to use in when masking type 16 errors. If 0 == (error_mask & 16), then this parameter is ignored. 0xFFFD is a popular choice for the error_code_point value.
sEndElement - [out] If sEndElement is not null, then *sEndElement points to the element of sInputUTF[] were conversion stopped.
If an error occurred and was not masked, then *sEndElement points to the element of sInputUTF[] where the conversion failed.
If no errors occurred or all errors were masked, then sEndElement = sInputUTF + sInputUTF_count or points to the zero terminator in sInputUTF[], depending on the input value of sInputUTF_count.
Returns: A UTF-XX encoded std::wstring. The returned string does not have a byte order mark (BOM).
ON_DECL std::string ON_UTF8_to_std_string | ( | int | bTestByteOrder, |
const char * | sInputUTF, | ||
int | sInputUTF_count, | ||
unsigned int * | error_status, | ||
unsigned int | error_mask, | ||
ON__UINT32 | error_code_point, | ||
const char ** | sEndElement | ||
) |
Description: Convert a UTF-8 encoded char string to a UTF-8 encoded std::string. This function removes byte order marks (BOM) and can repair encoding errors.
Parameters: bTestByteOrder - [in] If bTestByteOrder is true and the the input buffer is a byte order mark (BOM), then the BOM is skipped. It the value of the BOM is byte swapped, then subsequent input elements are byte swapped before being decoded. Specifically:
sInputUTF - [in] UTF-8 encoded char string to convert.
sInputUTF_count - [in] If sInputUTF_count >= 0, then it specifies the number of elements in sInputUTF[] to convert.
If sInputUTF_count == -1, then sInputUTF must be a zero terminated array and all the elements up to the first zero element are converted.
error_status - [out] If error_status is not null, then bits of *error_status are set to indicate the success or failure of the conversion.
When the error_mask parameter is used to used to mask some conversion errors, multiple bits may be set. 0: Successful conversion with no errors. 1: The input parameters were invalid. This error cannot be masked. 2: The output buffer was not large enough to hold the converted string. As much conversion as possible is performed in this case and the error cannot be masked. 4: When parsing a UTF-8 or UTF-32 string, the values of two consecutive encoding sequences formed a valid UTF-16 surrogate pair.
This error is masked if 0 != (4 & m_error_mask). If the error is masked, then the surrogate pair is decoded, the value of the resulting unicode code point is used, and parsing continues. 8: An overlong UTF-8 encoding sequence was encountered and the value of the overlong sUTF-8 sequence was a valid unicode code point.
This error is masked if 0 != (8 & m_error_mask). If the error is masked, then the unicode code point is used and parsing continues. 16: An illegal UTF-8, UTF-16 or UTF-32 encoding sequence occurred or an invalid unicode code point value resulted from decoding a UTF-8 sequence. This error is masked if 0 != (16 & m_error_mask). If the error is masked and the value of error_code_point is a valid unicode code point, then error_code_point is encoded in the output string and parsing continues.
error_mask - [in] If 0 != (error_mask & 4), then type 4 errors are masked. If 0 != (error_mask & 8), then type 8 errors are masked. If 0 != (error_mask & 16) and error_code_point is a valid unicode code point value, then type 16 errors are masked.
error_code_point - [in] Unicode code point value to use in when masking type 16 errors. If 0 == (error_mask & 16), then this parameter is ignored. 0xFFFD is a popular choice for the error_code_point value.
sEndElement - [out] If sEndElement is not null, then *sEndElement points to the element of sInputUTF[] were conversion stopped.
If an error occurred and was not masked, then *sEndElement points to the element of sInputUTF[] where the conversion failed.
If no errors occurred or all errors were masked, then sEndElement = sInputUTF + sInputUTF_count or points to the zero terminator in sInputUTF[], depending on the input value of sInputUTF_count.
Returns: A UTF-8 encoded std::string. The returned string does not have a byte order mark (BOM).
ON_DECL std::wstring ON_UTF8_to_std_wstring | ( | int | bTestByteOrder, |
const char * | sInputUTF, | ||
int | sInputUTF_count, | ||
unsigned int * | error_status, | ||
unsigned int | error_mask, | ||
ON__UINT32 | error_code_point, | ||
const char ** | sEndElement | ||
) |
Description: Convert a UTF-8 encoded char string to a UTF-XX encoded std::wstring. This function removes byte order marks (BOM) and can repair encoding errors.
The value of sizeof(wchar_t) determines which UTF-XX encoding is used. sizeof(wchar_t) UTF-XX 1 UTF-8 2 UTF-16 4 UTF-32
Parameters: bTestByteOrder - [in] If bTestByteOrder is true and the the input buffer is a byte order mark (BOM), then the BOM is skipped. It the value of the BOM is byte swapped, then subsequent input elements are byte swapped before being decoded. Specifically:
sInputUTF - [in] UTF-8 encoded char string to convert.
sInputUTF_count - [in] If sInputUTF_count >= 0, then it specifies the number of elements in sInputUTF[] to convert.
If sInputUTF_count == -1, then sInputUTF must be a zero terminated array and all the elements up to the first zero element are converted.
error_status - [out] If error_status is not null, then bits of *error_status are set to indicate the success or failure of the conversion.
When the error_mask parameter is used to used to mask some conversion errors, multiple bits may be set. 0: Successful conversion with no errors. 1: The input parameters were invalid. This error cannot be masked. 2: The output buffer was not large enough to hold the converted string. As much conversion as possible is performed in this case and the error cannot be masked. 4: When parsing a UTF-8 or UTF-32 string, the values of two consecutive encoding sequences formed a valid UTF-16 surrogate pair.
This error is masked if 0 != (4 & m_error_mask). If the error is masked, then the surrogate pair is decoded, the value of the resulting unicode code point is used, and parsing continues. 8: An overlong UTF-8 encoding sequence was encountered and the value of the overlong sUTF-8 sequence was a valid unicode code point.
This error is masked if 0 != (8 & m_error_mask). If the error is masked, then the unicode code point is used and parsing continues. 16: An illegal UTF-8, UTF-16 or UTF-32 encoding sequence occurred or an invalid unicode code point value resulted from decoding a UTF-8 sequence. This error is masked if 0 != (16 & m_error_mask). If the error is masked and the value of error_code_point is a valid unicode code point, then error_code_point is encoded in the output string and parsing continues.
error_mask - [in] If 0 != (error_mask & 4), then type 4 errors are masked. If 0 != (error_mask & 8), then type 8 errors are masked. If 0 != (error_mask & 16) and error_code_point is a valid unicode code point value, then type 16 errors are masked.
error_code_point - [in] Unicode code point value to use in when masking type 16 errors. If 0 == (error_mask & 16), then this parameter is ignored. 0xFFFD is a popular choice for the error_code_point value.
sEndElement - [out] If sEndElement is not null, then *sEndElement points to the element of sInputUTF[] were conversion stopped.
If an error occurred and was not masked, then *sEndElement points to the element of sInputUTF[] where the conversion failed.
If no errors occurred or all errors were masked, then sEndElement = sInputUTF + sInputUTF_count or points to the zero terminator in sInputUTF[], depending on the input value of sInputUTF_count.
Returns: A UTF-XX encoded std::wstring. The returned string does not have a byte order mark (BOM).
ON_DECL std::wstring ON_UTF_std_string_to_std_wstring | ( | int | bTestByteOrder, |
const std::string & | sInputUTF, | ||
int | sInputUTF_count, | ||
unsigned int * | error_status, | ||
unsigned int | error_mask, | ||
ON__UINT32 | error_code_point, | ||
int * | end_element_index | ||
) |
Description: Convert a UTF-8 encoded std::string to a UTF-XX encoded std::wstring. This function removes byte order marks (BOM) and can repair encoding errors.
The value of sizeof(wchar_t) determines which UTF-XX encoding is used. sizeof(wchar_t) UTF-XX 1 UTF-8 2 UTF-16 4 UTF-32
Parameters: bTestByteOrder - [in] If bTestByteOrder is true and the the input buffer is a byte order mark (BOM), then the BOM is skipped. It the value of the BOM is byte swapped, then subsequent input elements are byte swapped before being decoded. Specifically:
sInputUTF - [in] UTF-8 encoded std::string to convert.
sInputUTF_count - [in] If sInputUTF_count >= 0, then it specifies the number of elements in sInputUTF[] to convert.
If sInputUTF_count == -1, then sInputUTF must be a zero terminated array and all the elements up to the first zero element are converted.
sUTF8 - [out] If sUTF8 is not null and sUTF8_count > 0, then the UTF-8 encoded string is returned in this buffer. If there is room for the null terminator, the converted string will be null terminated. The null terminator is never included in the count of returned by this function. The converted string is in the CPU's native byte order. No byte order mark is prepended.
sUTF8_count - [in] If sUTF8_count > 0, then it specifies the number of available ON__UINT8 elements in the sUTF8[] buffer.
If sUTF8_count == 0, then the sUTF8 parameter is ignored.
error_status - [out] If error_status is not null, then bits of *error_status are set to indicate the success or failure of the conversion.
When the error_mask parameter is used to used to mask some conversion errors, multiple bits may be set. 0: Successful conversion with no errors. 1: The input parameters were invalid. This error cannot be masked. 2: The output buffer was not large enough to hold the converted string. As much conversion as possible is performed in this case and the error cannot be masked. 4: When parsing a UTF-8 or UTF-32 string, the values of two consecutive encoding sequences formed a valid UTF-16 surrogate pair.
This error is masked if 0 != (4 & m_error_mask). If the error is masked, then the surrogate pair is decoded, the value of the resulting unicode code point is used, and parsing continues. 8: An overlong UTF-8 encoding sequence was encountered and the value of the overlong sUTF-8 sequence was a valid unicode code point.
This error is masked if 0 != (8 & m_error_mask). If the error is masked, then the unicode code point is used and parsing continues. 16: An illegal UTF-8, UTF-16 or UTF-32 encoding sequence occurred or an invalid unicode code point value resulted from decoding a UTF-8 sequence. This error is masked if 0 != (16 & m_error_mask). If the error is masked and the value of error_code_point is a valid unicode code point, then error_code_point is encoded in the output string and parsing continues.
error_mask - [in] If 0 != (error_mask & 4), then type 4 errors are masked. If 0 != (error_mask & 8), then type 8 errors are masked. If 0 != (error_mask & 16) and error_code_point is a valid unicode code point value, then type 16 errors are masked.
error_code_point - [in] Unicode code point value to use in when masking type 16 errors. If 0 == (error_mask & 16), then this parameter is ignored. 0xFFFD is a popular choice for the error_code_point value.
end_element_index - [out] If end_element_index is not null, then *end_element_index is the index of the first element in sInputUTF that was not converted.
If an error occurred and was not masked, then *end_element_index is the index of the element of sInputUTF[] where the conversion failed.
If no errors occurred or all errors were masked, then end_element_index is the number of elements in sInputUTF[] that were converted.
Returns: A UTF-XX encoded std::wstring. The returned string does not have a byte order mark (BOM).
ON_DECL std::string ON_UTF_std_wstring_to_std_string | ( | int | bTestByteOrder, |
const std::wstring & | sInputUTF, | ||
int | sInputUTF_count, | ||
unsigned int * | error_status, | ||
unsigned int | error_mask, | ||
ON__UINT32 | error_code_point, | ||
int * | end_element_index | ||
) |
Description: Convert a UTF-XX encoded std::wstring to a UTF-8 encoded std:string. This function removes byte order marks (BOM) and can repair encoding errors.
The value of sizeof(wchar_t) determines which UTF-XX encoding is used. sizeof(wchar_t) UTF-XX 1 UTF-8 2 UTF-16 4 UTF-32
Parameters: bTestByteOrder - [in] If bTestByteOrder is true and the the input buffer is a byte order mark (BOM), then the BOM is skipped. It the value of the BOM is byte swapped, then subsequent input elements are byte swapped before being decoded. Specifically:
sInputUTF - [in] UTF-XX encoded std::wstring to convert.
sInputUTF_count - [in] If sInputUTF_count >= 0, then it specifies the number of elements in sInputUTF[] to convert.
If sInputUTF_count == -1, then sInputUTF must be a zero terminated array and all the elements up to the first zero element are converted.
sUTF8 - [out] If sUTF8 is not null and sUTF8_count > 0, then the UTF-8 encoded string is returned in this buffer. If there is room for the null terminator, the converted string will be null terminated. The null terminator is never included in the count of returned by this function. The converted string is in the CPU's native byte order. No byte order mark is prepended.
sUTF8_count - [in] If sUTF8_count > 0, then it specifies the number of available ON__UINT8 elements in the sUTF8[] buffer.
If sUTF8_count == 0, then the sUTF8 parameter is ignored.
error_status - [out] If error_status is not null, then bits of *error_status are set to indicate the success or failure of the conversion.
When the error_mask parameter is used to used to mask some conversion errors, multiple bits may be set. 0: Successful conversion with no errors. 1: The input parameters were invalid. This error cannot be masked. 2: The output buffer was not large enough to hold the converted string. As much conversion as possible is performed in this case and the error cannot be masked. 4: When parsing a UTF-8 or UTF-32 string, the values of two consecutive encoding sequences formed a valid UTF-16 surrogate pair.
This error is masked if 0 != (4 & m_error_mask). If the error is masked, then the surrogate pair is decoded, the value of the resulting unicode code point is used, and parsing continues. 8: An overlong UTF-8 encoding sequence was encountered and the value of the overlong sUTF-8 sequence was a valid unicode code point.
This error is masked if 0 != (8 & m_error_mask). If the error is masked, then the unicode code point is used and parsing continues. 16: An illegal UTF-8, UTF-16 or UTF-32 encoding sequence occurred or an invalid unicode code point value resulted from decoding a UTF-8 sequence. This error is masked if 0 != (16 & m_error_mask). If the error is masked and the value of error_code_point is a valid unicode code point, then error_code_point is encoded in the output string and parsing continues.
error_mask - [in] If 0 != (error_mask & 4), then type 4 errors are masked. If 0 != (error_mask & 8), then type 8 errors are masked. If 0 != (error_mask & 16) and error_code_point is a valid unicode code point value, then type 16 errors are masked.
error_code_point - [in] Unicode code point value to use in when masking type 16 errors. If 0 == (error_mask & 16), then this parameter is ignored. 0xFFFD is a popular choice for the error_code_point value.
end_element_index - [out] If end_element_index is not null, then *end_element_index is the index of the first element in sInputUTF that was not converted.
If an error occurred and was not masked, then *end_element_index is the index of the element of sInputUTF[] where the conversion failed.
If no errors occurred or all errors were masked, then end_element_index is the number of elements in sInputUTF[] that were converted.
Returns: A UTF-8 encoded std::string. The returned string does not have a byte order mark (BOM).
std::string ON_UTF_WideChar_to_std_string | ( | int | bTestByteOrder, |
const wchar_t * | sInputUTF, | ||
int | sInputUTF_count, | ||
unsigned int * | error_status, | ||
unsigned int | error_mask, | ||
ON__UINT32 | error_code_point, | ||
int * | end_element_index | ||
) |
Description: Convert a UTF-XX encoded wchar_t string to a UTF-8 encoded std:string. This function removes byte order marks (BOM) and can repair encoding errors.
The value of sizeof(wchar_t) determines which UTF-XX encoding is used. sizeof(wchar_t) UTF-XX 1 UTF-8 2 UTF-16 4 UTF-32
Parameters: bTestByteOrder - [in] If bTestByteOrder is true and the the input buffer is a byte order mark (BOM), then the BOM is skipped. It the value of the BOM is byte swapped, then subsequent input elements are byte swapped before being decoded. Specifically:
sInputUTF - [in] UTF-XX encoded wchar_t string to convert.
sInputUTF_count - [in] If sInputUTF_count >= 0, then it specifies the number of elements in sInputUTF[] to convert.
If sInputUTF_count == -1, then sInputUTF must be a zero terminated array and all the elements up to the first zero element are converted.
error_status - [out] If error_status is not null, then bits of *error_status are set to indicate the success or failure of the conversion.
When the error_mask parameter is used to used to mask some conversion errors, multiple bits may be set. 0: Successful conversion with no errors. 1: The input parameters were invalid. This error cannot be masked. 2: The output buffer was not large enough to hold the converted string. As much conversion as possible is performed in this case and the error cannot be masked. 4: When parsing a UTF-8 or UTF-32 string, the values of two consecutive encoding sequences formed a valid UTF-16 surrogate pair.
This error is masked if 0 != (4 & m_error_mask). If the error is masked, then the surrogate pair is decoded, the value of the resulting unicode code point is used, and parsing continues. 8: An overlong UTF-8 encoding sequence was encountered and the value of the overlong sUTF-8 sequence was a valid unicode code point.
This error is masked if 0 != (8 & m_error_mask). If the error is masked, then the unicode code point is used and parsing continues. 16: An illegal UTF-8, UTF-16 or UTF-32 encoding sequence occurred or an invalid unicode code point value resulted from decoding a UTF-8 sequence. This error is masked if 0 != (16 & m_error_mask). If the error is masked and the value of error_code_point is a valid unicode code point, then error_code_point is encoded in the output string and parsing continues.
error_mask - [in] If 0 != (error_mask & 4), then type 4 errors are masked. If 0 != (error_mask & 8), then type 8 errors are masked. If 0 != (error_mask & 16) and error_code_point is a valid unicode code point value, then type 16 errors are masked.
error_code_point - [in] Unicode code point value to use in when masking type 16 errors. If 0 == (error_mask & 16), then this parameter is ignored. 0xFFFD is a popular choice for the error_code_point value.
end_element_index - [out] If end_element_index is not null, then *end_element_index is the index of the first element in sInputUTF that was not converted.
If an error occurred and was not masked, then *end_element_index is the index of the element of sInputUTF[] where the conversion failed.
If no errors occurred or all errors were masked, then end_element_index is the number of elements in sInputUTF[] that were converted.
Returns: A UTF-8 encoded std::string. The returned string does not have a byte order mark (BOM).
std::wstring ON_UTF_WideChar_to_std_wstring | ( | int | bTestByteOrder, |
const wchar_t * | sInputUTF, | ||
int | sInputUTF_count, | ||
unsigned int * | error_status, | ||
unsigned int | error_mask, | ||
ON__UINT32 | error_code_point, | ||
int * | end_element_index | ||
) |
Description: Convert a UTF-XX encoded wchar_t string to a UTF-XX encoded std::wstring. This function removes byte order marks (BOM) and can repair encoding errors.
The value of sizeof(wchar_t) determines which UTF-XX encoding is used. sizeof(wchar_t) UTF-XX 1 UTF-8 2 UTF-16 4 UTF-32
Parameters: bTestByteOrder - [in] If bTestByteOrder is true and the the input buffer is a byte order mark (BOM), then the BOM is skipped. It the value of the BOM is byte swapped, then subsequent input elements are byte swapped before being decoded. Specifically:
sInputUTF - [in] UTF-XX encoded wchar_t string to convert.
sInputUTF_count - [in] If sInputUTF_count >= 0, then it specifies the number of elements in sInputUTF[] to convert.
If sInputUTF_count == -1, then sInputUTF must be a zero terminated array and all the elements up to the first zero element are converted.
error_status - [out] If error_status is not null, then bits of *error_status are set to indicate the success or failure of the conversion.
When the error_mask parameter is used to used to mask some conversion errors, multiple bits may be set. 0: Successful conversion with no errors. 1: The input parameters were invalid. This error cannot be masked. 2: The output buffer was not large enough to hold the converted string. As much conversion as possible is performed in this case and the error cannot be masked. 4: When parsing a UTF-8 or UTF-32 string, the values of two consecutive encoding sequences formed a valid UTF-16 surrogate pair.
This error is masked if 0 != (4 & m_error_mask). If the error is masked, then the surrogate pair is decoded, the value of the resulting unicode code point is used, and parsing continues. 8: An overlong UTF-8 encoding sequence was encountered and the value of the overlong sUTF-8 sequence was a valid unicode code point.
This error is masked if 0 != (8 & m_error_mask). If the error is masked, then the unicode code point is used and parsing continues. 16: An illegal UTF-8, UTF-16 or UTF-32 encoding sequence occurred or an invalid unicode code point value resulted from decoding a UTF-8 sequence. This error is masked if 0 != (16 & m_error_mask). If the error is masked and the value of error_code_point is a valid unicode code point, then error_code_point is encoded in the output string and parsing continues.
error_mask - [in] If 0 != (error_mask & 4), then type 4 errors are masked. If 0 != (error_mask & 8), then type 8 errors are masked. If 0 != (error_mask & 16) and error_code_point is a valid unicode code point value, then type 16 errors are masked.
error_code_point - [in] Unicode code point value to use in when masking type 16 errors. If 0 == (error_mask & 16), then this parameter is ignored. 0xFFFD is a popular choice for the error_code_point value.
end_element_index - [out] If end_element_index is not null, then *end_element_index is the index of the first element in sInputUTF that was not converted.
If an error occurred and was not masked, then *end_element_index is the index of the element of sInputUTF[] where the conversion failed.
If no errors occurred or all errors were masked, then end_element_index is the number of elements in sInputUTF[] that were converted.
Returns: A UTF-XX encoded std::wstring. The returned string does not have a byte order mark (BOM).
ON_DECL unsigned int ON_UTFSizeofByteOrderMark | ( | enum ON_UnicodeEncoding | e | ) |
Parameters: e - [in] Returns: Number of bytes in byte order mark for the specified encoding.
Description: ON_UuidCompare(a,b) compares two uuids. Parameters: a - [in] b - [in] Returns: @untitled table -1 a < b 0 a == b +1 a > b
Description: ON_UuidCompare(&a,&b) compares two uuids. Parameters: a - [in] b - [in] Returns: @untitled table -1 a < b 0 a == b +1 a > b Remarks: A nullptr pointer is considered < a non-nullptr pointer.
Description: Converts a string like "{85A08515-f383-11d3-BFE7-0010830122F0}" into a uuid. The brackets are optional and are ignored. Hyphens can appear anywhere or be missing. The hex digits can be upper or lower case. Parameters: s - [in] Returns: uuid.
If the string is not a uuid, then ON_nil_uuid is returned.
Description: Converts a string like "{85A08515-f383-11d3-BFE7-0010830122F0}" into a uuid. The brackets are optional and are ignored. Hyphens can appear anywhere or be missing. The hex digits can be upper or lower case. Parameters: s - [in] Returns: uuid.
If the string is not a uuid, then ON_nil_uuid is returned.
Description: Test uuid to see if it is nil (identically zero). Parameters: uuid - [in] Returns: true if uuid is nil.
Description: Test uuid to see if it is not nil (not identically zero). Parameters: uuid - [in] Returns: true if uuid is not nil (non zero)
Description: Converts a uuid to a null terminated ASCII string like "85a08515-f383-11d3-bfe7-0010830122f0". Parameters: uuid - [in] s - [out] The s[] char array must have length >= 37.
The returned char array will have a 36 character uuid in s[0..35] and a null in s[36]. Returns: The pointer to the array is returned.
Description: Converts a uuid to a null terminated string like "85a08515-f383-11d3-bfe7-0010830122f0". Parameters: uuid - [in] s - [out] Returns: The pointer to the array is returned.
const ON_DECL wchar_t* ON_UuidToString | ( | const ON_UUID & | uuid, |
ON_wString & | s | ||
) |
Description: Converts a uuid to a null terminated string like "85a08515-f383-11d3-bfe7-0010830122f0". Parameters: uuid - [in] s - [out] Returns: The pointer to the array is returned.
Description: Converts a uuid to a null terminated UNICODE string like "85a08515-f383-11d3-bfe7-0010830122f0". Parameters: uuid - [in] s - [out] The s[] wchar_t array must have length >= 37.
The returned char array will have a 36 character uuid in s[0..35] and a null in s[36]. Returns: The pointer to the array is returned.
ON_DECL bool ON_ValidateBrepLoops | ( | const ON_Brep & | B, |
ON_SimpleArray< int > * | loop_ids = 0 |
||
) |
Look for self-intersecting boundaries. Currently limited to slits and improper links between what should be an outer and inner boundary. If loop_ids == 0, returns as soon as a bad loop is found. Otherwise, the ids of all bad loops will end up on loop_ids True if no bad boundary is found
ON_DECL bool ON_ValidateCurveCVSpacing | ( | const ON_NurbsCurve & | crv, |
double | close_tol, | ||
double | stack_tol, | ||
ON_SimpleArray< int > & | close_ids, | ||
ON_SimpleArray< int > & | stacked_ids, | ||
double & | chord_length | ||
) |
chord_length | of control polygon |
ON_DECL bool ON_ValidateCurveSet | ( | const ON_SimpleArray< const ON_Curve * > & | Crvs, |
double | close_dist_tol, | ||
double | good_dist_tol, | ||
double | close_kink_tol, | ||
double | good_kink_tol, | ||
double | close_curvature_tol, | ||
double | good_curvature_tol, | ||
ON_SimpleArray< ON_2dex > & | overlap_problems, | ||
ON_SimpleArray< ON_Interval > & | overlap_subdoms, | ||
ON_SimpleArray< ON_4dex > & | g0_problems, | ||
ON_SimpleArray< ON_4dex > & | g1_problems, | ||
ON_SimpleArray< ON_4dex > & | g2_problems | ||
) |
overlap_subdoms | For Crvs[overlap_problems[n].i] |
ON_DECL bool ON_ValidateEdgeTrims | ( | const ON_Brep & | brep, |
int | edge_index, | ||
ON_TextLog * | text_log, | ||
ON_BrepTrimPoint * | bad_tp, | ||
int * | bad_eti, | ||
double * | deviation | ||
) |
Description: Does extensive tests of an edge and all of its trims to insure the edge and trims define the same 3d curve to a tolerance. Parameters: brep - [in] edge_index - [in] text_log - [in] bad_tp - [out] If not null and false is returned, then bad_tp->t and bad_tp->e will identify trim and edge parameters near the area where the two have parameterization problems. bad_eti - [out] If not null and false is returned, then *bad_eti will be the edge.m_ti[] index of the trim whose correspondence with the edge has parameterization problems. deviation - [out] If not null, then deviation[] should have length edge.m_ti.Count(). If true is returned, then the value of deviation[i] will be the maximum detected 3d deviation between the trim with index edge.m_ti[i] and the edge. Returns: True if the edge and trims have is valid parameterizations.
ON_DECL bool ON_ValidateNurbsSurfacePole | ( | const ON_NurbsSurface & | srf, |
int | side, | ||
double | tolerance, | ||
ON_3dPoint * | pAvgPole | ||
) |
If srf.IsSingular(side) == false, check control points along srf's side. If all are within tolerance, but not equal, return false. Otherwise, return true.
Note: If side is invalid, or if it does not make sense for srf to have a pole along side, this will return true.
side | 0-3, SENW same as O_Surface::IsSingular() |
pAvgPole | if not nullptr on input, and return is true, result will have the average location of the cv's along the side. |
ON_DECL bool ON_ValidateSurfaceCVSpacing | ( | const ON_NurbsSurface & | srf, |
double | close_tol, | ||
double | stack_tol, | ||
ON_SimpleArray< ON_2dex > & | close_ids, | ||
ON_SimpleArray< ON_2dex > & | stacked_ids | ||
) |
Simple check of the distance between adjacent surface cvs. If stack_tol < ON_ZERO_TOLERANCE, ON_ZERO_TOLERANCE will be used. If close_tol <= stack_tol, only stacked_ids will be filled in. Cvs at poles will not be considered close or stacked to other cvs at the same pole. Output lists will be sorted by u then v.
ON_DECL bool ON_ValidateSurfaceSeam | ( | const ON_Surface & | srf, |
int | dir, | ||
double | dist_tol, | ||
double | angle_tol, | ||
bool & | bIsCloseG1 | ||
) |
ON_DECL unsigned int ON_VersionNumberConstruct | ( | unsigned int | major_version, |
unsigned int | minor_version, | ||
unsigned int | year, | ||
unsigned int | month, | ||
unsigned int | day_of_month, | ||
unsigned int | platform_branch | ||
) |
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org. Description: Create a 4-byte unsigned integer value that has desirable version number properties.
Parameters: major_version - [in] major_version >= 0 and major_version <= 63
minor_version - [in] minor_version >= 0 and minor_version <= 127
year - [in] year >= 2000 and year <= 2099
month - [in] month >= 1 and month <= 12
day_of_month - [in] day_of_month >= 1 and day_of_month <= ON_DaysInMonthOfGregorianYear(year,month)
platform_branch - [in] 0: developer build 1: Windows Commercial build 2: Mac Commercial build 3: Windows BETA build 4: Mac Beta build 5: Windows WIP build 6: Mac WIP build
Returns: If the input values are valid, this returns a 4-byte nonzero version number with the following properties: verA = ON_VersionNumberConstruct(majorA,minorA,<timeA>,branchA) verB = ON_VersionNumberConstruct(majorB,minorB,<timeB>,branchB)
ON_DECL unsigned int ON_VersionNumberFromYearMonthDateFormat | ( | unsigned int | major_version, |
unsigned int | yyyy_mm_dd_n_version_number | ||
) |
Parameters: major_version - [in] >= 0 and < 64 Returns: The smallest possible non-zero version number ON_VersionNumberConstruct() will create for a specified major version with valid input.
ON_DECL bool ON_VersionNumberIsValid | ( | unsigned int | version_number | ) |
Returns: True if the version_number is a value created by ON_VersionNumberConstruct(). Parameters: version_number - [in]
ON_DECL bool ON_VersionNumberIsYearMonthDateFormat | ( | unsigned int | archive_3dm_version, |
unsigned int | version_number | ||
) |
Parameters: archive_3dm_version - [in] If the context of the query is a version number from an ON_BinaryArchive, then pass the value of ON_BinaryArchive.Archive3dmVersion() here. version_number - [in] version number to test. Returns: True if the version number is in the YYYYMMDDn format used by version 1,2,3,4,5 of opennurbs and the Rhino SDK.
ON_DECL unsigned int ON_VersionNumberMinimum | ( | unsigned int | major_version | ) |
Parameters: major_version - [in] major_version >= 0 and major_version <= 63
Returns: The smallest possible non-zero version number ON_VersionNumberConstruct() will create for a specified major version with valid input.
ON_DECL bool ON_VersionNumberParse | ( | unsigned int | version_number, |
unsigned int * | version_major, | ||
unsigned int * | version_minor, | ||
unsigned int * | version_year, | ||
unsigned int * | version_month, | ||
unsigned int * | version_day_of_month, | ||
unsigned int * | version_branch | ||
) |
Description: Parse a version number created by ON_VersionNumberConstruct() to recover the input parameters. Parameters: version_number - [in] A version number created with ON_VersionNumberConstruct().
version_major - [out] version_major >= 0 and version_major <= 63
version_minor - [out] version_minor >= 0 and version_minor <= 127
version_year - [out] version_year >= 2000 and version_year <= 2099
version_month - [out] version_month >= 1 and version_month <= 12
version_day_of_month - [out] version_day_of_month >= 1 and version_day_of_month <= ON_DaysInMonthOfGregorianYear(year,month)
version_branch - [out] version_branch >= 0 and version_branch <= 3 0: developer build 1: build system trunk branch build 2: build system release candidate build 3: build system release build
Remarks: Any output parameter pointer may be null if you do not want that information.
Returns: true: The version_number parameter is a valid version number. All output parameters are set. false: The version_number parameter is not a valid version number. All output parameters are set to zero.
const ON_DECL ON_String ON_VersionNumberToString | ( | unsigned int | version_number, |
bool | bUnsignedFormat, | ||
bool | bDateFormat | ||
) |
const ON_DECL ON_wString ON_VersionNumberToWideString | ( | unsigned int | version_number, |
bool | bUnsignedFormat, | ||
bool | bDateFormat | ||
) |
ON_DECL bool ON_ViewportFromRhinoView | ( | ON::view_projection | , |
const ON_3dPoint & | , | ||
double | , | ||
double | , | ||
double | , | ||
double | , | ||
double | , | ||
int | , | ||
int | , | ||
ON_Viewport & | |||
) |
ON_DECL double ON_VoronoiArea2d | ( | const ON_2dPoint & | p0, |
const ON_2dPoint & | p1, | ||
const ON_2dPoint & | p2 | ||
) |
Compute the Voronoi area contribution of a 2d triangle.
p0 | |
p1 | |
p2 |
ON_DECL double ON_VoronoiArea3d | ( | const ON_3dPoint & | p0, |
const ON_3dPoint & | p1, | ||
const ON_3dPoint & | p2 | ||
) |
Compute the Voronoi area contribution of a 3d triangle.
p0 | |
p1 | |
p2 |
ON_DECL void ON_VARGS_FUNC_CDECL ON_Warning | ( | const char * | file_name, |
int | line_number, | ||
const char * | format, | ||
... | |||
) |
ON_DECL void ON_VARGS_FUNC_CDECL ON_WarningEx | ( | const char * | file_name, |
int | line_number, | ||
const char * | function_name, | ||
const char * | format, | ||
... | |||
) |
ON_BEGIN_EXTERNC ON_DECL int on_wcsicmp | ( | const wchar_t * | , |
const wchar_t * | |||
) |
on_wcsicmp() is a wrapper for case insensitive wide string compare and calls one of _wcsicmp() or wcscasecmp() depending on OS.
ON_DECL wchar_t* on_wcslwr | ( | wchar_t * | ) |
on_wcslwr() calls _wcslwr() or wcslwr() depending on OS
ON_DECL wchar_t* on_wcsrev | ( | wchar_t * | ) |
on_wcsrev() calls _wcsrev() or wcsrev() depending on OS
ON_DECL wchar_t* on_wcsupr | ( | wchar_t * | ) |
on_wcsupr() calls _wcsupr() or wcsupr() depending on OS
ON_DECL double ON_WedgeProduct | ( | const ON_2dVector & | A, |
const ON_2dVector & | B | ||
) |
A | signed area of the parallelogram. Volume element. returns A.x * B.y - A.y * B.x |
ON_DECL int on_WideCharToMultiByte | ( | const wchar_t * | , |
int | , | ||
char * | , | ||
int | |||
) |
Description: Calls ON_ConvertWideCharToUTF8()
ON_DECL ON__UINT64 ON_WorkerThreadContextSerialNumber | ( | ) |
Returns: 0: No worker thread context is set. >0: Serial number of the worker thread context.
ON_DECL ON__UINT64 ON_WorkerThreadEnableTerminateRequest | ( | ) |
Description: If a worker thread context is active, then every subsequent memory allocation will call the fTerminateThreadFunction function passed to ON_SetWorkerThreadContext(). Returns: 0: No worker thread context is set. 0>: Serial number of the worker thread context with a pending terminate request.
ON_DECL ON__UINT64 ON_WorkerThreadTerminateRequestStatus | ( | ) |
Returns: 0: No pending terminate request. >0: Serial number of the worker thread context with a pending terminate request.
ON_DECL bool ON_WorldBBoxIsInTightBBox | ( | const ON_BoundingBox & | tight_bbox, |
const ON_BoundingBox & | world_bbox, | ||
const ON_Xform * | xform | ||
) |
bool ON_WriteMultipleObjectArchive | ( | const wchar_t * | filename, |
int | version, | ||
size_t | object_list_count, | ||
const ON_Object *const * | object_list | ||
) |
ON_DECL bool ON_WriteMultipleObjectArchive | ( | ON_BinaryArchive & | archive, |
int | version, | ||
const ON_SimpleArray< const ON_Object * > & | object_list | ||
) |
ON_DECL bool ON_WriteMultipleObjectArchive | ( | ON_BinaryArchive & | archive, |
int | version, | ||
size_t | object_list_count, | ||
const ON_Object *const * | object_list | ||
) |
ON_DECL bool ON_WriteOneObjectArchive | ( | ON_BinaryArchive & | archive, |
int | version, | ||
const ON_Object & | object | ||
) |
Description: Create a simple archive that contains a single or multiple geometric object(s). Parameters: archive - [in] destination archive. version - in format version.archive version number. Version 2 format can be read by Rhino 2 and Rhino 3. Version 3 format can be read by Rhino 3. Pass 0 or ON_BinaryArchive::CurrentArchiveVersion() to write the latest version of archives supported by Rhino. object - [in] object to be saved in the archive's object table. This is typically some type of ON_Curve, ON_Surface, ON_Mesh, or ON_Brep. object_list - [in] objects to be saved in the archive's object table. These are typically some type of ON_Curve, ON_Surface, ON_Mesh, or ON_Brep. object_list_count - [in] explicit count of number of objects in object_list. Returns: @untitled table true archive successfully written. false archive not successfully written. Example:
const char* filename = "myfile.3dm"; FILE* fp = ON::OpenFile( filename, "wb" ); ON_BinaryFile file( fp, ON::archive_mode::write3dm ); bool ok = ON_WriteArchive( archive, geometry ); ON::CloseFile( fp );
Remarks: For ON_WriteOneObjectArchive the object table in the archive will contain a single object.
ON_DECL void on_wsplitpath | ( | const wchar_t * | path, |
const wchar_t ** | volume, | ||
const wchar_t ** | dir, | ||
const wchar_t ** | fname, | ||
const wchar_t ** | ext | ||
) |
Description: Find the locations in a path the specify the drive, directory, file name and file extension. Parameters: path - [in] A legitimate file system path to a file. volume - [out] (pass null if you don't need the volume) If volume is not null and the path parameter begins with a Windows volum specification, the value of *volume will equal the input value of path. Otherwise *volume will be nullptr.
A Windows volume specification can be either a single A-Z or a-z letter followed by a colon ( C: ) or a Windows UNC host name (\MY_SERVER). dir - [out] (pass null if you don't need the directory) If dir is not null and the path parameter contains a directory specification, then the returned value of *dir will point to the character in path where the directory specification begins. fname - [out] (pass null if you don't need the file name) If fname is not null and the path parameter contains a file name specification, then the returned value of *fname will point to the character in path where the file name specification begins. ext - [out] (pass null if you don't need the extension) If ext is not null and the path parameter contains a file extension specification, then the returned value of ext will point to the '.' character in path where the file extension specification begins. Remarks: This function will treat a front slash ( / ) and a back slash ( \ ) as directory separators. Because this function parses file names store in .3dm files and the .3dm file may have been written on a Windows computer and then read on a another computer, it looks for a volume specification even when the operating system is not Windows. This function will not return an directory that does not end with a trailing slash. This function will not return an empty filename and a non-empty extension. This function parses the path string according to these rules. It does not check the actual file system to see if the answer is correct. See Also: ON_wString::SplitPath
ON_DECL void* oncalloc | ( | size_t | , |
size_t | |||
) |
ON_DECL void onfree | ( | void * | ) |
ON_DECL void* onmalloc | ( | size_t | ) |
ON_DECL void* onmalloc_forever | ( | size_t | ) |
Allocate memory that is intentionally never returned should not be considered a memory leak. Typically this is for an application workspace.
ON_DECL unsigned char* onmbsdup | ( | const unsigned char * | ) |
ON_DECL void* onmemdup | ( | const void * | , |
size_t | |||
) |
ON_DECL void* onrealloc | ( | void * | , |
size_t | |||
) |
ON_DECL char* onstrdup | ( | const char * | ) |
ON_DECL wchar_t* onwcsdup | ( | const wchar_t * | ) |
ON_SimpleArray< T >::operator const T * |
to the array. If Count() is zero, this pointer is nullptr.
ON_ClassArray< T >::operator const T * |
to the array. If Count() is zero, this pointer is nullptr.
ON_SimpleArray< T >::operator T* |
The cast operators return a pointer.
ON_ClassArray< T >::operator T* |
The cast operators return a pointer.
Returns: True if lhs and rhs are not identical as arrays of char elements.
ON_DECL bool operator!= | ( | const class ON_ParseSettings & | a, |
const class ON_ParseSettings & | b | ||
) |
Descriptions: result true if a and b are not identical.
bool operator!= | ( | const class ON_TextMask & | lhs, |
const class ON_TextMask & | rhs | ||
) |
ON_DECL bool operator!= | ( | const ON_2iBoundingBox & | , |
const ON_2iBoundingBox & | |||
) |
ON_DECL bool operator!= | ( | const ON_2iPoint & | , |
const ON_2iPoint & | |||
) |
ON_DECL bool operator!= | ( | const ON_2iVector & | , |
const ON_2iVector & | |||
) |
ON_DECL bool operator!= | ( | const ON_AngleUnitName & | a, |
const ON_AngleUnitName & | b | ||
) |
ON_DECL bool operator!= | ( | const ON_BoundingBox & | lhs, |
const ON_BoundingBox & | rhs | ||
) |
Returns: True if lhs and rhs are not equal.
ON_DECL bool operator!= | ( | const ON_LengthUnitName & | a, |
const ON_LengthUnitName & | b | ||
) |
Returns: True if a and be are not identical. Remarks: If a nan is involved in every coordinate compare, the result will be false.
ON_DECL bool operator!= | ( | const ON_ManifestMapItem & | lhs, |
const ON_ManifestMapItem & | rhs | ||
) |
ON_DECL bool operator!= | ( | const ON_MappingTag & | lhs, |
const ON_MappingTag & | rhs | ||
) |
ON_DECL bool operator!= | ( | const ON_Material & | , |
const ON_Material & | |||
) |
ON_DECL bool operator!= | ( | const ON_MD5_Hash & | a, |
const ON_MD5_Hash & | b | ||
) |
ON_DECL bool operator!= | ( | const ON_MeshParameters & | a, |
const ON_MeshParameters & | b | ||
) |
bool operator!= | ( | const ON_ModelComponentContentMark & | lhs, |
const ON_ModelComponentContentMark & | rhs | ||
) |
ON_DECL bool operator!= | ( | const ON_NameHash & | a, |
const ON_NameHash & | b | ||
) |
Compares id, then length, then SHA-1 digest
ON_DECL bool operator!= | ( | const ON_SHA1_Hash & | a, |
const ON_SHA1_Hash & | b | ||
) |
Returns: True if lhs and rhs are not identical as arrays of char elements.
Returns: True if lhs and rhs are not identical as arrays of char elements.
ON_DECL bool operator!= | ( | const ON_SubDEdgeSharpness & | lhs, |
const ON_SubDEdgeSharpness & | rhs | ||
) |
bool operator!= | ( | const ON_SubDExpandEdgesParameters & | lhs, |
const ON_SubDExpandEdgesParameters & | rhs | ||
) |
ON_WIP_DECL bool operator!= | ( | const ON_SubDFaceParameter & | lhs, |
const ON_SubDFaceParameter & | rhs | ||
) |
bool operator!= | ( | const ON_SubDHash & | lhs, |
const ON_SubDHash & | rhs | ||
) |
bool operator!= | ( | const ON_SubDToBrepParameters & | lhs, |
const ON_SubDToBrepParameters & | rhs | ||
) |
ON_DECL bool operator!= | ( | const ON_SurfaceCurvature & | lhs, |
const ON_SurfaceCurvature & | rhs | ||
) |
lhs | |
rhs |
ON_DECL bool operator!= | ( | const ON_SurfaceCurvatureColorMapping & | lhs, |
const ON_SurfaceCurvatureColorMapping & | rhs | ||
) |
Returns true if some property of lhs and rhs is different and no double is a nan.
ON_DECL bool operator!= | ( | const ON_SurfaceDraftAngleColorMapping & | lhs, |
const ON_SurfaceDraftAngleColorMapping & | rhs | ||
) |
Returns true if some property of lhs and rhs is different and no double is a nan.
ON_DECL bool operator!= | ( | const ON_Triangle & | a, |
const ON_Triangle & | b | ||
) |
Returns: True if a and be are not identical. Remarks: If a nan is involved in every coordinate compare, the result will be false.
ON_DECL bool operator!= | ( | const ON_wString & | lhs, |
const ON_wString & | rhs | ||
) |
Returns: True if lhs and rhs are not identical as arrays of wchar_t elements.
ON_DECL bool operator!= | ( | const ON_wString & | lhs, |
const wchar_t * | rhs | ||
) |
Returns: True if lhs and rhs are not identical as arrays of wchar_t elements.
bool operator!= | ( | const struct ON_UUID_struct & | a, |
const struct ON_UUID_struct & | b | ||
) |
ON_DECL bool operator!= | ( | const wchar_t * | lhs, |
const ON_wString & | rhs | ||
) |
Returns: True if lhs and rhs are not identical as arrays of wchar_t elements.
ON_DECL bool operator!= | ( | ON_Big5CodePoint | lhs, |
ON_Big5CodePoint | rhs | ||
) |
ON_DECL bool operator!= | ( | ON_Big5UnicodePair | lhs, |
ON_Big5UnicodePair | rhs | ||
) |
ON_DECL bool operator!= | ( | ON_SubDComponentPtr | lhs, |
ON_SubDComponentPtr | rhs | ||
) |
ON_DECL bool operator!= | ( | ON_SubDEdgePtr | lhs, |
ON_SubDEdgePtr | rhs | ||
) |
ON_DECL bool operator!= | ( | ON_SubDFacePtr | lhs, |
ON_SubDFacePtr | rhs | ||
) |
ON_DECL bool operator!= | ( | ON_SubDSectorId | , |
ON_SubDSectorId | |||
) |
ON_DECL bool operator!= | ( | ON_SubDVertexPtr | lhs, |
ON_SubDVertexPtr | rhs | ||
) |
ON_DECL bool operator!= | ( | ON_UnicodeShortCodePoint | lhs, |
ON_UnicodeShortCodePoint | rhs | ||
) |
ON_DECL ON_ParseSettings operator&& | ( | const class ON_ParseSettings & | a, |
const class ON_ParseSettings & | b | ||
) |
Descriptions: result setting value = a setting value OR b setting value Returns: Logical OR of the parse settings in a and b.
const ON_DECL ON_PlaneEquation operator* | ( | const ON_Xform & | , |
const ON_PlaneEquation & | |||
) |
ON_DECL ON_2dPoint operator* | ( | double | , |
const ON_2dPoint & | |||
) |
ON_DECL ON_2dVector operator* | ( | double | , |
const ON_2dVector & | |||
) |
ON_DECL ON_2dPoint operator* | ( | double | , |
const ON_2fPoint & | |||
) |
ON_DECL ON_2dVector operator* | ( | double | , |
const ON_2fVector & | |||
) |
ON_DECL ON_3dPoint operator* | ( | double | , |
const ON_3dPoint & | |||
) |
ON_DECL ON_3dVector operator* | ( | double | , |
const ON_3dVector & | |||
) |
ON_DECL ON_3dPoint operator* | ( | double | , |
const ON_3fPoint & | |||
) |
ON_DECL ON_3dVector operator* | ( | double | , |
const ON_3fVector & | |||
) |
ON_DECL ON_4dPoint operator* | ( | double | , |
const ON_4dPoint & | |||
) |
ON_DECL ON_4dPoint operator* | ( | double | , |
const ON_4fPoint & | |||
) |
ON_DECL ON_Quaternion operator* | ( | double | , |
const ON_Quaternion & | |||
) |
ON_DECL ON_2dPoint operator* | ( | float | , |
const ON_2dPoint & | |||
) |
ON_DECL ON_2dVector operator* | ( | float | , |
const ON_2dVector & | |||
) |
ON_DECL ON_2fPoint operator* | ( | float | , |
const ON_2fPoint & | |||
) |
ON_DECL ON_2fVector operator* | ( | float | , |
const ON_2fVector & | |||
) |
ON_DECL ON_3dPoint operator* | ( | float | , |
const ON_3dPoint & | |||
) |
ON_DECL ON_3dVector operator* | ( | float | , |
const ON_3dVector & | |||
) |
ON_DECL ON_3fPoint operator* | ( | float | , |
const ON_3fPoint & | |||
) |
ON_DECL ON_3fVector operator* | ( | float | , |
const ON_3fVector & | |||
) |
ON_DECL ON_4fPoint operator* | ( | float | , |
const ON_4fPoint & | |||
) |
ON_DECL ON_Quaternion operator* | ( | float | , |
const ON_Quaternion & | |||
) |
ON_DECL ON_2dPoint operator* | ( | int | , |
const ON_2dPoint & | |||
) |
ON_DECL ON_2dVector operator* | ( | int | , |
const ON_2dVector & | |||
) |
ON_DECL ON_2fPoint operator* | ( | int | , |
const ON_2fPoint & | |||
) |
ON_DECL ON_2fVector operator* | ( | int | , |
const ON_2fVector & | |||
) |
ON_DECL ON_2iVector operator* | ( | int | , |
const ON_2iVector & | |||
) |
ON_DECL ON_3dPoint operator* | ( | int | , |
const ON_3dPoint & | |||
) |
ON_DECL ON_3dVector operator* | ( | int | , |
const ON_3dVector & | |||
) |
ON_DECL ON_3fPoint operator* | ( | int | , |
const ON_3fPoint & | |||
) |
ON_DECL ON_3fVector operator* | ( | int | , |
const ON_3fVector & | |||
) |
ON_DECL ON_Quaternion operator* | ( | int | , |
const ON_Quaternion & | |||
) |
ON_DECL ON_2iPoint operator+ | ( | const ON_2iPoint & | , |
const ON_2iVector & | |||
) |
ON_DECL ON_2iVector operator+ | ( | const ON_2iVector & | , |
const ON_2iVector & | |||
) |
ON_DECL ON_2iPoint operator- | ( | const ON_2iPoint & | , |
const ON_2iVector & | |||
) |
ON_DECL ON_2iVector operator- | ( | const ON_2iVector & | , |
const ON_2iVector & | |||
) |
Returns: True if lhs is less than rhs as an array of unsigned bytes.
ON_DECL bool operator< | ( | const ON_NameHash & | a, |
const ON_NameHash & | b | ||
) |
Compares id, then length, then SHA-1 digest
Returns: True if lhs is less than rhs as an array of unsigned bytes.
Returns: True if lhs is less than rhs as an array of unsigned bytes.
ON_DECL bool operator< | ( | const ON_wString & | lhs, |
const ON_wString & | rhs | ||
) |
Returns: True if lhs is less than rhs as an array of wchar_t elements.
ON_DECL bool operator< | ( | const ON_wString & | lhs, |
const wchar_t * | rhs | ||
) |
Returns: True if lhs is less than rhs as an array of wchar_t elements.
ON_DECL bool operator< | ( | const wchar_t * | lhs, |
const ON_wString & | rhs | ||
) |
Returns: True if lhs is less than rhs as an array of wchar_t elements.
ON_DECL bool operator< | ( | ON_Big5CodePoint | lhs, |
ON_Big5CodePoint | rhs | ||
) |
ON_DECL bool operator< | ( | ON_SubDSectorId | , |
ON_SubDSectorId | |||
) |
ON_DECL bool operator< | ( | ON_UnicodeShortCodePoint | lhs, |
ON_UnicodeShortCodePoint | rhs | ||
) |
Returns: True if lhs is less than or equal to rhs as an array of unsigned bytes.
ON_DECL bool operator<= | ( | const ON_NameHash & | a, |
const ON_NameHash & | b | ||
) |
Compares id, then length, then SHA-1 digest
Returns: True if lhs is less than or equal to rhs as an array of unsigned bytes.
Returns: True if lhs is less than or equal to rhs as an array of unsigned bytes.
ON_DECL bool operator<= | ( | const ON_wString & | lhs, |
const ON_wString & | rhs | ||
) |
Returns: True if lhs is less than or equal to rhs as an array of wchar_t elements.
ON_DECL bool operator<= | ( | const ON_wString & | lhs, |
const wchar_t * | rhs | ||
) |
Returns: True if lhs is less than or equal to rhs as an array of wchar_t elements.
ON_DECL bool operator<= | ( | const wchar_t * | lhs, |
const ON_wString & | rhs | ||
) |
Returns: True if lhs is less than or equal to rhs as an array of wchar_t elements.
ON_DECL bool operator<= | ( | ON_Big5CodePoint | lhs, |
ON_Big5CodePoint | rhs | ||
) |
ON_DECL bool operator<= | ( | ON_SubDSectorId | , |
ON_SubDSectorId | |||
) |
ON_DECL bool operator<= | ( | ON_UnicodeShortCodePoint | lhs, |
ON_UnicodeShortCodePoint | rhs | ||
) |
ON_ClassArray< T > & ON_ClassArray< T >::operator= | ( | const ON_ClassArray< T > & | src | ) |
Assignment operator.
ON_ObjectArray< T > & ON_ObjectArray< T >::operator= | ( | const ON_ObjectArray< T > & | src | ) |
ON_SimpleArray< T > & ON_SimpleArray< T >::operator= | ( | const ON_SimpleArray< T > & | src | ) |
Returns: True if lhs and rhs are identical as arrays of char elements.
ON_DECL bool operator== | ( | const class ON_ParseSettings & | a, |
const class ON_ParseSettings & | b | ||
) |
Descriptions: result true if a and b are identical.
bool operator== | ( | const class ON_TextMask & | lhs, |
const class ON_TextMask & | rhs | ||
) |
ON_DECL bool operator== | ( | const ON_2iBoundingBox & | , |
const ON_2iBoundingBox & | |||
) |
ON_DECL bool operator== | ( | const ON_2iPoint & | , |
const ON_2iPoint & | |||
) |
ON_DECL bool operator== | ( | const ON_2iVector & | , |
const ON_2iVector & | |||
) |
ON_DECL bool operator== | ( | const ON_AngleUnitName & | a, |
const ON_AngleUnitName & | b | ||
) |
ON_DECL bool operator== | ( | const ON_BoundingBox & | lhs, |
const ON_BoundingBox & | rhs | ||
) |
Returns: True if lhs and rhs are identical.
ON_DECL bool operator== | ( | const ON_LengthUnitName & | a, |
const ON_LengthUnitName & | b | ||
) |
Returns: True if a and be are identical and no coordinate is a nan.
ON_DECL bool operator== | ( | const ON_ManifestMapItem & | lhs, |
const ON_ManifestMapItem & | rhs | ||
) |
ON_DECL bool operator== | ( | const ON_MappingTag & | lhs, |
const ON_MappingTag & | rhs | ||
) |
ON_DECL bool operator== | ( | const ON_Material & | , |
const ON_Material & | |||
) |
ON_DECL bool operator== | ( | const ON_MD5_Hash & | a, |
const ON_MD5_Hash & | b | ||
) |
ON_DECL bool operator== | ( | const ON_MeshParameters & | a, |
const ON_MeshParameters & | b | ||
) |
bool operator== | ( | const ON_ModelComponentContentMark & | lhs, |
const ON_ModelComponentContentMark & | rhs | ||
) |
ON_DECL bool operator== | ( | const ON_NameHash & | a, |
const ON_NameHash & | b | ||
) |
Compares id, then length, then SHA-1 digest
ON_DECL bool operator== | ( | const ON_SHA1_Hash & | a, |
const ON_SHA1_Hash & | b | ||
) |
Returns: True if lhs and rhs are identical as arrays of char elements.
Returns: True if lhs and rhs are identical as arrays of char elements.
ON_DECL bool operator== | ( | const ON_SubDEdgeSharpness & | lhs, |
const ON_SubDEdgeSharpness & | rhs | ||
) |
bool operator== | ( | const ON_SubDExpandEdgesParameters & | lhs, |
const ON_SubDExpandEdgesParameters & | rhs | ||
) |
ON_WIP_DECL bool operator== | ( | const ON_SubDFaceParameter & | lhs, |
const ON_SubDFaceParameter & | rhs | ||
) |
bool operator== | ( | const ON_SubDHash & | lhs, |
const ON_SubDHash & | rhs | ||
) |
bool operator== | ( | const ON_SubDToBrepParameters & | lhs, |
const ON_SubDToBrepParameters & | rhs | ||
) |
ON_DECL bool operator== | ( | const ON_SurfaceCurvature & | lhs, |
const ON_SurfaceCurvature & | rhs | ||
) |
lhs | |
rhs |
ON_DECL bool operator== | ( | const ON_SurfaceCurvatureColorMapping & | lhs, |
const ON_SurfaceCurvatureColorMapping & | rhs | ||
) |
Returns true if all properties of lhs and rhs are identical and no double is a nan.
ON_DECL bool operator== | ( | const ON_SurfaceDraftAngleColorMapping & | lhs, |
const ON_SurfaceDraftAngleColorMapping & | rhs | ||
) |
Returns true if all properties of lhs and rhs are identical and no double is a nan.
ON_DECL bool operator== | ( | const ON_Triangle & | a, |
const ON_Triangle & | b | ||
) |
Returns: True if a and be are identical and no coordinate is a nan.
ON_DECL bool operator== | ( | const ON_wString & | lhs, |
const ON_wString & | rhs | ||
) |
Returns: True if lhs and rhs are identical as arrays of wchar_t elements.
ON_DECL bool operator== | ( | const ON_wString & | lhs, |
const wchar_t * | rhs | ||
) |
Returns: True if lhs and rhs are identical as arrays of wchar_t elements.
bool operator== | ( | const struct ON_UUID_struct & | a, |
const struct ON_UUID_struct & | b | ||
) |
basic C++ declarations
/ / Copyright (c) 1993-2015 Robert McNeel & Associates. All rights reserved. / OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert / McNeel & Associates. / / THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. / ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF / MERCHANTABILITY ARE HEREBY DISCLAIMED. /
/ For complete openNURBS copyright information see http://www.opennurbs.org. / ////////////////////////////////////////////////////////////// basic C++ declarations
ON_DECL bool operator== | ( | const wchar_t * | lhs, |
const ON_wString & | rhs | ||
) |
Returns: True if lhs and rhs are identical as arrays of wchar_t elements.
ON_DECL bool operator== | ( | ON_Big5CodePoint | lhs, |
ON_Big5CodePoint | rhs | ||
) |
ON_DECL bool operator== | ( | ON_Big5UnicodePair | lhs, |
ON_Big5UnicodePair | rhs | ||
) |
ON_DECL bool operator== | ( | ON_SubDComponentPtr | lhs, |
ON_SubDComponentPtr | rhs | ||
) |
ON_DECL bool operator== | ( | ON_SubDEdgePtr | lhs, |
ON_SubDEdgePtr | rhs | ||
) |
ON_DECL bool operator== | ( | ON_SubDFacePtr | lhs, |
ON_SubDFacePtr | rhs | ||
) |
ON_DECL bool operator== | ( | ON_SubDSectorId | , |
ON_SubDSectorId | |||
) |
ON_DECL bool operator== | ( | ON_SubDVertexPtr | lhs, |
ON_SubDVertexPtr | rhs | ||
) |
ON_DECL bool operator== | ( | ON_UnicodeShortCodePoint | lhs, |
ON_UnicodeShortCodePoint | rhs | ||
) |
Returns: True if lhs is greater than rhs as an array of unsigned bytes.
ON_DECL bool operator> | ( | const ON_NameHash & | a, |
const ON_NameHash & | b | ||
) |
Compares id, then length, then SHA-1 digest
Returns: True if lhs is greater than rhs as an array of unsigned bytes.
Returns: True if lhs is greater than rhs as an array of unsigned bytes.
ON_DECL bool operator> | ( | const ON_wString & | lhs, |
const ON_wString & | rhs | ||
) |
Returns: True if lhs is greater than rhs as an array of wchar_t elements.
ON_DECL bool operator> | ( | const ON_wString & | lhs, |
const wchar_t * | rhs | ||
) |
Returns: True if lhs is greater than rhs as an array of wchar_t elements.
ON_DECL bool operator> | ( | const wchar_t * | lhs, |
const ON_wString & | rhs | ||
) |
Returns: True if lhs is greater than rhs as an array of wchar_t elements.
ON_DECL bool operator> | ( | ON_Big5CodePoint | lhs, |
ON_Big5CodePoint | rhs | ||
) |
ON_DECL bool operator> | ( | ON_SubDSectorId | , |
ON_SubDSectorId | |||
) |
ON_DECL bool operator> | ( | ON_UnicodeShortCodePoint | lhs, |
ON_UnicodeShortCodePoint | rhs | ||
) |
Returns: True if lhs is greater than or equal to rhs as an array of unsigned bytes.
ON_DECL bool operator>= | ( | const ON_NameHash & | a, |
const ON_NameHash & | b | ||
) |
Compares id, then length, then SHA-1 digest
Returns: True if lhs is greater than or equal to rhs as an array of unsigned bytes.
Returns: True if lhs is greater than or equal to rhs as an array of unsigned bytes.
ON_DECL bool operator>= | ( | const ON_wString & | lhs, |
const ON_wString & | rhs | ||
) |
Returns: True if lhs is greater than or equal to rhs as an array of wchar_t elements.
ON_DECL bool operator>= | ( | const ON_wString & | lhs, |
const wchar_t * | rhs | ||
) |
Returns: True if lhs is greater than or equal to rhs as an array of wchar_t elements.
ON_DECL bool operator>= | ( | const wchar_t * | lhs, |
const ON_wString & | rhs | ||
) |
Returns: True if lhs is greater than or equal to rhs as an array of wchar_t elements.
ON_DECL bool operator>= | ( | ON_Big5CodePoint | lhs, |
ON_Big5CodePoint | rhs | ||
) |
ON_DECL bool operator>= | ( | ON_SubDSectorId | , |
ON_SubDSectorId | |||
) |
ON_DECL bool operator>= | ( | ON_UnicodeShortCodePoint | lhs, |
ON_UnicodeShortCodePoint | rhs | ||
) |
T & ON_SimpleArray< T >::operator[] | ( | int | i | ) |
The operator[] does to not check for valid indices. The caller is responsible for insuring that 0 <= i < Capacity()
T & ON_ClassArray< T >::operator[] | ( | int | i | ) |
The operator[] does to not check for valid indices. The caller is responsible for insuring that 0 <= i < Capacity()
const T & ON_SimpleArray< T >::operator[] | ( | int | i | ) | const |
const T & ON_ClassArray< T >::operator[] | ( | int | i | ) | const |
T & ON_SimpleArray< T >::operator[] | ( | ON__INT64 | i | ) |
T & ON_ClassArray< T >::operator[] | ( | ON__INT64 | i | ) |
const T & ON_SimpleArray< T >::operator[] | ( | ON__INT64 | i | ) | const |
const T & ON_ClassArray< T >::operator[] | ( | ON__INT64 | i | ) | const |
T & ON_SimpleArray< T >::operator[] | ( | ON__UINT64 | i | ) |
T & ON_ClassArray< T >::operator[] | ( | ON__UINT64 | i | ) |
const T & ON_SimpleArray< T >::operator[] | ( | ON__UINT64 | i | ) | const |
const T & ON_ClassArray< T >::operator[] | ( | ON__UINT64 | i | ) | const |
T & ON_SimpleArray< T >::operator[] | ( | unsigned int | i | ) |
T & ON_ClassArray< T >::operator[] | ( | unsigned int | i | ) |
const T & ON_SimpleArray< T >::operator[] | ( | unsigned int | i | ) | const |
const T & ON_ClassArray< T >::operator[] | ( | unsigned int | i | ) | const |
ON_DECL ON_ParseSettings operator|| | ( | const class ON_ParseSettings & | a, |
const class ON_ParseSettings & | b | ||
) |
Descriptions: result setting value = a setting value AND b setting value Returns: Logical AND of the parse settings in a and b.
bool ON_SimpleArray< T >::Permute | ( | const int * | index | ) |
Permutes the array so that output[i] = input[index[i]]. The index[] array should be a permutation of (0,...,Count()-1).
< must use memcopy and not operator=
bool ON_ClassArray< T >::Permute | ( | const int * | index | ) |
Permutes the array so that output[i] = input[index[i]]. The index[] array should be a permutation of (0,...,Count()-1).
< must use memcopy and not operator=
void ON_SimpleArray< T >::Prepend | ( | int | count, |
const T * | buffer | ||
) |
Prepend copy of an array T[count].
buffer is in the block of memory about to be reallocated
ON_DECL ON_SDFQueryResult QueryBoundingBox | ( | const ON_BoundingBox & | bb, |
const ON_SignedDistanceFunction & | sdf, | ||
double | tolerance | ||
) |
these functions are not in any header but need testing
ON_DECL ON_SDFQueryResult QueryCurveTreeLeaf | ( | const ON_CurveTreeBezier & | node, |
const ON_SignedDistanceFunction & | sdf, | ||
double | tolerance | ||
) |
bool ON_SimpleArray< T >::QuickSort | ( | int(*)(const T *, const T *) | compar | ) |
See Also: ON_CompareIncreasing<T> and ON_CompareDeccreasing<T>
Sorts the array using the quick sort algorithm.
|
virtual |
Sorts the array using the heap sort algorithm.
Reimplemented in ON_ObjectArray< T >, ON_ObjectArray< ON_Texture >, ON_ObjectArray< ON_Linetype >, ON_ObjectArray< ON_Light >, ON_ObjectArray< ON_BrepVertex >, ON_ObjectArray< ON_BrepTrim >, ON_ObjectArray< ON_BrepRegion >, ON_ObjectArray< ON_BrepLoop >, ON_ObjectArray< ON_BrepFaceSide >, ON_ObjectArray< ON_BrepFace >, and ON_ObjectArray< ON_BrepEdge >.
|
virtual |
virtual ON_ClassArray<T> override that calls MemoryRelocate on each element after the quick sort.
The "this->" in this->m_count and this->m_a are needed for gcc 4 to compile.
The MemoryRelocate step is required to synch userdata back pointers so the user data destructor will work correctly.
Reimplemented from ON_ClassArray< T >.
bool ON_SimpleArray< T >::QuickSortAndRemoveDuplicates | ( | int(*)(const T *, const T *) | compar | ) |
See Also: ON_CompareIncreasing<T> and ON_CompareDeccreasing<T>
Sorts the array using the quick sort algorithma and then removes duplicates.
< duplicate
|
virtual |
low level memory management //////////////////////////////////////////
Class ON_SimpleArray<>
By default, ON_SimpleArray<> uses onrealloc() to manage the dynamic array memory. If you want to use something besides onrealloc() to manage the array memory, then override Realloc(). The T* Realloc(ptr, capacity) should do the following:
1) If ptr and capacity are zero, return nullptr. 2) If ptr is nullptr, an capacity > 0, allocate a memory block of capacity*sizeof(T) bytes and return a pointer to this block. If the allocation request fails, return nullptr. 3) If ptr is not nullptr and capacity is 0, free the memory block pointed to by ptr and return nullptr. 4) If ptr is not nullptr and capacity > 0, then reallocate the memory block and return a pointer to the reallocated block. If the reallocation request fails, return nullptr.
NOTE WELL: Microsoft's VC 6.0 realloc() contains a bug that can cause crashes and should be avoided. See MSDN Knowledge Base article ID Q225099 for more information. (re)allocated capacity*sizeof(T) bytes
Copyright (c) 1993-2022 Robert McNeel & Associates. All rights reserved. OpenNURBS, Rhinoceros, and Rhino3D are registered trademarks of Robert McNeel & Associates.
THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE HEREBY DISCLAIMED.
For complete openNURBS copyright information see http://www.opennurbs.org. When this file is parsed with /W4 warnings, two bogus warnings are generated. The ON_ClassArray<T>::DestroyElement template function generates a C4100: 'x' : unreferenced formal parameter warning. This appears to be caused by a bug in the compiler warning code or the way templates are expanded. This pragma is needed squelch the bogus warning. The ON_CompareIncreasing and ON_CompareDecreasing templates generate a C4211: nonstandard extension used : redefined extern to static warning. Microsoft's compiler appears to have a little trouble when static functions are declared before they are defined in a single .cpp file. This pragma is needed squelch the bogus warning. The main reason the definitions of the functions for the ON_SimpleArray and ON_ClassArray templates are in this separate file is so that the Microsoft developer studio autocomplete functions will work on these classes.
This file is included by opennurbs_array.h in the appropriate spot. If you need the definitions in the file, then you should include opennurbs_array.h and let it take care of including this file. construction ////////////////////////////////////////////////////////
|
virtual |
low level memory management ///////////////////////////////////////
Class ON_ClassArray<>
By default, ON_ClassArray<> uses onrealloc() to manage the dynamic array memory. If you want to use something besides onrealloc() to manage the array memory, then override Realloc(). The T* Realloc(ptr, capacity) should do the following:
1) If ptr and capacity are zero, return nullptr. 2) If ptr is nullptr, an capacity > 0, allocate a memory block of capacity*sizeof(T) bytes and return a pointer to this block. If the allocation request fails, return nullptr. 3) If ptr is not nullptr and capacity is 0, free the memory block pointed to by ptr and return nullptr. 4) If ptr is not nullptr and capacity > 0, then reallocate the memory block and return a pointer to the reallocated block. If the reallocation request fails, return nullptr.
NOTE WELL: Microsoft's VC 6.0 realloc() contains a bug that can cause crashes and should be avoided. See MSDN Knowledge Base article ID Q225099 for more information. (re)allocated capacity*sizeof(T) bytes
construction ////////////////////////////////////////////////////////
Reimplemented in ON_ObjectArray< T >, ON_ObjectArray< ON_Texture >, ON_ObjectArray< ON_Linetype >, ON_ObjectArray< ON_Light >, ON_ObjectArray< ON_BrepVertex >, ON_ObjectArray< ON_BrepTrim >, ON_ObjectArray< ON_BrepRegion >, ON_ObjectArray< ON_BrepLoop >, ON_ObjectArray< ON_BrepFaceSide >, ON_ObjectArray< ON_BrepFace >, and ON_ObjectArray< ON_BrepEdge >.
|
virtual |
virtual ON_ClassArray<T> override that calls MemoryRelocate on each element after the reallocation.
The "this->" in this->m_count and this->m_a are needed for gcc 4 to compile.
Reimplemented from ON_ClassArray< T >.
void ON_SimpleArray< T >::Remove |
Removes last element. Decrements count by 1. Does not change capacity.
void ON_ClassArray< T >::Remove |
Removes last element. Decrements count by 1. Does not change capacity.
|
virtual |
Removes element. Uses memmove() to perform any necessary shifting. Decrements count by 1. Does not change capacity
void ON_ClassArray< T >::Remove | ( | int | i | ) |
Removes element. Uses memmove() to perform any necessary shifting. Decrements count by 1. Does not change capacity
This call to memset is ok even when T has a vtable because in-place construction is used later.
This call to memset is ok even when T has a vtable because in-place construction is used later.
void ON_SimpleArray< T >::RemoveIf | ( | bool | predicateconst T &key | ) |
void ON_SimpleArray< T >::RemoveValue | ( | const T & | key | ) |
Removes elements. Uses memcmp() to compare Decrements count by removed items. Does not change capacity
T * ON_SimpleArray< T >::Reserve | ( | size_t | newcap | ) |
memory management ////////////////////////////////////////////////////
increase capacity to at least the requested value
T * ON_ClassArray< T >::Reserve | ( | size_t | newcap | ) |
memory management /////////////////////////////////////////////////
memory management ////////////////////////////////////////////////////
increase capacity to at least the requested value
void ON_SimpleFixedSizePoolIterator< T >::Reset |
Description: Sets the state of the iterator to the initial state that exists after construction. This is useful if the iterator has been used the get one or more elements and then the referenced fixed size pool is modified or code wants to begin iteration again a used a call to NextElement() to return the first element.
void ON_SimpleFixedSizePool< T >::ReturnAll |
Description: Return all allocated elements to the pool. No heap is freed and the pool remains initialized and ready for AllocateElement() to be called.
void ON_SimpleFixedSizePool< T >::ReturnElement | ( | T * | p | ) |
Description: Return an element to the pool. Parameters: p - [in] A pointer returned by AllocateElement(). It is critical that p be from this pool and that you return a pointer no more than one time. Remarks: If you find the following remarks confusing, but you really want to use ReturnElement(), then here are some simple guidelines. 1) SizeofElement() must be >= 16 2) SizeofElement() must be a multiple of 8. 3) Do not use FirstElement() and NextElement() to iterate through the pool.
If 1 to 3 don't work for you, then you need to understand the following information before using ReturnElement().
ON_FixedMemoryPool uses the first sizeof(void*) bytes of the returned element for bookkeeping purposes. Therefore, if you are going to use ReturnElement(), then SizeofElement() must be at least sizeof(void*). If you are using a platform that requires pointers to be aligned on sizeof(void*) boundaries, then SizeofElement() must be a multiple of sizeof(void*). If you are going to use ReturnElement() and then use FirstElement() and NextElement() to iterate through the list of elements, then you need to set a value in the returned element to indicate that it needs to be skipped during the iteration. This value cannot be located in the fist sizeof(void*) bytes of the element. If the element is a class with a vtable, you cannot call a virtual function on a returned element because the vtable pointer is trashed when ReturnElement() modifies the fist sizeof(void*) bytes.
void ON_SimpleArray< T >::Reverse |
reverse order
NOTE: If anything in "T" depends on the value of this's address, then don't call Reverse().
void ON_ClassArray< T >::Reverse |
reverse order
NOTE: If anything in "T" depends on the value of this's address, then don't call Reverse().
int ON_SimpleArray< T >::Search | ( | const T & | key | ) | const |
Search( e ) does a SLOW search of the array starting at array[0] and returns the index "i" of the first element that satisfies e == array[i]. (== is really memcmp()). If the search is not successful, then Search() returns -1. For Search(T) to work correctly, T must be a simple type. Use Search(p,compare()) for Ts that are structs/classes that contain pointers. Search() is only suitable for performing infrequent searches of small arrays. Sort the array and use BinarySearch() for performing efficient searches.
int ON_SimpleArray< T >::Search | ( | const T * | key, |
int(*)(const T *, const T *) | compar | ||
) | const |
See Also: ON_CompareIncreasing<T> and ON_CompareDeccreasing<T>
Search( p, compare ) does a SLOW search of the array starting at array[0] and returns the index "i" of the first element that satisfies compare(p,&array[i])==0. If the search is not successful, then Search() returns -1. Search() is only suitable for performing infrequent searches of small arrays. Sort the array and use BinarySearch() for performing efficient searches.
int ON_ClassArray< T >::Search | ( | const T * | key, |
int(*)(const T *, const T *) | compar | ||
) | const |
Search( p, compare ) does a SLOW search of the array starting at array[0] and returns the index "i" of the first element that satisfies compare(p,&array[i])==0. If the search is not successful, then Search() returns -1. Search() is only suitable for performing infrequent searches of small arrays. Sort the array and use BinarySearch() for performing efficient searches.
void ON_SimpleArray< T >::SetArray | ( | T * | p | ) |
Description: Do not use this version of SetArray(). Use the one that takes a pointer, count and capacity.
void ON_ClassArray< T >::SetArray | ( | T * | p | ) |
Description: Do not use this version of SetArray(). Use the one that takes a pointer, count and capacity: SetArray(pointer,count,capacity)
void ON_SimpleArray< T >::SetArray | ( | T * | p, |
int | count, | ||
int | capacity | ||
) |
Description: Expert user tool to set the memory used by the dynamic array. Parameters: T* pointer - [in] int count [in] int capacity - [in] m_a is set to pointer, m_count is set to count, and m_capacity is set to capacity. It is critical that the pointer be one returned by onmalloc(sz), where sz >= capacity*sizeof(T[0]).
void ON_ClassArray< T >::SetArray | ( | T * | p, |
int | count, | ||
int | capacity | ||
) |
Description: Expert user tool to set the memory used by the dynamic array. Parameters: T* pointer - [in] int count - [in] 0 <= count <= capacity int capacity - [in] m_a is set to pointer, m_count is set to count, and m_capacity is set to capacity. It is critical that the pointer be one returned by onmalloc(sz), where sz >= capacity*sizeof(T[0]), and that the in-place operator new has been used to initialize each element of the array.
T * ON_SimpleArray< T >::SetCapacity | ( | size_t | new_capacity | ) |
Shrink/grows capacity. If value
Allow "expert" users of ON_SimpleArray<>.SetArray(*,*,0) to clean up after themselves and deals with the case when the forget to clean up after themselves.
sets capacity to input value
NOTE: Realloc() does an allocation if the first argument is nullptr.
zero new memory
out of memory
T * ON_ClassArray< T >::SetCapacity | ( | size_t | new_capacity | ) |
Shrink/grows capacity. If value
Allow "expert" users of ON_SimpleArray<>.SetArray(*,*,0) to clean up after themselves and deals with the case when the forget to clean up after themselves.
uses "placement" for class construction/destruction
growing
initialize new elements with default constructor
even when m_a is an array of classes with vtable pointers, this call to memset(..., 0, ...) is what I want to do because in-place construction will be used when needed on this memory.
memory allocation failed
shrinking
memory allocation failed
void ON_SimpleArray< T >::SetCount | ( | int | count | ) |
low level memory management //////////////////////////////////////////
If value is <= Capacity(), then sets count to specified value.
void ON_ClassArray< T >::SetCount | ( | int | count | ) |
low level memory management //////////////////////////////////////////
If value is <= Capacity(), then sets count to specified value.
void ON_SimpleArray< T >::SetRange | ( | int | from, |
int | count, | ||
T | value | ||
) |
Sets all specified items in an array range to a value. Count and capacity are not changed.
void ON_SimpleArray< T >::Shrink |
remove unused capacity
void ON_ClassArray< T >::Shrink |
remove unused capacity
unsigned int ON_SimpleArray< T >::SizeOfArray |
amount of memory in the m_a[] array
unsigned int ON_ClassArray< T >::SizeOfArray |
amount of memory in the m_a[] array
unsigned int ON_SimpleArray< T >::SizeOfElement |
amount of memory in an m_a[] array element
unsigned int ON_ClassArray< T >::SizeOfElement |
amount of memory in an m_a[] array element
size_t ON_SimpleFixedSizePool< T >::SizeofElement |
Returns: Size of the elements in this pool.
bool ON_SimpleArray< T >::Sort | ( | ON::sort_algorithm | sort_algorithm, |
int * | index, | ||
int(*)(const T *, const T *) | compar | ||
) | const |
Description: Sort() fills in the index[] array so that array[index[i]] <= array[index[i+1]].
The array is not modified.
Parameters: sort_algorithm - [in]
ON::sort_algorithm::quick_sort (best in general) or ON::sort_algorithm::heap_sort Use ON::sort_algorithm::heap_sort only if you have done extensive testing with optimized release builds and are confident heap sort is significantly faster. index - [out] an array of length Count() that is returned with some permutation of (0,1,...,Count()-1). compare - [in] compare function compare(a,b,p) should return <0 if a<b, 0, if a==b, and >0 if a>b. Returns: true if successful
bool ON_ClassArray< T >::Sort | ( | ON::sort_algorithm | sort_algorithm, |
int * | index, | ||
int(*)(const T *, const T *) | compar | ||
) | const |
Description: Sort() fills in the index[] array so that array[index[i]] <= array[index[i+1]].
The array is not modified.
Parameters: sort_algorithm - [in]
ON::sort_algorithm::quick_sort (best in general) or ON::sort_algorithm::heap_sort Use ON::sort_algorithm::heap_sort only if you have done extensive testing with optimized release builds and are confident heap sort is significantly faster. index - [out] an array of length Count() that is returned with some permutation of (0,1,...,Count()-1). compare - [in] compare function compare(a,b) should return <0 if a<b, 0, if a==b, and >0 if a>b.
Returns: true if successful
bool ON_SimpleArray< T >::Sort | ( | ON::sort_algorithm | sort_algorithm, |
int * | index, | ||
int(*)(const T *, const T *, void *) | compar, | ||
void * | p | ||
) | const |
Description: Sort() fills in the index[] array so that array[index[i]] <= array[index[i+1]].
The array is not modified.
Parameters: sort_algorithm - [in]
ON::sort_algorithm::quick_sort (best in general) or ON::sort_algorithm::heap_sort Use ON::sort_algorithm::heap_sort only if you have done extensive testing with optimized release builds and are confident heap sort is significantly faster. index - [out] an array of length Count() that is returned with some permutation of (0,1,...,Count()-1). compare - [in] compare function compare(a,b,p) should return <0 if a<b, 0, if a==b, and >0 if a>b. p - [in] pointer passed as third argument to compare.
Returns: true if successful
index | index[] |
compar | int compare(const T*,const T*,void* p) |
p | p |
bool ON_ClassArray< T >::Sort | ( | ON::sort_algorithm | sort_algorithm, |
int * | index, | ||
int(*)(const T *, const T *, void *) | compar, | ||
void * | p | ||
) | const |
Description: Sort() fills in the index[] array so that array[index[i]] <= array[index[i+1]].
The array is not modified.
Parameters: sort_algorithm - [in]
ON::sort_algorithm::quick_sort (best in general) or ON::sort_algorithm::heap_sort Use ON::sort_algorithm::heap_sort only if you have done extensive testing with optimized release builds and are confident heap sort is significantly faster. index - [out] an array of length Count() that is returned with some permutation of (0,1,...,Count()-1). compare - [in] compare function compare(a,b,p) should return <0 if a<b, 0, if a==b, and >0 if a>b. p - [in] pointer passed as third argument to compare.
Returns: true if successful
index | index[] |
compar | int compare(const T*,const T*,void* p) |
p | p |
void ON_SimpleArray< T >::Swap | ( | int | i, |
int | j | ||
) |
swap elements i and j
void ON_ClassArray< T >::Swap | ( | int | i, |
int | j | ||
) |
swap elements i and j
|
static |
|
static |
|
static |
size_t ON_SimpleFixedSizePool< T >::TotalElementCount |
Returns: Total number of elements = number of active elements + number of returned elements.
unsigned int ON_SimpleArray< T >::UnsignedCount |
unsigned int ON_ClassArray< T >::UnsignedCount |
ON_BEGIN_EXTERNC voidpf zcalloc | ( | voidpf | , |
unsigned | , | ||
unsigned | |||
) |
void zcfree | ( | voidpf | , |
voidpf | |||
) |
void ON_SimpleArray< T >::Zero |
Zeros all array memory. Count and capacity are not changed.
void ON_ClassArray< T >::Zero |
Destroys all elements and fills them with values set by the default constructor. Count and capacity are not changed.
This call to memset is ok even when T has a vtable because in-place construction is used later.
const ON_EXTERN_DECL double ON_DBL_NINF |
const ON_EXTERN_DECL double ON_DBL_PINF |
ON_BEGIN_EXTERNC const ON_EXTERN_DECL double ON_DBL_QNAN |
IEEE 754 special values.
const ON_EXTERN_DECL float ON_FLT_NINF |
const ON_EXTERN_DECL float ON_FLT_PINF |
const ON_EXTERN_DECL float ON_FLT_QNAN |
const ON_EXTERN_DECL ON_UUID ON_max_uuid |
All bits are one in ON_max_uuid and ON_UuidCompare( U, ON_max_uuid ) < 0 if U != ON_max_uuid.
ON_BEGIN_EXTERNC const ON_EXTERN_DECL ON_UUID ON_nil_uuid |
All bits are zero in ON_nil_uuid and ON_UuidCompare( ON_nil_uuid, U ) < 0 if U != ON_nil_uuid.
const ON_EXTERN_DECL ON_UUID ON_opennurbs_id |
Application id for the versions of openNURBS that write userdata in 3dm files. User data whose class definition is in opennurbs should use these ids as the user data application id. No other user data should use these ids.
In situations where you want to use the id for the current version of opennurbs, use ON_opennurbs_id and you won't have to update your code when opennurbs versions roll.
Display material used to support front and back materials for realtime rendering in the viewport.
const ON_EXTERN_DECL ON_UUID ON_rhino2_id |
Application ids for the versions of Rhino that write 3dm files. All userdata classed defined in the core Rhino.exe should use these ids as the application id. In situations where you want to use the id for the current version of Rhino, use ON_rhino_id and you won't have to update your code when Rhino versions roll.
const ON_EXTERN_DECL ON_UUID ON_rhino3_id |
const ON_EXTERN_DECL ON_UUID ON_rhino4_id |
const ON_EXTERN_DECL ON_UUID ON_rhino5_id |
const ON_EXTERN_DECL ON_UUID ON_rhino6_id |
const ON_EXTERN_DECL ON_UUID ON_rhino7_id |
const ON_EXTERN_DECL ON_UUID ON_rhino8_id |
const ON_EXTERN_DECL ON_UUID ON_rhino_id |
Universal render engine id. Set as ON_Material plug-in id when using ON_RenderContentType_* ids in ON_Material::SetRdkMaterialInstanceId().
const ON_EXTERN_DECL ON_UUID ON_v2_userdata_id |
Application ids for userdata written by versions of opennurbs before userdata had application ids.
const ON_EXTERN_DECL ON_UUID ON_v3_userdata_id |
const ON_EXTERN_DECL ON_UUID ON_v4_userdata_id |
const ON_EXTERN_DECL ON_Plane ON_xy_plane |
const ON_EXTERN_DECL ON_Plane ON_yz_plane |
const ON_EXTERN_DECL ON_Plane ON_zx_plane |