Package apple.scenekit
Class SCNMaterial
- java.lang.Object
-
- org.moe.natj.general.NativeObject
-
- org.moe.natj.objc.ObjCObject
-
- apple.NSObject
-
- apple.scenekit.SCNMaterial
-
- All Implemented Interfaces:
NSCoding,NSCopying,NSSecureCoding,NSObject,SCNAnimatable,SCNShadable
public class SCNMaterial extends NSObject implements SCNAnimatable, SCNShadable, NSCopying, NSSecureCoding
SCNMaterial A SCNMaterial determines how a geometry is rendered. It encapsulates the colors and textures that define the appearance of 3d geometries.
-
-
Nested Class Summary
-
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
-
Nested classes/interfaces inherited from interface apple.scenekit.protocol.SCNShadable
SCNShadable.Block_handleBindingOfSymbolUsingBlock, SCNShadable.Block_handleUnbindingOfSymbolUsingBlock
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedSCNMaterial(org.moe.natj.general.Pointer peer)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description boolean_supportsSecureCoding()This property must return YES on all classes that allow secure coding.static booleanaccessInstanceVariablesDirectly()voidaddAnimationForKey(@NotNull SCNAnimation animation, @Nullable java.lang.String key)addAnimation:forKey: Adds and runs an animation Only SCNAnimation (preferred), CABasicAnimation, CAKeyframeAnimation and CAAnimationGroup are supported.voidaddAnimationPlayerForKey(@NotNull SCNAnimationPlayer player, @Nullable java.lang.String key)addAnimationPlayer:forKey: Add an animation player.static SCNMaterialalloc()static SCNMaterialallocWithZone(org.moe.natj.general.ptr.VoidPtr zone)@NotNull SCNMaterialPropertyambient()[@property] ambient Specifies the receiver's ambient property.@NotNull SCNMaterialPropertyambientOcclusion()[@property] ambientOcclusion The ambientOcclusion property specifies the ambient occlusion of the surface.@Nullable CAAnimationanimationForKey(@NotNull java.lang.String key)Deprecated.@NotNull NSArray<java.lang.String>animationKeys()[@property] animationKeys Returns an array containing the keys of all animations currently attached to the receiver.@Nullable SCNAnimationPlayeranimationPlayerForKey(@NotNull java.lang.String key)animationPlayerForKey: Returns the animation player with the given identifier This will return nil if no such animation player exists.static booleanautomaticallyNotifiesObserversForKey(@NotNull java.lang.String key)longblendMode()[@property] blendMode Specifies the receiver's blend mode.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()@NotNull SCNMaterialPropertyclearCoat()[@property] clearCoat The clearCoat property specifies color and intensity of the coat layer.@NotNull SCNMaterialPropertyclearCoatNormal()[@property] clearCoatNormal The clearCoatNormal property specifies color and intensity of the optional coat normal map.@NotNull SCNMaterialPropertyclearCoatRoughness()[@property] clearCoatRoughness The clearCoat property specifies color and intensity of the coat roughness.longcolorBufferWriteMask()Determines whether the receiver writes to the color buffer when rendered.@NotNull java.lang.ObjectcopyWithZone(@Nullable org.moe.natj.general.ptr.VoidPtr zone)longcullMode()[@property] cullMode Determines the culling mode of the receiver.static java.lang.StringdebugDescription_static()static java.lang.Stringdescription_static()@NotNull SCNMaterialPropertydiffuse()[@property] diffuse Specifies the receiver's diffuse property.@NotNull SCNMaterialPropertydisplacement()[@property] displacement The displacement property specifies how vertex are translated in tangent space.@NotNull SCNMaterialPropertyemission()[@property] emission The emission property specifies the amount of light the material emits.voidencodeWithCoder(@NotNull NSCoder coder)longfillMode()[@property] fillMode Determines of to how to rasterize the receiver's primitives.doublefresnelExponent()[@property] fresnelExponent Specifies the receiver's fresnel exponent value.voidhandleBindingOfSymbolUsingBlock(@NotNull java.lang.String symbol, SCNShadable.Block_handleBindingOfSymbolUsingBlock block)handleBindingOfSymbol:usingBlock: Sets the block to call at render time to bind the value for the specified symbol of the receiver's SCNProgram.voidhandleUnbindingOfSymbolUsingBlock(@NotNull java.lang.String symbol, SCNShadable.Block_handleUnbindingOfSymbolUsingBlock block)handleUnbindingOfSymbol:usingBlock: Sets the block to call at render time to unbind the value for the specified symbol of the receiver's SCNProgram.static longhash_static()SCNMaterialinit()SCNMaterialinitWithCoder(@NotNull NSCoder coder)NS_DESIGNATED_INITIALIZERstatic 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)booleanisAnimationForKeyPaused(@NotNull java.lang.String key)Deprecated.booleanisDoubleSided()[@property] doubleSided Determines whether the receiver is double sided.booleanisLitPerPixel()[@property] litPerPixel Determines whether the receiver is lit per pixel.static booleanisSubclassOfClass(org.moe.natj.objc.Class aClass)static @NotNull NSSet<java.lang.String>keyPathsForValuesAffectingValueForKey(@NotNull java.lang.String key)@NotNull java.lang.StringlightingModelName()[@property] lightingModelName Determines the receiver's lighting model.booleanlocksAmbientWithDiffuse()[@property] locksAmbientWithDiffuse Makes the ambient property automatically match the diffuse property.static SCNMaterialmaterial()material Creates and initialize a material instance.static SCNMaterialmaterialWithMDLMaterial(@NotNull MDLMaterial mdlMaterial)API-Since: 9.0@NotNull SCNMaterialPropertymetalness()[@property] metalness The metalness property specifies how metallic the material's surface appears.@Nullable NSNumberminimumLanguageVersion()[@property] minimumLanguageVersion The minimum language version required to interpret the shadable source code (wrapped MTLLanguageVersion).@NotNull SCNMaterialPropertymultiply()[@property] multiply The multiply property specifies a color or an image used to multiply the output fragments with.@Nullable java.lang.Stringname()[@property] name Determines the name of the receiver.static SCNMaterialnew_objc()@NotNull SCNMaterialPropertynormal()[@property] normal The normal property specifies the surface orientation.voidpauseAnimationForKey(@NotNull java.lang.String key)Deprecated.@Nullable SCNProgramprogram()[@property] program Specifies a custom program used to render the receiver.booleanreadsFromDepthBuffer()[@property] readsFromDepthBuffer Determines whether the receiver reads from the depth buffer when rendered.@NotNull SCNMaterialPropertyreflective()[@property] reflective The reflective property specifies the reflectivity of the surface.voidremoveAllAnimations()removeAllAnimations Remove all animations.voidremoveAllAnimationsWithBlendOutDuration(double duration)removeAllAnimationsWithBlendOutDuration Smoothly remove all animations.voidremoveAnimationForKey(@NotNull java.lang.String key)removeAnimationForKey Remove the animation with the given identifier.voidremoveAnimationForKeyBlendOutDuration(@NotNull java.lang.String key, double duration)removeAnimationForKey:blendOutDuration: Smoothly remove the animation with the given identifier.voidremoveAnimationForKeyFadeOutDuration(@NotNull java.lang.String key, double duration)Deprecated.static booleanresolveClassMethod(org.moe.natj.objc.SEL sel)static booleanresolveInstanceMethod(org.moe.natj.objc.SEL sel)voidresumeAnimationForKey(@NotNull java.lang.String key)Deprecated.@NotNull SCNMaterialPropertyroughness()[@property] roughness The roughness property specifies the apparent smoothness of the surface.@NotNull SCNMaterialPropertyselfIllumination()[@property] selfIllumination The selfIllumination property specifies a texture or a color that is added to the lighting contribution of the surface.voidsetBlendMode(long value)[@property] blendMode Specifies the receiver's blend mode.voidsetColorBufferWriteMask(long value)Determines whether the receiver writes to the color buffer when rendered.voidsetCullMode(long value)[@property] cullMode Determines the culling mode of the receiver.voidsetDoubleSided(boolean value)[@property] doubleSided Determines whether the receiver is double sided.voidsetFillMode(long value)[@property] fillMode Determines of to how to rasterize the receiver's primitives.voidsetFresnelExponent(double value)[@property] fresnelExponent Specifies the receiver's fresnel exponent value.voidsetLightingModelName(@NotNull java.lang.String value)[@property] lightingModelName Determines the receiver's lighting model.voidsetLitPerPixel(boolean value)[@property] litPerPixel Determines whether the receiver is lit per pixel.voidsetLocksAmbientWithDiffuse(boolean value)[@property] locksAmbientWithDiffuse Makes the ambient property automatically match the diffuse property.voidsetMinimumLanguageVersion(@Nullable NSNumber value)[@property] minimumLanguageVersion The minimum language version required to interpret the shadable source code (wrapped MTLLanguageVersion).voidsetName(@Nullable java.lang.String value)[@property] name Determines the name of the receiver.voidsetProgram(@Nullable SCNProgram value)[@property] program Specifies a custom program used to render the receiver.voidsetReadsFromDepthBuffer(boolean value)[@property] readsFromDepthBuffer Determines whether the receiver reads from the depth buffer when rendered.voidsetShaderModifiers(@Nullable NSDictionary<java.lang.String,java.lang.String> value)[@property] shaderModifiers Dictionary of shader modifiers snippets, targeting entry points.voidsetShininess(double value)[@property] shininess Specifies the receiver's shininess value.voidsetSpeedForAnimationKey(double speed, @NotNull java.lang.String key)Deprecated.voidsetTransparency(double value)[@property] transparency Specifies the receiver's transparency value.voidsetTransparencyMode(long value)[@property] transparencyMode Determines the transparency mode of the receiver.static voidsetVersion_static(long aVersion)voidsetWritesToDepthBuffer(boolean value)[@property] writeToDepthBuffer Determines whether the receiver writes to the depth buffer when rendered.@Nullable NSDictionary<java.lang.String,java.lang.String>shaderModifiers()[@property] shaderModifiers Dictionary of shader modifiers snippets, targeting entry points.doubleshininess()[@property] shininess Specifies the receiver's shininess value.@NotNull SCNMaterialPropertyspecular()[@property] specular Specifies the receiver's specular property.static org.moe.natj.objc.Classsuperclass_static()static booleansupportsSecureCoding()doubletransparency()[@property] transparency Specifies the receiver's transparency value.longtransparencyMode()[@property] transparencyMode Determines the transparency mode of the receiver.@NotNull SCNMaterialPropertytransparent()[@property] transparent The transparent property specifies the transparent areas of the material.static booleanuseStoredAccessor()Deprecated.static longversion_static()booleanwritesToDepthBuffer()[@property] writeToDepthBuffer Determines whether the receiver writes to the depth buffer when rendered.-
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 SCNMaterial alloc()
-
allocWithZone
public static SCNMaterial 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)
-
material
public static SCNMaterial material()
material Creates and initialize a material instance.
-
materialWithMDLMaterial
public static SCNMaterial materialWithMDLMaterial(@NotNull @NotNull MDLMaterial mdlMaterial)
API-Since: 9.0
-
new_objc
public static SCNMaterial 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()
-
supportsSecureCoding
public static boolean supportsSecureCoding()
-
version_static
public static long version_static()
-
addAnimationForKey
public void addAnimationForKey(@NotNull @NotNull SCNAnimation animation, @Nullable @Nullable java.lang.String key)Description copied from interface:SCNAnimatableaddAnimation:forKey: Adds and runs an animation Only SCNAnimation (preferred), CABasicAnimation, CAKeyframeAnimation and CAAnimationGroup are supported. The animation starts playing right away. The animation is automatically removed on completion unless if removedOnCompletion is explicitly set to NO.- Specified by:
addAnimationForKeyin interfaceSCNAnimatable- Parameters:
animation- Added animation.key- May be any string such that only one animation per unique key is added per animatable object.
-
ambient
@NotNull public @NotNull SCNMaterialProperty ambient()
[@property] ambient Specifies the receiver's ambient property. The ambient property specifies the amount of ambient light to reflect. This property has no visual impact on scenes that have no ambient light. Setting the ambient has no effect if locksAmbientWithDiffuse is set to YES.
-
ambientOcclusion
@NotNull public @NotNull SCNMaterialProperty ambientOcclusion()
[@property] ambientOcclusion The ambientOcclusion property specifies the ambient occlusion of the surface. The ambient occlusion is multiplied with the ambient light, then the result is added to the lighting contribution. This property has no visual impact on scenes that have no ambient light. When an ambient occlusion map is set, the ambient property is ignored. API-Since: 9.0
-
animationForKey
@Nullable @Deprecated public @Nullable CAAnimation animationForKey(@NotNull @NotNull java.lang.String key)
Deprecated.Description copied from interface:SCNAnimatableanimationForKey: Returns the animation with the given identifier This will return nil if no such animation exists. Attempting to modify any properties of the returned object will result in undefined behavior. API-Since: 8.0 Deprecated-Since: 11.0- Specified by:
animationForKeyin interfaceSCNAnimatable- Parameters:
key- The identifier for the animation to retrieve.
-
animationKeys
@NotNull public @NotNull NSArray<java.lang.String> animationKeys()
Description copied from interface:SCNAnimatable[@property] animationKeys Returns an array containing the keys of all animations currently attached to the receiver.- Specified by:
animationKeysin interfaceSCNAnimatable
-
blendMode
public long blendMode()
[@property] blendMode Specifies the receiver's blend mode. Defaults to SCNBlendModeAlpha. API-Since: 9.0
-
copyWithZone
@NotNull public @NotNull java.lang.Object copyWithZone(@Nullable @Nullable org.moe.natj.general.ptr.VoidPtr zone)- Specified by:
copyWithZonein interfaceNSCopying
-
cullMode
public long cullMode()
[@property] cullMode Determines the culling mode of the receiver. Defaults to SCNCullModeBack. Animatable.
-
diffuse
@NotNull public @NotNull SCNMaterialProperty diffuse()
[@property] diffuse Specifies the receiver's diffuse property. The diffuse property specifies the amount of light diffusely reflected from the surface. The diffuse light is reflected equally in all directions and is therefore independent of the point of view.
-
emission
@NotNull public @NotNull SCNMaterialProperty emission()
[@property] emission The emission property specifies the amount of light the material emits. This emission does not light up other surfaces in the scene.
-
encodeWithCoder
public void encodeWithCoder(@NotNull @NotNull NSCoder coder)- Specified by:
encodeWithCoderin interfaceNSCoding
-
fresnelExponent
public double fresnelExponent()
[@property] fresnelExponent Specifies the receiver's fresnel exponent value. Defaults to 0.0. Animatable. The effect of the reflectivity property is modulated by this property. The fresnelExponent changes the exponent of the reflectance. The bigger the exponent, the more concentrated the reflection is around the edges.
-
handleBindingOfSymbolUsingBlock
public void handleBindingOfSymbolUsingBlock(@NotNull @NotNull java.lang.String symbol, @Nullable SCNShadable.Block_handleBindingOfSymbolUsingBlock block)Description copied from interface:SCNShadablehandleBindingOfSymbol:usingBlock: Sets the block to call at render time to bind the value for the specified symbol of the receiver's SCNProgram. This method has no effect for symbols declared in shader modifiers. This method can only be used with OpenGL and OpenGLES based programs.- Specified by:
handleBindingOfSymbolUsingBlockin interfaceSCNShadable- Parameters:
symbol- The name of the symbol to bind a value for.block- The block to call to bind the specified symbol.
-
handleUnbindingOfSymbolUsingBlock
public void handleUnbindingOfSymbolUsingBlock(@NotNull @NotNull java.lang.String symbol, @Nullable SCNShadable.Block_handleUnbindingOfSymbolUsingBlock block)Description copied from interface:SCNShadablehandleUnbindingOfSymbol:usingBlock: Sets the block to call at render time to unbind the value for the specified symbol of the receiver's SCNProgram. This method has no effect for symbols declared in shader modifiers. This method can only be used with OpenGL and OpenGLES based programs.- Specified by:
handleUnbindingOfSymbolUsingBlockin interfaceSCNShadable- Parameters:
symbol- The name of the symbol to unbind.block- The block to call to unbind the specified symbol.
-
init
public SCNMaterial init()
-
initWithCoder
public SCNMaterial initWithCoder(@NotNull @NotNull NSCoder coder)
Description copied from interface:NSCodingNS_DESIGNATED_INITIALIZER- Specified by:
initWithCoderin interfaceNSCoding
-
isAnimationForKeyPaused
@Deprecated public boolean isAnimationForKeyPaused(@NotNull @NotNull java.lang.String key)Deprecated.Description copied from interface:SCNAnimatableisAnimationForKeyPaused: Returns whether the animation for the specified identifier is paused.- Specified by:
isAnimationForKeyPausedin interfaceSCNAnimatable- Parameters:
key- The identifier for the animation to query. API-Since: 8.0 Deprecated-Since: 11.0 Deprecated-Message: Use -[SCNAnimationPlayer paused] instead
-
isDoubleSided
public boolean isDoubleSided()
[@property] doubleSided Determines whether the receiver is double sided. Defaults to NO. Animatable.
-
setDoubleSided
public void setDoubleSided(boolean value)
[@property] doubleSided Determines whether the receiver is double sided. Defaults to NO. Animatable.
-
isLitPerPixel
public boolean isLitPerPixel()
[@property] litPerPixel Determines whether the receiver is lit per pixel. Defaults to YES. Animatable.
-
setLitPerPixel
public void setLitPerPixel(boolean value)
[@property] litPerPixel Determines whether the receiver is lit per pixel. Defaults to YES. Animatable.
-
lightingModelName
@NotNull public @NotNull java.lang.String lightingModelName()
[@property] lightingModelName Determines the receiver's lighting model. See above for the list of lighting models. Defaults to SCNLightingModelBlinn.
-
locksAmbientWithDiffuse
public boolean locksAmbientWithDiffuse()
[@property] locksAmbientWithDiffuse Makes the ambient property automatically match the diffuse property. Defaults to YES. Animatable.
-
metalness
@NotNull public @NotNull SCNMaterialProperty metalness()
[@property] metalness The metalness property specifies how metallic the material's surface appears. Lower values (darker colors) cause the material to appear more like a dielectric surface. Higher values (brighter colors) cause the surface to appear more metallic. This property is only used when 'lightingModelName' is 'SCNLightingModelPhysicallyBased'. API-Since: 10.0
-
multiply
@NotNull public @NotNull SCNMaterialProperty multiply()
[@property] multiply The multiply property specifies a color or an image used to multiply the output fragments with. The computed fragments are multiplied with the multiply value to produce the final fragments. This property may be used for shadow maps, to fade out or tint 3d objects.
-
name
@Nullable public @Nullable java.lang.String name()
[@property] name Determines the name of the receiver.
-
normal
@NotNull public @NotNull SCNMaterialProperty normal()
[@property] normal The normal property specifies the surface orientation. When an image is set on the normal property the material is automatically lit per pixel. Setting a color has no effect.
-
pauseAnimationForKey
@Deprecated public void pauseAnimationForKey(@NotNull @NotNull java.lang.String key)Deprecated.Description copied from interface:SCNAnimatablepauseAnimationForKey: Pause the animation with the given identifier.- Specified by:
pauseAnimationForKeyin interfaceSCNAnimatable- Parameters:
key- The identifier for the animation to pause. API-Since: 8.0 Deprecated-Since: 11.0 Deprecated-Message: Use -[SCNAnimationPlayer setPaused:] instead
-
program
@Nullable public @Nullable SCNProgram program()
Description copied from interface:SCNShadable[@property] program Specifies a custom program used to render the receiver. When a program is set, it overrides all the rendering parameters such as material settings and shaderModifiers.- Specified by:
programin interfaceSCNShadable
-
readsFromDepthBuffer
public boolean readsFromDepthBuffer()
[@property] readsFromDepthBuffer Determines whether the receiver reads from the depth buffer when rendered. Defaults to YES.
-
reflective
@NotNull public @NotNull SCNMaterialProperty reflective()
[@property] reflective The reflective property specifies the reflectivity of the surface. The surface will not actually reflect other objects in the scene. This property may be used as a sphere mapping to reflect a precomputed environment.
-
removeAllAnimations
public void removeAllAnimations()
Description copied from interface:SCNAnimatableremoveAllAnimations Remove all animations.- Specified by:
removeAllAnimationsin interfaceSCNAnimatable
-
removeAnimationForKey
public void removeAnimationForKey(@NotNull @NotNull java.lang.String key)Description copied from interface:SCNAnimatableremoveAnimationForKey Remove the animation with the given identifier.- Specified by:
removeAnimationForKeyin interfaceSCNAnimatable- Parameters:
key- The identifier for the animation to remove.
-
removeAnimationForKeyFadeOutDuration
@Deprecated public void removeAnimationForKeyFadeOutDuration(@NotNull @NotNull java.lang.String key, double duration)Deprecated.Description copied from interface:SCNAnimatableremoveAnimationForKey:fadeOutDuration: Smoothly remove the animation with the given identifier.- Specified by:
removeAnimationForKeyFadeOutDurationin interfaceSCNAnimatable- Parameters:
key- The identifier for the animation to remove.duration- The fade out duration used to remove the animation. API-Since: 8.0 Deprecated-Since: 11.0
-
resumeAnimationForKey
@Deprecated public void resumeAnimationForKey(@NotNull @NotNull java.lang.String key)Deprecated.Description copied from interface:SCNAnimatableresumeAnimationForKey: Resume the animation with the given identifier.- Specified by:
resumeAnimationForKeyin interfaceSCNAnimatable- Parameters:
key- The identifier for the animation to resume. API-Since: 8.0 Deprecated-Since: 11.0 Deprecated-Message: Use -[SCNAnimationPlayer setPaused:] instead
-
roughness
@NotNull public @NotNull SCNMaterialProperty roughness()
[@property] roughness The roughness property specifies the apparent smoothness of the surface. Lower values (darker colors) cause the material to appear shiny, with well-defined specular highlights. Higher values (brighter colors) cause specular highlights to spread out and the diffuse property of the material to become more retroreflective. This property is only used when 'lightingModelName' is 'SCNLightingModelPhysicallyBased'. API-Since: 10.0
-
selfIllumination
@NotNull public @NotNull SCNMaterialProperty selfIllumination()
[@property] selfIllumination The selfIllumination property specifies a texture or a color that is added to the lighting contribution of the surface. When a selfIllumination is set, the emission property is ignored. API-Since: 9.0
-
setBlendMode
public void setBlendMode(long value)
[@property] blendMode Specifies the receiver's blend mode. Defaults to SCNBlendModeAlpha. API-Since: 9.0
-
setCullMode
public void setCullMode(long value)
[@property] cullMode Determines the culling mode of the receiver. Defaults to SCNCullModeBack. Animatable.
-
setFresnelExponent
public void setFresnelExponent(double value)
[@property] fresnelExponent Specifies the receiver's fresnel exponent value. Defaults to 0.0. Animatable. The effect of the reflectivity property is modulated by this property. The fresnelExponent changes the exponent of the reflectance. The bigger the exponent, the more concentrated the reflection is around the edges.
-
setLightingModelName
public void setLightingModelName(@NotNull @NotNull java.lang.String value)[@property] lightingModelName Determines the receiver's lighting model. See above for the list of lighting models. Defaults to SCNLightingModelBlinn.
-
setLocksAmbientWithDiffuse
public void setLocksAmbientWithDiffuse(boolean value)
[@property] locksAmbientWithDiffuse Makes the ambient property automatically match the diffuse property. Defaults to YES. Animatable.
-
setName
public void setName(@Nullable @Nullable java.lang.String value)[@property] name Determines the name of the receiver.
-
setProgram
public void setProgram(@Nullable @Nullable SCNProgram value)Description copied from interface:SCNShadable[@property] program Specifies a custom program used to render the receiver. When a program is set, it overrides all the rendering parameters such as material settings and shaderModifiers.- Specified by:
setProgramin interfaceSCNShadable
-
setReadsFromDepthBuffer
public void setReadsFromDepthBuffer(boolean value)
[@property] readsFromDepthBuffer Determines whether the receiver reads from the depth buffer when rendered. Defaults to YES.
-
setShaderModifiers
public void setShaderModifiers(@Nullable @Nullable NSDictionary<java.lang.String,java.lang.String> value)Description copied from interface:SCNShadable[@property] shaderModifiers Dictionary of shader modifiers snippets, targeting entry points. The valid keys are the entry points described in the "Shader Modifier Entry Point" constants. The values are the code snippets formatted as described below. Shader modifiers allow you to inject shader code in the standard shaders of SceneKit. This injection is allowed in few controlled entry points, allowing specific kind of tasks in specific context. Each modifier can operate on specific structures along with access to global uniforms, that could be the standard SceneKit uniforms or its own declared uniforms. Shader modifiers can be used to tweak SceneKit rendering by adding custom code at the following entry points: 1. vertex (SCNShaderModifierEntryPointGeometry) 2. surface (SCNShaderModifierEntryPointSurface) 3. lighting (SCNShaderModifierEntryPointLightingModel) 4. fragment (SCNShaderModifierEntryPointFragment) See below for a detailed explanation of these entry points and the context they provide. Shader modifiers can be written in either GLSL or the Metal Shading Language. Metal shaders won't run on iOS 8 and macOS 10.10 or earlier. The structure of a shader modifier is: GLSL | uniform float myGrayAmount = 3.0; // Custom GLSL uniforms declarations are of the form `[uniform type uniformName [= defaultValue]]` | | // Optional global function definitions (for Metal: references to uniforms in global functions are not supported). | float mySin(float t) { | return sin(t); | } | | [#pragma transparent | opaque] | [#pragma body] | | // the shader modifier code snippet itself | vec3 myColor = myGrayAmount; | _output.color.rgb += myColor; Metal Shading Language | #pragma arguments | float myGrayAmount; // Custom Metal uniforms declarations require a #pragma and are of the form `[type name]` | | #pragma declaration | // Optional global function definitions (for Metal: references to uniforms in global functions are not supported). | float mySin(float t) { | return sin(t); | } | | [#pragma transparent | opaque] | [#pragma body] | | // the shader modifier code snippet itself | float3 myColor = myGrayAmount; | _output.color.rgb += myColor; The `#pragma body` directive Is only needed if you declared functions that must not be included in the shader code itself. The `#pragma transparent` directive Forces the rendering to be blended using the following equation: _output.color.rgb + (1 - _output.color.a) * dst.rgb; where `dst` represents the current fragment color. The rgb components must be premultiplied. The `#pragma opaque` directive Forces the rendering to be opaque. It then ignores the alpha component of the fragment. When using Metal, you can also transfer varying values from the vertex shader (geometry shader modifier) to the fragment shader (surface and/or fragment shader modifier): 1. Start by declaring the varying values in at least one of the shader modifiers: Metal Shading Language | #pragma varyings | half3 myVec; 2. Then write the varying values from the vertex shader (geometry shader modifier): Metal Shading Language | #pragma body | out.myVec = _geometry.normal.xyz * 0.5h + 0.5h; 3. Finally read the varying values from the fragment shader (surface and/or fragment shader modifier): Metal Shading Language | _output.color.rgb = saturate(in.myVec); SceneKit declares the following built-in uniforms: GLSL | Metal Shading Language | --------------------------------------------┼-------------------------------------------------------┤ float u_time | float scn_frame.time | The current time, in seconds vec2 u_inverseResolution | float2 scn_frame.inverseResolution | 1.0 / screen size --------------------------------------------┼-------------------------------------------------------┤ mat4 u_viewTransform | float4x4 scn_frame.viewTransform | See SCNViewTransform mat4 u_inverseViewTransform | float4x4 scn_frame.inverseViewTransform | mat4 u_projectionTransform | float4x4 scn_frame.projectionTransform | See SCNProjectionTransform mat4 u_inverseProjectionTransform | float4x4 scn_frame.inverseProjectionTransform | --------------------------------------------┼-------------------------------------------------------┤ mat4 u_normalTransform | float4x4 scn_node.normalTransform | See SCNNormalTransform mat4 u_modelTransform | float4x4 scn_node.modelTransform | See SCNModelTransform mat4 u_inverseModelTransform | float4x4 scn_node.inverseModelTransform | mat4 u_modelViewTransform | float4x4 scn_node.modelViewTransform | See SCNModelViewTransform mat4 u_inverseModelViewTransform | float4x4 scn_node.inverseModelViewTransform | mat4 u_modelViewProjectionTransform | float4x4 scn_node.modelViewProjectionTransform | See SCNModelViewProjectionTransform mat4 u_inverseModelViewProjectionTransform | float4x4 scn_node.inverseModelViewProjectionTransform | --------------------------------------------┼-------------------------------------------------------┤ mat2x3 u_boundingBox; | float2x3 scn_node.boundingBox | The bounding box of the current geometry, in model space, u_boundingBox[0].xyz and u_boundingBox[1].xyz being respectively the minimum and maximum corner of the box. mat2x3 u_worldBoundingBox; | float2x3 scn_node.worldBoundingBox | The bounding box of the current geometry, in world space. When writing shaders using the Metal Shading Language a complete description of the type of the scn_frame variable (SCNSceneBuffer) can be found in theheader file. The type of the scn_node variable is generated at compile time and there's no corresponding header file in the framework. In addition to these built-in uniforms, it is possible to use custom uniforms: The SCNGeometry and SCNMaterial classes are key-value coding compliant classes, which means that you can set values for arbitrary keys. Even if the key `myAmplitude` is not a declared property of the class, you can still set a value for it. Declaring a `myAmplitude` uniform in the shader modifier makes SceneKit observe the reveiver's `myAmplitude` key. Any change to that key will make SceneKit bind the uniform with the new value. The following GLSL and Metal Shading Language types (and their Objective-C counterparts) can be used to declare (and bind) custom uniforms: GLSL | Metal Shading Language | Objective-C | ------------┼------------------------┼---------------------------------------┤ int | int | NSNumber, NSInteger, int | float | float | NSNumber, CGFloat, float, double | vec2 | float2 | CGPoint | vec3 | float3 | SCNVector3 | vec4 | float4 | SCNVector4 | mat4, mat44 | float4x4 | SCNMatrix4 | sampler2D | texture2d | SCNMaterialProperty | samplerCube | texturecube | SCNMaterialProperty (with a cube map) | - | device const T* | MTLBuffer | Feature introduced in macOS 10.13, iOS 11.0 and tvOS 11.0 - | struct {...} | NSData | The entire struct can be set using NSData but it is also possible to set individual members using the member's name as a key and a value compatible with the member's type Common scalar types wrapped into a NSValue are also supported. The following prefixes are reserved by SceneKit and should not be used in custom names: 1. u_ 2. a_ 3. v_ Custom uniforms can be animated using explicit animations. - Specified by:
setShaderModifiersin interfaceSCNShadable
-
setShininess
public void setShininess(double value)
[@property] shininess Specifies the receiver's shininess value. Defaults to 1.0. Animatable.
-
setSpeedForAnimationKey
@Deprecated public void setSpeedForAnimationKey(double speed, @NotNull @NotNull java.lang.String key)Deprecated.Description copied from interface:SCNAnimatablesetSpeed:forAnimationKey: Update the animation speed of the animation with the given identifier.- Specified by:
setSpeedForAnimationKeyin interfaceSCNAnimatable- Parameters:
speed- The new speed of the animation.key- The identifier for the animation to update. API-Since: 10.0 Deprecated-Since: 11.0 Deprecated-Message: Use -[SCNAnimationPlayer setSpeed:] instead
-
setTransparency
public void setTransparency(double value)
[@property] transparency Specifies the receiver's transparency value. Defaults to 1.0. Animatable. The color of the transparent property is multiplied by this property. The result is then used to produce the final transparency according to the rule defined by the transparencyMode property.
-
setTransparencyMode
public void setTransparencyMode(long value)
[@property] transparencyMode Determines the transparency mode of the receiver. See above for the transparency modes. Defaults to SCNTransparencyModeDefault.
-
setWritesToDepthBuffer
public void setWritesToDepthBuffer(boolean value)
[@property] writeToDepthBuffer Determines whether the receiver writes to the depth buffer when rendered. Defaults to YES.
-
shaderModifiers
@Nullable public @Nullable NSDictionary<java.lang.String,java.lang.String> shaderModifiers()
Description copied from interface:SCNShadable[@property] shaderModifiers Dictionary of shader modifiers snippets, targeting entry points. The valid keys are the entry points described in the "Shader Modifier Entry Point" constants. The values are the code snippets formatted as described below. Shader modifiers allow you to inject shader code in the standard shaders of SceneKit. This injection is allowed in few controlled entry points, allowing specific kind of tasks in specific context. Each modifier can operate on specific structures along with access to global uniforms, that could be the standard SceneKit uniforms or its own declared uniforms. Shader modifiers can be used to tweak SceneKit rendering by adding custom code at the following entry points: 1. vertex (SCNShaderModifierEntryPointGeometry) 2. surface (SCNShaderModifierEntryPointSurface) 3. lighting (SCNShaderModifierEntryPointLightingModel) 4. fragment (SCNShaderModifierEntryPointFragment) See below for a detailed explanation of these entry points and the context they provide. Shader modifiers can be written in either GLSL or the Metal Shading Language. Metal shaders won't run on iOS 8 and macOS 10.10 or earlier. The structure of a shader modifier is: GLSL | uniform float myGrayAmount = 3.0; // Custom GLSL uniforms declarations are of the form `[uniform type uniformName [= defaultValue]]` | | // Optional global function definitions (for Metal: references to uniforms in global functions are not supported). | float mySin(float t) { | return sin(t); | } | | [#pragma transparent | opaque] | [#pragma body] | | // the shader modifier code snippet itself | vec3 myColor = myGrayAmount; | _output.color.rgb += myColor; Metal Shading Language | #pragma arguments | float myGrayAmount; // Custom Metal uniforms declarations require a #pragma and are of the form `[type name]` | | #pragma declaration | // Optional global function definitions (for Metal: references to uniforms in global functions are not supported). | float mySin(float t) { | return sin(t); | } | | [#pragma transparent | opaque] | [#pragma body] | | // the shader modifier code snippet itself | float3 myColor = myGrayAmount; | _output.color.rgb += myColor; The `#pragma body` directive Is only needed if you declared functions that must not be included in the shader code itself. The `#pragma transparent` directive Forces the rendering to be blended using the following equation: _output.color.rgb + (1 - _output.color.a) * dst.rgb; where `dst` represents the current fragment color. The rgb components must be premultiplied. The `#pragma opaque` directive Forces the rendering to be opaque. It then ignores the alpha component of the fragment. When using Metal, you can also transfer varying values from the vertex shader (geometry shader modifier) to the fragment shader (surface and/or fragment shader modifier): 1. Start by declaring the varying values in at least one of the shader modifiers: Metal Shading Language | #pragma varyings | half3 myVec; 2. Then write the varying values from the vertex shader (geometry shader modifier): Metal Shading Language | #pragma body | out.myVec = _geometry.normal.xyz * 0.5h + 0.5h; 3. Finally read the varying values from the fragment shader (surface and/or fragment shader modifier): Metal Shading Language | _output.color.rgb = saturate(in.myVec); SceneKit declares the following built-in uniforms: GLSL | Metal Shading Language | --------------------------------------------┼-------------------------------------------------------┤ float u_time | float scn_frame.time | The current time, in seconds vec2 u_inverseResolution | float2 scn_frame.inverseResolution | 1.0 / screen size --------------------------------------------┼-------------------------------------------------------┤ mat4 u_viewTransform | float4x4 scn_frame.viewTransform | See SCNViewTransform mat4 u_inverseViewTransform | float4x4 scn_frame.inverseViewTransform | mat4 u_projectionTransform | float4x4 scn_frame.projectionTransform | See SCNProjectionTransform mat4 u_inverseProjectionTransform | float4x4 scn_frame.inverseProjectionTransform | --------------------------------------------┼-------------------------------------------------------┤ mat4 u_normalTransform | float4x4 scn_node.normalTransform | See SCNNormalTransform mat4 u_modelTransform | float4x4 scn_node.modelTransform | See SCNModelTransform mat4 u_inverseModelTransform | float4x4 scn_node.inverseModelTransform | mat4 u_modelViewTransform | float4x4 scn_node.modelViewTransform | See SCNModelViewTransform mat4 u_inverseModelViewTransform | float4x4 scn_node.inverseModelViewTransform | mat4 u_modelViewProjectionTransform | float4x4 scn_node.modelViewProjectionTransform | See SCNModelViewProjectionTransform mat4 u_inverseModelViewProjectionTransform | float4x4 scn_node.inverseModelViewProjectionTransform | --------------------------------------------┼-------------------------------------------------------┤ mat2x3 u_boundingBox; | float2x3 scn_node.boundingBox | The bounding box of the current geometry, in model space, u_boundingBox[0].xyz and u_boundingBox[1].xyz being respectively the minimum and maximum corner of the box. mat2x3 u_worldBoundingBox; | float2x3 scn_node.worldBoundingBox | The bounding box of the current geometry, in world space. When writing shaders using the Metal Shading Language a complete description of the type of the scn_frame variable (SCNSceneBuffer) can be found in theheader file. The type of the scn_node variable is generated at compile time and there's no corresponding header file in the framework. In addition to these built-in uniforms, it is possible to use custom uniforms: The SCNGeometry and SCNMaterial classes are key-value coding compliant classes, which means that you can set values for arbitrary keys. Even if the key `myAmplitude` is not a declared property of the class, you can still set a value for it. Declaring a `myAmplitude` uniform in the shader modifier makes SceneKit observe the reveiver's `myAmplitude` key. Any change to that key will make SceneKit bind the uniform with the new value. The following GLSL and Metal Shading Language types (and their Objective-C counterparts) can be used to declare (and bind) custom uniforms: GLSL | Metal Shading Language | Objective-C | ------------┼------------------------┼---------------------------------------┤ int | int | NSNumber, NSInteger, int | float | float | NSNumber, CGFloat, float, double | vec2 | float2 | CGPoint | vec3 | float3 | SCNVector3 | vec4 | float4 | SCNVector4 | mat4, mat44 | float4x4 | SCNMatrix4 | sampler2D | texture2d | SCNMaterialProperty | samplerCube | texturecube | SCNMaterialProperty (with a cube map) | - | device const T* | MTLBuffer | Feature introduced in macOS 10.13, iOS 11.0 and tvOS 11.0 - | struct {...} | NSData | The entire struct can be set using NSData but it is also possible to set individual members using the member's name as a key and a value compatible with the member's type Common scalar types wrapped into a NSValue are also supported. The following prefixes are reserved by SceneKit and should not be used in custom names: 1. u_ 2. a_ 3. v_ Custom uniforms can be animated using explicit animations. - Specified by:
shaderModifiersin interfaceSCNShadable
-
shininess
public double shininess()
[@property] shininess Specifies the receiver's shininess value. Defaults to 1.0. Animatable.
-
specular
@NotNull public @NotNull SCNMaterialProperty specular()
[@property] specular Specifies the receiver's specular property. The specular property specifies the amount of light to reflect in a mirror-like manner. The specular intensity increases when the point of view lines up with the direction of the reflected light.
-
_supportsSecureCoding
public boolean _supportsSecureCoding()
Description copied from interface:NSSecureCodingThis property must return YES on all classes that allow secure coding. Subclasses of classes that adopt NSSecureCoding and override initWithCoder: must also override this method and return YES. The Secure Coding Guide should be consulted when writing methods that decode data.- Specified by:
_supportsSecureCodingin interfaceNSSecureCoding
-
transparency
public double transparency()
[@property] transparency Specifies the receiver's transparency value. Defaults to 1.0. Animatable. The color of the transparent property is multiplied by this property. The result is then used to produce the final transparency according to the rule defined by the transparencyMode property.
-
transparencyMode
public long transparencyMode()
[@property] transparencyMode Determines the transparency mode of the receiver. See above for the transparency modes. Defaults to SCNTransparencyModeDefault.
-
transparent
@NotNull public @NotNull SCNMaterialProperty transparent()
[@property] transparent The transparent property specifies the transparent areas of the material.
-
writesToDepthBuffer
public boolean writesToDepthBuffer()
[@property] writeToDepthBuffer Determines whether the receiver writes to the depth buffer when rendered. Defaults to YES.
-
addAnimationPlayerForKey
public void addAnimationPlayerForKey(@NotNull @NotNull SCNAnimationPlayer player, @Nullable @Nullable java.lang.String key)Description copied from interface:SCNAnimatableaddAnimationPlayer:forKey: Add an animation player. The animation player is not removed automatically on completion. The animation doesn't start playing immediatelly. Call "play" on the player to start playing it.- Specified by:
addAnimationPlayerForKeyin interfaceSCNAnimatable- Parameters:
player- Added animation player.key- May be any string such that only one animation per unique key is added per animatable object.
-
animationPlayerForKey
@Nullable public @Nullable SCNAnimationPlayer animationPlayerForKey(@NotNull @NotNull java.lang.String key)
Description copied from interface:SCNAnimatableanimationPlayerForKey: Returns the animation player with the given identifier This will return nil if no such animation player exists. API-Since: 11.0- Specified by:
animationPlayerForKeyin interfaceSCNAnimatable- Parameters:
key- The identifier for the animation player to retrieve.
-
colorBufferWriteMask
public long colorBufferWriteMask()
Determines whether the receiver writes to the color buffer when rendered. Defaults to SCNColorMaskAll. API-Since: 11.0
-
displacement
@NotNull public @NotNull SCNMaterialProperty displacement()
[@property] displacement The displacement property specifies how vertex are translated in tangent space. Pass a grayscale image for a simple 'elevation' or rgb image for a vector displacement. API-Since: 11.0
-
fillMode
public long fillMode()
[@property] fillMode Determines of to how to rasterize the receiver's primitives. Defaults to SCNFillModeFill. API-Since: 11.0
-
removeAnimationForKeyBlendOutDuration
public void removeAnimationForKeyBlendOutDuration(@NotNull @NotNull java.lang.String key, double duration)Description copied from interface:SCNAnimatableremoveAnimationForKey:blendOutDuration: Smoothly remove the animation with the given identifier.- Specified by:
removeAnimationForKeyBlendOutDurationin interfaceSCNAnimatable- Parameters:
key- The identifier for the animation to remove.duration- The blend out duration used to remove the animation. API-Since: 11.0
-
setColorBufferWriteMask
public void setColorBufferWriteMask(long value)
Determines whether the receiver writes to the color buffer when rendered. Defaults to SCNColorMaskAll. API-Since: 11.0
-
setFillMode
public void setFillMode(long value)
[@property] fillMode Determines of to how to rasterize the receiver's primitives. Defaults to SCNFillModeFill. API-Since: 11.0
-
clearCoat
@NotNull public @NotNull SCNMaterialProperty clearCoat()
[@property] clearCoat The clearCoat property specifies color and intensity of the coat layer. API-Since: 13.0
-
clearCoatNormal
@NotNull public @NotNull SCNMaterialProperty clearCoatNormal()
[@property] clearCoatNormal The clearCoatNormal property specifies color and intensity of the optional coat normal map. API-Since: 13.0
-
clearCoatRoughness
@NotNull public @NotNull SCNMaterialProperty clearCoatRoughness()
[@property] clearCoatRoughness The clearCoat property specifies color and intensity of the coat roughness. API-Since: 13.0
-
minimumLanguageVersion
@Nullable public @Nullable NSNumber minimumLanguageVersion()
Description copied from interface:SCNShadable[@property] minimumLanguageVersion The minimum language version required to interpret the shadable source code (wrapped MTLLanguageVersion). Defaults to nil. By default SceneKit does not use the most recent language version in order to reduce compilation times. If set to nil the shadable source code is assumed to compile with any language version greater than or equal to Metal 2.0. API-Since: 15.0- Specified by:
minimumLanguageVersionin interfaceSCNShadable
-
removeAllAnimationsWithBlendOutDuration
public void removeAllAnimationsWithBlendOutDuration(double duration)
Description copied from interface:SCNAnimatableremoveAllAnimationsWithBlendOutDuration Smoothly remove all animations.- Specified by:
removeAllAnimationsWithBlendOutDurationin interfaceSCNAnimatable- Parameters:
duration- The blend out duration used to remove the animation. API-Since: 15.0
-
setMinimumLanguageVersion
public void setMinimumLanguageVersion(@Nullable @Nullable NSNumber value)Description copied from interface:SCNShadable[@property] minimumLanguageVersion The minimum language version required to interpret the shadable source code (wrapped MTLLanguageVersion). Defaults to nil. By default SceneKit does not use the most recent language version in order to reduce compilation times. If set to nil the shadable source code is assumed to compile with any language version greater than or equal to Metal 2.0. API-Since: 15.0- Specified by:
setMinimumLanguageVersionin interfaceSCNShadable
-
useStoredAccessor
@Deprecated public static boolean useStoredAccessor()
Deprecated.
-
-