Added in API level 28

Channel


class Channel
kotlin.Any
   ↳ android.media.audiofx.DynamicsProcessing.Channel

Class for Channel configuration parameters. It is composed of multiple stages, which can be used/enabled independently. Stages not used or disabled will be bypassed and the sound would be unaffected by them.

Summary

Public constructors
Channel(inputGain: Float, preEqInUse: Boolean, preEqBandCount: Int, mbcInUse: Boolean, mbcBandCount: Int, postEqInUse: Boolean, postEqBandCount: Int, limiterInUse: Boolean)

Class constructor for Channel configuration.

Class constructor for Channel configuration

Public methods
Float

Gets inputGain value in decibels (dB).

DynamicsProcessing.Limiter!

Gets Limiter configuration stage

DynamicsProcessing.Mbc!

Gets Mbc configuration stage

DynamicsProcessing.MbcBand!
getMbcBand(band: Int)

Gets MbcBand configuration for Mbc stage, for given band index.

DynamicsProcessing.Eq!

Gets PostEq configuration stage

DynamicsProcessing.EqBand!

Gets EqBand for PostEq stage for given band index.

DynamicsProcessing.Eq!

Gets PreEq configuration stage

DynamicsProcessing.EqBand!

Gets EqBand for PreEq stage for given band index.

Unit
setInputGain(inputGain: Float)

Sets inputGain value in decibels (dB).

Unit

Sets Limiter configuration stage.

Unit

Sets Mbc configuration stage.

Unit

Sets MbcBand for Mbc stage for given band index

Unit

Sets PostEq configuration stage.

Unit

Sets EqBand for PostEq stage for given band index

Unit

Sets PreEq configuration stage.

Unit

Sets EqBand for PreEq stage for given band index

String

Public constructors

Channel

Added in API level 28
Channel(
    inputGain: Float,
    preEqInUse: Boolean,
    preEqBandCount: Int,
    mbcInUse: Boolean,
    mbcBandCount: Int,
    postEqInUse: Boolean,
    postEqBandCount: Int,
    limiterInUse: Boolean)

Class constructor for Channel configuration.

Parameters
inputGain Float: value in decibels (dB) of level change applied to the audio before processing. A value of 0 dB means no change.
preEqInUse Boolean: true if PreEq stage will be used, false otherwise. This can't be changed later.
preEqBandCount Int: number of bands for PreEq stage. This can't be changed later.
mbcInUse Boolean: true if Mbc stage will be used, false otherwise. This can't be changed later.
mbcBandCount Int: number of bands for Mbc stage. This can't be changed later.
postEqInUse Boolean: true if PostEq stage will be used, false otherwise. This can't be changed later.
postEqBandCount Int: number of bands for PostEq stage. This can't be changed later.
limiterInUse Boolean: true if Limiter stage will be used, false otherwise. This can't be changed later.

Channel

Added in API level 28
Channel(cfg: DynamicsProcessing.Channel!)

Class constructor for Channel configuration

Parameters
cfg DynamicsProcessing.Channel!: copy constructor

Public methods

getInputGain

Added in API level 28
fun getInputGain(): Float

Gets inputGain value in decibels (dB). 0 dB means no change;

Return
Float gain value in decibels (dB)

getLimiter

Added in API level 28
fun getLimiter(): DynamicsProcessing.Limiter!

Gets Limiter configuration stage

Return
DynamicsProcessing.Limiter! Limiter configuration stage

getMbc

Added in API level 28
fun getMbc(): DynamicsProcessing.Mbc!

Gets Mbc configuration stage

Return
DynamicsProcessing.Mbc! Mbc configuration stage

getMbcBand

Added in API level 28
fun getMbcBand(band: Int): DynamicsProcessing.MbcBand!

Gets MbcBand configuration for Mbc stage, for given band index.

Parameters
band Int: index of band of interest from Mbc stage
Return
DynamicsProcessing.MbcBand! MbcBand configuration

getPostEq

Added in API level 28
fun getPostEq(): DynamicsProcessing.Eq!

Gets PostEq configuration stage

Return
DynamicsProcessing.Eq! PostEq configuration stage

getPostEqBand

Added in API level 28
fun getPostEqBand(band: Int): DynamicsProcessing.EqBand!

Gets EqBand for PostEq stage for given band index.

Parameters
band Int: index of band of interest from PostEq stage
Return
DynamicsProcessing.EqBand! EqBand configuration

getPreEq

Added in API level 28
fun getPreEq(): DynamicsProcessing.Eq!

Gets PreEq configuration stage

Return
DynamicsProcessing.Eq! PreEq configuration stage

getPreEqBand

Added in API level 28
fun getPreEqBand(band: Int): DynamicsProcessing.EqBand!

Gets EqBand for PreEq stage for given band index.

Parameters
band Int: index of band of interest from PreEq stage
Return
DynamicsProcessing.EqBand! EqBand configuration

setInputGain

Added in API level 28
fun setInputGain(inputGain: Float): Unit

Sets inputGain value in decibels (dB). 0 dB means no change;

Parameters
inputGain Float: desired gain value in decibels (dB)

setLimiter

Added in API level 28
fun setLimiter(limiter: DynamicsProcessing.Limiter!): Unit

Sets Limiter configuration stage.

Parameters
limiter DynamicsProcessing.Limiter!: configuration stage.

setMbc

Added in API level 28
fun setMbc(mbc: DynamicsProcessing.Mbc!): Unit

Sets Mbc configuration stage. New Mbc stage must have the same number of bands than original Mbc stage.

Parameters
mbc DynamicsProcessing.Mbc!:

setMbcBand

Added in API level 28
fun setMbcBand(
    band: Int,
    mbcBand: DynamicsProcessing.MbcBand!
): Unit

Sets MbcBand for Mbc stage for given band index

Parameters
band Int: index of band of interest from Mbc Stage
mbcBand DynamicsProcessing.MbcBand!: configuration to be set

setPostEq

Added in API level 28
fun setPostEq(postEq: DynamicsProcessing.Eq!): Unit

Sets PostEq configuration stage. New PostEq stage must have the same number of bands than original PostEq stage.

Parameters
postEq DynamicsProcessing.Eq!: configuration

setPostEqBand

Added in API level 28
fun setPostEqBand(
    band: Int,
    postEqBand: DynamicsProcessing.EqBand!
): Unit

Sets EqBand for PostEq stage for given band index

Parameters
band Int: index of band of interest from PostEq stage
postEqBand DynamicsProcessing.EqBand!: configuration to be set.

setPreEq

Added in API level 28
fun setPreEq(preEq: DynamicsProcessing.Eq!): Unit

Sets PreEq configuration stage. New PreEq stage must have the same number of bands than original PreEq stage.

Parameters
preEq DynamicsProcessing.Eq!: configuration

setPreEqBand

Added in API level 28
fun setPreEqBand(
    band: Int,
    preEqBand: DynamicsProcessing.EqBand!
): Unit

Sets EqBand for PreEq stage for given band index

Parameters
band Int: index of band of interest from PreEq stage
preEqBand DynamicsProcessing.EqBand!: configuration to be set.

toString

Added in API level 28
fun toString(): String
Return
String a string representation of the object.