MeshLib C Docs
Loading...
Searching...
No Matches
MRPointToPlaneAligningTransform.h File Reference
#include <MRCMesh/MRAffineXf.h>
#include <MRCMesh/MRVector3.h>
#include <MRCMisc/exports.h>
#include <stddef.h>

Go to the source code of this file.

Typedefs

typedef struct MR_RigidScaleXf3d MR_RigidScaleXf3d

Functions

MRC_API MR_PointToPlaneAligningTransformMR_PointToPlaneAligningTransform_DefaultConstruct (void)
MRC_API MR_PointToPlaneAligningTransformMR_PointToPlaneAligningTransform_DefaultConstructArray (size_t num_elems)
MRC_API const MR_PointToPlaneAligningTransformMR_PointToPlaneAligningTransform_OffsetPtr (const MR_PointToPlaneAligningTransform *ptr, ptrdiff_t i)
MRC_API MR_PointToPlaneAligningTransformMR_PointToPlaneAligningTransform_OffsetMutablePtr (MR_PointToPlaneAligningTransform *ptr, ptrdiff_t i)
MRC_API MR_PointToPlaneAligningTransformMR_PointToPlaneAligningTransform_ConstructFromAnother (const MR_PointToPlaneAligningTransform *_other)
MRC_API void MR_PointToPlaneAligningTransform_Destroy (const MR_PointToPlaneAligningTransform *_this)
 Destroys a heap-allocated instance of MR_PointToPlaneAligningTransform. Does nothing if the pointer is null.
MRC_API void MR_PointToPlaneAligningTransform_DestroyArray (const MR_PointToPlaneAligningTransform *_this)
 Destroys a heap-allocated array of MR_PointToPlaneAligningTransform. Does nothing if the pointer is null.
MRC_API MR_PointToPlaneAligningTransformMR_PointToPlaneAligningTransform_AssignFromAnother (MR_PointToPlaneAligningTransform *_this, const MR_PointToPlaneAligningTransform *_other)
MRC_API void MR_PointToPlaneAligningTransform_add_MR_Vector3d (MR_PointToPlaneAligningTransform *_this, const MR_Vector3d *p1, const MR_Vector3d *p2, const MR_Vector3d *normal2, const double *w)
MRC_API void MR_PointToPlaneAligningTransform_add_MR_Vector3f (MR_PointToPlaneAligningTransform *_this, const MR_Vector3f *p1, const MR_Vector3f *p2, const MR_Vector3f *normal2, const float *w)
MRC_API void MR_PointToPlaneAligningTransform_prepare (MR_PointToPlaneAligningTransform *_this)
MRC_API void MR_PointToPlaneAligningTransform_clear (MR_PointToPlaneAligningTransform *_this)
MRC_API MR_AffineXf3d MR_PointToPlaneAligningTransform_findBestRigidXf (const MR_PointToPlaneAligningTransform *_this)
MRC_API MR_AffineXf3d MR_PointToPlaneAligningTransform_findBestRigidScaleXf (const MR_PointToPlaneAligningTransform *_this)
MRC_API MR_AffineXf3d MR_PointToPlaneAligningTransform_findBestRigidXfFixedRotationAxis (const MR_PointToPlaneAligningTransform *_this, const MR_Vector3d *axis)
MRC_API MR_AffineXf3d MR_PointToPlaneAligningTransform_findBestRigidXfOrthogonalRotationAxis (const MR_PointToPlaneAligningTransform *_this, const MR_Vector3d *ort)
MRC_API MR_Vector3d MR_PointToPlaneAligningTransform_findBestTranslation (const MR_PointToPlaneAligningTransform *_this, const MR_Vector3d *rotAngles, const double *scale)
MRC_API MR_RigidScaleXf3dMR_PointToPlaneAligningTransform_calculateAmendment (const MR_PointToPlaneAligningTransform *_this)
MRC_API MR_RigidScaleXf3dMR_PointToPlaneAligningTransform_calculateAmendmentWithScale (const MR_PointToPlaneAligningTransform *_this)
MRC_API MR_RigidScaleXf3dMR_PointToPlaneAligningTransform_calculateFixedAxisAmendment (const MR_PointToPlaneAligningTransform *_this, const MR_Vector3d *axis)
MRC_API MR_RigidScaleXf3dMR_PointToPlaneAligningTransform_calculateOrthogonalAxisAmendment (const MR_PointToPlaneAligningTransform *_this, const MR_Vector3d *ort)

