MeshLib C Docs
Loading...
Searching...
No Matches
MRMeshOrPoints.h File Reference
#include <MRCMesh/MRAffineXf.h>
#include <MRCMesh/MRBox.h>
#include <MRCMesh/MRId.h>
#include <MRCMesh/MRVector3.h>
#include <MRCMisc/common.h>
#include <MRCMisc/exports.h>
#include <stdbool.h>
#include <stddef.h>

Go to the source code of this file.

Typedefs

typedef struct MR_AABBTreeObjects MR_AABBTreeObjects
 
typedef struct MR_Mesh MR_Mesh
 
typedef struct MR_MeshPart MR_MeshPart
 
typedef struct MR_PointAccumulator MR_PointAccumulator
 
typedef struct MR_PointCloud MR_PointCloud
 
typedef struct MR_PointCloudPart MR_PointCloudPart
 
typedef struct MR_VertBitSet MR_VertBitSet
 
typedef struct MR_VertCoords MR_VertCoords
 
typedef struct MR_VisualObject MR_VisualObject
 
typedef struct MR_std_function_MR_MeshOrPoints_ProjectionResult_from_const_MR_Vector3f_ref MR_std_function_MR_MeshOrPoints_ProjectionResult_from_const_MR_Vector3f_ref
 
typedef struct MR_std_function_MR_Vector3f_from_MR_VertId MR_std_function_MR_Vector3f_from_MR_VertId
 
typedef struct MR_std_function_bool_from_float MR_std_function_bool_from_float
 
typedef struct MR_std_function_float_from_MR_VertId MR_std_function_float_from_MR_VertId
 
typedef struct MR_std_function_void_from_MR_ObjId_MR_MeshOrPoints_ProjectionResult MR_std_function_void_from_MR_ObjId_MR_MeshOrPoints_ProjectionResult
 
typedef struct MR_std_function_void_from_const_MR_Vector3f_ref_MR_MeshOrPoints_ProjectionResult_ref MR_std_function_void_from_const_MR_Vector3f_ref_MR_MeshOrPoints_ProjectionResult_ref
 
typedef struct MR_std_optional_MR_MeshOrPoints MR_std_optional_MR_MeshOrPoints
 
typedef struct MR_std_optional_MR_Vector3f MR_std_optional_MR_Vector3f
 
typedef struct MR_std_optional_MR_VertBitSet MR_std_optional_MR_VertBitSet
 
typedef struct MR_MeshOrPoints MR_MeshOrPoints
 
typedef struct MR_MeshOrPoints_ProjectionResult MR_MeshOrPoints_ProjectionResult
 Generated from class MR::MeshOrPoints::ProjectionResult.
 
typedef struct MR_MeshOrPointsXf MR_MeshOrPointsXf
 

Functions

MRC_API MR_MeshOrPointsMR_MeshOrPoints_ConstructFromAnother (const MR_MeshOrPoints *_other)
 
