@UnstableApi
public interface EncoderSelector


Selector of MediaCodec encoder instances.

Summary

Constants

default static final EncoderSelector

Default implementation of EncoderSelector, which returns the preferred encoders for the given MIME type.

Public methods

abstract ImmutableList<MediaCodecInfo>

Returns a list of encoders that can encode media in the specified mimeType, in priority order.

Constants

DEFAULT

default static final EncoderSelector DEFAULT

Default implementation of EncoderSelector, which returns the preferred encoders for the given MIME type.

The EncoderSelector selection result contains only hardware encoders if they exist, or only software encoders otherwise.

Public methods

selectEncoderInfos

abstract ImmutableList<MediaCodecInfoselectEncoderInfos(String mimeType)

Returns a list of encoders that can encode media in the specified mimeType, in priority order.

Parameters
String mimeType

The MIME type for which an encoder is required.

Returns
ImmutableList<MediaCodecInfo>

An immutable list of encoders that support the mimeType. The list may be empty.