Package apple.modelio

Class MDLVoxelArray

  • All Implemented Interfaces:
    MDLNamed, NSObject

    public class MDLVoxelArray
    extends MDLObject
    MDLVoxelArray [@summary] Voxel data represented on a three dimensional grid. Voxel data can include voxels considered to be on the surface of an object, and a series of shells on the outside and inside of the surface.
    • Constructor Detail

      • MDLVoxelArray

        protected MDLVoxelArray​(org.moe.natj.general.Pointer peer)
    • Method Detail

      • accessInstanceVariablesDirectly

        public static boolean accessInstanceVariablesDirectly()
      • allocWithZone

        public static java.lang.Object allocWithZone​(org.moe.natj.general.ptr.VoidPtr zone)
      • automaticallyNotifiesObserversForKey

        public static boolean automaticallyNotifiesObserversForKey​(java.lang.String key)
      • cancelPreviousPerformRequestsWithTarget

        public static void cancelPreviousPerformRequestsWithTarget​(java.lang.Object aTarget)
      • cancelPreviousPerformRequestsWithTargetSelectorObject

        public static void cancelPreviousPerformRequestsWithTargetSelectorObject​(java.lang.Object aTarget,
                                                                                 org.moe.natj.objc.SEL aSelector,
                                                                                 java.lang.Object anArgument)
      • classFallbacksForKeyedArchiver

        public static NSArray<java.lang.String> classFallbacksForKeyedArchiver()
      • classForKeyedUnarchiver

        public static org.moe.natj.objc.Class classForKeyedUnarchiver()
      • debugDescription_static

        public static java.lang.String debugDescription_static()
      • description_static

        public static java.lang.String description_static()
      • hash_static

        public static long hash_static()
      • instanceMethodSignatureForSelector

        public static NSMethodSignature instanceMethodSignatureForSelector​(org.moe.natj.objc.SEL aSelector)
      • instancesRespondToSelector

        public static boolean instancesRespondToSelector​(org.moe.natj.objc.SEL aSelector)
      • isSubclassOfClass

        public static boolean isSubclassOfClass​(org.moe.natj.objc.Class aClass)
      • keyPathsForValuesAffectingValueForKey

        public static NSSet<java.lang.String> keyPathsForValuesAffectingValueForKey​(java.lang.String key)
      • new_objc

        public static java.lang.Object new_objc()
      • resolveClassMethod

        public static boolean resolveClassMethod​(org.moe.natj.objc.SEL sel)
      • resolveInstanceMethod

        public static boolean resolveInstanceMethod​(org.moe.natj.objc.SEL sel)
      • setVersion_static

        public static void setVersion_static​(long aVersion)
      • superclass_static

        public static org.moe.natj.objc.Class superclass_static()
      • version_static

        public static long version_static()
      • coarseMesh

        public MDLMesh coarseMesh()
        Creates a coarse mesh from the voxel grid
      • convertToSignedShellField

        public void convertToSignedShellField()
        Converts volume grid into a signed shell field by surrounding the surface voxels, which have shell level values of zero, by an inner layer of voxels with shell level values of negative one and an outer layer of voxels with shell level values of positive one. The volume model must be closed in order to generate a signed shell field.
      • count

        public long count()
        The number of voxels in the grid
      • differenceWithVoxels

        public void differenceWithVoxels​(MDLVoxelArray voxels)
        Difference modifies the voxel grid so that voxels also in the supplied voxel grid are removed. It is assumed that the spatial voxel extent of one voxel in the supplied grid is the same as that of the voxel grid. Note that the shell level data will be cleared.
      • initWithAssetDivisionsPatchRadius

        public MDLVoxelArray initWithAssetDivisionsPatchRadius​(MDLAsset asset,
                                                               int divisions,
                                                               float patchRadius)
        Initialize a voxel grid from an MDLAsset. Attempts to create a closed volume model by applying "patches" of radius patchRadius to any holes found in the orginal mesh. Choose a patch radius that will be large enough to fill in the largest hole in the model.
      • intersectWithVoxels

        public void intersectWithVoxels​(MDLVoxelArray voxels)
        Intersection modifies the voxel grid so that only voxels that are also in the supplied voxel grid are retained. It is assumed that the spatial voxel extent of one voxel in the supplied grid is the same as that of the voxel grid. Note that the shell level data will be cleared.
      • isValidSignedShellField

        public boolean isValidSignedShellField()
        Returns whether or not the volume grid is in a valid signed shell field form. This property will be set to YES after calling generateSignedShellField. All other methods that modify the voxel grid will cause this property to be set to NO. Setting shellFieldInteriorThickness and shellFieldExteriorThickness will not affect the value of this property.
      • setShellFieldExteriorThickness

        public void setShellFieldExteriorThickness​(float value)
        If voxel grid is in a valid signed shell field form, sets the exterior thickness to the desired width, as measured from the model surface. If the voxel grid is not in a valid signed shell field form, the value of this property is zero.
      • setShellFieldInteriorThickness

        public void setShellFieldInteriorThickness​(float value)
        If voxel grid is in a valid signed shell field form, sets the interior thickness to the desired width, as measured from the model surface. If the voxel grid is not in a valid signed shell field form, the value of this property is zero.
      • setVoxelsForMeshDivisionsPatchRadius

        public void setVoxelsForMeshDivisionsPatchRadius​(MDLMesh mesh,
                                                         int divisions,
                                                         float patchRadius)
        Set voxels corresponding to a mesh. Routine will attempt to create a closed volume model by applying "patches" of a given radius to any holes it may find in the mesh.
      • shellFieldExteriorThickness

        public float shellFieldExteriorThickness()
        If voxel grid is in a valid signed shell field form, sets the exterior thickness to the desired width, as measured from the model surface. If the voxel grid is not in a valid signed shell field form, the value of this property is zero.
      • shellFieldInteriorThickness

        public float shellFieldInteriorThickness()
        If voxel grid is in a valid signed shell field form, sets the interior thickness to the desired width, as measured from the model surface. If the voxel grid is not in a valid signed shell field form, the value of this property is zero.
      • unionWithVoxels

        public void unionWithVoxels​(MDLVoxelArray voxels)
        Union modifies the voxel grid to be the merger with the supplied voxel grid. It is assumed that the spatial voxel extent of one voxel in the supplied grid is the same as that of the voxel grid. Note that the shell level data will be cleared.
      • voxelIndices

        public NSData voxelIndices()
        Returns an NSData containing the indices of all voxels in the voxel grid