Package apple.audiotoolbox
Class AUAudioUnit
- java.lang.Object
-
- org.moe.natj.general.NativeObject
-
- org.moe.natj.objc.ObjCObject
-
- apple.NSObject
-
- apple.audiotoolbox.AUAudioUnit
-
- All Implemented Interfaces:
NSObject
- Direct Known Subclasses:
AUAudioUnitV2Bridge,AVSpeechSynthesisProviderAudioUnit
public class AUAudioUnit extends NSObject
AUAudioUnit An audio unit instance. AUAudioUnit is a host interface to an audio unit. Hosts can instantiate either version 2 or version 3 units with this class, and to some extent control whether an audio unit is instantiated in-process or in a separate extension process. Implementors of version 3 audio units can and should subclass AUAudioUnit. To port an existing version 2 audio unit easily, AUAudioUnitV2Bridge can be subclassed. These are the ways in which audio unit components can be registered: - (v2) Packaged into a component bundle containing an `AudioComponents` Info.plist entry, referring to an `AudioComponentFactoryFunction`. See AudioComponent.h. - (v2) AudioComponentRegister(). Associates a component description with an AudioComponentFactoryFunction. See AudioComponent.h. - (v3) Packaged into an app extension containing an AudioComponents Info.plist entry. The principal class must conform to the AUAudioUnitFactory protocol, which will typically instantiate an AUAudioUnit subclass. - (v3) `+[AUAudioUnit registerSubclass:asComponentDescription:name:version:]`. Associates a component description with an AUAudioUnit subclass. A host need not be aware of the concrete subclass of AUAudioUnit that is being instantiated. `initWithComponentDescription:options:error:` ensures that the proper subclass is used. When using AUAudioUnit with a v2 audio unit, or the C AudioComponent and AudioUnit API's with a v3 audio unit, all major pieces of functionality are bridged between the two API's. This header describes, for each v3 method or property, the v2 equivalent. API-Since: 9.0
-
-
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
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedAUAudioUnit(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()static AUAudioUnitalloc()booleanallocateRenderResourcesAndReturnError(@Nullable org.moe.natj.general.ptr.Ptr<NSError> outError)allocateRenderResourcesAndReturnError: Allocate resources required to render.static AUAudioUnitallocWithZone(org.moe.natj.general.ptr.VoidPtr zone)booleanallParameterValues()intAudioUnitMIDIProtocol()[@property] AudioUnitMIDIProtocol The MIDI protocol used by the Audio Unit for receiving MIDIEventList data.@Nullable java.lang.StringaudioUnitName()[@property] audioUnitName The audio unit's name.@Nullable java.lang.StringaudioUnitShortName()[@property] audioUnitShortName A short name for the audio unit.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)booleancanPerformInput()[@property] canPerformInput Whether the I/O device can perform input.booleancanPerformOutput()[@property] canPerformOutput Whether the I/O device can perform output.booleancanProcessInPlace()[@property] canProcessInPlace Expresses whether an audio unit can process in place.@Nullable NSArray<? extends NSNumber>channelCapabilities()[@property] channelCapabilities Expresses valid combinations of input and output channel counts.@Nullable NSArray<? extends NSNumber>channelMap()[@property] channelMap Specify a mapping of input channels to output channels.static @NotNull NSArray<java.lang.String>classFallbacksForKeyedArchiver()static @NotNull org.moe.natj.objc.ClassclassForKeyedUnarchiver()@NotNull AudioComponentcomponent()[@property] component The AudioComponent which was found based on componentDescription when the audio unit was created.AudioComponentDescriptioncomponentDescription()[@property] componentDescription The AudioComponentDescription with which the audio unit was created.@Nullable java.lang.StringcomponentName()[@property] componentName The unit's component's name.intcomponentVersion()[@property] componentVersion The unit's component's version.@Nullable java.lang.StringcontextName()[@property] contextName Information about the host context in which the audio unit is connected, for display in the audio unit's view.@Nullable AUAudioUnitPresetcurrentPreset()[@property] currentPreset The audio unit's last-selected preset.voiddeallocateRenderResources()deallocateRenderResources Deallocate resources allocated by allocateRenderResourcesAndReturnError: Hosts should call this after finishing rendering.static java.lang.StringdebugDescription_static()booleandeleteUserPresetError(@NotNull AUAudioUnitPreset userPreset, @Nullable org.moe.natj.general.ptr.Ptr<NSError> outError)deleteUserPreset:error Remove a user preset.static java.lang.Stringdescription_static()booleandisableProfileCableOnChannelError(@NotNull MIDICIProfile profile, byte cable, byte channel, @Nullable org.moe.natj.general.ptr.Ptr<NSError> outError)disableProfile:cable:onChannel:error: Disable a MIDI-CI Profile on the specified cable/channel.booleanenableProfileCableOnChannelError(@NotNull MIDICIProfile profile, byte cable, byte channel, @Nullable org.moe.natj.general.ptr.Ptr<NSError> outError)enableProfile:cable:onChannel:error: Enable a MIDI-CI Profile on the specified cable/channel.@Nullable NSArray<? extends AUAudioUnitPreset>factoryPresets()[@property] factoryPresets A collection of presets provided by the audio unit's developer.@Nullable NSDictionary<java.lang.String,?>fullState()[@property] fullState A persistable snapshot of the Audio Unit's properties and parameters, suitable for saving as a user preset.@Nullable NSDictionary<java.lang.String,?>fullStateForDocument()[@property] fullStateForDocument A persistable snapshot of the audio unit's properties and parameters, suitable for saving in a user's document.static longhash_static()inthostMIDIProtocol()[@property] hostMIDIProtocol The MIDI protocol to be used by the host for receiving MIDIEventList data.AUAudioUnitinit()AUAudioUnitinitWithComponentDescriptionError(AudioComponentDescription componentDescription, @Nullable org.moe.natj.general.ptr.Ptr<NSError> outError)initWithComponentDescription:error: Convenience initializer (omits options).AUAudioUnitinitWithComponentDescriptionOptionsError(AudioComponentDescription componentDescription, int options, @Nullable org.moe.natj.general.ptr.Ptr<NSError> outError)initWithComponentDescription:options:error: Designated initializer.@NotNull AUAudioUnitBusArrayinputBusses()[@property] inputBusses An audio unit's audio input connection points.@Nullable AUAudioUnit.Block_inputHandler_retinputHandler()[@property] inputHandler The block that the output unit will call to notify when input is available.static 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 voidinstantiateWithComponentDescriptionOptionsCompletionHandler(AudioComponentDescription componentDescription, int options, @NotNull AUAudioUnit.Block_instantiateWithComponentDescriptionOptionsCompletionHandler completionHandler)instantiateWithComponentDescription:options:completionHandler: Asynchronously create an AUAudioUnit instance.@NotNull AUAudioUnit.Block_internalRenderBlock_retinternalRenderBlock()Block which subclassers must provide (via a getter) to implement rendering.booleanisInputEnabled()[@property] inputEnabled Flag enabling audio input from the unit.booleanisMusicDeviceOrEffect()[@property] musicDeviceOrEffect Specifies whether an audio unit responds to MIDI events.booleanisOutputEnabled()[@property] outputEnabled Flag enabling audio output from the unit.booleanisRenderingOffline()[@property] renderingOffline Communicates to an audio unit that it is rendering offline.booleanisRunning()[@property] running The audio device's running state.static booleanisSubclassOfClass(org.moe.natj.objc.Class aClass)static @NotNull NSSet<java.lang.String>keyPathsForValuesAffectingValueForKey(@NotNull java.lang.String key)doublelatency()[@property] latency The audio unit's processing latency, in seconds.@Nullable java.lang.StringmanufacturerName()[@property] manufacturerName The manufacturer's name.intmaximumFramesToRender()[@property] maximumFramesToRender The maximum number of frames which the audio unit can render at once.@NotNull AUMessageChannelmessageChannelFor(@NotNull java.lang.String channelName)messageChannelFor: Returns an object for bidirectional communication between an Audio Unit and its host.longMIDIOutputBufferSizeHint()[@property] MIDIOutputBufferSizeHint Hint to control the size of the allocated buffer for outgoing MIDI events.@Nullable AUAudioUnit.Block_MIDIOutputEventBlock_retMIDIOutputEventBlock()[@property] MIDIOutputEventBlock Block used by the host to access the MIDI output generated by an Audio Unit.@Nullable AUAudioUnit.Block_MIDIOutputEventListBlock_retMIDIOutputEventListBlock()[@property] MIDIOutputEventListBlock Block used by the host to access the MIDIEventList output generated by an Audio Unit.@NotNull NSArray<java.lang.String>MIDIOutputNames()[@property] MIDIOutputNames Count, and names of, a plug-in's MIDI outputs.@Nullable AUAudioUnit.Block_musicalContextBlock_retmusicalContextBlock()[@property] musicalContextBlock A callback for the AU to call the host for musical context information.static AUAudioUnitnew_objc()@NotNull os_workgroup_tosWorkgroup()[@property] osWorkgroup The os_workgroup_t to which the input/output audio unit belongs.@NotNull AUAudioUnitBusArrayoutputBusses()[@property] outputBusses An audio unit's audio output connection points.@Nullable AUAudioUnit.Block_outputProvider_retoutputProvider()[@property] outputProvider The block that the output unit will call to get audio to send to the output.@NotNull NSArray<? extends NSNumber>parametersForOverviewWithCount(long count)parametersForOverviewWithCount: Returns the audio unit's `count` most important parameters.@Nullable AUParameterTreeparameterTree()[@property] parameterTree An audio unit's parameters, organized in a hierarchy.@Nullable NSDictionary<java.lang.String,?>presetStateForError(@NotNull AUAudioUnitPreset userPreset, @Nullable org.moe.natj.general.ptr.Ptr<NSError> outError)presetStateFor:error Retrieve the state stored in a user preset This method allows access to the contents of a preset without having to set that preset as current.@Nullable AUAudioUnit.Block_profileChangedBlock_retprofileChangedBlock()[@property] profileChangedBlock A block called when a device notifies that a MIDI-CI profile has been enabled or disabled.@NotNull MIDICIProfileStateprofileStateForCableChannel(byte cable, byte channel)profileStateForCable:channel: Given a MIDI cable and channel number, return the supported MIDI-CI Profiles.booleanprovidesUserInterface()[@property] providesUserInterface Specifies whether an audio unit provides UI (normally in the form of a view controller).static voidregisterSubclassAsComponentDescriptionNameVersion(@NotNull org.moe.natj.objc.Class cls, AudioComponentDescription componentDescription, @NotNull java.lang.String name, int version)Register an audio unit component implemented as an AUAudioUnit subclass.voidremoveRenderObserver(long token)removeRenderObserver: Remove an observer block added via tokenByAddingRenderObserver:@NotNull AUAudioUnit.Block_renderBlock_retrenderBlock()[@property] renderBlock Block which hosts use to ask the unit to render.@NotNull AUAudioUnit.Block_renderContextObserver_retrenderContextObserver()[@property] renderContextObserver Block called by the OS when the rendering context changes.longrenderQuality()[@property] renderQuality Provides a trade-off between rendering quality and CPU load.booleanrenderResourcesAllocated()[@property] renderResourcesAllocated returns YES if the unit has render resources allocated.voidreset()reset Reset transitory rendering state to its initial state.static booleanresolveClassMethod(org.moe.natj.objc.SEL sel)static booleanresolveInstanceMethod(org.moe.natj.objc.SEL sel)booleansaveUserPresetError(@NotNull AUAudioUnitPreset userPreset, @Nullable org.moe.natj.general.ptr.Ptr<NSError> outError)saveUserPreset:error Persistently save the current state of the audio unit into a userPreset The new preset will be added to userPresets and will become selectable by assigning it to the currentPreset property.@Nullable AUAudioUnit.Block_scheduleMIDIEventBlock_retscheduleMIDIEventBlock()[@property] scheduleMIDIEventBlock Block used to schedule MIDI events.@Nullable AUAudioUnit.Block_scheduleMIDIEventListBlock_retscheduleMIDIEventListBlock()[@property] scheduleMIDIEventListBlock Block used to schedule MIDIEventLists.@NotNull AUAudioUnit.Block_scheduleParameterBlock_retscheduleParameterBlock()[@property] scheduleParameterBlock Block which hosts use to schedule parameters.voidselectViewConfiguration(@NotNull AUAudioUnitViewConfiguration viewConfiguration)selectViewConfiguration Request a view configuration from the audio unit.voidsetChannelMap(@Nullable NSArray<? extends NSNumber> value)[@property] channelMap Specify a mapping of input channels to output channels.voidsetContextName(@Nullable java.lang.String value)[@property] contextName Information about the host context in which the audio unit is connected, for display in the audio unit's view.voidsetCurrentPreset(@Nullable AUAudioUnitPreset value)[@property] currentPreset The audio unit's last-selected preset.voidsetFullState(@Nullable NSDictionary<java.lang.String,?> value)[@property] fullState A persistable snapshot of the Audio Unit's properties and parameters, suitable for saving as a user preset.voidsetFullStateForDocument(@Nullable NSDictionary<java.lang.String,?> value)[@property] fullStateForDocument A persistable snapshot of the audio unit's properties and parameters, suitable for saving in a user's document.voidsetHostMIDIProtocol(int value)[@property] hostMIDIProtocol The MIDI protocol to be used by the host for receiving MIDIEventList data.voidsetInputEnabled(boolean value)[@property] inputEnabled Flag enabling audio input from the unit.voidsetInputHandler(@Nullable AUAudioUnit.Block_setInputHandler value)[@property] inputHandler The block that the output unit will call to notify when input is available.voidsetMaximumFramesToRender(int value)[@property] maximumFramesToRender The maximum number of frames which the audio unit can render at once.voidsetMIDIOutputBufferSizeHint(long value)[@property] MIDIOutputBufferSizeHint Hint to control the size of the allocated buffer for outgoing MIDI events.voidsetMIDIOutputEventBlock(@Nullable AUAudioUnit.Block_setMIDIOutputEventBlock value)[@property] MIDIOutputEventBlock Block used by the host to access the MIDI output generated by an Audio Unit.voidsetMIDIOutputEventListBlock(@Nullable AUAudioUnit.Block_setMIDIOutputEventListBlock value)[@property] MIDIOutputEventListBlock Block used by the host to access the MIDIEventList output generated by an Audio Unit.voidsetMusicalContextBlock(@Nullable AUAudioUnit.Block_setMusicalContextBlock value)[@property] musicalContextBlock A callback for the AU to call the host for musical context information.voidsetOutputEnabled(boolean value)[@property] outputEnabled Flag enabling audio output from the unit.voidsetOutputProvider(@Nullable AUAudioUnit.Block_setOutputProvider value)[@property] outputProvider The block that the output unit will call to get audio to send to the output.voidsetParameterTree(@Nullable AUParameterTree value)[@property] parameterTree An audio unit's parameters, organized in a hierarchy.voidsetProfileChangedBlock(@Nullable AUAudioUnit.Block_setProfileChangedBlock value)[@property] profileChangedBlock A block called when a device notifies that a MIDI-CI profile has been enabled or disabled.voidsetRenderingOffline(boolean value)[@property] renderingOffline Communicates to an audio unit that it is rendering offline.voidsetRenderQuality(long value)[@property] renderQuality Provides a trade-off between rendering quality and CPU load.voidsetRenderResourcesAllocated(boolean flag)setRenderResourcesAllocated:voidsetShouldBypassEffect(boolean value)[@property] shouldBypassEffect Directs an effect to route input directly to output, without any processing.voidsetTransportStateBlock(@Nullable AUAudioUnit.Block_setTransportStateBlock value)[@property] transportStateBlock A callback for the AU to call the host for transport state information.static voidsetVersion_static(long aVersion)booleanshouldBypassEffect()[@property] shouldBypassEffect Directs an effect to route input directly to output, without any processing.booleanshouldChangeToFormatForBus(@NotNull AVAudioFormat format, @NotNull AUAudioUnitBus bus)shouldChangeToFormat:forBus: This is called when setting the format on an AUAudioUnitBus.booleanstartHardwareAndReturnError(@Nullable org.moe.natj.general.ptr.Ptr<NSError> outError)startHardwareAndReturnError: Starts the audio hardware.voidstopHardware()stopHardware Stops the audio hardware.static org.moe.natj.objc.Classsuperclass_static()@NotNull NSIndexSetsupportedViewConfigurations(@NotNull NSArray<? extends AUAudioUnitViewConfiguration> availableViewConfigurations)supportedViewConfigurations Query the list of supported view configurations.booleansupportsMPE()[@property] supportsMPE Specifies whether an audio unit supports Multi-dimensional Polyphonic Expression.booleansupportsUserPresets()[@property] supportsUserPresets Specifies whether an audio unit supports loading and saving user presets The audio unit should set this property to YES if a user preset can be assigned to currentPreset.doubletailTime()[@property] tailTime The audio unit's tail time, in seconds.longtokenByAddingRenderObserver(@NotNull AUAudioUnit.Block_tokenByAddingRenderObserver observer)tokenByAddingRenderObserver: Add a block to be called on each render cycle.@Nullable AUAudioUnit.Block_transportStateBlock_rettransportStateBlock()[@property] transportStateBlock A callback for the AU to call the host for transport state information.@NotNull NSArray<? extends AUAudioUnitPreset>userPresets()[@property] userPresets A collection of presets saved by the user In addition to factory presets, provided by the audio unit vendor, users have the ability to save the values of the parameters of an audio unit into a user preset.static booleanuseStoredAccessor()Deprecated.static longversion_static()longvirtualMIDICableCount()[@property] virtualMIDICableCount The number of virtual MIDI cables implemented by a music device or effect.-
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 AUAudioUnit alloc()
-
allocWithZone
public static AUAudioUnit 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)
-
instantiateWithComponentDescriptionOptionsCompletionHandler
public static void instantiateWithComponentDescriptionOptionsCompletionHandler(AudioComponentDescription componentDescription, int options, @NotNull @NotNull AUAudioUnit.Block_instantiateWithComponentDescriptionOptionsCompletionHandler completionHandler)
instantiateWithComponentDescription:options:completionHandler: Asynchronously create an AUAudioUnit instance. Certain types of AUAudioUnits must be instantiated asynchronously -- see the discussion of kAudioComponentFlag_RequiresAsyncInstantiation in AudioToolbox/AudioComponent.h. Note: Do not block the main thread while waiting for the completion handler to be called; this can deadlock.- Parameters:
componentDescription- The AudioComponentDescription of the audio unit to instantiate.options- See the discussion of AudioComponentInstantiationOptions in AudioToolbox/AudioComponent.h.completionHandler- Called in a thread/dispatch queue context internal to the implementation. The client should retain the supplied AUAudioUnit.
-
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)
-
new_objc
public static AUAudioUnit new_objc()
-
registerSubclassAsComponentDescriptionNameVersion
public static void registerSubclassAsComponentDescriptionNameVersion(@NotNull @NotNull org.moe.natj.objc.Class cls, AudioComponentDescription componentDescription, @NotNull @NotNull java.lang.String name, int version)Register an audio unit component implemented as an AUAudioUnit subclass. This method dynamically registers the supplied AUAudioUnit subclass with the Audio Component system, in the context of the current process (only). After registering the subclass, it can be instantiated via AudioComponentInstanceNew, -[AUAudioUnit initWithComponentDescription:options:error:], and via any other API's which instantiate audio units via their component descriptions (e.g., or ).
-
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()
-
allParameterValues
public boolean allParameterValues()
-
allocateRenderResourcesAndReturnError
public boolean allocateRenderResourcesAndReturnError(@Nullable @Nullable org.moe.natj.general.ptr.Ptr<NSError> outError)allocateRenderResourcesAndReturnError: Allocate resources required to render. Hosts must call this before beginning to render. Subclassers should call the superclass implementation. Bridged to the v2 API AudioUnitInitialize().
-
audioUnitName
@Nullable public @Nullable java.lang.String audioUnitName()
[@property] audioUnitName The audio unit's name.
-
canPerformInput
public boolean canPerformInput()
[@property] canPerformInput Whether the I/O device can perform input.
-
canPerformOutput
public boolean canPerformOutput()
[@property] canPerformOutput Whether the I/O device can perform output.
-
canProcessInPlace
public boolean canProcessInPlace()
[@property] canProcessInPlace Expresses whether an audio unit can process in place. In-place processing is the ability for an audio unit to transform an input signal to an output signal in-place in the input buffer, without requiring a separate output buffer. A host can express its desire to process in place by using null mData pointers in the output buffer list. The audio unit may process in-place in the input buffers. See the discussion of renderBlock. Partially bridged to the v2 property kAudioUnitProperty_InPlaceProcessing; in v3 it is not settable. Defaults to NO. Subclassers can override to return YES.
-
channelCapabilities
@Nullable public @Nullable NSArray<? extends NSNumber> channelCapabilities()
[@property] channelCapabilities Expresses valid combinations of input and output channel counts. Elements are NSNumber containing integers; [0]=input count, [1]=output count, [2]=2nd input count, [3]=2nd output count, etc. An input, output count of (2, 2) signifies that the audio unit can process 2 input channels to 2 output channels. Negative numbers (-1, -2) indicate *any* number of channels. (-1, -1) means any number of channels on input and output as long as they are the same. (-1, -2) means any number of channels on input or output, without the requirement that the counts are the same. A negative number less than -2 is used to indicate a total number of channels across every bus in that scope, regardless of how many channels are set on any particular bus. For example, (-16, 2) indicates that a unit can accept up to 16 channels of input across its input busses, but will only produce 2 channels of output. Zero on either side (though typically input) means "not applicable", because there are no elements on that side. Bridged to the v2 property kAudioUnitProperty_SupportedNumChannels.
-
channelMap
@Nullable public @Nullable NSArray<? extends NSNumber> channelMap()
[@property] channelMap Specify a mapping of input channels to output channels. Converter and input/output audio units may support re-ordering or splitting of input channels to output channels. The number of channels in the channel map is the number of channels of the destination (output format). The channel map entries contain a channel number of the source channel that should be mapped to that destination channel. If -1 is specified, then that destination channel will not contain any channel from the source (so it will be silent). If the property value is nil, then the audio unit does not support this property. Bridged to the v2 property kAudioOutputUnitProperty_ChannelMap. API-Since: 10.0
-
component
@NotNull public @NotNull AudioComponent component()
[@property] component The AudioComponent which was found based on componentDescription when the audio unit was created.
-
componentDescription
public AudioComponentDescription componentDescription()
[@property] componentDescription The AudioComponentDescription with which the audio unit was created.
-
componentName
@Nullable public @Nullable java.lang.String componentName()
[@property] componentName The unit's component's name. By convention, an audio unit's component name is its manufacturer's name, plus ": ", plus the audio unit's name. The audioUnitName and manufacturerName properties are derived from the component name.
-
componentVersion
public int componentVersion()
[@property] componentVersion The unit's component's version.
-
contextName
@Nullable public @Nullable java.lang.String contextName()
[@property] contextName Information about the host context in which the audio unit is connected, for display in the audio unit's view. For example, a host could set "track 3" as the context, so that the audio unit's view could then display to the user "My audio unit on track 3". Bridged to the v2 property kAudioUnitProperty_ContextName.
-
currentPreset
@Nullable public @Nullable AUAudioUnitPreset currentPreset()
[@property] currentPreset The audio unit's last-selected preset. Hosts can let the user select a preset by setting this property. Note that when getting this property, it does not reflect whether parameters may have been modified since the preset was selected. Bridged to the v2 property kAudioUnitProperty_PresentPreset.
-
deallocateRenderResources
public void deallocateRenderResources()
deallocateRenderResources Deallocate resources allocated by allocateRenderResourcesAndReturnError: Hosts should call this after finishing rendering. Subclassers should call the superclass implementation. Bridged to the v2 API AudioUnitUninitialize().
-
factoryPresets
@Nullable public @Nullable NSArray<? extends AUAudioUnitPreset> factoryPresets()
[@property] factoryPresets A collection of presets provided by the audio unit's developer. A preset provides users of an audio unit with an easily-selectable, fine-tuned set of parameters provided by the developer. This property returns all of the available factory presets. Bridged to the v2 property kAudioUnitProperty_FactoryPresets.
-
fullState
@Nullable public @Nullable NSDictionary<java.lang.String,?> fullState()
[@property] fullState A persistable snapshot of the Audio Unit's properties and parameters, suitable for saving as a user preset. Hosts may use this property to save and restore the state of an Audio Unit being used in a user preset or document. The Audio Unit should not persist transitory properties such as stream formats, but should save and restore all parameters and custom properties. The base class implementation of this property saves the values of all parameters currently in the parameter tree. A subclass which dynamically produces multiple variants of the parameter tree needs to be aware that the serialization method does a depth-first preorder traversal of the tree. Bridged to the v2 property kAudioUnitProperty_ClassInfo.
-
fullStateForDocument
@Nullable public @Nullable NSDictionary<java.lang.String,?> fullStateForDocument()
[@property] fullStateForDocument A persistable snapshot of the audio unit's properties and parameters, suitable for saving in a user's document. This property is distinct from fullState in that some state is suitable for saving in user presets, while other state is not. For example, a synthesizer's master tuning setting could be considered global state, inappropriate for storing in reusable presets, but desirable for storing in a document for a specific live performance. Hosts saving documents should use this property. If the audio unit does not implement it, the base class simply sets/gets fullState. Bridged to the v2 property kAudioUnitProperty_ClassInfoFromDocument.
-
init
public AUAudioUnit init()
-
initWithComponentDescriptionError
public AUAudioUnit initWithComponentDescriptionError(AudioComponentDescription componentDescription, @Nullable @Nullable org.moe.natj.general.ptr.Ptr<NSError> outError)
initWithComponentDescription:error: Convenience initializer (omits options).
-
initWithComponentDescriptionOptionsError
public AUAudioUnit initWithComponentDescriptionOptionsError(AudioComponentDescription componentDescription, int options, @Nullable @Nullable org.moe.natj.general.ptr.Ptr<NSError> outError)
initWithComponentDescription:options:error: Designated initializer.- Parameters:
componentDescription- A single AUAudioUnit subclass may implement multiple audio units, for example, an effect that can also function as a generator, or a cluster of related effects. The component description specifies the component which was instantiated.options- Options for loading the unit in-process or out-of-process.outError- Returned in the event of failure.
-
inputBusses
@NotNull public @NotNull AUAudioUnitBusArray inputBusses()
[@property] inputBusses An audio unit's audio input connection points. Subclassers must override this property's getter. The implementation should return the same object every time it is asked for it, since clients can install KVO observers on it.
-
inputHandler
@Nullable public @Nullable AUAudioUnit.Block_inputHandler_ret inputHandler()
[@property] inputHandler The block that the output unit will call to notify when input is available. See discussion for AUInputHandler.
-
isInputEnabled
public boolean isInputEnabled()
[@property] inputEnabled Flag enabling audio input from the unit. Input is disabled by default. This must be set to YES if input audio is desired. Setting to YES will have no effect if canPerformInput is false.
-
setInputEnabled
public void setInputEnabled(boolean value)
[@property] inputEnabled Flag enabling audio input from the unit. Input is disabled by default. This must be set to YES if input audio is desired. Setting to YES will have no effect if canPerformInput is false.
-
isMusicDeviceOrEffect
public boolean isMusicDeviceOrEffect()
[@property] musicDeviceOrEffect Specifies whether an audio unit responds to MIDI events. This is implemented in the base class and returns YES if the component type is music device or music effect.
-
isOutputEnabled
public boolean isOutputEnabled()
[@property] outputEnabled Flag enabling audio output from the unit. Output is enabled by default. Setting to YES will have no effect if canPerformOutput is false.
-
setOutputEnabled
public void setOutputEnabled(boolean value)
[@property] outputEnabled Flag enabling audio output from the unit. Output is enabled by default. Setting to YES will have no effect if canPerformOutput is false.
-
isRenderingOffline
public boolean isRenderingOffline()
[@property] renderingOffline Communicates to an audio unit that it is rendering offline. A host should set this property when using an audio unit in a context where there are no realtime deadlines, before asking the unit to allocate render resources. An audio unit may respond by using a more expensive signal processing algorithm, or allowing itself to block at render time if data being generated on secondary work threads is not ready in time. (Normally, in a realtime thread, this data would have to be dropped). Bridged to the v2 property kAudioUnitProperty_OfflineRender.
-
setRenderingOffline
public void setRenderingOffline(boolean value)
[@property] renderingOffline Communicates to an audio unit that it is rendering offline. A host should set this property when using an audio unit in a context where there are no realtime deadlines, before asking the unit to allocate render resources. An audio unit may respond by using a more expensive signal processing algorithm, or allowing itself to block at render time if data being generated on secondary work threads is not ready in time. (Normally, in a realtime thread, this data would have to be dropped). Bridged to the v2 property kAudioUnitProperty_OfflineRender.
-
latency
public double latency()
[@property] latency The audio unit's processing latency, in seconds. This property reflects the delay between when an impulse in the unit's audio unit stream arrives in the input vs. output streams. This should reflect the delay due to signal processing (e.g. filters, FFT's, etc.), not delay or reverberation which is being applied as an effect. Note that a latency that varies with parameter settings, including bypass, is generally not useful to hosts. A host is usually only prepared to add delays before starting to render and those delays need to be fixed. A variable delay would introduce artifacts even if the host could track it. If an algorithm has a variable latency it should be adjusted upwards to some fixed latency within the audio unit. If for some reason this is not possible, then latency could be regarded as an unavoidable consequence of the algorithm and left unreported (i.e. with a value of 0). Bridged to the v2 property kAudioUnitProperty_Latency.
-
manufacturerName
@Nullable public @Nullable java.lang.String manufacturerName()
[@property] manufacturerName The manufacturer's name.
-
maximumFramesToRender
public int maximumFramesToRender()
[@property] maximumFramesToRender The maximum number of frames which the audio unit can render at once. This must be set by the host before render resources are allocated. It cannot be changed while render resources are allocated. Bridged to the v2 property kAudioUnitProperty_MaximumFramesPerSlice.
-
musicalContextBlock
@Nullable public @Nullable AUAudioUnit.Block_musicalContextBlock_ret musicalContextBlock()
[@property] musicalContextBlock A callback for the AU to call the host for musical context information. Note that an audio unit implementation accessing this property should cache it in realtime-safe storage before beginning to render. Bridged to the HostCallback_GetBeatAndTempo and HostCallback_GetMusicalTimeLocation callback members in kAudioUnitProperty_HostCallbacks.
-
outputBusses
@NotNull public @NotNull AUAudioUnitBusArray outputBusses()
[@property] outputBusses An audio unit's audio output connection points. Subclassers must override this property's getter. The implementation should return the same object every time it is asked for it, since clients can install KVO observers on it.
-
outputProvider
@Nullable public @Nullable AUAudioUnit.Block_outputProvider_ret outputProvider()
[@property] outputProvider The block that the output unit will call to get audio to send to the output. This block must be set if output is enabled.
-
parameterTree
@Nullable public @Nullable AUParameterTree parameterTree()
[@property] parameterTree An audio unit's parameters, organized in a hierarchy. Audio unit hosts can fetch this property to discover a unit's parameters. KVO notifications are issued on this member to notify the host of changes to the set of available parameters. AUAudioUnit has an additional pseudo-property, "allParameterValues", on which KVO notifications are issued in response to certain events where potentially all parameter values are invalidated. This includes changes to currentPreset, fullState, and fullStateForDocument. Hosts should not attempt to set this property. Subclassers should implement the parameterTree getter to expose parameters to hosts. They should cache as much as possible and send KVO notifications on "parameterTree" when altering the structure of the tree or the static information (ranges, etc) of parameters. This is similar to the v2 properties kAudioUnitProperty_ParameterList and kAudioUnitProperty_ParameterInfo. Note that it is not safe to modify this property in a real-time context.- Returns:
- A parameter tree object, or nil if the unit has no parameters.
-
parametersForOverviewWithCount
@NotNull public @NotNull NSArray<? extends NSNumber> parametersForOverviewWithCount(long count)
parametersForOverviewWithCount: Returns the audio unit's `count` most important parameters. This property allows a host to query an audio unit for some small number of parameters which are its "most important", to be displayed in a compact generic view. An audio unit subclass should return an array of NSNumbers representing the addresses of the `count` most important parameters. The base class returns an empty array regardless of count. Partially bridged to kAudioUnitProperty_ParametersForOverview (v2 hosts can use that property to access this v3 method of an audio unit).
-
removeRenderObserver
public void removeRenderObserver(long token)
removeRenderObserver: Remove an observer block added via tokenByAddingRenderObserver:- Parameters:
token- The token previously returned by tokenByAddingRenderObserver: Bridged to the v2 API AudioUnitRemoveRenderNotify().
-
renderQuality
public long renderQuality()
[@property] renderQuality Provides a trade-off between rendering quality and CPU load. The range of valid values is 0-127. Bridged to the v2 property kAudioUnitProperty_RenderQuality.
-
renderResourcesAllocated
public boolean renderResourcesAllocated()
[@property] renderResourcesAllocated returns YES if the unit has render resources allocated.
-
reset
public void reset()
reset Reset transitory rendering state to its initial state. Hosts should call this at the point of a discontinuity in the input stream being provided to an audio unit, for example, when seeking forward or backward within a track. In response, implementations should clear delay lines, filters, etc. Subclassers should call the superclass implementation. Bridged to the v2 API AudioUnitReset(), in the global scope.
-
scheduleMIDIEventBlock
@Nullable public @Nullable AUAudioUnit.Block_scheduleMIDIEventBlock_ret scheduleMIDIEventBlock()
[@property] scheduleMIDIEventBlock Block used to schedule MIDI events. As with renderBlock, a host should fetch and cache this block before calling allocateRenderResources if it intends to schedule MIDI events. This is implemented in the base class. It is nil when musicDeviceOrEffect is NO. Subclasses should not override. When hosts schedule events via this block, they are sent to the Audio Unit via the list of AURenderEvents delivered to internalRenderBlock. All events sent via this block will be delivered to the internalRenderBlock in the MIDI protocol returned by the AudioUnitMIDIProtocol property. For example, if AudioUnitMIDIProtocol returns kMIDIProtocol_2_0, incoming events will be translated to MIDI 2.0 if necessary. If AudioUnitMIDIProtocol is not set, events will be delivered as legacy MIDI. This bridged to the v2 API MusicDeviceMIDIEvent.
-
scheduleParameterBlock
@NotNull public @NotNull AUAudioUnit.Block_scheduleParameterBlock_ret scheduleParameterBlock()
[@property] scheduleParameterBlock Block which hosts use to schedule parameters. As with renderBlock, a host should fetch and cache this block before calling allocateRenderResources, if it intends to schedule parameters. The block is safe to call from any thread context, including realtime audio render threads. Subclassers should not override this; it is implemented in the base class and will schedule the events to be provided to the internalRenderBlock. Bridged to the v2 API AudioUnitScheduleParameters().
-
setChannelMap
public void setChannelMap(@Nullable @Nullable NSArray<? extends NSNumber> value)[@property] channelMap Specify a mapping of input channels to output channels. Converter and input/output audio units may support re-ordering or splitting of input channels to output channels. The number of channels in the channel map is the number of channels of the destination (output format). The channel map entries contain a channel number of the source channel that should be mapped to that destination channel. If -1 is specified, then that destination channel will not contain any channel from the source (so it will be silent). If the property value is nil, then the audio unit does not support this property. Bridged to the v2 property kAudioOutputUnitProperty_ChannelMap. API-Since: 10.0
-
setContextName
public void setContextName(@Nullable @Nullable java.lang.String value)[@property] contextName Information about the host context in which the audio unit is connected, for display in the audio unit's view. For example, a host could set "track 3" as the context, so that the audio unit's view could then display to the user "My audio unit on track 3". Bridged to the v2 property kAudioUnitProperty_ContextName.
-
setCurrentPreset
public void setCurrentPreset(@Nullable @Nullable AUAudioUnitPreset value)[@property] currentPreset The audio unit's last-selected preset. Hosts can let the user select a preset by setting this property. Note that when getting this property, it does not reflect whether parameters may have been modified since the preset was selected. Bridged to the v2 property kAudioUnitProperty_PresentPreset.
-
setFullState
public void setFullState(@Nullable @Nullable NSDictionary<java.lang.String,?> value)[@property] fullState A persistable snapshot of the Audio Unit's properties and parameters, suitable for saving as a user preset. Hosts may use this property to save and restore the state of an Audio Unit being used in a user preset or document. The Audio Unit should not persist transitory properties such as stream formats, but should save and restore all parameters and custom properties. The base class implementation of this property saves the values of all parameters currently in the parameter tree. A subclass which dynamically produces multiple variants of the parameter tree needs to be aware that the serialization method does a depth-first preorder traversal of the tree. Bridged to the v2 property kAudioUnitProperty_ClassInfo.
-
setFullStateForDocument
public void setFullStateForDocument(@Nullable @Nullable NSDictionary<java.lang.String,?> value)[@property] fullStateForDocument A persistable snapshot of the audio unit's properties and parameters, suitable for saving in a user's document. This property is distinct from fullState in that some state is suitable for saving in user presets, while other state is not. For example, a synthesizer's master tuning setting could be considered global state, inappropriate for storing in reusable presets, but desirable for storing in a document for a specific live performance. Hosts saving documents should use this property. If the audio unit does not implement it, the base class simply sets/gets fullState. Bridged to the v2 property kAudioUnitProperty_ClassInfoFromDocument.
-
setInputHandler
public void setInputHandler(@Nullable @Nullable AUAudioUnit.Block_setInputHandler value)[@property] inputHandler The block that the output unit will call to notify when input is available. See discussion for AUInputHandler.
-
setMaximumFramesToRender
public void setMaximumFramesToRender(int value)
[@property] maximumFramesToRender The maximum number of frames which the audio unit can render at once. This must be set by the host before render resources are allocated. It cannot be changed while render resources are allocated. Bridged to the v2 property kAudioUnitProperty_MaximumFramesPerSlice.
-
setMusicalContextBlock
public void setMusicalContextBlock(@Nullable @Nullable AUAudioUnit.Block_setMusicalContextBlock value)[@property] musicalContextBlock A callback for the AU to call the host for musical context information. Note that an audio unit implementation accessing this property should cache it in realtime-safe storage before beginning to render. Bridged to the HostCallback_GetBeatAndTempo and HostCallback_GetMusicalTimeLocation callback members in kAudioUnitProperty_HostCallbacks.
-
setOutputProvider
public void setOutputProvider(@Nullable @Nullable AUAudioUnit.Block_setOutputProvider value)[@property] outputProvider The block that the output unit will call to get audio to send to the output. This block must be set if output is enabled.
-
setRenderQuality
public void setRenderQuality(long value)
[@property] renderQuality Provides a trade-off between rendering quality and CPU load. The range of valid values is 0-127. Bridged to the v2 property kAudioUnitProperty_RenderQuality.
-
setRenderResourcesAllocated
public void setRenderResourcesAllocated(boolean flag)
setRenderResourcesAllocated:- Parameters:
flag- In the base class implementation of allocateRenderResourcesAndReturnError:, the property renderResourcesAllocated is set to YES. If allocateRenderResourcesAndReturnError: should fail in a subclass, subclassers must use this method to set renderResourcesAllocated to NO.
-
setShouldBypassEffect
public void setShouldBypassEffect(boolean value)
[@property] shouldBypassEffect Directs an effect to route input directly to output, without any processing. Bridged to the v2 property kAudioUnitProperty_BypassEffect.
-
setTransportStateBlock
public void setTransportStateBlock(@Nullable @Nullable AUAudioUnit.Block_setTransportStateBlock value)[@property] transportStateBlock A callback for the AU to call the host for transport state information. Note that an audio unit implementation accessing this property should cache it in realtime-safe storage before beginning to render. Bridged to the HostCallback_GetTransportState and HostCallback_GetTransportState2 callback members in kAudioUnitProperty_HostCallbacks.
-
shouldBypassEffect
public boolean shouldBypassEffect()
[@property] shouldBypassEffect Directs an effect to route input directly to output, without any processing. Bridged to the v2 property kAudioUnitProperty_BypassEffect.
-
shouldChangeToFormatForBus
public boolean shouldChangeToFormatForBus(@NotNull @NotNull AVAudioFormat format, @NotNull @NotNull AUAudioUnitBus bus)shouldChangeToFormat:forBus: This is called when setting the format on an AUAudioUnitBus. The bus has already checked that the format meets the channel constraints of the bus. The AU can override this method to check before allowing a new format to be set on the bus. If this method returns NO, then the new format will not be set on the bus. The default implementation returns NO if the unit has renderResourcesAllocated, otherwise it results YES.- Parameters:
format- An AVAudioFormat which is proposed as the new format.bus- The AUAudioUnitBus on which the format will be changed.
-
startHardwareAndReturnError
public boolean startHardwareAndReturnError(@Nullable @Nullable org.moe.natj.general.ptr.Ptr<NSError> outError)startHardwareAndReturnError: Starts the audio hardware.- Parameters:
outError- Returned in the event of failure.
-
stopHardware
public void stopHardware()
stopHardware Stops the audio hardware.
-
supportsMPE
public boolean supportsMPE()
[@property] supportsMPE Specifies whether an audio unit supports Multi-dimensional Polyphonic Expression. Bridged to the v2 property kAudioUnitProperty_SupportsMPE. API-Since: 10.0
-
tailTime
public double tailTime()
[@property] tailTime The audio unit's tail time, in seconds. This property reflects the time interval between when the input stream ends or otherwise transitions to silence, and when the output stream becomes silent. Unlike latency, this should reflect the duration of a delay or reverb effect. Bridged to the v2 property kAudioUnitProperty_TailTime.
-
tokenByAddingRenderObserver
public long tokenByAddingRenderObserver(@NotNull @NotNull AUAudioUnit.Block_tokenByAddingRenderObserver observer)tokenByAddingRenderObserver: Add a block to be called on each render cycle. The supplied block is called at the beginning and ending of each render cycle. It should not make any blocking calls. This method is implemented in the base class AUAudioUnit, and should not be overridden. Bridged to the v2 API AudioUnitAddRenderNotify().- Parameters:
observer- The block to call.- Returns:
- A token to be used when removing the observer.
-
transportStateBlock
@Nullable public @Nullable AUAudioUnit.Block_transportStateBlock_ret transportStateBlock()
[@property] transportStateBlock A callback for the AU to call the host for transport state information. Note that an audio unit implementation accessing this property should cache it in realtime-safe storage before beginning to render. Bridged to the HostCallback_GetTransportState and HostCallback_GetTransportState2 callback members in kAudioUnitProperty_HostCallbacks.
-
virtualMIDICableCount
public long virtualMIDICableCount()
[@property] virtualMIDICableCount The number of virtual MIDI cables implemented by a music device or effect. A music device or MIDI effect can support up to 256 virtual MIDI cables of input; this property expresses the number of cables supported by the audio unit.
-
MIDIOutputBufferSizeHint
public long MIDIOutputBufferSizeHint()
[@property] MIDIOutputBufferSizeHint Hint to control the size of the allocated buffer for outgoing MIDI events. This property allows the plug-in to provide a hint to the framework regarding the size of its outgoing MIDI data buffer. If the plug-in produces more MIDI output data than the default size of the allocated buffer, then the plug-in can provide this property to increase the size of this buffer. The value represents the number of 3-byte Legacy MIDI messages that fit into the buffer or a single MIDIEventList containing 1 MIDIEventPacket of 2 words when using MIDI 2.0 (MIDIEventList based API's). This property is set to the default value by the framework. In case of kAudioUnitErr_MIDIOutputBufferFull errors caused by producing too much MIDI output in one render call, set this property to increase the buffer. This only provides a recommendation to the framework. Bridged to kAudioUnitProperty_MIDIOutputBufferSizeHint. API-Since: 11.0
-
MIDIOutputEventBlock
@Nullable public @Nullable AUAudioUnit.Block_MIDIOutputEventBlock_ret MIDIOutputEventBlock()
[@property] MIDIOutputEventBlock Block used by the host to access the MIDI output generated by an Audio Unit. The host can set this block and the plug-in can call it in its renderBlock to provide to the host the MIDI data associated with the current render cycle. All events sent via this block will be delivered to the host in the MIDI protocol returned by the hostMIDIProtocol property. For example, if hostMIDIProtocol is set to kMIDIProtocol_2_0, incoming events will be translated to MIDI 2.0. If hostMIDIProtocol is not set, events will be delivered as legacy MIDI. Note: AUMIDIEventListBlock should be preferred over this block going forward. This is bridged to the v2 API property kAudioUnitProperty_MIDIOutputCallback. API-Since: 11.0
-
MIDIOutputNames
@NotNull public @NotNull NSArray<java.lang.String> MIDIOutputNames()
[@property] MIDIOutputNames Count, and names of, a plug-in's MIDI outputs. A plug-in may override this method to inform hosts about its MIDI outputs. The size of the array is the number of outputs the Audio Unit supports. Each item in the array is the name of the MIDI output at that index. This is bridged to the v2 API property kAudioUnitProperty_MIDIOutputCallbackInfo. API-Since: 11.0
-
audioUnitShortName
@Nullable public @Nullable java.lang.String audioUnitShortName()
[@property] audioUnitShortName A short name for the audio unit. Audio unit host applications can display this name in situations where the audioUnitName might be too long. The recommended length is up to 16 characters. Host applications may truncate it. API-Since: 11.0
-
isRunning
public boolean isRunning()
[@property] running The audio device's running state. API-Since: 11.0
-
providesUserInterface
public boolean providesUserInterface()
[@property] providesUserInterface Specifies whether an audio unit provides UI (normally in the form of a view controller). Implemented in the framework and should not be overridden by implementators. The framework detects whether any subclass has implemented `requestViewControllerWithCompletionHandler:` or is implemented by an AU extension whose extension point identifier is `com.apple.AudioUnit-UI`. See also `requestViewControllerWithCompletionHandler:` inAPI-Since: 11.0
-
selectViewConfiguration
public void selectViewConfiguration(@NotNull @NotNull AUAudioUnitViewConfiguration viewConfiguration)selectViewConfiguration Request a view configuration from the audio unit. The host can use this method to switch the audio unit's view into a new configuration. Audio Units should override this method with the logic needed to adapt their view controller to the requested configuration. API-Since: 11.0- Parameters:
viewConfiguration- The requested view configuration. The view configuration passed to this method should be one which was indicated as supported via supportedViewConfigurations. If any other, unsupported, view configuration is passed or if supportedViewConfigurations returns an empty set, the audio unit implementation should fall back to its default (largest available) view configuration.
-
setMIDIOutputBufferSizeHint
public void setMIDIOutputBufferSizeHint(long value)
[@property] MIDIOutputBufferSizeHint Hint to control the size of the allocated buffer for outgoing MIDI events. This property allows the plug-in to provide a hint to the framework regarding the size of its outgoing MIDI data buffer. If the plug-in produces more MIDI output data than the default size of the allocated buffer, then the plug-in can provide this property to increase the size of this buffer. The value represents the number of 3-byte Legacy MIDI messages that fit into the buffer or a single MIDIEventList containing 1 MIDIEventPacket of 2 words when using MIDI 2.0 (MIDIEventList based API's). This property is set to the default value by the framework. In case of kAudioUnitErr_MIDIOutputBufferFull errors caused by producing too much MIDI output in one render call, set this property to increase the buffer. This only provides a recommendation to the framework. Bridged to kAudioUnitProperty_MIDIOutputBufferSizeHint. API-Since: 11.0
-
setMIDIOutputEventBlock
public void setMIDIOutputEventBlock(@Nullable @Nullable AUAudioUnit.Block_setMIDIOutputEventBlock value)[@property] MIDIOutputEventBlock Block used by the host to access the MIDI output generated by an Audio Unit. The host can set this block and the plug-in can call it in its renderBlock to provide to the host the MIDI data associated with the current render cycle. All events sent via this block will be delivered to the host in the MIDI protocol returned by the hostMIDIProtocol property. For example, if hostMIDIProtocol is set to kMIDIProtocol_2_0, incoming events will be translated to MIDI 2.0. If hostMIDIProtocol is not set, events will be delivered as legacy MIDI. Note: AUMIDIEventListBlock should be preferred over this block going forward. This is bridged to the v2 API property kAudioUnitProperty_MIDIOutputCallback. API-Since: 11.0
-
supportedViewConfigurations
@NotNull public @NotNull NSIndexSet supportedViewConfigurations(@NotNull @NotNull NSArray<? extends AUAudioUnitViewConfiguration> availableViewConfigurations)
supportedViewConfigurations Query the list of supported view configurations. The host can query the audio unit for all the view configurations it supports. Hosts can support multiple configurations in which they can display the user interfaces of audio units (for example: full screen, normal, live mode, etc). These configurations can be of different sizes and the host might display its own control surfaces along with the view of the audio unit. The host will call this method and pass an array of supported configurations. The audio unit should override this method and implement its own logic to report all the view configurations it supports. The size of the view in the selected configuration should be large enough to fit the view of the audio unit, otherwise it might be truncated and a scroll bar might be necessary to navigate it. In case an empty set is returned from this method, it is considered that the plugin only supports the largest available view configuration. API-Since: 11.0- Parameters:
availableViewConfigurations- The list of all available view configurations supported by the host.- Returns:
- A set of indices of view configurations from the availableViewConfigurations array that the audio unit supports.
-
deleteUserPresetError
public boolean deleteUserPresetError(@NotNull @NotNull AUAudioUnitPreset userPreset, @Nullable @Nullable org.moe.natj.general.ptr.Ptr<NSError> outError)deleteUserPreset:error Remove a user preset. The user preset will be removed from userPresets and will be permanently deleted. The default implementation of this method will delete the user preset from an internal location. Audio Units are free to override this method to operate on a different location (e.g. their iCloud container).- Parameters:
userPreset- The preset to be deleted.outError- In the event of a failure, the method will return NO and outError will be set to an NSError, describing the problem. Some possible errors: - domain: NSOSStatusErrorDomain code: kAudioUnitErr_NoConnection - domain: NSPOSIXErrorDomain code: ENOENT - domain: NSOSStatusErrorDomain code: kAudioUnitErr_InvalidFilePath- Returns:
- YES for success. NO in the event of a failure, in which case the error is returned in outError. API-Since: 13.0
-
disableProfileCableOnChannelError
public boolean disableProfileCableOnChannelError(@NotNull @NotNull MIDICIProfile profile, byte cable, byte channel, @Nullable @Nullable org.moe.natj.general.ptr.Ptr<NSError> outError)disableProfile:cable:onChannel:error: Disable a MIDI-CI Profile on the specified cable/channel.- Parameters:
profile- The MIDI-CI profile to be disabled.cable- The virtual MIDI cable.channel- The MIDI channel.outError- Returned in the event of failure.- Returns:
- YES for success. NO in the event of a failure, in which case the error is returned in outError. API-Since: 12.0
-
enableProfileCableOnChannelError
public boolean enableProfileCableOnChannelError(@NotNull @NotNull MIDICIProfile profile, byte cable, byte channel, @Nullable @Nullable org.moe.natj.general.ptr.Ptr<NSError> outError)enableProfile:cable:onChannel:error: Enable a MIDI-CI Profile on the specified cable/channel.- Parameters:
profile- The MIDI-CI profile to be enabled.cable- The virtual MIDI cable.channel- The MIDI channel.outError- Returned in the event of failure.- Returns:
- YES for success. NO in the event of a failure, in which case the error is returned in outError. API-Since: 12.0
-
presetStateForError
@Nullable public @Nullable NSDictionary<java.lang.String,?> presetStateForError(@NotNull @NotNull AUAudioUnitPreset userPreset, @Nullable @Nullable org.moe.natj.general.ptr.Ptr<NSError> outError)
presetStateFor:error Retrieve the state stored in a user preset This method allows access to the contents of a preset without having to set that preset as current. The returned dictionary is assignable to the audio unit's fullState and/or fullStateForDocument properties. Audio units can override this method in order to vend user presets from a different location (e.g. their iCloud container). In order to restore the state from a user preset, the audio unit should override the setter for the currentPreset property and check the preset number to determine the type of preset. If the preset number is >= 0 then the preset is a factory preset. If the preset number is < 0 then it is a user preset. This method can then be called to retrieve the state stored in a user preset and the audio unit can assign this to fullState or fullStateForDocument. [@kAUPresetSubtypeKey] : NSNumber, [@kAUPresetManufacturerKey] : NSNumber, [@kAUPresetVersionKey] : NSNumber, [@kAUPresetNameKey] : NSString, [@kAUPresetNumberKey] NSNumber, [@kAUPresetDataKey] : NSData API-Since: 13.0- Parameters:
userPreset- The preset to be selected.outError- In the event of a failure, the method will return nil and outError will be set to an NSError, describing the problem. Some possible errors: - domain: NSOSStatusErrorDomain code: kAudioUnitErr_NoConnection - domain: NSPOSIXErrorDomain code: ENOENT - domain: NSCocoaErrorDomain code: NSCoderReadCorruptError- Returns:
- Returns nil if there was an error, otherwise returns a dictionary containing the full state of the audio unit saved in the preset. For details on the possible keys present in the full state dictionary, please see the documentation for kAudioUnitProperty_ClassInfo. The minimal set of keys and their type is: @kAUPresetTypeKey : NSNumber,
-
profileChangedBlock
@Nullable public @Nullable AUAudioUnit.Block_profileChangedBlock_ret profileChangedBlock()
[@property] profileChangedBlock A block called when a device notifies that a MIDI-CI profile has been enabled or disabled. Since enabling / disabling MIDI-CI profiles is an asynchronous operation, the host can set this block and the audio unit is expected to call it every time the state of a MIDI-CI profile has changed. API-Since: 12.0
-
profileStateForCableChannel
@NotNull public @NotNull MIDICIProfileState profileStateForCableChannel(byte cable, byte channel)
profileStateForCable:channel: Given a MIDI cable and channel number, return the supported MIDI-CI Profiles.- Parameters:
cable- The virtual MIDI cable for which the profiles are requested.channel- The MIDI channel for which the profiles are requested.- Returns:
- A MIDICIProfileState object containing all the supported MIDI-CI profiles for this channel on this cable. API-Since: 12.0
-
saveUserPresetError
public boolean saveUserPresetError(@NotNull @NotNull AUAudioUnitPreset userPreset, @Nullable @Nullable org.moe.natj.general.ptr.Ptr<NSError> outError)saveUserPreset:error Persistently save the current state of the audio unit into a userPreset The new preset will be added to userPresets and will become selectable by assigning it to the currentPreset property. If a preset with the provided name already exists then it will be overwritten. For user presets, the preset number is required to be negative. If a positive number is passed, the sign will be changed to negative. If zero is passed, the number will be set to -1. These changes will be reflected on the userPreset argument. The default implementation of this method will save the user preset to an internal location. Audio Units are free to override this method to operate on a different location (e.g. their iCloud container).- Parameters:
userPreset- The preset under which the current state will be saved.outError- In the event of a failure, the method will return NO and outError will be set to an NSError, describing the problem. Some possible errors: - domain: NSOSStatusErrorDomain code: kAudioUnitErr_NoConnection - domain: NSOSStatusErrorDomain code: kAudioUnitErr_InvalidFilePath - domain: NSOSStatusErrorDomain code: kAudioUnitErr_MissingKey- Returns:
- YES for success. NO in the event of a failure, in which case the error is returned in outError. API-Since: 13.0
-
setParameterTree
public void setParameterTree(@Nullable @Nullable AUParameterTree value)[@property] parameterTree An audio unit's parameters, organized in a hierarchy. Audio unit hosts can fetch this property to discover a unit's parameters. KVO notifications are issued on this member to notify the host of changes to the set of available parameters. AUAudioUnit has an additional pseudo-property, "allParameterValues", on which KVO notifications are issued in response to certain events where potentially all parameter values are invalidated. This includes changes to currentPreset, fullState, and fullStateForDocument. Hosts should not attempt to set this property. Subclassers should implement the parameterTree getter to expose parameters to hosts. They should cache as much as possible and send KVO notifications on "parameterTree" when altering the structure of the tree or the static information (ranges, etc) of parameters. This is similar to the v2 properties kAudioUnitProperty_ParameterList and kAudioUnitProperty_ParameterInfo. Note that it is not safe to modify this property in a real-time context.
-
setProfileChangedBlock
public void setProfileChangedBlock(@Nullable @Nullable AUAudioUnit.Block_setProfileChangedBlock value)[@property] profileChangedBlock A block called when a device notifies that a MIDI-CI profile has been enabled or disabled. Since enabling / disabling MIDI-CI profiles is an asynchronous operation, the host can set this block and the audio unit is expected to call it every time the state of a MIDI-CI profile has changed. API-Since: 12.0
-
supportsUserPresets
public boolean supportsUserPresets()
[@property] supportsUserPresets Specifies whether an audio unit supports loading and saving user presets The audio unit should set this property to YES if a user preset can be assigned to currentPreset. Audio unit host applications should query this property to determine whether the audio unit supports user presets. Assigning a user preset to the currentPreset property of an audio unit that does not support restoring state from user presets may result in incorrect behavior. API-Since: 13.0
-
userPresets
@NotNull public @NotNull NSArray<? extends AUAudioUnitPreset> userPresets()
[@property] userPresets A collection of presets saved by the user In addition to factory presets, provided by the audio unit vendor, users have the ability to save the values of the parameters of an audio unit into a user preset. These users presets can be accessed using this property. The default implementation of this method will load the user presets from an internal location that might not be directly accessible to the audio unit host application or to the audio unit. Instead of accessing this path directly, the audio unit should rely on the superclass implementation of this method to retrieve the presets. Audio Units are free to override this method to load their user presets via different means (e.g. from their iCloud container). API-Since: 13.0
-
renderBlock
@NotNull public @NotNull AUAudioUnit.Block_renderBlock_ret renderBlock()
[@property] renderBlock Block which hosts use to ask the unit to render. Before invoking an audio unit's rendering functionality, a host should fetch this block and cache the result. The block can then be called from a realtime context without the possibility of blocking and causing an overload at the Core Audio HAL level. This block will call a subclass' internalRenderBlock, providing all realtime events scheduled for the current render time interval, bracketed by calls to any render observers. Subclassers should override internalRenderBlock, not this property. Bridged to the v2 API AudioUnitRender().
-
osWorkgroup
@NotNull public @NotNull os_workgroup_t osWorkgroup()
[@property] osWorkgroup The os_workgroup_t to which the input/output audio unit belongs. For further background, see. Bridged to the v2 property kAudioOutputUnitProperty_OSWorkgroup. API-Since: 14.0
-
renderContextObserver
@NotNull public @NotNull AUAudioUnit.Block_renderContextObserver_ret renderContextObserver()
[@property] renderContextObserver Block called by the OS when the rendering context changes. Audio Units which create auxiliary realtime rendering threads should implement this property to return a block which will be called by the OS when the render context changes. Audio Unit hosts must not attempt to interact with the AudioUnit through this block; it is for the exclusive use of the OS. Seefor more information. API-Since: 14.0
-
AudioUnitMIDIProtocol
public int AudioUnitMIDIProtocol()
[@property] AudioUnitMIDIProtocol The MIDI protocol used by the Audio Unit for receiving MIDIEventList data. Subclassers should override to return the desired protocol in which the Audio Unit wants to receive input MIDI data, otherwise the Audio Unit will default to receiving legacy MIDI. All translatable messages will be converted (if necessary) to this protocol prior to delivery to the Audio Unit. This is bridged to the v2 API property kAudioUnitProperty_AudioUnitMIDIProtocol. API-Since: 15.0
-
MIDIOutputEventListBlock
@Nullable public @Nullable AUAudioUnit.Block_MIDIOutputEventListBlock_ret MIDIOutputEventListBlock()
[@property] MIDIOutputEventListBlock Block used by the host to access the MIDIEventList output generated by an Audio Unit. The host can set this block and the plug-in can call it in its renderBlock to provide to the host the MIDIEventList data associated with the current render cycle. All events sent via this block will be delivered to the host in the MIDI protocol returned by the hostMIDIProtocol property. For example, if hostMIDIProtocol is set to kMIDIProtocol_2_0, incoming events will be translated to MIDI 2.0. If hostMIDIProtocol is not set, events will be delivered as legacy MIDI. Note: This block is cross-compatible with Audio Units using MIDIOutputEventBlock and should be preferred over MIDIOutputEventBlock by hosts going forward. The framework will provide the Audio Unit with both a MIDIOutputEventBlock and MIDIOutputEventListBlock, the Audio Unit is free to call either block as all messages will be translated as described above. Host should setup in the following order: - Set hostMIDIProtocol - Set MIDIOutputEventListBlock - Call allocateRenderResourcesAndReturnError This is bridged to the v2 API property kAudioUnitProperty_MIDIOutputEventListCallback. API-Since: 15.0
-
hostMIDIProtocol
public int hostMIDIProtocol()
[@property] hostMIDIProtocol The MIDI protocol to be used by the host for receiving MIDIEventList data. Hosts should set this property to the protocol they wish to receive MIDIEventList data from the Audio Unit. This should be set prior to initialization, all translatable messages will be converted (if necessary) to this property's protocol prior to delivery to the host. Host should setup in the following order: - Set hostMIDIProtocol - Set MIDIOutputEventListBlock - Call allocateRenderResourcesAndReturnError This is bridged to the v2 API property kAudioUnitProperty_HostMIDIProtocol. Notes: - If overriding this property, subclassers must call [super setHostMIDIProtocol:] - hostMIDIProtocol should be set before attempting to query AudioUnitMIDIProtocol or calling allocateRenderResourcesAndReturnError to allow Audio Units to optionally match their input MIDI protocol to the desired host protocol and prevent protocol conversion. API-Since: 15.0
-
scheduleMIDIEventListBlock
@Nullable public @Nullable AUAudioUnit.Block_scheduleMIDIEventListBlock_ret scheduleMIDIEventListBlock()
[@property] scheduleMIDIEventListBlock Block used to schedule MIDIEventLists. As with renderBlock, a host should fetch and cache this block before calling allocateRenderResources, if it intends to schedule MIDI events. When scheduling events during the render cycle (e.g. via a render observer) eventSampleTime can be AUEventSampleTimeImmediate plus an optional buffer offset, in which case the event is scheduled at the provided offset position within the current render cycle. This is implemented in the base class. It is nil when musicDeviceOrEffect is NO. Subclassers should not override. When hosts schedule events via this block, they are delivered to the Audio Unit via the list of AURenderEvents delivered to internalRenderBlock. All events sent via this block will be delivered to the internalRenderBlock in the MIDI protocol returned by the AudioUnitMIDIProtocol property. For example, if this block is called with MIDI-1.0 events but AudioUnitMIDIProtocol returns kMIDIProtocol_2_0, incoming events will be translated to MIDI 2.0. If AudioUnitMIDIProtocol is not set, events will be delivered as legacy MIDI. Note: This block should be preferred over scheduleMIDIEventBlock going forward. This bridged to the v2 API MusicDeviceMIDIEventList. API-Since: 15.0
-
setHostMIDIProtocol
public void setHostMIDIProtocol(int value)
[@property] hostMIDIProtocol The MIDI protocol to be used by the host for receiving MIDIEventList data. Hosts should set this property to the protocol they wish to receive MIDIEventList data from the Audio Unit. This should be set prior to initialization, all translatable messages will be converted (if necessary) to this property's protocol prior to delivery to the host. Host should setup in the following order: - Set hostMIDIProtocol - Set MIDIOutputEventListBlock - Call allocateRenderResourcesAndReturnError This is bridged to the v2 API property kAudioUnitProperty_HostMIDIProtocol. Notes: - If overriding this property, subclassers must call [super setHostMIDIProtocol:] - hostMIDIProtocol should be set before attempting to query AudioUnitMIDIProtocol or calling allocateRenderResourcesAndReturnError to allow Audio Units to optionally match their input MIDI protocol to the desired host protocol and prevent protocol conversion. API-Since: 15.0
-
setMIDIOutputEventListBlock
public void setMIDIOutputEventListBlock(@Nullable @Nullable AUAudioUnit.Block_setMIDIOutputEventListBlock value)[@property] MIDIOutputEventListBlock Block used by the host to access the MIDIEventList output generated by an Audio Unit. The host can set this block and the plug-in can call it in its renderBlock to provide to the host the MIDIEventList data associated with the current render cycle. All events sent via this block will be delivered to the host in the MIDI protocol returned by the hostMIDIProtocol property. For example, if hostMIDIProtocol is set to kMIDIProtocol_2_0, incoming events will be translated to MIDI 2.0. If hostMIDIProtocol is not set, events will be delivered as legacy MIDI. Note: This block is cross-compatible with Audio Units using MIDIOutputEventBlock and should be preferred over MIDIOutputEventBlock by hosts going forward. The framework will provide the Audio Unit with both a MIDIOutputEventBlock and MIDIOutputEventListBlock, the Audio Unit is free to call either block as all messages will be translated as described above. Host should setup in the following order: - Set hostMIDIProtocol - Set MIDIOutputEventListBlock - Call allocateRenderResourcesAndReturnError This is bridged to the v2 API property kAudioUnitProperty_MIDIOutputEventListCallback. API-Since: 15.0
-
internalRenderBlock
@NotNull public @NotNull AUAudioUnit.Block_internalRenderBlock_ret internalRenderBlock()
Block which subclassers must provide (via a getter) to implement rendering.
-
messageChannelFor
@NotNull public @NotNull AUMessageChannel messageChannelFor(@NotNull @NotNull java.lang.String channelName)
messageChannelFor: Returns an object for bidirectional communication between an Audio Unit and its host. Message channels provide a flexible way for custom data exchange between an Audio Unit and its host. An Audio Unit can support multiple message channels which are identified by the `channelName`. The message channel object's lifetime is managed by the host. Message channel objects should be designed in such a way that they could outlive the AU that vended them. For further details see discussion for `AUMessageChannel`.- Parameters:
channelName- The name of the message channel to be returned by the Audio Unit if supported.- Returns:
- An object that conforms to the `AUMessageChannel` protocol. API-Since: 16.0
-
useStoredAccessor
@Deprecated public static boolean useStoredAccessor()
Deprecated.
-
-