Typedef Documentation

◆ MR_RigidScaleXf3d

rigid (with scale) transformation that multiplies all distances on same scale: y = s*A*x + b, where s is a scalar, A is rotation matrix 3x3 stored as 3 angles, and b is shift vector Generated from class MR::RigidScaleXf3d. Supported MR_PassBy modes: MR_PassBy_DefaultConstruct, MR_PassBy_Copy, MR_PassBy_Move (and MR_PassBy_DefaultArgument and MR_PassBy_NoObject if supported by the callee). rotation angles relative to x,y,z axes Returns a pointer to a member variable of class MR::RigidScaleXf3f named a. Parameter _this can not be null. It is a single object. The returned pointer will never be null. It is non-owning, do NOT destroy it. The reference to this object might be preserved as the return value.

Function Documentation

◆ MR_PointToPlaneAligningTransform_add_MR_Vector3d()

MRC_API void MR_PointToPlaneAligningTransform_add_MR_Vector3d ( MR_PointToPlaneAligningTransform * _this,
const MR_Vector3d * p1,
const MR_Vector3d * p2,
const MR_Vector3d * normal2,
const double * w )

Add a pair of corresponding points and the normal of the tangent plane at the second point Generated from method MR::PointToPlaneAligningTransform::add. Parameter _this can not be null. It is a single object. Parameter p1 can not be null. It is a single object. Parameter p2 can not be null. It is a single object. Parameter normal2 can not be null. It is a single object. Parameter w has a default argument: 1, pass a null pointer to use it.

◆ MR_PointToPlaneAligningTransform_add_MR_Vector3f()

MRC_API void MR_PointToPlaneAligningTransform_add_MR_Vector3f ( MR_PointToPlaneAligningTransform * _this,
const MR_Vector3f * p1,
const MR_Vector3f * p2,
const MR_Vector3f * normal2,
const float * w )

Add a pair of corresponding points and the normal of the tangent plane at the second point Generated from method MR::PointToPlaneAligningTransform::add. Parameter _this can not be null. It is a single object. Parameter p1 can not be null. It is a single object. Parameter p2 can not be null. It is a single object. Parameter normal2 can not be null. It is a single object. Parameter w has a default argument: 1, pass a null pointer to use it.

◆ MR_PointToPlaneAligningTransform_AssignFromAnother()

MRC_API MR_PointToPlaneAligningTransform * MR_PointToPlaneAligningTransform_AssignFromAnother ( MR_PointToPlaneAligningTransform * _this,
const MR_PointToPlaneAligningTransform * _other )

Generated from method MR::PointToPlaneAligningTransform::operator=. Parameter _this can not be null. It is a single object. Parameter _other can not be null. It is a single object. The reference to things referred to by the parameter _other (if any) might be preserved in this object. The returned pointer will never be null. It is non-owning, do NOT destroy it. When this function is called, this object will drop any object references it held previously.

◆ MR_PointToPlaneAligningTransform_calculateAmendment()

MRC_API MR_RigidScaleXf3d * MR_PointToPlaneAligningTransform_calculateAmendment ( const MR_PointToPlaneAligningTransform * _this)

Compute transformation relative to given approximation and return it as angles and shift (scale = 1) Generated from method MR::PointToPlaneAligningTransform::calculateAmendment. Parameter _this can not be null. It is a single object. Never returns null. Returns an instance allocated on the heap! Must call MR_RigidScaleXf3d_Destroy() to free it when you're done using it.

◆ MR_PointToPlaneAligningTransform_calculateAmendmentWithScale()

MRC_API MR_RigidScaleXf3d * MR_PointToPlaneAligningTransform_calculateAmendmentWithScale ( const MR_PointToPlaneAligningTransform * _this)

