DynamicsProcessing Class
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
DynamicsProcessing is an audio effect for equalizing and changing dynamic range properties of the sound.
[Android.Runtime.Register("android/media/audiofx/DynamicsProcessing", ApiSince=28, DoNotGenerateAcw=true)]
public sealed class DynamicsProcessing : Android.Media.Audiofx.AudioEffect
[<Android.Runtime.Register("android/media/audiofx/DynamicsProcessing", ApiSince=28, DoNotGenerateAcw=true)>]
type DynamicsProcessing = class
inherit AudioEffect
- Inheritance
- Attributes
Remarks
DynamicsProcessing is an audio effect for equalizing and changing dynamic range properties of the sound. It is composed of multiple stages including equalization, multi-band compression and limiter.
The number of bands and active stages is configurable, and most parameters can be controlled in realtime, such as gains, attack/release times, thresholds, etc.
The effect is instantiated and controlled by channels. Each channel has the same basic architecture, but all of their parameters are independent from other channels.
The basic channel configuration is:
Channel 0 Channel 1 .... Channel N-1
Input Input Input
| | |
+----v----+ +----v----+ +----v----+
|inputGain| |inputGain| |inputGain|
+---------+ +---------+ +---------+
| | |
+-----v-----+ +-----v-----+ +-----v-----+
| PreEQ | | PreEQ | | PreEQ |
+-----------+ +-----------+ +-----------+
| | |
+-----v-----+ +-----v-----+ +-----v-----+
| MBC | | MBC | | MBC |
+-----------+ +-----------+ +-----------+
| | |
+-----v-----+ +-----v-----+ +-----v-----+
| PostEQ | | PostEQ | | PostEQ |
+-----------+ +-----------+ +-----------+
| | |
+-----v-----+ +-----v-----+ +-----v-----+
| Limiter | | Limiter | | Limiter |
+-----------+ +-----------+ +-----------+
| | |
Output Output Output
Where the stages are: inputGain: input gain factor in decibels (dB). 0 dB means no change in level. PreEQ: Multi-band Equalizer. MBC: Multi-band Compressor PostEQ: Multi-band Equalizer Limiter: Single band compressor/limiter.
An application creates a DynamicsProcessing object to instantiate and control this audio effect in the audio framework. A DynamicsProcessor.Config and DynamicsProcessor.Config.Builder are available to help configure the multiple stages and each band parameters if desired.
See each stage documentation for further details.
If no Config is specified during creation, a default configuration is chosen.
To attach the DynamicsProcessing to a particular AudioTrack or MediaPlayer, specify the audio session ID of this AudioTrack or MediaPlayer when constructing the effect (see AudioTrack#getAudioSessionId() and MediaPlayer#getAudioSessionId()).
To attach the DynamicsProcessing to a particular AudioTrack or MediaPlayer, specify the audio session ID of this AudioTrack or MediaPlayer when constructing the DynamicsProcessing.
See android.media.MediaPlayer#getAudioSessionId() for details on audio sessions.
See android.media.audiofx.AudioEffect class for more details on controlling audio effects.
Java documentation for android.media.audiofx.DynamicsProcessing.
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.
Constructors
| Name | Description |
|---|---|
| DynamicsProcessing(Int32, Int32, DynamicsProcessing+Config) |
Class constructor. |
| DynamicsProcessing(Int32) |
Class constructor. |
Fields
| Name | Description |
|---|---|
| ActionCloseAudioEffectControlSession |
Intent to signal to the effect control application or service that an audio session is closed and that effects should not be applied anymore. (Inherited from AudioEffect) |
| ActionDisplayAudioEffectControlPanel |
Intent to launch an audio effect control panel UI. (Inherited from AudioEffect) |
| ActionOpenAudioEffectControlSession |
Intent to signal to the effect control application or service that a new audio session is opened and requires audio effects to be applied. (Inherited from AudioEffect) |
| AlreadyExists |
Obsolete.
Internal operation status. (Inherited from AudioEffect) |
| ContentTypeGame |
Obsolete.
Value for |
| ContentTypeMovie |
Obsolete.
Value for |
| ContentTypeMusic |
Obsolete.
Value for |
| ContentTypeVoice |
Obsolete.
Value for |
| EffectAuxiliary |
Effect connection mode is auxiliary. (Inherited from AudioEffect) |
| EffectInsert |
Effect connection mode is insert. (Inherited from AudioEffect) |
| EffectPostProcessing |
Effect connection mode is post processing. (Inherited from AudioEffect) |
| EffectPreProcessing |
Effect connection mode is pre processing. (Inherited from AudioEffect) |
| Error |
Obsolete.
Unspecified error. (Inherited from AudioEffect) |
| ErrorBadValue |
Obsolete.
Operation failed due to bad parameter value. (Inherited from AudioEffect) |
| ErrorDeadObject |
Obsolete.
Operation failed due to dead remote object. (Inherited from AudioEffect) |
| ErrorInvalidOperation |
Obsolete.
Operation failed because it was requested in wrong state. (Inherited from AudioEffect) |
| ErrorNoInit |
Obsolete.
Operation failed due to bad object initialization. (Inherited from AudioEffect) |
| ErrorNoMemory |
Obsolete.
Operation failed due to lack of memory. (Inherited from AudioEffect) |
| ExtraAudioSession |
Contains the ID of the audio session the effects should be applied to. (Inherited from AudioEffect) |
| ExtraContentType |
Indicates which type of content is played by the application. (Inherited from AudioEffect) |
| ExtraPackageName |
Contains the package name of the calling application. (Inherited from AudioEffect) |
| Success |
Obsolete.
Successful operation. (Inherited from AudioEffect) |
| VariantFavorFrequencyResolution |
Obsolete.
Index of variant that favors frequency resolution. |
| VariantFavorTimeResolution |
Obsolete.
Index of variant that favors time resolution resolution. |
Properties
| Name | Description |
|---|---|
| ChannelCount |
Gets the number of channels in the effect engine |
| Class |
Returns the runtime class of this |
| Enabled |
Returns effect enabled state (Inherited from AudioEffect) |
| Handle |
The handle to the underlying Android instance. (Inherited from Object) |
| HasControl |
Checks if this AudioEffect object is controlling the effect engine. (Inherited from AudioEffect) |
| Id |
Returns effect unique identifier. (Inherited from AudioEffect) |
| JniIdentityHashCode |
Gets the identity hash code assigned to this Java peer by the interop runtime. (Inherited from Object) |
| JniManagedPeerState | (Inherited from JavaObject) |
| JniPeerMembers |
Gets the JNI metadata used to access members of this Java binding. |
| PeerReference |
Gets the JNI object reference for this Java peer. (Inherited from Object) |
| ThresholdClass |
This API supports the Mono for Android infrastructure and is not intended to be used directly from your code. (Inherited from AudioEffect) |
| ThresholdType |
This API supports the Mono for Android infrastructure and is not intended to be used directly from your code. (Inherited from AudioEffect) |
Methods
| Name | Description |
|---|---|
| Clone() |
Creates and returns a copy of this object. (Inherited from Object) |
| Construct(JniObjectReference, JniObjectReferenceOptions) | (Inherited from JavaObject) |
| Dispose() |
Releases the resources held by this Java peer. (Inherited from Object) |
| Dispose(Boolean) |
Releases the resources held by this Java peer. (Inherited from Object) |
| DisposeUnlessReferenced() | (Inherited from JavaObject) |
| Equals(Object) | (Inherited from JavaObject) |
| Equals(Object) |
Indicates whether some other object is "equal to" this one. (Inherited from Object) |
| GetChannelByChannelIndex(Int32) |
Gets the input gain and all processing stage settings for one channel. |
| GetConfig() |
Returns the Config object used to setup this effect. |
| GetDescriptor() |
Get the effect descriptor. (Inherited from AudioEffect) |
| GetHashCode() |
Returns a hash code value for the object. (Inherited from Object) |
| GetInputGainByChannelIndex(Int32) |
Gets the input gain for one channel. |
| GetLimiterByChannelIndex(Int32) |
Gets the limiter stage settings for one channel. |
| GetMbcBandByChannelIndex(Int32, Int32) |
Gets the multiband compressor band settings for one channel. |
| GetMbcByChannelIndex(Int32) |
Gets the multiband compressor stage settings for one channel. |
| GetPostEqBandByChannelIndex(Int32, Int32) |
Gets the post-equalizer band settings for one channel. |
| GetPostEqByChannelIndex(Int32) |
Gets the post-equalizer stage settings for one channel. |
| GetPreEqBandByChannelIndex(Int32, Int32) |
Gets the pre-equalizer band settings for one channel. |
| GetPreEqByChannelIndex(Int32) |
Gets the pre-equalizer stage settings for one channel. |
| JavaFinalize() |
Obsolete.
Called by the garbage collector on an object when garbage collection determines that there are no more references to the object. (Inherited from Object) |
| Notify() |
Wakes up a single thread that is waiting on this object's monitor. (Inherited from Object) |
| NotifyAll() |
Wakes up all threads that are waiting on this object's monitor. (Inherited from Object) |
| Release() |
Releases the native AudioEffect resources. (Inherited from AudioEffect) |
| SetAllChannelsTo(DynamicsProcessing+Channel) |
Sets the complete channel settings for all channels. |
| SetChannelTo(Int32, DynamicsProcessing+Channel) |
Sets the complete channel settings for one channel. |
| SetControlStatusListener(AudioEffect+IOnControlStatusChangeListener) |
Sets the listener AudioEffect notifies when the effect engine control is taken or returned. (Inherited from AudioEffect) |
| SetEnabled(Boolean) |
Enable or disable the effect. (Inherited from AudioEffect) |
| SetEnableStatusListener(AudioEffect+IOnEnableStatusChangeListener) |
Sets the listener AudioEffect notifies when the effect engine is enabled or disabled. (Inherited from AudioEffect) |
| SetHandle(IntPtr, JniHandleOwnership) |
Sets the Handle property. (Inherited from Object) |
| SetInputGainAllChannelsTo(Single) |
Sets the input gain for all channels. |
| SetInputGainbyChannel(Int32, Single) |
Sets the input gain for one channel. |
| SetLimiterAllChannelsTo(DynamicsProcessing+Limiter) |
Sets the limiter stage settings for all channels. |
| SetLimiterByChannelIndex(Int32, DynamicsProcessing+Limiter) |
Sets the limiter stage settings for one channel. |
| SetMbcAllChannelsTo(DynamicsProcessing+Mbc) |
Sets the multiband compressor stage settings for all channels. |
| SetMbcBandAllChannelsTo(Int32, DynamicsProcessing+MbcBand) |
Sets the multiband compressor band settings for all channels. |
| SetMbcBandByChannelIndex(Int32, Int32, DynamicsProcessing+MbcBand) |
Sets the multiband compressor band settings for one channel. |
| SetMbcByChannelIndex(Int32, DynamicsProcessing+Mbc) |
Sets the multiband compressor stage settings for one channel. |
| SetPeerReference(JniObjectReference, JniObjectReferenceOptions) | (Inherited from JavaObject) |
| SetPostEqAllChannelsTo(DynamicsProcessing+Eq) |
Sets the post-equalizer stage settings for all channels. |
| SetPostEqBandAllChannelsTo(Int32, DynamicsProcessing+EqBand) |
Sets the post-equalizer band settings for all channels. |
| SetPostEqBandByChannelIndex(Int32, Int32, DynamicsProcessing+EqBand) |
Sets the post-equalizer band settings for one channel. |
| SetPostEqByChannelIndex(Int32, DynamicsProcessing+Eq) |
Sets the post-equalizer stage settings for one channel. |
| SetPreEqAllChannelsTo(DynamicsProcessing+Eq) |
Sets the pre-equalizer stage settings for all channels. |
| SetPreEqBandAllChannelsTo(Int32, DynamicsProcessing+EqBand) |
Sets the pre-equalizer band settings for all channels. |
| SetPreEqBandByChannelIndex(Int32, Int32, DynamicsProcessing+EqBand) |
Sets the pre-equalizer band settings for one channel. |
| SetPreEqByChannelIndex(Int32, DynamicsProcessing+Eq) |
Sets the pre-equalizer stage settings for one channel. |
| ToArray<T>() |
Creates a managed array from this Java array wrapper. (Inherited from Object) |
| ToString() |
Returns a string representation of the object. (Inherited from Object) |
| UnregisterFromRuntime() |
Unregisters this Java peer from the interop runtime. (Inherited from Object) |
| Wait() |
Causes the current thread to wait until it is awakened, typically by being <em>notified</em> or <em>interrupted</em>. (Inherited from Object) |
| Wait(Int64, Int32) |
Causes the current thread to wait until it is awakened, typically by being <em>notified</em> or <em>interrupted</em>, or until a certain amount of real time has elapsed. (Inherited from Object) |
| Wait(Int64) |
Causes the current thread to wait until it is awakened, typically by being <em>notified</em> or <em>interrupted</em>, or until a certain amount of real time has elapsed. (Inherited from Object) |
Events
| Name | Description |
|---|---|
| ControlStatus |
Occurs when this application gains or loses control of the effect engine. (Inherited from AudioEffect) |
| EnableStatus |
Occurs when the controlling application changes the effect engine's enabled state. (Inherited from AudioEffect) |
Explicit Interface Implementations
| Name | Description |
|---|---|
| IJavaPeerable.Disposed() | (Inherited from JavaObject) |
| IJavaPeerable.Finalized() | (Inherited from JavaObject) |
| IJavaPeerable.JniObjectReferenceControlBlock | (Inherited from JavaObject) |
| IJavaPeerable.SetJniIdentityHashCode(Int32) | (Inherited from JavaObject) |
| IJavaPeerable.SetJniManagedPeerState(JniManagedPeerStates) | (Inherited from JavaObject) |
| IJavaPeerable.SetPeerReference(JniObjectReference) | (Inherited from JavaObject) |
Extension Methods
| Name | Description |
|---|---|
| GetJniTypeName(IJavaPeerable) |
Gets the JNI name of the type of the instance |
| JavaAs<TResult>(IJavaPeerable) |
Try to coerce |
| JavaCast<TResult>(IJavaObject) |
Performs an Android runtime-checked type conversion. |
| JavaCast<TResult>(IJavaObject) | |
| TryJavaCast<TResult>(IJavaPeerable, TResult) |
Try to coerce |