LoudnessCodecController


@RequiresApi(value = 35)
@UnstableApi
public final class LoudnessCodecController


Wrapper class for the platform android.media.LoudnessCodecController.

Summary

Nested types

Interface to intercept and modify loudness parameters before applying them to the codec.

Public constructors

Creates the loudness controller.

Creates the loudness controller.

Public methods

void

Adds a codec to be configured by the loudness controller.

void

Releases the loudness controller.

void

Removes a codec from being configured by the loudness controller.

void
setAudioSessionId(int audioSessionId)

Configures the loudness controller with an audio session id.

Public constructors

LoudnessCodecController

public LoudnessCodecController()

Creates the loudness controller.

LoudnessCodecController

public LoudnessCodecController(
    LoudnessCodecController.LoudnessParameterUpdateListener updateListener
)

Creates the loudness controller.

Parameters
LoudnessCodecController.LoudnessParameterUpdateListener updateListener

The LoudnessParameterUpdateListener to intercept and modify parameters.

Public methods

addMediaCodec

public void addMediaCodec(MediaCodec mediaCodec)

Adds a codec to be configured by the loudness controller.

Parameters
MediaCodec mediaCodec

A MediaCodec.

release

public void release()

Releases the loudness controller.

removeMediaCodec

public void removeMediaCodec(MediaCodec mediaCodec)

Removes a codec from being configured by the loudness controller.

Parameters
MediaCodec mediaCodec

A MediaCodec.

setAudioSessionId

public void setAudioSessionId(int audioSessionId)

Configures the loudness controller with an audio session id.

Parameters
int audioSessionId

The audio session ID.