Compute transformation relative to given approximation and return it as scale, angles and shift Generated from method MR::PointToPlaneAligningTransform::calculateAmendmentWithScale. Parameter _this can not be null. It is a single object. Never returns null. Returns an instance allocated on the heap! Must call MR_RigidScaleXf3d_Destroy() to free it when you're done using it.

◆ MR_PointToPlaneAligningTransform_calculateFixedAxisAmendment()

MRC_API MR_RigidScaleXf3d * MR_PointToPlaneAligningTransform_calculateFixedAxisAmendment ( const MR_PointToPlaneAligningTransform * _this,
const MR_Vector3d * axis )

this version searches for best transformation where rotation is allowed only around given axis and with arbitrary translation Generated from method MR::PointToPlaneAligningTransform::calculateFixedAxisAmendment. Parameter _this can not be null. It is a single object. Parameter axis can not be null. It is a single object. Never returns null. Returns an instance allocated on the heap! Must call MR_RigidScaleXf3d_Destroy() to free it when you're done using it.

◆ MR_PointToPlaneAligningTransform_calculateOrthogonalAxisAmendment()

MRC_API MR_RigidScaleXf3d * MR_PointToPlaneAligningTransform_calculateOrthogonalAxisAmendment ( const MR_PointToPlaneAligningTransform * _this,
const MR_Vector3d * ort )

this version searches for best transformation where rotation is allowed only around axes orthogonal to given one Generated from method MR::PointToPlaneAligningTransform::calculateOrthogonalAxisAmendment. Parameter _this can not be null. It is a single object. Parameter ort can not be null. It is a single object. Never returns null. Returns an instance allocated on the heap! Must call MR_RigidScaleXf3d_Destroy() to free it when you're done using it.

◆ MR_PointToPlaneAligningTransform_clear()

MRC_API void MR_PointToPlaneAligningTransform_clear ( MR_PointToPlaneAligningTransform * _this)

Clear points and normals data Generated from method MR::PointToPlaneAligningTransform::clear. Parameter _this can not be null. It is a single object.

◆ MR_PointToPlaneAligningTransform_ConstructFromAnother()

MRC_API MR_PointToPlaneAligningTransform * MR_PointToPlaneAligningTransform_ConstructFromAnother ( const MR_PointToPlaneAligningTransform * _other)

Generated from constructor MR::PointToPlaneAligningTransform::PointToPlaneAligningTransform. Parameter _other can not be null. It is a single object. The reference to things referred to by the parameter _other (if any) might be preserved in the constructed object. Never returns null. Returns an instance allocated on the heap! Must call MR_PointToPlaneAligningTransform_Destroy() to free it when you're done using it.

◆ MR_PointToPlaneAligningTransform_DefaultConstruct()

MRC_API MR_PointToPlaneAligningTransform * MR_PointToPlaneAligningTransform_DefaultConstruct ( void )

Constructs an empty (default-constructed) instance. Never returns null. Returns an instance allocated on the heap! Must call MR_PointToPlaneAligningTransform_Destroy() to free it when you're done using it.

◆ MR_PointToPlaneAligningTransform_DefaultConstructArray()

MRC_API MR_PointToPlaneAligningTransform * MR_PointToPlaneAligningTransform_DefaultConstructArray ( size_t num_elems)

Constructs an array of empty (default-constructed) instances, of the specified size. Will never return null. The array must be destroyed using MR_PointToPlaneAligningTransform_DestroyArray(). Use MR_PointToPlaneAligningTransform_OffsetMutablePtr() and MR_PointToPlaneAligningTransform_OffsetPtr() to access the array elements.

◆ MR_PointToPlaneAligningTransform_Destroy()

MRC_API void MR_PointToPlaneAligningTransform_Destroy ( const MR_PointToPlaneAligningTransform * _this)

Destroys a heap-allocated instance of MR_PointToPlaneAligningTransform. Does nothing if the pointer is null.

◆ MR_PointToPlaneAligningTransform_DestroyArray()

MRC_API void MR_PointToPlaneAligningTransform_DestroyArray ( const MR_PointToPlaneAligningTransform * _this)

