Package apple.modelio
Class MDLMesh
- java.lang.Object
-
- org.moe.natj.general.NativeObject
-
- org.moe.natj.objc.ObjCObject
-
- apple.NSObject
-
- apple.modelio.MDLObject
-
- apple.modelio.MDLMesh
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class apple.modelio.MDLObject
MDLObject.Block_enumerateChildObjectsOfClassRootUsingBlockStopPointer
-
Nested classes/interfaces inherited from class apple.NSObject
NSObject.Block_accessibilityActivateBlock_ret, NSObject.Block_accessibilityActivationPointBlock_ret, NSObject.Block_accessibilityAttributedHintBlock_ret, NSObject.Block_accessibilityAttributedLabelBlock_ret, NSObject.Block_accessibilityAttributedUserInputLabelsBlock_ret, NSObject.Block_accessibilityAttributedValueBlock_ret, NSObject.Block_accessibilityContainerTypeBlock_ret, NSObject.Block_accessibilityCustomActionsBlock_ret, NSObject.Block_accessibilityCustomRotorsBlock_ret, NSObject.Block_accessibilityDecrementBlock_ret, NSObject.Block_accessibilityElementsBlock_ret, NSObject.Block_accessibilityElementsHiddenBlock_ret, NSObject.Block_accessibilityFrameBlock_ret, NSObject.Block_accessibilityHeaderElementsBlock_ret, NSObject.Block_accessibilityHintBlock_ret, NSObject.Block_accessibilityIdentifierBlock_ret, NSObject.Block_accessibilityIncrementBlock_ret, NSObject.Block_accessibilityLabelBlock_ret, NSObject.Block_accessibilityLanguageBlock_ret, NSObject.Block_accessibilityMagicTapBlock_ret, NSObject.Block_accessibilityNavigationStyleBlock_ret, NSObject.Block_accessibilityPathBlock_ret, NSObject.Block_accessibilityPerformEscapeBlock_ret, NSObject.Block_accessibilityRespondsToUserInteractionBlock_ret, NSObject.Block_accessibilityShouldGroupAccessibilityChildrenBlock_ret, NSObject.Block_accessibilityTextualContextBlock_ret, NSObject.Block_accessibilityTraitsBlock_ret, NSObject.Block_accessibilityUserInputLabelsBlock_ret, NSObject.Block_accessibilityValueBlock_ret, NSObject.Block_accessibilityViewIsModalBlock_ret, NSObject.Block_automationElementsBlock_ret, NSObject.Block_isAccessibilityElementBlock_ret, NSObject.Block_setAccessibilityActivateBlock, NSObject.Block_setAccessibilityActivationPointBlock, NSObject.Block_setAccessibilityAttributedHintBlock, NSObject.Block_setAccessibilityAttributedLabelBlock, NSObject.Block_setAccessibilityAttributedUserInputLabelsBlock, NSObject.Block_setAccessibilityAttributedValueBlock, NSObject.Block_setAccessibilityContainerTypeBlock, NSObject.Block_setAccessibilityCustomActionsBlock, NSObject.Block_setAccessibilityCustomRotorsBlock, NSObject.Block_setAccessibilityDecrementBlock, NSObject.Block_setAccessibilityElementsBlock, NSObject.Block_setAccessibilityElementsHiddenBlock, NSObject.Block_setAccessibilityFrameBlock, NSObject.Block_setAccessibilityHeaderElementsBlock, NSObject.Block_setAccessibilityHintBlock, NSObject.Block_setAccessibilityIdentifierBlock, NSObject.Block_setAccessibilityIncrementBlock, NSObject.Block_setAccessibilityLabelBlock, NSObject.Block_setAccessibilityLanguageBlock, NSObject.Block_setAccessibilityMagicTapBlock, NSObject.Block_setAccessibilityNavigationStyleBlock, NSObject.Block_setAccessibilityPathBlock, NSObject.Block_setAccessibilityPerformEscapeBlock, NSObject.Block_setAccessibilityRespondsToUserInteractionBlock, NSObject.Block_setAccessibilityShouldGroupAccessibilityChildrenBlock, NSObject.Block_setAccessibilityTextualContextBlock, NSObject.Block_setAccessibilityTraitsBlock, NSObject.Block_setAccessibilityUserInputLabelsBlock, NSObject.Block_setAccessibilityValueBlock, NSObject.Block_setAccessibilityViewIsModalBlock, NSObject.Block_setAutomationElementsBlock, NSObject.Block_setIsAccessibilityElementBlock, NSObject.Function_instanceMethodForSelector_ret, NSObject.Function_methodForSelector_ret
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedMDLMesh(org.moe.natj.general.Pointer peer)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static booleanaccessInstanceVariablesDirectly()voidaddAttributeWithNameFormat(@NotNull java.lang.String name, long format)addAttributeWithName:format Convenience method to add an attribute The mesh's allocator will be used to create storage for the new attribute.voidaddAttributeWithNameFormatTypeDataStride(@NotNull java.lang.String name, long format, @NotNull java.lang.String type, @NotNull NSData data, long stride)addAttributeWithName:format:type:data:stride Create a new vertex attribute including an associated buffer with a copy of the supplied data, and update the vertex descriptor accordinglyvoidaddAttributeWithNameFormatTypeDataStrideTime(@NotNull java.lang.String name, long format, @NotNull java.lang.String type, @NotNull NSData data, long stride, double time)addAttributeWithName:format:type:data:stride:time Create a new vertex attribute including an associated buffer with a copy of the supplied data, and update the vertex descriptor accordingly Adding an attribute, such as position data, at multiple times will result in attributes being created for each of those times.voidaddNormalsWithAttributeNamedCreaseThreshold(@Nullable java.lang.String attributeName, float creaseThreshold)addNormalsWithAttributeNamed:creaseThreshold: Calculate and add vertex normal data Uses the attribute named MDLVertexAttributePosition to calculate vertex normals.voidaddOrthTanBasisForTextureCoordinateAttributeNamedNormalAttributeNamedTangentAttributeNamed(@NotNull java.lang.String textureCoordinateAttributeName, @NotNull java.lang.String normalAttributeName, @NotNull java.lang.String tangentAttributeName)addOrthTanBasisForTextureCoordinateAttributeNamed:normalAttributeNamed:tangentAttributeNamed Create an orthonormal tangent basis with tangent specified Uses the attribute named MDLVertexAttributePosition and textureCoordinateAttributeName and the specified normals to calculate tangent information.voidaddTangentBasisForTextureCoordinateAttributeNamedNormalAttributeNamedTangentAttributeNamed(@NotNull java.lang.String textureCoordinateAttributeName, @NotNull java.lang.String normalAttributeName, @NotNull java.lang.String tangentAttributeName)addTangentBasisForTextureCoordinateAttributeNamed:normalAttributeNamed:tangentAttributeNamed Create tangents which are orthogonal to the normal Uses the attribute named MDLVertexAttributePosition and textureCoordinateAttributeName and the specified normals to calculate tangent information.voidaddTangentBasisForTextureCoordinateAttributeNamedTangentAttributeNamedBitangentAttributeNamed(@NotNull java.lang.String textureCoordinateAttributeName, @NotNull java.lang.String tangentAttributeName, @Nullable java.lang.String bitangentAttributeName)addTangentBasisForTextureCoordinateAttributeNamed:tangentAttributeNamed:bitangentAttributeNamed Create a shader basis where the tangent and bitangent span the uv -> object space transform Uses the attribute named MDLVertexAttributePosition and textureCoordinateAttributeName to calculate tangent and bitangent attributes.voidaddUnwrappedTextureCoordinatesForAttributeNamed(@NotNull java.lang.String textureCoordinateAttributeName)addTextureCoordinatesForAttributeNamed:textureCoordinateAttributeName Creates texture coordinates by unwrapping the mesh Uses the attribute named MDLVertexAttributePosition and if available, the attribute named MDLVertexAttributeNormal to calculate texture coordinatesstatic MDLMeshalloc()@NotNull MDLMeshBufferAllocatorallocator()[@property] allocator allocator used to allocate contained mesh buffersstatic MDLMeshallocWithZone(org.moe.natj.general.ptr.VoidPtr zone)static booleanautomaticallyNotifiesObserversForKey(@NotNull java.lang.String key)static voidcancelPreviousPerformRequestsWithTarget(@NotNull java.lang.Object aTarget)static voidcancelPreviousPerformRequestsWithTargetSelectorObject(@NotNull java.lang.Object aTarget, @NotNull org.moe.natj.objc.SEL aSelector, @Nullable java.lang.Object anArgument)static @NotNull NSArray<java.lang.String>classFallbacksForKeyedArchiver()static @NotNull org.moe.natj.objc.ClassclassForKeyedUnarchiver()static java.lang.StringdebugDescription_static()static java.lang.Stringdescription_static()voidflipTextureCoordinatesInAttributeNamed(@NotNull java.lang.String textureCoordinateAttributeName)flipTextureCoordinatesInAttributeNamed: Flips texture coordinates by performing the operation (u,v) = (u, 1-v) Many application generate model files with texture coordinate mapping assuming a bottom left bitmap origin.booleangenerateAmbientOcclusionTextureWithQualityAttenuationFactorObjectsToConsiderVertexAttributeNamedMaterialPropertyNamed(float bakeQuality, float attenuationFactor, @NotNull NSArray<? extends MDLObject> objectsToConsider, @NotNull java.lang.String vertexAttributeName, @NotNull java.lang.String materialPropertyName)generateAmbientOcclusionTextureWithQuality: Creates an Ambient Occlusion texture, returns true upon success, false upon failurebooleangenerateAmbientOcclusionVertexColorsWithQualityAttenuationFactorObjectsToConsiderVertexAttributeNamed(float bakeQuality, float attenuationFactor, @NotNull NSArray<? extends MDLObject> objectsToConsider, @NotNull java.lang.String vertexAttributeName)booleangenerateAmbientOcclusionVertexColorsWithRaysPerSampleAttenuationFactorObjectsToConsiderVertexAttributeNamed(long raysPerSample, float attenuationFactor, @NotNull NSArray<? extends MDLObject> objectsToConsider, @NotNull java.lang.String vertexAttributeName)booleangenerateLightMapTextureWithQualityLightsToConsiderObjectsToConsiderVertexAttributeNamedMaterialPropertyNamed(float bakeQuality, @NotNull NSArray<? extends MDLLight> lightsToConsider, @NotNull NSArray<? extends MDLObject> objectsToConsider, @NotNull java.lang.String vertexAttributeName, @NotNull java.lang.String materialPropertyName)booleangenerateLightMapVertexColorsWithLightsToConsiderObjectsToConsiderVertexAttributeNamed(@NotNull NSArray<? extends MDLLight> lightsToConsider, @NotNull NSArray<? extends MDLObject> objectsToConsider, @NotNull java.lang.String vertexAttributeName)static longhash_static()MDLMeshinit()MDLMeshinitMeshBySubdividingMeshSubmeshIndexSubdivisionLevelsAllocator(@NotNull MDLMesh mesh, int submeshIndex, int subdivisionLevels, @Nullable MDLMeshBufferAllocator allocator)initMeshBySubdividingMesh:submeshIndex:subdivisionLevels:allocator Factory method that generates a subdivided mesh from a source mesh Subdivision levels over four are likely to generate more triangles than can be reasonably displayed.MDLMeshinitWithBufferAllocator(@Nullable MDLMeshBufferAllocator bufferAllocator)initWithAllocator: Initialize a mesh with an allocatorMDLMeshinitWithVertexBuffersVertexCountDescriptorSubmeshes(@NotNull NSArray<?> vertexBuffers, long vertexCount, @NotNull MDLVertexDescriptor descriptor, @NotNull NSArray<? extends MDLSubmesh> submeshes)initWithVertexBuffer:vertexCount:descriptor:submeshes: Initialize object with an array of vertex buffers (Structure of Arrays) and a collection of submeshes Allows initialization with the layout of the vertexBuffers in a structure-of-arrays form, in other words, non-interleaved vertex attributesMDLMeshinitWithVertexBufferVertexCountDescriptorSubmeshes(@NotNull MDLMeshBuffer vertexBuffer, long vertexCount, @NotNull MDLVertexDescriptor descriptor, @NotNull NSArray<? extends MDLSubmesh> submeshes)initWithVertexBuffer:vertexCount:descriptor:submeshes: Initialize object with a vertex buffer and a collection of submeshesstatic NSObject.Function_instanceMethodForSelector_retinstanceMethodForSelector(org.moe.natj.objc.SEL aSelector)static NSMethodSignatureinstanceMethodSignatureForSelector(org.moe.natj.objc.SEL aSelector)static booleaninstancesRespondToSelector(org.moe.natj.objc.SEL aSelector)static booleanisSubclassOfClass(org.moe.natj.objc.Class aClass)static @NotNull NSSet<java.lang.String>keyPathsForValuesAffectingValueForKey(@NotNull java.lang.String key)voidmakeVerticesUnique()Deprecated.booleanmakeVerticesUniqueAndReturnError(@Nullable org.moe.natj.general.ptr.Ptr<NSError> error)makeVerticesUniqueAndReturnError: Deindexes the vertex array If any vertices are shared on multiple faces, duplicate those vertices so faces do not share vertices.static MDLMeshmeshWithSCNGeometry(@NotNull SCNGeometry scnGeometry)API-Since: 9.0static MDLMeshmeshWithSCNGeometryBufferAllocator(@NotNull SCNGeometry scnGeometry, @Nullable MDLMeshBufferAllocator bufferAllocator)API-Since: 10.0static MDLMeshnew_objc()static MDLMeshnewIcosahedronWithRadiusInwardNormalsAllocator(float radius, boolean inwardNormals, @Nullable MDLMeshBufferAllocator allocator)static MDLMeshnewIcosahedronWithRadiusInwardNormalsGeometryTypeAllocator(float radius, boolean inwardNormals, long geometryType, @Nullable MDLMeshBufferAllocator allocator)API-Since: 11.0static MDLMeshnewSubdividedMeshSubmeshIndexSubdivisionLevels(@NotNull MDLMesh mesh, long submeshIndex, long subdivisionLevels)static MDLMeshobjectWithSCNNode(@NotNull SCNNode scnNode)static MDLMeshobjectWithSCNNodeBufferAllocator(@NotNull SCNNode scnNode, @Nullable MDLMeshBufferAllocator bufferAllocator)voidremoveAttributeNamed(@NotNull java.lang.String name)removeAttributeNamed: remove an attribute if the named attribute does not exist, nothing happens.voidreplaceAttributeNamedWithData(@NotNull java.lang.String name, @NotNull MDLVertexAttributeData newData)replaceAttributeNamed:withData replace existing attribute data with new attribute data retaining the format of the replacement data.static booleanresolveClassMethod(org.moe.natj.objc.SEL sel)static booleanresolveInstanceMethod(org.moe.natj.objc.SEL sel)voidsetSubmeshes(@Nullable NSMutableArray<MDLSubmesh> value)[@property] submeshes Array of submeshes containing an indexbuffer referencing the vertex data and material to be applied when the mesh is renderedstatic voidsetVersion_static(long aVersion)voidsetVertexBuffers(@NotNull NSArray<?> value)[@property] vertexBuffers Array of buffers containing vertex data The vertex buffers in this array are indexed by the vertex descriptor.voidsetVertexCount(long value)[@property] vertexCount Number of vertices in the vertexBuffers The size of vertex data in each buffer can be computed by multiplying this value with the stride of the buffer in the vertexDescriptor's layoutvoidsetVertexDescriptor(@NotNull MDLVertexDescriptor value)[@property] vertexDescriptor Immutable vertex descriptor for interpreting data in vertexBuffers Setting this applies the new layout in 'vertexBuffers' thus is a heavyweight operation as structured copies of almost all vertex buffer data could be made.@Nullable NSMutableArray<MDLSubmesh>submeshes()[@property] submeshes Array of submeshes containing an indexbuffer referencing the vertex data and material to be applied when the mesh is renderedstatic org.moe.natj.objc.Classsuperclass_static()voidupdateAttributeNamedWithData(@NotNull java.lang.String name, @NotNull MDLVertexAttributeData newData)updateAttributeNamed:withData update existing attribute data with new attribute data retaining the format of the existing data.static booleanuseStoredAccessor()Deprecated.static longversion_static()@Nullable MDLVertexAttributeDatavertexAttributeDataForAttributeNamed(@NotNull java.lang.String name)vertexAttributeDataForAttributeNamed: convenience selector to get quick access to vertex attribute data the vertex buffer will remain mapped until the MDLVertexAttributeData is freed.@Nullable MDLVertexAttributeDatavertexAttributeDataForAttributeNamedAsFormat(@NotNull java.lang.String name, long format)vertexAttributeDataForAttributeNamed:asFormat convenience selector to get quick access to vertex attribute data reformatted to the requested format if necessary.@NotNull NSArray<?>vertexBuffers()[@property] vertexBuffers Array of buffers containing vertex data The vertex buffers in this array are indexed by the vertex descriptor.longvertexCount()[@property] vertexCount Number of vertices in the vertexBuffers The size of vertex data in each buffer can be computed by multiplying this value with the stride of the buffer in the vertexDescriptor's layout@NotNull MDLVertexDescriptorvertexDescriptor()[@property] vertexDescriptor Immutable vertex descriptor for interpreting data in vertexBuffers Setting this applies the new layout in 'vertexBuffers' thus is a heavyweight operation as structured copies of almost all vertex buffer data could be made.-
Methods inherited from class apple.modelio.MDLObject
addChild, children, components, enumerateChildObjectsOfClassRootUsingBlockStopPointer, hidden, instance, name, objectAtPath, parent, path, setChildren, setHidden, setInstance, setName, setParent, setParent_unsafe, setTransform, transform
-
Methods inherited from class apple.NSObject
accessibilityActivate, accessibilityActivateBlock, accessibilityActivationPoint, accessibilityActivationPointBlock, accessibilityAssistiveTechnologyFocusedIdentifiers, accessibilityAttributedHint, accessibilityAttributedHintBlock, accessibilityAttributedLabel, accessibilityAttributedLabelBlock, accessibilityAttributedUserInputLabels, accessibilityAttributedUserInputLabelsBlock, accessibilityAttributedValue, accessibilityAttributedValueBlock, accessibilityContainerType, accessibilityContainerTypeBlock, accessibilityCustomActions, accessibilityCustomActionsBlock, accessibilityCustomRotors, accessibilityCustomRotorsBlock, accessibilityDecrement, accessibilityDecrementBlock, accessibilityDirectTouchOptions, accessibilityDragSourceDescriptors, accessibilityDropPointDescriptors, accessibilityElementAtIndex, accessibilityElementCount, accessibilityElementDidBecomeFocused, accessibilityElementDidLoseFocus, accessibilityElementIsFocused, accessibilityElements, accessibilityElementsBlock, accessibilityElementsHidden, accessibilityElementsHiddenBlock, accessibilityFrame, accessibilityFrameBlock, accessibilityHeaderElementsBlock, accessibilityHint, accessibilityHintBlock, accessibilityIdentifierBlock, accessibilityIncrement, accessibilityIncrementBlock, accessibilityLabel, accessibilityLabelBlock, accessibilityLanguage, accessibilityLanguageBlock, accessibilityMagicTapBlock, accessibilityNavigationStyle, accessibilityNavigationStyleBlock, accessibilityPath, accessibilityPathBlock, accessibilityPerformEscape, accessibilityPerformEscapeBlock, accessibilityPerformMagicTap, accessibilityRespondsToUserInteraction, accessibilityRespondsToUserInteractionBlock, accessibilityScroll, accessibilityShouldGroupAccessibilityChildrenBlock, accessibilityTextualContext, accessibilityTextualContextBlock, accessibilityTraits, accessibilityTraitsBlock, accessibilityUserInputLabels, accessibilityUserInputLabelsBlock, accessibilityValue, accessibilityValueBlock, accessibilityViewIsModal, accessibilityViewIsModalBlock, accessibilityZoomInAtPoint, accessibilityZoomOutAtPoint, addObserverForKeyPathOptionsContext, attemptRecoveryFromErrorOptionIndex, attemptRecoveryFromErrorOptionIndexDelegateDidRecoverSelectorContextInfo, autoContentAccessingProxy, automationElements, automationElementsBlock, awakeAfterUsingCoder, awakeFromNib, class_objc, classForCoder, classForKeyedArchiver, copy, dealloc, debugDescription, description, dictionaryWithValuesForKeys, didChangeValueForKey, didChangeValueForKeyWithSetMutationUsingObjects, didChangeValuesAtIndexesForKey, doesNotRecognizeSelector, fileManagerShouldProceedAfterError, fileManagerWillProcessPath, finalize_objc, forwardingTargetForSelector, forwardInvocation, handleQueryWithUnboundKey, handleTakeValueForUnboundKey, hash, indexOfAccessibilityElement, isAccessibilityElement, isAccessibilityElementBlock, isEqual, isKindOfClass, isMemberOfClass, isProxy, methodForSelector, methodSignatureForSelector, mutableArrayValueForKey, mutableArrayValueForKeyPath, mutableCopy, mutableOrderedSetValueForKey, mutableOrderedSetValueForKeyPath, mutableSetValueForKey, mutableSetValueForKeyPath, observationInfo, observeValueForKeyPathOfObjectChangeContext, performSelector, performSelectorInBackgroundWithObject, performSelectorOnMainThreadWithObjectWaitUntilDone, performSelectorOnMainThreadWithObjectWaitUntilDoneModes, performSelectorOnThreadWithObjectWaitUntilDone, performSelectorOnThreadWithObjectWaitUntilDoneModes, performSelectorWithObject, performSelectorWithObjectAfterDelay, performSelectorWithObjectAfterDelayInModes, performSelectorWithObjectWithObject, prepareForInterfaceBuilder, provideImageDataBytesPerRowOrigin_Size_UserInfo, removeObserverForKeyPath, removeObserverForKeyPathContext, replacementObjectForCoder, replacementObjectForKeyedArchiver, respondsToSelector, self, setAccessibilityActivateBlock, setAccessibilityActivationPoint, setAccessibilityActivationPointBlock, setAccessibilityAttributedHint, setAccessibilityAttributedHintBlock, setAccessibilityAttributedLabel, setAccessibilityAttributedLabelBlock, setAccessibilityAttributedUserInputLabels, setAccessibilityAttributedUserInputLabelsBlock, setAccessibilityAttributedValue, setAccessibilityAttributedValueBlock, setAccessibilityContainerType, setAccessibilityContainerTypeBlock, setAccessibilityCustomActions, setAccessibilityCustomActionsBlock, setAccessibilityCustomRotors, setAccessibilityCustomRotorsBlock, setAccessibilityDecrementBlock, setAccessibilityDirectTouchOptions, setAccessibilityDragSourceDescriptors, setAccessibilityDropPointDescriptors, setAccessibilityElements, setAccessibilityElementsBlock, setAccessibilityElementsHidden, setAccessibilityElementsHiddenBlock, setAccessibilityFrame, setAccessibilityFrameBlock, setAccessibilityHeaderElementsBlock, setAccessibilityHint, setAccessibilityHintBlock, setAccessibilityIdentifierBlock, setAccessibilityIncrementBlock, setAccessibilityLabel, setAccessibilityLabelBlock, setAccessibilityLanguage, setAccessibilityLanguageBlock, setAccessibilityMagicTapBlock, setAccessibilityNavigationStyle, setAccessibilityNavigationStyleBlock, setAccessibilityPath, setAccessibilityPathBlock, setAccessibilityPerformEscapeBlock, setAccessibilityRespondsToUserInteraction, setAccessibilityRespondsToUserInteractionBlock, setAccessibilityShouldGroupAccessibilityChildrenBlock, setAccessibilityTextualContext, setAccessibilityTextualContextBlock, setAccessibilityTraits, setAccessibilityTraitsBlock, setAccessibilityUserInputLabels, setAccessibilityUserInputLabelsBlock, setAccessibilityValue, setAccessibilityValueBlock, setAccessibilityViewIsModal, setAccessibilityViewIsModalBlock, setAutomationElements, setAutomationElementsBlock, setIsAccessibilityElement, setIsAccessibilityElementBlock, setNilValueForKey, setObservationInfo, setShouldGroupAccessibilityChildren, setValueForKey, setValueForKeyPath, setValueForUndefinedKey, setValuesForKeysWithDictionary, shouldGroupAccessibilityChildren, storedValueForKey, superclass, takeStoredValueForKey, takeValueForKey, takeValueForKeyPath, takeValuesFromDictionary, unableToSetNilForKey, validateValueForKeyError, validateValueForKeyPathError, valueForKey, valueForKeyPath, valueForUndefinedKey, valuesForKeys, willChangeValueForKey, willChangeValueForKeyWithSetMutationUsingObjects, willChangeValuesAtIndexesForKey
-
-
-
-
Method Detail
-
accessInstanceVariablesDirectly
public static boolean accessInstanceVariablesDirectly()
-
alloc
public static MDLMesh alloc()
-
allocWithZone
public static MDLMesh allocWithZone(org.moe.natj.general.ptr.VoidPtr zone)
-
automaticallyNotifiesObserversForKey
public static boolean automaticallyNotifiesObserversForKey(@NotNull @NotNull java.lang.String key)
-
cancelPreviousPerformRequestsWithTarget
public static void cancelPreviousPerformRequestsWithTarget(@NotNull @NotNull java.lang.Object aTarget)
-
cancelPreviousPerformRequestsWithTargetSelectorObject
public static void cancelPreviousPerformRequestsWithTargetSelectorObject(@NotNull @NotNull java.lang.Object aTarget, @NotNull @NotNull org.moe.natj.objc.SEL aSelector, @Nullable @Nullable java.lang.Object anArgument)
-
classFallbacksForKeyedArchiver
@NotNull public static @NotNull NSArray<java.lang.String> classFallbacksForKeyedArchiver()
-
classForKeyedUnarchiver
@NotNull public static @NotNull 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()
-
instanceMethodForSelector
public static NSObject.Function_instanceMethodForSelector_ret instanceMethodForSelector(org.moe.natj.objc.SEL aSelector)
-
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
@NotNull public static @NotNull NSSet<java.lang.String> keyPathsForValuesAffectingValueForKey(@NotNull @NotNull java.lang.String key)
-
meshWithSCNGeometry
public static MDLMesh meshWithSCNGeometry(@NotNull @NotNull SCNGeometry scnGeometry)
API-Since: 9.0
-
meshWithSCNGeometryBufferAllocator
public static MDLMesh meshWithSCNGeometryBufferAllocator(@NotNull @NotNull SCNGeometry scnGeometry, @Nullable @Nullable MDLMeshBufferAllocator bufferAllocator)
API-Since: 10.0
-
new_objc
public static MDLMesh new_objc()
-
newIcosahedronWithRadiusInwardNormalsAllocator
public static MDLMesh newIcosahedronWithRadiusInwardNormalsAllocator(float radius, boolean inwardNormals, @Nullable @Nullable MDLMeshBufferAllocator allocator)
-
newIcosahedronWithRadiusInwardNormalsGeometryTypeAllocator
public static MDLMesh newIcosahedronWithRadiusInwardNormalsGeometryTypeAllocator(float radius, boolean inwardNormals, long geometryType, @Nullable @Nullable MDLMeshBufferAllocator allocator)
API-Since: 11.0
-
newSubdividedMeshSubmeshIndexSubdivisionLevels
public static MDLMesh newSubdividedMeshSubmeshIndexSubdivisionLevels(@NotNull @NotNull MDLMesh mesh, long submeshIndex, long subdivisionLevels)
-
objectWithSCNNodeBufferAllocator
public static MDLMesh objectWithSCNNodeBufferAllocator(@NotNull @NotNull SCNNode scnNode, @Nullable @Nullable MDLMeshBufferAllocator bufferAllocator)
-
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()
-
addAttributeWithNameFormat
public void addAttributeWithNameFormat(@NotNull @NotNull java.lang.String name, long format)addAttributeWithName:format Convenience method to add an attribute The mesh's allocator will be used to create storage for the new attribute.
-
addAttributeWithNameFormatTypeDataStride
public void addAttributeWithNameFormatTypeDataStride(@NotNull @NotNull java.lang.String name, long format, @NotNull @NotNull java.lang.String type, @NotNull @NotNull NSData data, long stride)addAttributeWithName:format:type:data:stride Create a new vertex attribute including an associated buffer with a copy of the supplied data, and update the vertex descriptor accordingly- Parameters:
name- The name the attribute can be found byformat- Format of the data, such as MDLVertexFormatFloat3type- The usage of the attribute, such as MDLVertexAttributePositiondata- Object containing the data to be used in the new vertex bufferstride- The increment in bytes from the start of one data entry to the next.
-
addAttributeWithNameFormatTypeDataStrideTime
public void addAttributeWithNameFormatTypeDataStrideTime(@NotNull @NotNull java.lang.String name, long format, @NotNull @NotNull java.lang.String type, @NotNull @NotNull NSData data, long stride, double time)addAttributeWithName:format:type:data:stride:time Create a new vertex attribute including an associated buffer with a copy of the supplied data, and update the vertex descriptor accordingly Adding an attribute, such as position data, at multiple times will result in attributes being created for each of those times. Attributes corresponding to multiple times can be retrieved from the vertex descriptor.- Parameters:
name- The name the attribute can be found byformat- Format of the data, such as MDLVertexFormatFloat3type- The usage of the attribute, such as MDLVertexAttributePositiondata- Object containing the data to be used in the new vertex bufferstride- The increment in bytes from the start of one data entry to the next.time- The time the attribute is to be invoked at.
-
addNormalsWithAttributeNamedCreaseThreshold
public void addNormalsWithAttributeNamedCreaseThreshold(@Nullable @Nullable java.lang.String attributeName, float creaseThreshold)addNormalsWithAttributeNamed:creaseThreshold: Calculate and add vertex normal data Uses the attribute named MDLVertexAttributePosition to calculate vertex normals. If the mesh does not have an attribute with 'attributeName', it will be added, otherwise the attribute name will be overwritten with vertex normal data. 'vertexDescriptor' will be updated to reflect the new attribute.- Parameters:
attributeName- Name is the attribute name of vertex normal attribute. If nil, vertex normals will be added with the MDLVertexAttributeNormal name stringcreaseThreshold- Threshold of the dot product between the 2 triangles after which their face normal will be smoothed out. Therefore, a threshold of 0 will smooth everything and a threshold of 1 won't smooth anything.
-
addTangentBasisForTextureCoordinateAttributeNamedNormalAttributeNamedTangentAttributeNamed
public void addTangentBasisForTextureCoordinateAttributeNamedNormalAttributeNamedTangentAttributeNamed(@NotNull @NotNull java.lang.String textureCoordinateAttributeName, @NotNull @NotNull java.lang.String normalAttributeName, @NotNull @NotNull java.lang.String tangentAttributeName)addTangentBasisForTextureCoordinateAttributeNamed:normalAttributeNamed:tangentAttributeNamed Create tangents which are orthogonal to the normal Uses the attribute named MDLVertexAttributePosition and textureCoordinateAttributeName and the specified normals to calculate tangent information. The mesh's vertexDescriptor will be updated to reflect the new attribute if necessary. Note that this method does NOT produce a T.w component which is used in B = (N x T) * T.w Please use addOrthTanBasisForTextureCoordinateAttributeNamed.- Parameters:
textureCoordinateAttributeName- texture coordinates to use in calculationsnormalAttributeName- normals to use in calculationstangentAttributeName- Name of a four component vertex tangent attribute.
-
addTangentBasisForTextureCoordinateAttributeNamedTangentAttributeNamedBitangentAttributeNamed
public void addTangentBasisForTextureCoordinateAttributeNamedTangentAttributeNamedBitangentAttributeNamed(@NotNull @NotNull java.lang.String textureCoordinateAttributeName, @NotNull @NotNull java.lang.String tangentAttributeName, @Nullable @Nullable java.lang.String bitangentAttributeName)addTangentBasisForTextureCoordinateAttributeNamed:tangentAttributeNamed:bitangentAttributeNamed Create a shader basis where the tangent and bitangent span the uv -> object space transform Uses the attribute named MDLVertexAttributePosition and textureCoordinateAttributeName to calculate tangent and bitangent attributes. The mesh's vertexDescriptor will be updated to reflect the new attributes if necessary. The basis may not be orthogonal; to gaurantee an orthogonal tangent basis please use addOrthTanBasisForTextureCoordinateAttibuteNamed selector.- Parameters:
textureCoordinateAttributeName- Name of texture coordinates to use in calculationstangentAttributeName- Name of vertex tangent attribute.bitangentAttributeName- Name of vertex bitangent attribute.
-
addUnwrappedTextureCoordinatesForAttributeNamed
public void addUnwrappedTextureCoordinatesForAttributeNamed(@NotNull @NotNull java.lang.String textureCoordinateAttributeName)addTextureCoordinatesForAttributeNamed:textureCoordinateAttributeName Creates texture coordinates by unwrapping the mesh Uses the attribute named MDLVertexAttributePosition and if available, the attribute named MDLVertexAttributeNormal to calculate texture coordinates- Parameters:
textureCoordinateAttributeName- texture coordinates to modify or create
-
allocator
@NotNull public @NotNull MDLMeshBufferAllocator allocator()
[@property] allocator allocator used to allocate contained mesh buffers
-
generateAmbientOcclusionTextureWithQualityAttenuationFactorObjectsToConsiderVertexAttributeNamedMaterialPropertyNamed
public boolean generateAmbientOcclusionTextureWithQualityAttenuationFactorObjectsToConsiderVertexAttributeNamedMaterialPropertyNamed(float bakeQuality, float attenuationFactor, @NotNull @NotNull NSArray<? extends MDLObject> objectsToConsider, @NotNull @NotNull java.lang.String vertexAttributeName, @NotNull @NotNull java.lang.String materialPropertyName)generateAmbientOcclusionTextureWithQuality: Creates an Ambient Occlusion texture, returns true upon success, false upon failure- Parameters:
bakeQuality- Float between 0 and 1 that defines quality of the bake process. 0 is of lower quality but bakes faster and uses less memory, where 1 is of higher quality.attenuationFactor- Float between 0 to 1 that defines how to attenuate the AO value. 0 doesn't change it, and at 1, all AO values are white except if they are originally completely black. Quadratic attenuation in between.objectsToConsider- NSArray of MDLMeshes containing the objects to raytrace againstvertexAttributeName- NSString of the MDLVertexAttribute where the vertex texture UVs will be stored. Creates it if it doesn't exist, otherwise overwrites current values.materialPropertyName- NSString of the MDLMaterialProperty that will store the texture in the Mesh.- Returns:
- Success or failure of the baking process.
-
generateAmbientOcclusionVertexColorsWithQualityAttenuationFactorObjectsToConsiderVertexAttributeNamed
public boolean generateAmbientOcclusionVertexColorsWithQualityAttenuationFactorObjectsToConsiderVertexAttributeNamed(float bakeQuality, float attenuationFactor, @NotNull @NotNull NSArray<? extends MDLObject> objectsToConsider, @NotNull @NotNull java.lang.String vertexAttributeName)
-
generateAmbientOcclusionVertexColorsWithRaysPerSampleAttenuationFactorObjectsToConsiderVertexAttributeNamed
public boolean generateAmbientOcclusionVertexColorsWithRaysPerSampleAttenuationFactorObjectsToConsiderVertexAttributeNamed(long raysPerSample, float attenuationFactor, @NotNull @NotNull NSArray<? extends MDLObject> objectsToConsider, @NotNull @NotNull java.lang.String vertexAttributeName)
-
generateLightMapTextureWithQualityLightsToConsiderObjectsToConsiderVertexAttributeNamedMaterialPropertyNamed
public boolean generateLightMapTextureWithQualityLightsToConsiderObjectsToConsiderVertexAttributeNamedMaterialPropertyNamed(float bakeQuality, @NotNull @NotNull NSArray<? extends MDLLight> lightsToConsider, @NotNull @NotNull NSArray<? extends MDLObject> objectsToConsider, @NotNull @NotNull java.lang.String vertexAttributeName, @NotNull @NotNull java.lang.String materialPropertyName)
-
generateLightMapVertexColorsWithLightsToConsiderObjectsToConsiderVertexAttributeNamed
public boolean generateLightMapVertexColorsWithLightsToConsiderObjectsToConsiderVertexAttributeNamed(@NotNull @NotNull NSArray<? extends MDLLight> lightsToConsider, @NotNull @NotNull NSArray<? extends MDLObject> objectsToConsider, @NotNull @NotNull java.lang.String vertexAttributeName)
-
initMeshBySubdividingMeshSubmeshIndexSubdivisionLevelsAllocator
public MDLMesh initMeshBySubdividingMeshSubmeshIndexSubdivisionLevelsAllocator(@NotNull @NotNull MDLMesh mesh, int submeshIndex, int subdivisionLevels, @Nullable @Nullable MDLMeshBufferAllocator allocator)
initMeshBySubdividingMesh:submeshIndex:subdivisionLevels:allocator Factory method that generates a subdivided mesh from a source mesh Subdivision levels over four are likely to generate more triangles than can be reasonably displayed. Index and vertex data will use the same allocator used for the source mesh. Loading an asset using the topology preservation flag set to YES will result in the best subdivision results.- Parameters:
mesh- Mesh from which to generate a subdivided meshsubmeshIndex- Index of submesh in Mesh's submesh array from which to generate a subdivided meshsubdivisionLevels- The number of levels to subdivide mesh- Returns:
- Returns a mesh subdivided to index level, unless subdivision is impossible.
-
initWithBufferAllocator
public MDLMesh initWithBufferAllocator(@Nullable @Nullable MDLMeshBufferAllocator bufferAllocator)
initWithAllocator: Initialize a mesh with an allocator- Returns:
- An empty mesh
-
initWithVertexBufferVertexCountDescriptorSubmeshes
public MDLMesh initWithVertexBufferVertexCountDescriptorSubmeshes(@NotNull @NotNull MDLMeshBuffer vertexBuffer, long vertexCount, @NotNull @NotNull MDLVertexDescriptor descriptor, @NotNull @NotNull NSArray<? extends MDLSubmesh> submeshes)
initWithVertexBuffer:vertexCount:descriptor:submeshes: Initialize object with a vertex buffer and a collection of submeshes- Parameters:
vertexBuffer- MDLMeshBuffer object containing all vertex data for the meshvertexCount- Number of vertices in the vertexBufferdescriptor- VertexDescriptor specifying how to interpret vertex datasubmeshes- Array of submeshes with index buffers referencing vertex data and/or materials to be applied to mesh- Returns:
- Initialized mesh or nil if descriptor's layout array does not describe a single buffer
-
initWithVertexBuffersVertexCountDescriptorSubmeshes
public MDLMesh initWithVertexBuffersVertexCountDescriptorSubmeshes(@NotNull @NotNull NSArray<?> vertexBuffers, long vertexCount, @NotNull @NotNull MDLVertexDescriptor descriptor, @NotNull @NotNull NSArray<? extends MDLSubmesh> submeshes)
initWithVertexBuffer:vertexCount:descriptor:submeshes: Initialize object with an array of vertex buffers (Structure of Arrays) and a collection of submeshes Allows initialization with the layout of the vertexBuffers in a structure-of-arrays form, in other words, non-interleaved vertex attributes- Parameters:
vertexCount- Number of vertices in vertexBuffersdescriptor- VertexDescriptor specifying how to interpret vertex datasubmeshes- Array of submeshes with index buffers referencing vertex data and/or materials to be applied to mesh- Returns:
- Initialized mesh or nil if descriptor's layout array is incompatible with vertexBuffers array
-
makeVerticesUnique
@Deprecated public void makeVerticesUnique()
Deprecated.makeVerticesUnique: Deindexes the vertex array If any vertices are shared on multiple faces, duplicate those vertices so faces do not share vertices. The vertex buffer and index buffers on submeshes may grow to accomadate any vertices added. API-Since: 9.0 Deprecated-Since: 11.0
-
removeAttributeNamed
public void removeAttributeNamed(@NotNull @NotNull java.lang.String name)removeAttributeNamed: remove an attribute if the named attribute does not exist, nothing happens.
-
replaceAttributeNamedWithData
public void replaceAttributeNamedWithData(@NotNull @NotNull java.lang.String name, @NotNull @NotNull MDLVertexAttributeData newData)replaceAttributeNamed:withData replace existing attribute data with new attribute data retaining the format of the replacement data. If the specified attribute does not already exist, it will be created.
-
setSubmeshes
public void setSubmeshes(@Nullable @Nullable NSMutableArray<MDLSubmesh> value)[@property] submeshes Array of submeshes containing an indexbuffer referencing the vertex data and material to be applied when the mesh is rendered
-
setVertexBuffers
public void setVertexBuffers(@NotNull @NotNull NSArray<?> value)[@property] vertexBuffers Array of buffers containing vertex data The vertex buffers in this array are indexed by the vertex descriptor.
-
setVertexCount
public void setVertexCount(long value)
[@property] vertexCount Number of vertices in the vertexBuffers The size of vertex data in each buffer can be computed by multiplying this value with the stride of the buffer in the vertexDescriptor's layout
-
setVertexDescriptor
public void setVertexDescriptor(@NotNull @NotNull MDLVertexDescriptor value)[@property] vertexDescriptor Immutable vertex descriptor for interpreting data in vertexBuffers Setting this applies the new layout in 'vertexBuffers' thus is a heavyweight operation as structured copies of almost all vertex buffer data could be made. Additionally, if the new vertexDescriptor does not have an attribute in the original vertexDescriptor, that attribute will be deleted. If the original vertexDescriptor does not have an attribute in the new vertexDescriptor, the data for the added attribute set as the added attribute's initializationValue property. The allocator associated with each original meshbuffer is used to reallocate the corresponding resultant meshbuffer.
-
submeshes
@Nullable public @Nullable NSMutableArray<MDLSubmesh> submeshes()
[@property] submeshes Array of submeshes containing an indexbuffer referencing the vertex data and material to be applied when the mesh is rendered
-
updateAttributeNamedWithData
public void updateAttributeNamedWithData(@NotNull @NotNull java.lang.String name, @NotNull @NotNull MDLVertexAttributeData newData)updateAttributeNamed:withData update existing attribute data with new attribute data retaining the format of the existing data. If the specified attribute does not already exist, it will be created with the same format as the newData.
-
vertexAttributeDataForAttributeNamed
@Nullable public @Nullable MDLVertexAttributeData vertexAttributeDataForAttributeNamed(@NotNull @NotNull java.lang.String name)
vertexAttributeDataForAttributeNamed: convenience selector to get quick access to vertex attribute data the vertex buffer will remain mapped until the MDLVertexAttributeData is freed.
-
vertexAttributeDataForAttributeNamedAsFormat
@Nullable public @Nullable MDLVertexAttributeData vertexAttributeDataForAttributeNamedAsFormat(@NotNull @NotNull java.lang.String name, long format)
vertexAttributeDataForAttributeNamed:asFormat convenience selector to get quick access to vertex attribute data reformatted to the requested format if necessary. If the desired format has less elements than the source attribute elements, excess elements will be discarded. If the desired format has more elements than the source attribute, then the destination elements will be set to zero. The vertex buffer will remain mapped until the MDLVertexAttributeData is freed.
-
vertexBuffers
@NotNull public @NotNull NSArray<?> vertexBuffers()
[@property] vertexBuffers Array of buffers containing vertex data The vertex buffers in this array are indexed by the vertex descriptor.
-
vertexCount
public long vertexCount()
[@property] vertexCount Number of vertices in the vertexBuffers The size of vertex data in each buffer can be computed by multiplying this value with the stride of the buffer in the vertexDescriptor's layout
-
vertexDescriptor
@NotNull public @NotNull MDLVertexDescriptor vertexDescriptor()
[@property] vertexDescriptor Immutable vertex descriptor for interpreting data in vertexBuffers Setting this applies the new layout in 'vertexBuffers' thus is a heavyweight operation as structured copies of almost all vertex buffer data could be made. Additionally, if the new vertexDescriptor does not have an attribute in the original vertexDescriptor, that attribute will be deleted. If the original vertexDescriptor does not have an attribute in the new vertexDescriptor, the data for the added attribute set as the added attribute's initializationValue property. The allocator associated with each original meshbuffer is used to reallocate the corresponding resultant meshbuffer.
-
addOrthTanBasisForTextureCoordinateAttributeNamedNormalAttributeNamedTangentAttributeNamed
public void addOrthTanBasisForTextureCoordinateAttributeNamedNormalAttributeNamedTangentAttributeNamed(@NotNull @NotNull java.lang.String textureCoordinateAttributeName, @NotNull @NotNull java.lang.String normalAttributeName, @NotNull @NotNull java.lang.String tangentAttributeName)addOrthTanBasisForTextureCoordinateAttributeNamed:normalAttributeNamed:tangentAttributeNamed Create an orthonormal tangent basis with tangent specified Uses the attribute named MDLVertexAttributePosition and textureCoordinateAttributeName and the specified normals to calculate tangent information. The mesh's vertexDescriptor will be updated to reflect the new attribute if necessary. Note that the bitangent can be calculated from the normal and tangent by B = (N x T) * T.w API-Since: 11.0- Parameters:
textureCoordinateAttributeName- texture coordinates to use in calculationsnormalAttributeName- normals to use in calculationstangentAttributeName- Name of a three/four component vertex tangent attribute.
-
flipTextureCoordinatesInAttributeNamed
public void flipTextureCoordinatesInAttributeNamed(@NotNull @NotNull java.lang.String textureCoordinateAttributeName)flipTextureCoordinatesInAttributeNamed: Flips texture coordinates by performing the operation (u,v) = (u, 1-v) Many application generate model files with texture coordinate mapping assuming a bottom left bitmap origin. It can be more convenient to have texture coordinates corresponding to an upper left bitmap origin. This selector will perform the flip operation if the requested texture coordinate attribute exists on the mesh. An exception will be raised if the attribute cannot be found API-Since: 11.0- Parameters:
textureCoordinateAttributeName- texture coordinates to modify
-
makeVerticesUniqueAndReturnError
public boolean makeVerticesUniqueAndReturnError(@Nullable @Nullable org.moe.natj.general.ptr.Ptr<NSError> error)makeVerticesUniqueAndReturnError: Deindexes the vertex array If any vertices are shared on multiple faces, duplicate those vertices so faces do not share vertices. The vertex buffer and index buffers on submeshes may grow to accomadate any vertices added. API-Since: 11.0
-
useStoredAccessor
@Deprecated public static boolean useStoredAccessor()
Deprecated.
-
-