3#ifndef MRMESH_NO_OPENVDB
17struct MergeVolumePartSettings
20 using PreCutCallback = std::function<void(
Mesh& mesh,
float leftCutPosition,
float rightCutPosition )>;
57template <
typename Volume>
59mergeVolumePart(
Mesh& mesh, std::vector<EdgePath>& cutContours, Volume&& volume,
float leftCutPosition,
float rightCutPosition,
64template <
typename Volume>
94template <
typename Volume>
represents a 3-dimentional float-typed vector
Definition MRDotNet/MRVector3.h:8
auto begin(const BitSet &a)
Definition MRMesh/MRBitSet.h:263
auto end(const BitSet &)
Definition MRMesh/MRBitSet.h:265
Definition MRCameraOrientationPlugin.h:7
tl::expected< T, E > Expected
Definition MRExpected.h:49
std::function< Expected< Volume >(int begin, int end, std::optional< Vector3i > &offset)> VolumePartBuilder
Definition MRVoxelsConversionsByParts.h:65
Expected< Mesh > volumeToMeshByParts(const VolumePartBuilder< Volume > &builder, const Vector3i &dimensions, const Vector3f &voxelSize, const VolumeToMeshByPartsSettings &settings={}, const MergeVolumePartSettings &mergeSettings={})
converts a voxel volume into a mesh without full memory loading
VoidOrErrStr mergeVolumePart(Mesh &mesh, std::vector< EdgePath > &cutContours, Volume &&volume, float leftCutPosition, float rightCutPosition, const MergeVolumePartSettings &settings={})
Merge one mesh with another generated from a voxel volume part.
Expected< void > VoidOrErrStr
return type for a void function that can produce an error string
Definition MRExpected.h:60
Parameters' structure for MR::mergeVolumePart.
PartMapping mapping
mapping with initialized maps required for the postMerge callback
Definition MRVoxelsConversionsByParts.h:31
PostCutCallback postCut
Definition MRVoxelsConversionsByParts.h:24
Vector3f origin
origin (position of the (0;0;0) voxel) of the voxel volume part, usually specified for SimpleVolume
Definition MRVoxelsConversionsByParts.h:33
std::function< void(Mesh &, const PartMapping &)> PostMergeCallback
Definition MRVoxelsConversionsByParts.h:28
PreCutCallback preCut
Definition MRVoxelsConversionsByParts.h:21
std::function< void(Mesh &mesh, float leftCutPosition, float rightCutPosition)> PreCutCallback
callback to process the generated mesh before the side cutting, e.g. fixing specific generation artif...
Definition MRVoxelsConversionsByParts.h:20
std::function< void(Mesh &)> PostCutCallback
callback to process the generated mesh after the side cutting, e.g. decimating
Definition MRVoxelsConversionsByParts.h:23
PostMergeCallback postMerge
Definition MRVoxelsConversionsByParts.h:29
Definition MRMesh/MRMesh.h:23
Definition MRPartMapping.h:10
Parameters' structure for MR::volumeToMeshByParts.
size_t stripeOverlap
overlap in voxels between two parts
Definition MRVoxelsConversionsByParts.h:79
size_t maxVolumePartMemoryUsage
the upper limit of memory amount used to store a voxel volume part
Definition MRVoxelsConversionsByParts.h:77