#include <MRCMisc/exports.h>Go to the source code of this file.
Typedefs | |
| typedef struct MR_expected_MR_VertScalars_std_string | MR_expected_MR_VertScalars_std_string |
Functions | |
| MRC_API MR_expected_MR_VertScalars_std_string * | MR_computeLocalConvexity_MR_Mesh (const MR_Mesh *mesh, float radius, const MR_std_function_bool_from_float *cb) |
| MRC_API MR_expected_MR_VertScalars_std_string * | MR_computeLocalConvexity_MR_PointCloud (const MR_PointCloud *cloud, float radius, const MR_std_function_bool_from_float *cb) |
Stores either a MR::VertScalars that represents success or a std::string that represents an error. 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).
| MRC_API MR_expected_MR_VertScalars_std_string * MR_computeLocalConvexity_MR_Mesh | ( | const MR_Mesh * | mesh, |
| float | radius, | ||
| const MR_std_function_bool_from_float * | cb ) |
computes unitless convexity of the mesh at each vertex on the scale of given radius: for each vertex v considers the edge-connected region of triangles with the centers within given radius from v, finds the best plane for the vertices on the boundary of the region, and returns sum_f( distance( plane, triCenter( f ) ) * dot( plane.n, dirArea( f ) ) ) / radius^3, which approximates the signed volume between the region and the plane: positive in convex areas, negative in concave ones, independent of the sign of plane's normal Generated from function MR::computeLocalConvexity. Parameter mesh can not be null. It is a single object. 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_expected_MR_VertScalars_std_string_Destroy() to free it when you're done using it.
| MRC_API MR_expected_MR_VertScalars_std_string * MR_computeLocalConvexity_MR_PointCloud | ( | const MR_PointCloud * | cloud, |
| float | radius, | ||
| const MR_std_function_bool_from_float * | cb ) |
computes unitless convexity of the point cloud with oriented normals at each point on the scale of given radius: for each point p considers n points q_i within given radius from p, finds the best plane for the furthest max( 3, sqrt( n ) ) of them, and returns pi * sum_i( distance( plane, q_i ) * dot( plane.n, N_i ) ) / ( sum_i |dot( plane.n, N_i )| * radius ), which approximates the same signed volume divided by radius^3 as the mesh version Generated from function MR::computeLocalConvexity. Parameter cloud can not be null. It is a single object. 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_expected_MR_VertScalars_std_string_Destroy() to free it when you're done using it.