Destroys a heap-allocated array of MR_PointToPlaneAligningTransform. Does nothing if the pointer is null.

◆ MR_PointToPlaneAligningTransform_findBestRigidScaleXf()

MRC_API MR_AffineXf3d MR_PointToPlaneAligningTransform_findBestRigidScaleXf ( const MR_PointToPlaneAligningTransform * _this)

this version searches for best rigid body transformation with uniform scaling Generated from method MR::PointToPlaneAligningTransform::findBestRigidScaleXf. Parameter _this can not be null. It is a single object.

◆ MR_PointToPlaneAligningTransform_findBestRigidXf()

MRC_API MR_AffineXf3d MR_PointToPlaneAligningTransform_findBestRigidXf ( const MR_PointToPlaneAligningTransform * _this)

Compute transformation as the solution to a least squares optimization problem: xf( p1_i ) = p2_i this version searches for best rigid body transformation Generated from method MR::PointToPlaneAligningTransform::findBestRigidXf. Parameter _this can not be null. It is a single object.

◆ MR_PointToPlaneAligningTransform_findBestRigidXfFixedRotationAxis()

MRC_API MR_AffineXf3d MR_PointToPlaneAligningTransform_findBestRigidXfFixedRotationAxis ( const MR_PointToPlaneAligningTransform * _this,
const MR_Vector3d * axis )

this version searches for best transformation where rotation is allowed only around given axis and with arbitrary translation Generated from method MR::PointToPlaneAligningTransform::findBestRigidXfFixedRotationAxis. Parameter _this can not be null. It is a single object. Parameter axis can not be null. It is a single object.

◆ MR_PointToPlaneAligningTransform_findBestRigidXfOrthogonalRotationAxis()

MRC_API MR_AffineXf3d MR_PointToPlaneAligningTransform_findBestRigidXfOrthogonalRotationAxis ( const MR_PointToPlaneAligningTransform * _this,
const MR_Vector3d * ort )

this version searches for best transformation where rotation is allowed only around axes orthogonal to given one Generated from method MR::PointToPlaneAligningTransform::findBestRigidXfOrthogonalRotationAxis. Parameter _this can not be null. It is a single object. Parameter ort can not be null. It is a single object.

◆ MR_PointToPlaneAligningTransform_findBestTranslation()

MRC_API MR_Vector3d MR_PointToPlaneAligningTransform_findBestTranslation ( const MR_PointToPlaneAligningTransform * _this,
const MR_Vector3d * rotAngles,
const double * scale )

this version searches for best translational part of affine transformation with given linear part Generated from method MR::PointToPlaneAligningTransform::findBestTranslation. Parameter _this can not be null. It is a single object. Parameter rotAngles has a default argument: {}, pass a null pointer to use it. Parameter scale has a default argument: 1, pass a null pointer to use it.

◆ MR_PointToPlaneAligningTransform_OffsetMutablePtr()

MRC_API MR_PointToPlaneAligningTransform * MR_PointToPlaneAligningTransform_OffsetMutablePtr ( MR_PointToPlaneAligningTransform * ptr,
ptrdiff_t i )

Offsets a pointer to an array element by i positions (not bytes). Use only if you're certain that the pointer points to an array element. The reference to the parameter ptr might be preserved in the return value.

◆ MR_PointToPlaneAligningTransform_OffsetPtr()

MRC_API const MR_PointToPlaneAligningTransform * MR_PointToPlaneAligningTransform_OffsetPtr ( const MR_PointToPlaneAligningTransform * ptr,
ptrdiff_t i )

Offsets a pointer to an array element by i positions (not bytes). Use only if you're certain that the pointer points to an array element. The reference to the parameter ptr might be preserved in the return value.

◆ MR_PointToPlaneAligningTransform_prepare()

MRC_API void MR_PointToPlaneAligningTransform_prepare ( MR_PointToPlaneAligningTransform * _this)

this method must be called after add() and before constant find...()/calculate...() to make the matrix symmetric Generated from method MR::PointToPlaneAligningTransform::prepare. Parameter _this can not be null. It is a single object.