MRC_API const MR_MeshOrPointsMR_MeshOrPoints_OffsetPtr (const MR_MeshOrPoints *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.
 
MRC_API MR_MeshOrPointsMR_MeshOrPoints_OffsetMutablePtr (MR_MeshOrPoints *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.
 
MRC_API MR_MeshOrPointsMR_MeshOrPoints_Construct_MR_MeshPart (const MR_MeshPart *mp)
 
MRC_API MR_MeshOrPointsMR_MeshOrPoints_Construct_MR_PointCloudPart (const MR_PointCloudPart *pcp)
 
MRC_API MR_MeshOrPointsMR_MeshOrPoints_Construct_MR_Mesh (const MR_Mesh *mesh)
 
MRC_API MR_MeshOrPointsMR_MeshOrPoints_Construct_MR_PointCloud (const MR_PointCloud *pc)
 
MRC_API void MR_MeshOrPoints_Destroy (const MR_MeshOrPoints *_this)
 Destroys a heap-allocated instance of MR_MeshOrPoints. Does nothing if the pointer is null.
 
MRC_API void MR_MeshOrPoints_DestroyArray (const MR_MeshOrPoints *_this)
 Destroys a heap-allocated array of MR_MeshOrPoints. Does nothing if the pointer is null.
 
MRC_API MR_MeshOrPointsMR_MeshOrPoints_AssignFromAnother (MR_MeshOrPoints *_this, const MR_MeshOrPoints *_other)
 
MRC_API const MR_MeshPartMR_MeshOrPoints_asMeshPart (const MR_MeshOrPoints *_this)
 
MRC_API const MR_PointCloudPartMR_MeshOrPoints_asPointCloudPart (const MR_MeshOrPoints *_this)
 
MRC_API MR_Box3f MR_MeshOrPoints_getObjBoundingBox (const MR_MeshOrPoints *_this)
 
MRC_API void MR_MeshOrPoints_cacheAABBTree (const MR_MeshOrPoints *_this)
 
MRC_API MR_Box3f MR_MeshOrPoints_computeBoundingBox (const MR_MeshOrPoints *_this, const MR_AffineXf3f *toWorld)
 
MRC_API void MR_MeshOrPoints_accumulate (const MR_MeshOrPoints *_this, MR_PointAccumulator *accum, const MR_AffineXf3f *xf)
 
MRC_API MR_std_optional_MR_VertBitSetMR_MeshOrPoints_pointsGridSampling (const MR_MeshOrPoints *_this, float voxelSize, const MR_uint64_t *maxVoxels, const MR_std_function_bool_from_float *cb)
 
MRC_API const MR_VertCoordsMR_MeshOrPoints_points (const MR_MeshOrPoints *_this)
 
MRC_API const MR_VertBitSetMR_MeshOrPoints_validPoints (const MR_MeshOrPoints *_this)
 
MRC_API MR_std_function_MR_Vector3f_from_MR_VertIdMR_MeshOrPoints_normals (const MR_MeshOrPoints *_this)
 
MRC_API MR_std_function_float_from_MR_VertIdMR_MeshOrPoints_weights (const MR_MeshOrPoints *_this)
 
MRC_API MR_std_function_MR_MeshOrPoints_ProjectionResult_from_const_MR_Vector3f_refMR_MeshOrPoints_projector (const MR_MeshOrPoints *_this)
 
MRC_API MR_std_function_void_from_const_MR_Vector3f_ref_MR_MeshOrPoints_ProjectionResult_refMR_MeshOrPoints_limitedProjector (const MR_MeshOrPoints *_this)
 
MRC_API const MR_Vector3fMR_MeshOrPoints_ProjectionResult_Get_point (const MR_MeshOrPoints_ProjectionResult *_this)
 
MRC_API void MR_MeshOrPoints_ProjectionResult_Set_point (MR_MeshOrPoints_ProjectionResult *_this, MR_Vector3f value)
 
MRC_API MR_Vector3fMR_MeshOrPoints_ProjectionResult_GetMutable_point (MR_MeshOrPoints_ProjectionResult *_this)
 
MRC_API const MR_std_optional_MR_Vector3fMR_MeshOrPoints_ProjectionResult_Get_normal (const MR_MeshOrPoints_ProjectionResult *_this)
 
MRC_API void MR_MeshOrPoints_ProjectionResult_Set_normal (MR_MeshOrPoints_ProjectionResult *_this, const MR_Vector3f *value)
 
MRC_API MR_std_optional_MR_Vector3fMR_MeshOrPoints_ProjectionResult_GetMutable_normal (MR_MeshOrPoints_ProjectionResult *_this)
 
MRC_API const bool * MR_MeshOrPoints_ProjectionResult_Get_isBd (const MR_MeshOrPoints_ProjectionResult *_this)
 
MRC_API void MR_MeshOrPoints_ProjectionResult_Set_isBd (MR_MeshOrPoints_ProjectionResult *_this, bool value)
 
MRC_API bool * MR_MeshOrPoints_ProjectionResult_GetMutable_isBd (MR_MeshOrPoints_ProjectionResult *_this)
 
MRC_API const float * MR_MeshOrPoints_ProjectionResult_Get_distSq (const MR_MeshOrPoints_ProjectionResult *_this)
 
MRC_API void MR_MeshOrPoints_ProjectionResult_Set_distSq (MR_MeshOrPoints_ProjectionResult *_this, float value)
 
MRC_API float * MR_MeshOrPoints_ProjectionResult_GetMutable_distSq (MR_MeshOrPoints_ProjectionResult *_this)
 
MRC_API const MR_VertIdMR_MeshOrPoints_ProjectionResult_Get_closestVert (const MR_MeshOrPoints_ProjectionResult *_this)
 
MRC_API void MR_MeshOrPoints_ProjectionResult_Set_closestVert (MR_MeshOrPoints_ProjectionResult *_this, MR_VertId value)
 
MRC_API MR_VertIdMR_MeshOrPoints_ProjectionResult_GetMutable_closestVert (MR_MeshOrPoints_ProjectionResult *_this)
 
MRC_API MR_MeshOrPoints_ProjectionResultMR_MeshOrPoints_ProjectionResult_DefaultConstruct (void)
 
MRC_API MR_MeshOrPoints_ProjectionResultMR_MeshOrPoints_ProjectionResult_DefaultConstructArray (size_t num_elems)
 
MRC_API MR_MeshOrPoints_ProjectionResultMR_MeshOrPoints_ProjectionResult_ConstructFrom (MR_Vector3f point, const MR_Vector3f *normal, bool isBd, float distSq, MR_VertId closestVert)
 
MRC_API const MR_MeshOrPoints_ProjectionResultMR_MeshOrPoints_ProjectionResult_OffsetPtr (const MR_MeshOrPoints_ProjectionResult *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.
 
MRC_API MR_MeshOrPoints_ProjectionResultMR_MeshOrPoints_ProjectionResult_OffsetMutablePtr (MR_MeshOrPoints_ProjectionResult *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.
 
MRC_API MR_MeshOrPoints_ProjectionResultMR_MeshOrPoints_ProjectionResult_ConstructFromAnother (const MR_MeshOrPoints_ProjectionResult *_other)
 
MRC_API void MR_MeshOrPoints_ProjectionResult_Destroy (const MR_MeshOrPoints_ProjectionResult *_this)
 Destroys a heap-allocated instance of MR_MeshOrPoints_ProjectionResult. Does nothing if the pointer is null.
 
MRC_API void MR_MeshOrPoints_ProjectionResult_DestroyArray (const MR_MeshOrPoints_ProjectionResult *_this)
 Destroys a heap-allocated array of MR_MeshOrPoints_ProjectionResult. Does nothing if the pointer is null.
 
MRC_API MR_MeshOrPoints_ProjectionResultMR_MeshOrPoints_ProjectionResult_AssignFromAnother (MR_MeshOrPoints_ProjectionResult *_this, const MR_MeshOrPoints_ProjectionResult *_other)
 
MRC_API const MR_MeshOrPointsMR_MeshOrPointsXf_Get_obj (const MR_MeshOrPointsXf *_this)
 
MRC_API void MR_MeshOrPointsXf_Set_obj (MR_MeshOrPointsXf *_this, const MR_MeshOrPoints *value)
 
MRC_API MR_MeshOrPointsMR_MeshOrPointsXf_GetMutable_obj (MR_MeshOrPointsXf *_this)
 
MRC_API const MR_AffineXf3fMR_MeshOrPointsXf_Get_xf (const MR_MeshOrPointsXf *_this)
 
MRC_API void MR_MeshOrPointsXf_Set_xf (MR_MeshOrPointsXf *_this, MR_AffineXf3f value)
 
MRC_API MR_AffineXf3fMR_MeshOrPointsXf_GetMutable_xf (MR_MeshOrPointsXf *_this)
 
MRC_API MR_MeshOrPointsXfMR_MeshOrPointsXf_ConstructFromAnother (const MR_MeshOrPointsXf *_other)
 
MRC_API MR_MeshOrPointsXfMR_MeshOrPointsXf_ConstructFrom (const MR_MeshOrPoints *obj, MR_AffineXf3f xf)
 
MRC_API const MR_MeshOrPointsXfMR_MeshOrPointsXf_OffsetPtr (const MR_MeshOrPointsXf *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.
 
MRC_API MR_MeshOrPointsXfMR_MeshOrPointsXf_OffsetMutablePtr (MR_MeshOrPointsXf *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.
 
MRC_API void MR_MeshOrPointsXf_Destroy (const MR_MeshOrPointsXf *_this)
 Destroys a heap-allocated instance of MR_MeshOrPointsXf. Does nothing if the pointer is null.
 
MRC_API void MR_MeshOrPointsXf_DestroyArray (const MR_MeshOrPointsXf *_this)
 Destroys a heap-allocated array of MR_MeshOrPointsXf. Does nothing if the pointer is null.
 
MRC_API MR_MeshOrPointsXfMR_MeshOrPointsXf_AssignFromAnother (MR_MeshOrPointsXf *_this, const MR_MeshOrPointsXf *_other)
 
MRC_API MR_std_optional_MR_MeshOrPointsMR_getMeshOrPoints (const MR_VisualObject *obj)
 
MRC_API void MR_projectOnAll (const MR_Vector3f *pt, const MR_AABBTreeObjects *tree, float upDistLimitSq, const MR_std_function_void_from_MR_ObjId_MR_MeshOrPoints_ProjectionResult *callback, const MR_ObjId *skipObjId)
 

Typedef Documentation

◆ MR_AABBTreeObjects

◆ MR_Mesh

typedef struct MR_Mesh MR_Mesh

◆ MR_MeshOrPoints

This class can hold either mesh part or point cloud. It is used for generic algorithms operating with either of them Generated from class MR::MeshOrPoints.

◆ MR_MeshOrPoints_ProjectionResult

◆ MR_MeshOrPointsXf

an object and its transformation to global space with other objects Generated from class MR::MeshOrPointsXf.

◆ MR_MeshPart

typedef struct MR_MeshPart MR_MeshPart

◆ MR_PointAccumulator

◆ MR_PointCloud

typedef struct MR_PointCloud MR_PointCloud

◆ MR_PointCloudPart

◆ MR_std_function_bool_from_float

◆ MR_std_function_float_from_MR_VertId

◆ MR_std_function_MR_MeshOrPoints_ProjectionResult_from_const_MR_Vector3f_ref

◆ MR_std_function_MR_Vector3f_from_MR_VertId

◆ MR_std_function_void_from_const_MR_Vector3f_ref_MR_MeshOrPoints_ProjectionResult_ref

◆ MR_std_function_void_from_MR_ObjId_MR_MeshOrPoints_ProjectionResult

◆ MR_std_optional_MR_MeshOrPoints

◆ MR_std_optional_MR_Vector3f

◆ MR_std_optional_MR_VertBitSet

◆ MR_VertBitSet

typedef struct MR_VertBitSet MR_VertBitSet

◆ MR_VertCoords

typedef struct MR_VertCoords MR_VertCoords

◆ MR_VisualObject

Function Documentation

◆ MR_getMeshOrPoints()

MRC_API MR_std_optional_MR_MeshOrPoints * MR_getMeshOrPoints ( const MR_VisualObject * obj)

constructs MeshOrPoints from ObjectMesh or ObjectPoints, otherwise returns nullopt Generated from function MR::getMeshOrPoints. Never returns null. Returns an instance allocated on the heap! Must call MR_std_optional_MR_MeshOrPoints_Destroy() to free it when you're done using it.

◆ MR_MeshOrPoints_accumulate()

MRC_API void MR_MeshOrPoints_accumulate ( const MR_MeshOrPoints * _this,
MR_PointAccumulator * accum,
const MR_AffineXf3f * xf )

Adds in existing PointAccumulator the elements of the contained object Generated from a method of class MR::MeshOrPoints named accumulate. Parameter _this can not be null. It is a single object. Parameter accum can not be null. It is a single object. Parameter xf defaults to a null pointer in C++.

◆ MR_MeshOrPoints_asMeshPart()

MRC_API const MR_MeshPart * MR_MeshOrPoints_asMeshPart ( const MR_MeshOrPoints * _this)

if this object holds a mesh part then returns pointer on it, otherwise returns nullptr Generated from a method of class MR::MeshOrPoints named asMeshPart. Parameter _this can not be null. It is a single object.

◆ MR_MeshOrPoints_asPointCloudPart()

MRC_API const MR_PointCloudPart * MR_MeshOrPoints_asPointCloudPart ( const MR_MeshOrPoints * _this)

if this object holds a point cloud part then returns pointer on it, otherwise returns nullptr Generated from a method of class MR::MeshOrPoints named asPointCloudPart. Parameter _this can not be null. It is a single object.

◆ MR_MeshOrPoints_AssignFromAnother()

MRC_API MR_MeshOrPoints * MR_MeshOrPoints_AssignFromAnother ( MR_MeshOrPoints * _this,
const MR_MeshOrPoints * _other )

Generated from a method of class MR::MeshOrPoints named operator=. Parameter _this can not be null. It is a single object. Parameter _other can not be null. It is a single object. The returned pointer will never be null. It is non-owning, do NOT destroy it.

◆ MR_MeshOrPoints_cacheAABBTree()

MRC_API void MR_MeshOrPoints_cacheAABBTree ( const MR_MeshOrPoints * _this)

if AABBTree is already built does nothing otherwise builds and caches it Generated from a method of class MR::MeshOrPoints named cacheAABBTree. Parameter _this can not be null. It is a single object.

◆ MR_MeshOrPoints_computeBoundingBox()

MRC_API MR_Box3f MR_MeshOrPoints_computeBoundingBox ( const MR_MeshOrPoints * _this,
const MR_AffineXf3f * toWorld )

passes through all valid vertices and finds the minimal bounding box containing all of them; if toWorld transformation is given then returns minimal bounding box in world space Generated from a method of class MR::MeshOrPoints named computeBoundingBox. Parameter _this can not be null. It is a single object. Parameter toWorld defaults to a null pointer in C++.

◆ MR_MeshOrPoints_Construct_MR_Mesh()

MRC_API MR_MeshOrPoints * MR_MeshOrPoints_Construct_MR_Mesh ( const MR_Mesh * mesh)

Generated from a constructor of class MR::MeshOrPoints. Parameter mesh can not be null. It is a single object. Never returns null. Returns an instance allocated on the heap! Must call MR_MeshOrPoints_Destroy() to free it when you're done using it.

◆ MR_MeshOrPoints_Construct_MR_MeshPart()

MRC_API MR_MeshOrPoints * MR_MeshOrPoints_Construct_MR_MeshPart ( const MR_MeshPart * mp)

Generated from a constructor of class MR::MeshOrPoints. Parameter mp can not be null. It is a single object. Never returns null. Returns an instance allocated on the heap! Must call MR_MeshOrPoints_Destroy() to free it when you're done using it.

◆ MR_MeshOrPoints_Construct_MR_PointCloud()

MRC_API MR_MeshOrPoints * MR_MeshOrPoints_Construct_MR_PointCloud ( const MR_PointCloud * pc)

Generated from a constructor of class MR::MeshOrPoints. Parameter pc can not be null. It is a single object. Never returns null. Returns an instance allocated on the heap! Must call MR_MeshOrPoints_Destroy() to free it when you're done using it.

◆ MR_MeshOrPoints_Construct_MR_PointCloudPart()

MRC_API MR_MeshOrPoints * MR_MeshOrPoints_Construct_MR_PointCloudPart ( const MR_PointCloudPart * pcp)

Generated from a constructor of class MR::MeshOrPoints. Parameter pcp can not be null. It is a single object. Never returns null. Returns an instance allocated on the heap! Must call MR_MeshOrPoints_Destroy() to free it when you're done using it.

◆ MR_MeshOrPoints_ConstructFromAnother()

MRC_API MR_MeshOrPoints * MR_MeshOrPoints_ConstructFromAnother ( const MR_MeshOrPoints * _other)

Generated from a constructor of class MR::MeshOrPoints. Parameter _other can not be null. It is a single object. Never returns null. Returns an instance allocated on the heap! Must call MR_MeshOrPoints_Destroy() to free it when you're done using it.

◆ MR_MeshOrPoints_Destroy()

MRC_API void MR_MeshOrPoints_Destroy ( const MR_MeshOrPoints * _this)

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

◆ MR_MeshOrPoints_DestroyArray()

MRC_API void MR_MeshOrPoints_DestroyArray ( const MR_MeshOrPoints * _this)

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

◆ MR_MeshOrPoints_getObjBoundingBox()

MRC_API MR_Box3f MR_MeshOrPoints_getObjBoundingBox ( const MR_MeshOrPoints * _this)

returns the minimal bounding box containing all valid vertices of the object (and not only part of mesh); implemented via obj.getAABBTree() Generated from a method of class MR::MeshOrPoints named getObjBoundingBox. Parameter _this can not be null. It is a single object.

◆ MR_MeshOrPoints_limitedProjector()

returns a function that updates previously known projection (closest) points on this, the update takes place only if newly found closest point is closer to p than sqrt(res.distSq) given on input Generated from a method of class MR::MeshOrPoints named limitedProjector. Parameter _this can not be null. It is a single object. Never returns null. Returns an instance allocated on the heap! Must call MR_std_function_void_from_const_MR_Vector3f_ref_MR_MeshOrPoints_ProjectionResult_ref_Destroy() to free it when you're done using it.

◆ MR_MeshOrPoints_normals()

MRC_API MR_std_function_MR_Vector3f_from_MR_VertId * MR_MeshOrPoints_normals ( const MR_MeshOrPoints * _this)

returns normals generating function: VertId->normal (or empty for point cloud without normals) Generated from a method of class MR::MeshOrPoints named normals. Parameter _this can not be null. It is a single object. Never returns null. Returns an instance allocated on the heap! Must call MR_std_function_MR_Vector3f_from_MR_VertId_Destroy() to free it when you're done using it.

◆ MR_MeshOrPoints_OffsetMutablePtr()

MRC_API MR_MeshOrPoints * MR_MeshOrPoints_OffsetMutablePtr ( MR_MeshOrPoints * 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.

◆ MR_MeshOrPoints_OffsetPtr()

MRC_API const MR_MeshOrPoints * MR_MeshOrPoints_OffsetPtr ( const MR_MeshOrPoints * 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.

◆ MR_MeshOrPoints_points()

MRC_API const MR_VertCoords * MR_MeshOrPoints_points ( const MR_MeshOrPoints * _this)

gives access to points-vector (which can include invalid points as well) Generated from a method of class MR::MeshOrPoints named points. 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.

◆ MR_MeshOrPoints_pointsGridSampling()

MRC_API MR_std_optional_MR_VertBitSet * MR_MeshOrPoints_pointsGridSampling ( const MR_MeshOrPoints * _this,
float voxelSize,
const MR_uint64_t * maxVoxels,
const MR_std_function_bool_from_float * cb )

performs sampling of vertices or points; subdivides bounding box of the object on voxels of approximately given size and returns at most one vertex per voxel; voxelSize is automatically increased to avoid more voxels than

Parameters
maxVoxels;returns std::nullopt if it was terminated by the callback Generated from a method of class MR::MeshOrPoints named pointsGridSampling. Parameter _this can not be null. It is a single object. Parameter maxVoxels has a default argument: 500000, pass a null pointer to use it. Parameter cb is a single object. Parameter cb has a default argument: {}, pass a null pointer to use it. Never returns null. Returns an instance allocated on the heap! Must call MR_std_optional_MR_VertBitSet_Destroy() to free it when you're done using it.

◆ MR_MeshOrPoints_ProjectionResult_AssignFromAnother()

MRC_API MR_MeshOrPoints_ProjectionResult * MR_MeshOrPoints_ProjectionResult_AssignFromAnother ( MR_MeshOrPoints_ProjectionResult * _this,
const MR_MeshOrPoints_ProjectionResult * _other )

Generated from a method of class MR::MeshOrPoints::ProjectionResult named operator=. Parameter _this can not be null. It is a single object. Parameter _other can not be null. It is a single object. The returned pointer will never be null. It is non-owning, do NOT destroy it.

◆ MR_MeshOrPoints_ProjectionResult_ConstructFrom()

MRC_API MR_MeshOrPoints_ProjectionResult * MR_MeshOrPoints_ProjectionResult_ConstructFrom ( MR_Vector3f point,
const MR_Vector3f * normal,
bool isBd,
float distSq,
MR_VertId closestVert )

Constructs MR::MeshOrPoints::ProjectionResult elementwise. Parameter normal is optional. To keep it empty, pass a null pointer. Never returns null. Returns an instance allocated on the heap! Must call MR_MeshOrPoints_ProjectionResult_Destroy() to free it when you're done using it.

◆ MR_MeshOrPoints_ProjectionResult_ConstructFromAnother()

MRC_API MR_MeshOrPoints_ProjectionResult * MR_MeshOrPoints_ProjectionResult_ConstructFromAnother ( const MR_MeshOrPoints_ProjectionResult * _other)

Generated from a constructor of class MR::MeshOrPoints::ProjectionResult. Parameter _other can not be null. It is a single object. Never returns null. Returns an instance allocated on the heap! Must call MR_MeshOrPoints_ProjectionResult_Destroy() to free it when you're done using it.

◆ MR_MeshOrPoints_ProjectionResult_DefaultConstruct()

MRC_API MR_MeshOrPoints_ProjectionResult * MR_MeshOrPoints_ProjectionResult_DefaultConstruct ( void )

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

◆ MR_MeshOrPoints_ProjectionResult_DefaultConstructArray()

MRC_API MR_MeshOrPoints_ProjectionResult * MR_MeshOrPoints_ProjectionResult_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_MeshOrPoints_ProjectionResult_DestroyArray(). Use MR_MeshOrPoints_ProjectionResult_OffsetMutablePtr() and MR_MeshOrPoints_ProjectionResult_OffsetPtr() to access the array elements.

◆ MR_MeshOrPoints_ProjectionResult_Destroy()

MRC_API void MR_MeshOrPoints_ProjectionResult_Destroy ( const MR_MeshOrPoints_ProjectionResult * _this)

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

◆ MR_MeshOrPoints_ProjectionResult_DestroyArray()

MRC_API void MR_MeshOrPoints_ProjectionResult_DestroyArray ( const MR_MeshOrPoints_ProjectionResult * _this)

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

◆ MR_MeshOrPoints_ProjectionResult_Get_closestVert()

MRC_API const MR_VertId * MR_MeshOrPoints_ProjectionResult_Get_closestVert ( const MR_MeshOrPoints_ProjectionResult * _this)

for point clouds it is the closest vertex, for meshes it is the closest vertex of the triangle with the closest point Returns a pointer to a member variable of class MR::MeshOrPoints::ProjectionResult named closestVert. 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.

◆ MR_MeshOrPoints_ProjectionResult_Get_distSq()

MRC_API const float * MR_MeshOrPoints_ProjectionResult_Get_distSq ( const MR_MeshOrPoints_ProjectionResult * _this)

squared distance from query point to the closest point Returns a pointer to a member variable of class MR::MeshOrPoints::ProjectionResult named distSq. 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.

◆ MR_MeshOrPoints_ProjectionResult_Get_isBd()

MRC_API const bool * MR_MeshOrPoints_ProjectionResult_Get_isBd ( const MR_MeshOrPoints_ProjectionResult * _this)

can be true only for meshes, if the closest point is located on the boundary of the mesh (or the current region) Returns a pointer to a member variable of class MR::MeshOrPoints::ProjectionResult named isBd. 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.

◆ MR_MeshOrPoints_ProjectionResult_Get_normal()

MRC_API const MR_std_optional_MR_Vector3f * MR_MeshOrPoints_ProjectionResult_Get_normal ( const MR_MeshOrPoints_ProjectionResult * _this)

normal at the closest point; for meshes it will be pseudonormal with the differentiation depending on closest point location (face/edge/vertex) Returns a pointer to a member variable of class MR::MeshOrPoints::ProjectionResult named normal. 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.

◆ MR_MeshOrPoints_ProjectionResult_Get_point()

MRC_API const MR_Vector3f * MR_MeshOrPoints_ProjectionResult_Get_point ( const MR_MeshOrPoints_ProjectionResult * _this)

found closest point Returns a pointer to a member variable of class MR::MeshOrPoints::ProjectionResult named point. 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.

◆ MR_MeshOrPoints_ProjectionResult_GetMutable_closestVert()

MRC_API MR_VertId * MR_MeshOrPoints_ProjectionResult_GetMutable_closestVert ( MR_MeshOrPoints_ProjectionResult * _this)

for point clouds it is the closest vertex, for meshes it is the closest vertex of the triangle with the closest point Returns a mutable pointer to a member variable of class MR::MeshOrPoints::ProjectionResult named closestVert. 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.

◆ MR_MeshOrPoints_ProjectionResult_GetMutable_distSq()

MRC_API float * MR_MeshOrPoints_ProjectionResult_GetMutable_distSq ( MR_MeshOrPoints_ProjectionResult * _this)

squared distance from query point to the closest point Returns a mutable pointer to a member variable of class MR::MeshOrPoints::ProjectionResult named distSq. 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.

◆ MR_MeshOrPoints_ProjectionResult_GetMutable_isBd()

MRC_API bool * MR_MeshOrPoints_ProjectionResult_GetMutable_isBd ( MR_MeshOrPoints_ProjectionResult * _this)

can be true only for meshes, if the closest point is located on the boundary of the mesh (or the current region) Returns a mutable pointer to a member variable of class MR::MeshOrPoints::ProjectionResult named isBd. 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.

◆ MR_MeshOrPoints_ProjectionResult_GetMutable_normal()

MRC_API MR_std_optional_MR_Vector3f * MR_MeshOrPoints_ProjectionResult_GetMutable_normal ( MR_MeshOrPoints_ProjectionResult * _this)

normal at the closest point; for meshes it will be pseudonormal with the differentiation depending on closest point location (face/edge/vertex) Returns a mutable pointer to a member variable of class MR::MeshOrPoints::ProjectionResult named normal. 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.

◆ MR_MeshOrPoints_ProjectionResult_GetMutable_point()

MRC_API MR_Vector3f * MR_MeshOrPoints_ProjectionResult_GetMutable_point ( MR_MeshOrPoints_ProjectionResult * _this)

found closest point Returns a mutable pointer to a member variable of class MR::MeshOrPoints::ProjectionResult named point. 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.

◆ MR_MeshOrPoints_ProjectionResult_OffsetMutablePtr()

MRC_API MR_MeshOrPoints_ProjectionResult * MR_MeshOrPoints_ProjectionResult_OffsetMutablePtr ( MR_MeshOrPoints_ProjectionResult * 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.

◆ MR_MeshOrPoints_ProjectionResult_OffsetPtr()

MRC_API const MR_MeshOrPoints_ProjectionResult * MR_MeshOrPoints_ProjectionResult_OffsetPtr ( const MR_MeshOrPoints_ProjectionResult * 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.

◆ MR_MeshOrPoints_ProjectionResult_Set_closestVert()

MRC_API void MR_MeshOrPoints_ProjectionResult_Set_closestVert ( MR_MeshOrPoints_ProjectionResult * _this,
MR_VertId value )

for point clouds it is the closest vertex, for meshes it is the closest vertex of the triangle with the closest point Modifies a member variable of class MR::MeshOrPoints::ProjectionResult named closestVert. Parameter _this can not be null. It is a single object.

◆ MR_MeshOrPoints_ProjectionResult_Set_distSq()

MRC_API void MR_MeshOrPoints_ProjectionResult_Set_distSq ( MR_MeshOrPoints_ProjectionResult * _this,
float value )

squared distance from query point to the closest point Modifies a member variable of class MR::MeshOrPoints::ProjectionResult named distSq. Parameter _this can not be null. It is a single object.

◆ MR_MeshOrPoints_ProjectionResult_Set_isBd()

MRC_API void MR_MeshOrPoints_ProjectionResult_Set_isBd ( MR_MeshOrPoints_ProjectionResult * _this,
bool value )

can be true only for meshes, if the closest point is located on the boundary of the mesh (or the current region) Modifies a member variable of class MR::MeshOrPoints::ProjectionResult named isBd. Parameter _this can not be null. It is a single object.

◆ MR_MeshOrPoints_ProjectionResult_Set_normal()

MRC_API void MR_MeshOrPoints_ProjectionResult_Set_normal ( MR_MeshOrPoints_ProjectionResult * _this,
const MR_Vector3f * value )

normal at the closest point; for meshes it will be pseudonormal with the differentiation depending on closest point location (face/edge/vertex) Modifies a member variable of class MR::MeshOrPoints::ProjectionResult named normal. Parameter _this can not be null. It is a single object. Parameter value is optional. To keep it empty, pass a null pointer.

◆ MR_MeshOrPoints_ProjectionResult_Set_point()

MRC_API void MR_MeshOrPoints_ProjectionResult_Set_point ( MR_MeshOrPoints_ProjectionResult * _this,
MR_Vector3f value )

found closest point Modifies a member variable of class MR::MeshOrPoints::ProjectionResult named point. Parameter _this can not be null. It is a single object.

◆ MR_MeshOrPoints_projector()

returns a function that finds projection (closest) points on this: Vector3f->ProjectionResult Generated from a method of class MR::MeshOrPoints named projector. Parameter _this can not be null. It is a single object. Never returns null. Returns an instance allocated on the heap! Must call MR_std_function_MR_MeshOrPoints_ProjectionResult_from_const_MR_Vector3f_ref_Destroy() to free it when you're done using it.

◆ MR_MeshOrPoints_validPoints()

MRC_API const MR_VertBitSet * MR_MeshOrPoints_validPoints ( const MR_MeshOrPoints * _this)

gives access to bit set of valid points Generated from a method of class MR::MeshOrPoints named validPoints. 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.

◆ MR_MeshOrPoints_weights()

MRC_API MR_std_function_float_from_MR_VertId * MR_MeshOrPoints_weights ( const MR_MeshOrPoints * _this)

returns weights generating function: VertId->float: for mesh it is double area of surrounding triangles, and for point cloud - nothing Generated from a method of class MR::MeshOrPoints named weights. Parameter _this can not be null. It is a single object. Never returns null. Returns an instance allocated on the heap! Must call MR_std_function_float_from_MR_VertId_Destroy() to free it when you're done using it.

◆ MR_MeshOrPointsXf_AssignFromAnother()

MRC_API MR_MeshOrPointsXf * MR_MeshOrPointsXf_AssignFromAnother ( MR_MeshOrPointsXf * _this,
const MR_MeshOrPointsXf * _other )

Generated from a method of class MR::MeshOrPointsXf named operator=. Parameter _this can not be null. It is a single object. Parameter _other can not be null. It is a single object. The returned pointer will never be null. It is non-owning, do NOT destroy it.

◆ MR_MeshOrPointsXf_ConstructFrom()

MRC_API MR_MeshOrPointsXf * MR_MeshOrPointsXf_ConstructFrom ( const MR_MeshOrPoints * obj,
MR_AffineXf3f xf )

Constructs MR::MeshOrPointsXf elementwise. Parameter obj can not be null. It is a single object. Never returns null. Returns an instance allocated on the heap! Must call MR_MeshOrPointsXf_Destroy() to free it when you're done using it.

◆ MR_MeshOrPointsXf_ConstructFromAnother()

MRC_API MR_MeshOrPointsXf * MR_MeshOrPointsXf_ConstructFromAnother ( const MR_MeshOrPointsXf * _other)

Generated from a constructor of class MR::MeshOrPointsXf. Parameter _other can not be null. It is a single object. Never returns null. Returns an instance allocated on the heap! Must call MR_MeshOrPointsXf_Destroy() to free it when you're done using it.

◆ MR_MeshOrPointsXf_Destroy()

MRC_API void MR_MeshOrPointsXf_Destroy ( const MR_MeshOrPointsXf * _this)

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

◆ MR_MeshOrPointsXf_DestroyArray()

MRC_API void MR_MeshOrPointsXf_DestroyArray ( const MR_MeshOrPointsXf * _this)

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

◆ MR_MeshOrPointsXf_Get_obj()

MRC_API const MR_MeshOrPoints * MR_MeshOrPointsXf_Get_obj ( const MR_MeshOrPointsXf * _this)

Returns a pointer to a member variable of class MR::MeshOrPointsXf named obj. 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.

◆ MR_MeshOrPointsXf_Get_xf()

MRC_API const MR_AffineXf3f * MR_MeshOrPointsXf_Get_xf ( const MR_MeshOrPointsXf * _this)

Returns a pointer to a member variable of class MR::MeshOrPointsXf named xf. 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.

◆ MR_MeshOrPointsXf_GetMutable_obj()

MRC_API MR_MeshOrPoints * MR_MeshOrPointsXf_GetMutable_obj ( MR_MeshOrPointsXf * _this)

Returns a mutable pointer to a member variable of class MR::MeshOrPointsXf named obj. 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.

◆ MR_MeshOrPointsXf_GetMutable_xf()

MRC_API MR_AffineXf3f * MR_MeshOrPointsXf_GetMutable_xf ( MR_MeshOrPointsXf * _this)

Returns a mutable pointer to a member variable of class MR::MeshOrPointsXf named xf. 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.

◆ MR_MeshOrPointsXf_OffsetMutablePtr()

MRC_API MR_MeshOrPointsXf * MR_MeshOrPointsXf_OffsetMutablePtr ( MR_MeshOrPointsXf * 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.

◆ MR_MeshOrPointsXf_OffsetPtr()

MRC_API const MR_MeshOrPointsXf * MR_MeshOrPointsXf_OffsetPtr ( const MR_MeshOrPointsXf * 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.

◆ MR_MeshOrPointsXf_Set_obj()

MRC_API void MR_MeshOrPointsXf_Set_obj ( MR_MeshOrPointsXf * _this,
const MR_MeshOrPoints * value )

Modifies a member variable of class MR::MeshOrPointsXf named obj. Parameter _this can not be null. It is a single object. Parameter value can not be null. It is a single object.

◆ MR_MeshOrPointsXf_Set_xf()

MRC_API void MR_MeshOrPointsXf_Set_xf ( MR_MeshOrPointsXf * _this,
MR_AffineXf3f value )

Modifies a member variable of class MR::MeshOrPointsXf named xf. Parameter _this can not be null. It is a single object.

◆ MR_projectOnAll()

MRC_API void MR_projectOnAll ( const MR_Vector3f * pt,
const MR_AABBTreeObjects * tree,
float upDistLimitSq,
const MR_std_function_void_from_MR_ObjId_MR_MeshOrPoints_ProjectionResult * callback,
const MR_ObjId * skipObjId )

finds closest point on every object within given distance Generated from function MR::projectOnAll. Parameter pt can not be null. It is a single object. Parameter tree can not be null. It is a single object. Parameter callback can not be null. It is a single object. Parameter skipObjId has a default argument: {}, pass a null pointer to use it.