ConvexDecompositionInterface Class Reference

#include <convexdecomposition.h>

Inheritance diagram for ConvexDecompositionInterface:

Public Member Functions

MAXON_METHOD Result< void > Init (Float levelOfDetail=0.5, UInt32 maxVoxelCount=16000000)
 
MAXON_METHOD Result< DataDictionary > GetSettings () const
 
MAXON_METHOD Bool IsReady () const
 
MAXON_METHOD Result< UInt16GetProgress () const
 
MAXON_METHOD Result< void > Compute (const GeometryObject &geometryObject)
 
MAXON_METHOD Result< Array< GeometryObject > > FetchResults ()
 
MAXON_METHOD Result< void > Cancel ()
 
MAXON_METHOD Result< void > Clear ()
 

Private Member Functions

 MAXON_INTERFACE (ConvexDecompositionInterface, MAXON_REFERENCE_NORMAL, "net.maxon.interface.convexdecomposition")
 

Member Function Documentation

◆ MAXON_INTERFACE()

MAXON_INTERFACE ( ConvexDecompositionInterface  ,
MAXON_REFERENCE_NORMAL  ,
"net.maxon.interface.convexdecomposition"   
)
private

◆ Init()

MAXON_METHOD Result<void> Init ( Float  levelOfDetail = 0.5,
UInt32  maxVoxelCount = 16000000 
)

Initialize the convex decomposition library.

Parameters
levelOfDetaildesired level of detail to retail in the decomposition. Allowed values are between 0 and 1. Recommended 0.5.
maxVoxelCountMaximum number of voxels used to decompose the bounding box
Returns
This @CLASS (to allow method chaining).

◆ GetSettings()

MAXON_METHOD Result<DataDictionary> GetSettings ( ) const

◆ IsReady()

MAXON_METHOD Bool IsReady ( ) const

Get the current status of the decomposition job.

Returns
true if the decomposition is complete

◆ GetProgress()

MAXON_METHOD Result<UInt16> GetProgress ( ) const

Get the current progress of the decomposition job.

Returns
percentage completed

◆ Compute()

MAXON_METHOD Result<void> Compute ( const GeometryObject &  geometryObject)

Compute convex decomposition. By default this is done asynchronously. To be called after Init().

Parameters
geometryObjectgeometry object to decompose

◆ FetchResults()

MAXON_METHOD Result<Array<GeometryObject> > FetchResults ( )

Fetch results of the decomposition. In case the decomposition job is not done, wait for the results to be available. To be called after Compute().

Returns
An array of geometry objects where each entry represents one of the convex hulls the original object was decomposed into.

◆ Cancel()

MAXON_METHOD Result<void> Cancel ( )

Cancel the decomposition job.

◆ Clear()

MAXON_METHOD Result<void> Clear ( )