public class AVAudioEnvironmentNode extends AVAudioNode implements AVAudioMixing
Mixer node that simulates a 3D environment
AVAudioEnvironmentNode is a mixer node that simulates a 3D audio environment. Any node that conforms to the AVAudioMixing protocol (e.g. AVAudioPlayerNode) can act as a source in this environment.
The environment has an implicit "listener". By controlling the listener's position and orientation, the application controls the way the user experiences the virtual world. In addition, this node also defines properties for distance attenuation and reverberation that help characterize the environment.
It is important to note that AVAudio3DMixingSourceMode affects how inputs with different channel configurations are rendered. By default, only inputs with a mono channel are spatialized.
In order to set the environment node’s output to a multichannel format, use an AVAudioFormat with a desired AudioChannelLayout.
AVAudioNode.Block_installTapOnBusBufferSizeFormatBlockNSObject.Function_instanceMethodForSelector_ret, NSObject.Function_methodForSelector_ret| Modifier | Constructor and Description |
|---|---|
protected |
AVAudioEnvironmentNode(org.moe.natj.general.Pointer peer) |
| Modifier and Type | Method and Description |
|---|---|
static boolean |
accessInstanceVariablesDirectly() |
static AVAudioEnvironmentNode |
alloc() |
static AVAudioEnvironmentNode |
allocWithZone(org.moe.natj.general.ptr.VoidPtr zone) |
NSArray<? extends NSNumber> |
applicableRenderingAlgorithms()
[@property] applicableRenderingAlgorithms
|
static boolean |
automaticallyNotifiesObserversForKey(java.lang.String key) |
static void |
cancelPreviousPerformRequestsWithTarget(java.lang.Object aTarget) |
static void |
cancelPreviousPerformRequestsWithTargetSelectorObject(java.lang.Object aTarget,
org.moe.natj.objc.SEL aSelector,
java.lang.Object anArgument) |
static NSArray<java.lang.String> |
classFallbacksForKeyedArchiver() |
static org.moe.natj.objc.Class |
classForKeyedUnarchiver() |
static java.lang.String |
debugDescription_static() |
static java.lang.String |
description_static() |
AVAudioMixingDestination |
destinationForMixerBus(AVAudioNode mixer,
long bus)
Returns the AVAudioMixingDestination object corresponding to specified mixer node and
its input bus
|
AVAudioEnvironmentDistanceAttenuationParameters |
distanceAttenuationParameters()
[@property] distanceAttenuationParameters
|
static long |
hash_static() |
AVAudioEnvironmentNode |
init() |
static NSObject.Function_instanceMethodForSelector_ret |
instanceMethodForSelector(org.moe.natj.objc.SEL aSelector) |
static NSMethodSignature |
instanceMethodSignatureForSelector(org.moe.natj.objc.SEL aSelector) |
static boolean |
instancesRespondToSelector(org.moe.natj.objc.SEL aSelector) |
static boolean |
isSubclassOfClass(org.moe.natj.objc.Class aClass) |
static NSSet<java.lang.String> |
keyPathsForValuesAffectingValueForKey(java.lang.String key) |
AVAudio3DAngularOrientation |
listenerAngularOrientation()
[@property] listenerAngularOrientation
|
AVAudio3DPoint |
listenerPosition()
[@property] listenerPosition
|
AVAudio3DVectorOrientation |
listenerVectorOrientation()
[@property] listenerVectorOrientation
|
static AVAudioEnvironmentNode |
new_objc() |
long |
nextAvailableInputBus()
[@property] nextAvailableInputBus
|
float |
obstruction()
[@property] obstruction
|
float |
occlusion()
[@property] occlusion
|
long |
outputType()
[@property] outputType
|
float |
outputVolume()
[@property] outputVolume
|
float |
pan()
[@property] pan
|
long |
pointSourceInHeadMode()
[@property] pointSourceInHeadMode
|
AVAudio3DPoint |
position()
[@property] position
|
float |
rate()
[@property] rate
|
long |
renderingAlgorithm()
[@property] renderingAlgorithm
|
static boolean |
resolveClassMethod(org.moe.natj.objc.SEL sel) |
static boolean |
resolveInstanceMethod(org.moe.natj.objc.SEL sel) |
float |
reverbBlend()
[@property] reverbBlend
|
AVAudioEnvironmentReverbParameters |
reverbParameters()
[@property] reverbParameters
|
void |
setListenerAngularOrientation(AVAudio3DAngularOrientation value)
[@property] listenerAngularOrientation
|
void |
setListenerPosition(AVAudio3DPoint value)
[@property] listenerPosition
|
void |
setListenerVectorOrientation(AVAudio3DVectorOrientation value)
[@property] listenerVectorOrientation
|
void |
setObstruction(float value)
[@property] obstruction
|
void |
setOcclusion(float value)
[@property] occlusion
|
void |
setOutputType(long value)
[@property] outputType
|
void |
setOutputVolume(float value)
[@property] outputVolume
|
void |
setPan(float value)
[@property] pan
|
void |
setPointSourceInHeadMode(long value)
[@property] pointSourceInHeadMode
|
void |
setPosition(AVAudio3DPoint value)
[@property] position
|
void |
setRate(float value)
[@property] rate
|
void |
setRenderingAlgorithm(long value)
[@property] renderingAlgorithm
|
void |
setReverbBlend(float value)
[@property] reverbBlend
|
void |
setSourceMode(long value)
[@property] sourceMode
|
static void |
setVersion_static(long aVersion) |
void |
setVolume(float value)
[@property] volume
|
long |
sourceMode()
[@property] sourceMode
|
static org.moe.natj.objc.Class |
superclass_static() |
static long |
version_static() |
float |
volume()
[@property] volume
|
AUAudioUnit, engine, inputFormatForBus, installTapOnBusBufferSizeFormatBlock, lastRenderTime, latency, nameForInputBus, nameForOutputBus, numberOfInputs, numberOfOutputs, outputFormatForBus, outputPresentationLatency, removeTapOnBus, resetaccessibilityActivate, accessibilityActivationPoint, accessibilityAssistiveTechnologyFocusedIdentifiers, accessibilityAttributedHint, accessibilityAttributedLabel, accessibilityAttributedUserInputLabels, accessibilityAttributedValue, accessibilityContainerType, accessibilityCustomActions, accessibilityCustomRotors, accessibilityDecrement, accessibilityDragSourceDescriptors, accessibilityDropPointDescriptors, accessibilityElementAtIndex, accessibilityElementCount, accessibilityElementDidBecomeFocused, accessibilityElementDidLoseFocus, accessibilityElementIsFocused, accessibilityElements, accessibilityElementsHidden, accessibilityFrame, accessibilityHint, accessibilityIncrement, accessibilityLabel, accessibilityLanguage, accessibilityNavigationStyle, accessibilityPath, accessibilityPerformEscape, accessibilityPerformMagicTap, accessibilityRespondsToUserInteraction, accessibilityScroll, accessibilityTextualContext, accessibilityTraits, accessibilityUserInputLabels, accessibilityValue, accessibilityViewIsModal, addObserverForKeyPathOptionsContext, attemptRecoveryFromErrorOptionIndex, attemptRecoveryFromErrorOptionIndexDelegateDidRecoverSelectorContextInfo, autoContentAccessingProxy, awakeAfterUsingCoder, awakeFromNib, class_objc, classForCoder, classForKeyedArchiver, copy, dealloc, debugDescription, description, dictionaryWithValuesForKeys, didChangeValueForKey, didChangeValueForKeyWithSetMutationUsingObjects, didChangeValuesAtIndexesForKey, doesNotRecognizeSelector, fileManagerShouldProceedAfterError, fileManagerWillProcessPath, finalize_objc, forwardingTargetForSelector, forwardInvocation, hash, indexOfAccessibilityElement, isAccessibilityElement, 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, setAccessibilityActivationPoint, setAccessibilityAttributedHint, setAccessibilityAttributedLabel, setAccessibilityAttributedUserInputLabels, setAccessibilityAttributedValue, setAccessibilityContainerType, setAccessibilityCustomActions, setAccessibilityCustomRotors, setAccessibilityDragSourceDescriptors, setAccessibilityDropPointDescriptors, setAccessibilityElements, setAccessibilityElementsHidden, setAccessibilityFrame, setAccessibilityHint, setAccessibilityLabel, setAccessibilityLanguage, setAccessibilityNavigationStyle, setAccessibilityPath, setAccessibilityRespondsToUserInteraction, setAccessibilityTextualContext, setAccessibilityTraits, setAccessibilityUserInputLabels, setAccessibilityValue, setAccessibilityViewIsModal, setIsAccessibilityElement, setNilValueForKey, setObservationInfo, setShouldGroupAccessibilityChildren, setValueForKey, setValueForKeyPath, setValueForUndefinedKey, setValuesForKeysWithDictionary, shouldGroupAccessibilityChildren, superclass, validateValueForKeyError, validateValueForKeyPathError, valueForKey, valueForKeyPath, valueForUndefinedKey, willChangeValueForKey, willChangeValueForKeyWithSetMutationUsingObjects, willChangeValuesAtIndexesForKeyprotected AVAudioEnvironmentNode(org.moe.natj.general.Pointer peer)
public static boolean accessInstanceVariablesDirectly()
public static AVAudioEnvironmentNode alloc()
public static AVAudioEnvironmentNode allocWithZone(org.moe.natj.general.ptr.VoidPtr zone)
public NSArray<? extends NSNumber> applicableRenderingAlgorithms()
Returns an array of AVAudio3DMixingRenderingAlgorithm values based on the current output format
AVAudioEnvironmentNode supports several rendering algorithms per input bus which are defined
in
Depending on the current output format of the environment node, this method returns
an immutable array of the applicable rendering algorithms. This is important when the
environment node has been configured to a multichannel output format because only a subset
of the available rendering algorithms are designed to render to all of the channels.
This information should be retrieved after a successful connection to the destination node
via the engine's connect method.
public static boolean automaticallyNotifiesObserversForKey(java.lang.String key)
public static void cancelPreviousPerformRequestsWithTarget(java.lang.Object aTarget)
public static void cancelPreviousPerformRequestsWithTargetSelectorObject(java.lang.Object aTarget,
org.moe.natj.objc.SEL aSelector,
java.lang.Object anArgument)
public static NSArray<java.lang.String> classFallbacksForKeyedArchiver()
public static org.moe.natj.objc.Class classForKeyedUnarchiver()
public static java.lang.String debugDescription_static()
public static java.lang.String description_static()
public AVAudioMixingDestination destinationForMixerBus(AVAudioNode mixer, long bus)
AVAudioMixingWhen a source node is connected to multiple mixers downstream, setting AVAudioMixing properties directly on the source node will apply the change to all the mixers downstream. If you want to set/get properties on a specific mixer, use this method to get the corresponding AVAudioMixingDestination and set/get properties on it.
Note: - Properties set on individual AVAudioMixingDestination instances will not reflect at the source node level.
- AVAudioMixingDestination reference returned by this method could become invalid when there is any disconnection between the source and the mixer node. Hence this reference should not be retained and should be fetched every time you want to set/get properties on a specific mixer.
If the source node is not connected to the specified mixer/input bus, this method returns nil.
Calling this on an AVAudioMixingDestination instance returns self if the specified mixer/input bus matches its connection point, otherwise, it returns nil.
destinationForMixerBus in interface AVAudioMixingpublic AVAudioEnvironmentDistanceAttenuationParameters distanceAttenuationParameters()
The distance attenuation parameters for the environment
public static long hash_static()
public AVAudioEnvironmentNode init()
init in class AVAudioNodepublic static NSObject.Function_instanceMethodForSelector_ret instanceMethodForSelector(org.moe.natj.objc.SEL aSelector)
public static NSMethodSignature instanceMethodSignatureForSelector(org.moe.natj.objc.SEL aSelector)
public static boolean instancesRespondToSelector(org.moe.natj.objc.SEL aSelector)
public static boolean isSubclassOfClass(org.moe.natj.objc.Class aClass)
public static NSSet<java.lang.String> keyPathsForValuesAffectingValueForKey(java.lang.String key)
public AVAudio3DAngularOrientation listenerAngularOrientation()
The listener's orientation in the environment
Changing listenerAngularOrientation will result in a corresponding change in listenerVectorOrientation. All angles are specified in degrees. Default: The default orientation is with the listener looking directly along the negative Z axis. yaw: 0.0 pitch: 0.0 roll: 0.0
public AVAudio3DPoint listenerPosition()
Sets the listener's position in the 3D environment
The coordinates are specified in meters. Default: The default position of the listener is at the origin. x: 0.0 y: 0.0 z: 0.0
public AVAudio3DVectorOrientation listenerVectorOrientation()
The listener's orientation in the environment
Changing listenerVectorOrientation will result in a corresponding change in listenerAngularOrientation. Default: The default orientation is with the listener looking directly along the negative Z axis. forward: (0, 0, -1) up: (0, 1, 0)
public static AVAudioEnvironmentNode new_objc()
public long nextAvailableInputBus()
Find an unused input bus
This will find and return the first input bus to which no other node is connected.
public float obstruction()
AVAudio3DMixingSimulates filtering of the direct path of sound due to an obstacle
Only the direct path of sound between the source and listener is blocked.
Range: -100.0 -> 0.0 dB Default: 0.0 Mixer: AVAudioEnvironmentNode
obstruction in interface AVAudio3DMixingpublic float occlusion()
AVAudio3DMixingSimulates filtering of the direct and reverb paths of sound due to an obstacle
Both the direct and reverb paths of sound between the source and listener are blocked.
Range: -100.0 -> 0.0 dB Default: 0.0 Mixer: AVAudioEnvironmentNode
occlusion in interface AVAudio3DMixingpublic long outputType()
Type of output hardware to be used with AVAudio3DMixingRenderingAlgorithmAuto
Output hardware cannot be automatically determined in Manual Rendering modes or for wired output. This property can be used to override the output type if the correct type is known.
Selecting an output type that does not match the actual hardware can produce unexpected results, especially with AVAudioEnvironmentOutputTypeBuiltInSpeakers. An app choosing a value other than AVAudio3DMixingOutputTypeAuto should listen to route change notifications and update the output type accordingly.
Default: AVAudio3DMixingOutputTypeAuto
public float outputVolume()
The mixer's output volume.
This accesses the mixer's output volume (0.0-1.0, inclusive).
public float pan()
AVAudioStereoMixingSet a bus's stereo pan
Range: -1.0 -> 1.0 Default: 0.0 Mixer: AVAudioMixerNode
pan in interface AVAudioStereoMixingpublic long pointSourceInHeadMode()
AVAudio3DMixingIn-head rendering choice for AVAudio3DMixingSourceModePointSource in AVAudio3DMixingRenderingAlgorithmAuto
Default: AVAudio3DMixingPointSourceInHeadModeMono Mixer: AVAudioEnvironmentNode
pointSourceInHeadMode in interface AVAudio3DMixingpublic AVAudio3DPoint position()
AVAudio3DMixingThe location of the source in the 3D environment
The coordinates are specified in meters.
Mixer: AVAudioEnvironmentNode
position in interface AVAudio3DMixingpublic float rate()
AVAudio3DMixingChanges the playback rate of the input signal
A value of 2.0 results in the output audio playing one octave higher. A value of 0.5, results in the output audio playing one octave lower.
Range: 0.5 -> 2.0 Default: 1.0 Mixer: AVAudioEnvironmentNode
rate in interface AVAudio3DMixingpublic long renderingAlgorithm()
AVAudio3DMixingType of rendering algorithm used
Depending on the current output format of the AVAudioEnvironmentNode, only a subset of the rendering algorithms may be supported. An array of valid rendering algorithms can be retrieved by calling applicableRenderingAlgorithms on AVAudioEnvironmentNode.
Default: AVAudio3DMixingRenderingAlgorithmEqualPowerPanning Mixer: AVAudioEnvironmentNode
renderingAlgorithm in interface AVAudio3DMixingpublic static boolean resolveClassMethod(org.moe.natj.objc.SEL sel)
public static boolean resolveInstanceMethod(org.moe.natj.objc.SEL sel)
public float reverbBlend()
AVAudio3DMixingControls the blend of dry and reverb processed audio
This property controls the amount of the source's audio that will be processed by the reverb in AVAudioEnvironmentNode. A value of 0.5 will result in an equal blend of dry and processed (wet) audio.
Range: 0.0 (completely dry) -> 1.0 (completely wet) Default: 0.0 Mixer: AVAudioEnvironmentNode
reverbBlend in interface AVAudio3DMixingpublic AVAudioEnvironmentReverbParameters reverbParameters()
The reverb parameters for the environment
public void setListenerAngularOrientation(AVAudio3DAngularOrientation value)
The listener's orientation in the environment
Changing listenerAngularOrientation will result in a corresponding change in listenerVectorOrientation. All angles are specified in degrees. Default: The default orientation is with the listener looking directly along the negative Z axis. yaw: 0.0 pitch: 0.0 roll: 0.0
public void setListenerPosition(AVAudio3DPoint value)
Sets the listener's position in the 3D environment
The coordinates are specified in meters. Default: The default position of the listener is at the origin. x: 0.0 y: 0.0 z: 0.0
public void setListenerVectorOrientation(AVAudio3DVectorOrientation value)
The listener's orientation in the environment
Changing listenerVectorOrientation will result in a corresponding change in listenerAngularOrientation. Default: The default orientation is with the listener looking directly along the negative Z axis. forward: (0, 0, -1) up: (0, 1, 0)
public void setObstruction(float value)
AVAudio3DMixingSimulates filtering of the direct path of sound due to an obstacle
Only the direct path of sound between the source and listener is blocked.
Range: -100.0 -> 0.0 dB Default: 0.0 Mixer: AVAudioEnvironmentNode
setObstruction in interface AVAudio3DMixingpublic void setOcclusion(float value)
AVAudio3DMixingSimulates filtering of the direct and reverb paths of sound due to an obstacle
Both the direct and reverb paths of sound between the source and listener are blocked.
Range: -100.0 -> 0.0 dB Default: 0.0 Mixer: AVAudioEnvironmentNode
setOcclusion in interface AVAudio3DMixingpublic void setOutputType(long value)
Type of output hardware to be used with AVAudio3DMixingRenderingAlgorithmAuto
Output hardware cannot be automatically determined in Manual Rendering modes or for wired output. This property can be used to override the output type if the correct type is known.
Selecting an output type that does not match the actual hardware can produce unexpected results, especially with AVAudioEnvironmentOutputTypeBuiltInSpeakers. An app choosing a value other than AVAudio3DMixingOutputTypeAuto should listen to route change notifications and update the output type accordingly.
Default: AVAudio3DMixingOutputTypeAuto
public void setOutputVolume(float value)
The mixer's output volume.
This accesses the mixer's output volume (0.0-1.0, inclusive).
public void setPan(float value)
AVAudioStereoMixingSet a bus's stereo pan
Range: -1.0 -> 1.0 Default: 0.0 Mixer: AVAudioMixerNode
setPan in interface AVAudioStereoMixingpublic void setPointSourceInHeadMode(long value)
AVAudio3DMixingIn-head rendering choice for AVAudio3DMixingSourceModePointSource in AVAudio3DMixingRenderingAlgorithmAuto
Default: AVAudio3DMixingPointSourceInHeadModeMono Mixer: AVAudioEnvironmentNode
setPointSourceInHeadMode in interface AVAudio3DMixingpublic void setPosition(AVAudio3DPoint value)
AVAudio3DMixingThe location of the source in the 3D environment
The coordinates are specified in meters.
Mixer: AVAudioEnvironmentNode
setPosition in interface AVAudio3DMixingpublic void setRate(float value)
AVAudio3DMixingChanges the playback rate of the input signal
A value of 2.0 results in the output audio playing one octave higher. A value of 0.5, results in the output audio playing one octave lower.
Range: 0.5 -> 2.0 Default: 1.0 Mixer: AVAudioEnvironmentNode
setRate in interface AVAudio3DMixingpublic void setRenderingAlgorithm(long value)
AVAudio3DMixingType of rendering algorithm used
Depending on the current output format of the AVAudioEnvironmentNode, only a subset of the rendering algorithms may be supported. An array of valid rendering algorithms can be retrieved by calling applicableRenderingAlgorithms on AVAudioEnvironmentNode.
Default: AVAudio3DMixingRenderingAlgorithmEqualPowerPanning Mixer: AVAudioEnvironmentNode
setRenderingAlgorithm in interface AVAudio3DMixingpublic void setReverbBlend(float value)
AVAudio3DMixingControls the blend of dry and reverb processed audio
This property controls the amount of the source's audio that will be processed by the reverb in AVAudioEnvironmentNode. A value of 0.5 will result in an equal blend of dry and processed (wet) audio.
Range: 0.0 (completely dry) -> 1.0 (completely wet) Default: 0.0 Mixer: AVAudioEnvironmentNode
setReverbBlend in interface AVAudio3DMixingpublic void setSourceMode(long value)
AVAudio3DMixingControls how individual channels of an input bus are rendered
Default: AVAudio3DMixingSourceModeSpatializeIfMono Mixer: AVAudioEnvironmentNode
setSourceMode in interface AVAudio3DMixingpublic static void setVersion_static(long aVersion)
public void setVolume(float value)
AVAudioMixingSet a bus's input volume
Range: 0.0 -> 1.0 Default: 1.0 Mixers: AVAudioMixerNode, AVAudioEnvironmentNode
setVolume in interface AVAudioMixingpublic long sourceMode()
AVAudio3DMixingControls how individual channels of an input bus are rendered
Default: AVAudio3DMixingSourceModeSpatializeIfMono Mixer: AVAudioEnvironmentNode
sourceMode in interface AVAudio3DMixingpublic static org.moe.natj.objc.Class superclass_static()
public static long version_static()
public float volume()
AVAudioMixingSet a bus's input volume
Range: 0.0 -> 1.0 Default: 1.0 Mixers: AVAudioMixerNode, AVAudioEnvironmentNode
volume in interface AVAudioMixing