Back to Exoplayer

RendererCapabilities (ExoPlayer library)

docs/doc/reference/com/google/android/exoplayer2/RendererCapabilities.html

latest34.6 KB
Original Source

Package com.google.android.exoplayer2

Interface RendererCapabilities

  • All Known Implementing Classes:BaseRenderer, CameraMotionRenderer, DecoderAudioRenderer, DecoderVideoRenderer, FakeAudioRenderer, FakeMediaClockRenderer, FakeRenderer, FakeVideoRenderer, FfmpegAudioRenderer, LibflacAudioRenderer, Libgav1VideoRenderer, LibopusAudioRenderer, LibvpxVideoRenderer, MediaCodecAudioRenderer, MediaCodecRenderer, MediaCodecVideoRenderer, MetadataRenderer, NoSampleRenderer, TextRenderer

[@Deprecated](https://developer.android.com/reference/java/lang/Deprecated.html "class or interface in java.lang")public interfaceRendererCapabilities

Deprecated. com.google.android.exoplayer2 is deprecated. Please migrate to androidx.media3 (which contains the same ExoPlayer code). See the migration guide for more details, including a script to help with the migration.

Defines the capabilities of a Renderer.

Nested Class Summary

Nested Classes | Modifier and Type | Interface | Description | | --- | --- | --- | | static interface | RendererCapabilities.AdaptiveSupport | Deprecated.

Level of renderer support for adaptive format switches. | | static interface | RendererCapabilities.Capabilities | Deprecated.

Combined renderer capabilities. | | static interface | RendererCapabilities.DecoderSupport | Deprecated.

Level of decoder support. | | static interface | RendererCapabilities.FormatSupport | Deprecated. Use C.FormatSupport instead.

| | static interface | RendererCapabilities.HardwareAccelerationSupport | Deprecated.

Level of renderer support for hardware acceleration. | | static interface | RendererCapabilities.Listener | Deprecated.

Listener for renderer capabilities events. | | static interface | RendererCapabilities.TunnelingSupport | Deprecated.

Level of renderer support for tunneling. |

Field Summary

Fields | Modifier and Type | Field | Description | | --- | --- | --- | | static int | ADAPTIVE_NOT_SEAMLESS | Deprecated.

The Renderer can adapt between formats, but may suffer a brief discontinuity (~50-100ms) when adaptation occurs. | | static int | ADAPTIVE_NOT_SUPPORTED | Deprecated.

The Renderer does not support adaptation between formats. | | static int | ADAPTIVE_SEAMLESS | Deprecated.

The Renderer can seamlessly adapt between formats. | | static int | ADAPTIVE_SUPPORT_MASK | Deprecated.

A mask to apply to RendererCapabilities.Capabilities to obtain the RendererCapabilities.AdaptiveSupport only. | | static int | DECODER_SUPPORT_FALLBACK | Deprecated.

The format exceeds the primary decoder's capabilities but is supported by fallback decoder | | static int | DECODER_SUPPORT_FALLBACK_MIMETYPE | Deprecated.

The format's MIME type is unsupported and the renderer may use a decoder for a fallback MIME type. | | static int | DECODER_SUPPORT_PRIMARY | Deprecated.

The renderer is able to use the primary decoder for the format's MIME type. | | static int | FORMAT_EXCEEDS_CAPABILITIES | Deprecated. Use C.FORMAT_EXCEEDS_CAPABILITIES instead.

| | static int | FORMAT_HANDLED | Deprecated. Use C.FORMAT_HANDLED instead.

| | static int | FORMAT_SUPPORT_MASK | Deprecated.

A mask to apply to RendererCapabilities.Capabilities to obtain the C.FormatSupport only. | | static int | FORMAT_UNSUPPORTED_DRM | Deprecated. Use C.FORMAT_UNSUPPORTED_DRM instead.

| | static int | FORMAT_UNSUPPORTED_SUBTYPE | Deprecated. Use C.FORMAT_UNSUPPORTED_SUBTYPE instead.

| | static int | FORMAT_UNSUPPORTED_TYPE | Deprecated. Use C.FORMAT_UNSUPPORTED_TYPE instead.

| | static int | HARDWARE_ACCELERATION_NOT_SUPPORTED | Deprecated.

The renderer is not able to use hardware acceleration. | | static int | HARDWARE_ACCELERATION_SUPPORT_MASK | Deprecated.

A mask to apply to RendererCapabilities.Capabilities to obtain RendererCapabilities.HardwareAccelerationSupport only. | | static int | HARDWARE_ACCELERATION_SUPPORTED | Deprecated.

The renderer is able to use hardware acceleration. | | static int | MODE_SUPPORT_MASK | Deprecated.

A mask to apply to RendererCapabilities.Capabilities to obtain RendererCapabilities.DecoderSupport only. | | static int | TUNNELING_NOT_SUPPORTED | Deprecated.

The Renderer does not support tunneled output. | | static int | TUNNELING_SUPPORT_MASK | Deprecated.

A mask to apply to RendererCapabilities.Capabilities to obtain RendererCapabilities.TunnelingSupport only. | | static int | TUNNELING_SUPPORTED | Deprecated.

The Renderer supports tunneled output. |

Method Summary

All Methods Static Methods Instance Methods Abstract Methods Default Methods Deprecated Methods | Modifier and Type | Method | Description | | --- | --- | --- | | default void | clearListener() | Deprecated.

Clears the RendererCapabilities.Listener. | | static @com.google.android.exoplayer2.RendererCapabilities.Capabilities int | create​(@com.google.android.exoplayer2.C.FormatSupport int formatSupport) | Deprecated.

Returns RendererCapabilities.Capabilities for the given C.FormatSupport. | | static @com.google.android.exoplayer2.RendererCapabilities.Capabilities int | create​(@com.google.android.exoplayer2.C.FormatSupport int formatSupport, @com.google.android.exoplayer2.RendererCapabilities.AdaptiveSupport int adaptiveSupport, @com.google.android.exoplayer2.RendererCapabilities.TunnelingSupport int tunnelingSupport) | Deprecated.

Returns RendererCapabilities.Capabilities combining the given C.FormatSupport, RendererCapabilities.AdaptiveSupport and RendererCapabilities.TunnelingSupport. | | static @com.google.android.exoplayer2.RendererCapabilities.Capabilities int | create​(@com.google.android.exoplayer2.C.FormatSupport int formatSupport, @com.google.android.exoplayer2.RendererCapabilities.AdaptiveSupport int adaptiveSupport, @com.google.android.exoplayer2.RendererCapabilities.TunnelingSupport int tunnelingSupport, @com.google.android.exoplayer2.RendererCapabilities.HardwareAccelerationSupport int hardwareAccelerationSupport, @com.google.android.exoplayer2.RendererCapabilities.DecoderSupport int decoderSupport) | Deprecated.

Returns RendererCapabilities.Capabilities combining the given C.FormatSupport, RendererCapabilities.AdaptiveSupport, RendererCapabilities.TunnelingSupport, RendererCapabilities.HardwareAccelerationSupport and RendererCapabilities.DecoderSupport. | | static @com.google.android.exoplayer2.RendererCapabilities.AdaptiveSupport int | getAdaptiveSupport​(@com.google.android.exoplayer2.RendererCapabilities.Capabilities int supportFlags) | Deprecated.

Returns the RendererCapabilities.AdaptiveSupport from the combined RendererCapabilities.Capabilities. | | static @com.google.android.exoplayer2.RendererCapabilities.DecoderSupport int | getDecoderSupport​(@com.google.android.exoplayer2.RendererCapabilities.Capabilities int supportFlags) | Deprecated.

Returns the RendererCapabilities.DecoderSupport from the combined RendererCapabilities.Capabilities. | | static @com.google.android.exoplayer2.C.FormatSupport int | getFormatSupport​(@com.google.android.exoplayer2.RendererCapabilities.Capabilities int supportFlags) | Deprecated.

Returns the C.FormatSupport from the combined RendererCapabilities.Capabilities. | | static @com.google.android.exoplayer2.RendererCapabilities.HardwareAccelerationSupport int | getHardwareAccelerationSupport​(@com.google.android.exoplayer2.RendererCapabilities.Capabilities int supportFlags) | Deprecated.

Returns the RendererCapabilities.HardwareAccelerationSupport from the combined RendererCapabilities.Capabilities. | | String | getName() | Deprecated.

Returns the name of the Renderer. | | @com.google.android.exoplayer2.C.TrackType int | getTrackType() | Deprecated.

Returns the track type that the Renderer handles. | | static @com.google.android.exoplayer2.RendererCapabilities.TunnelingSupport int | getTunnelingSupport​(@com.google.android.exoplayer2.RendererCapabilities.Capabilities int supportFlags) | Deprecated.

Returns the RendererCapabilities.TunnelingSupport from the combined RendererCapabilities.Capabilities. | | default void | setListener​(RendererCapabilities.Listener listener) | Deprecated.

Sets the RendererCapabilities.Listener. | | @com.google.android.exoplayer2.RendererCapabilities.Capabilities int | supportsFormat​(Format format) | Deprecated.

Returns the extent to which the Renderer supports a given format. | | @com.google.android.exoplayer2.RendererCapabilities.AdaptiveSupport int | supportsMixedMimeTypeAdaptation() | Deprecated.

Returns the extent to which the Renderer supports adapting between supported formats that have different MIME types. |

Field Detail

- 

FORMAT_SUPPORT_MASK

static final int FORMAT_SUPPORT_MASK

Deprecated.

A mask to apply to RendererCapabilities.Capabilities to obtain the C.FormatSupport only. See Also:Constant Field Values

- 

FORMAT_HANDLED

[@Deprecated](https://developer.android.com/reference/java/lang/Deprecated.html "class or interface in java.lang")static final int FORMAT_HANDLED

Deprecated. Use C.FORMAT_HANDLED instead.

See Also:Constant Field Values

- 

FORMAT_EXCEEDS_CAPABILITIES

[@Deprecated](https://developer.android.com/reference/java/lang/Deprecated.html "class or interface in java.lang")static final int FORMAT_EXCEEDS_CAPABILITIES

Deprecated. Use C.FORMAT_EXCEEDS_CAPABILITIES instead.

See Also:Constant Field Values

- 

FORMAT_UNSUPPORTED_DRM

[@Deprecated](https://developer.android.com/reference/java/lang/Deprecated.html "class or interface in java.lang")static final int FORMAT_UNSUPPORTED_DRM

Deprecated. Use C.FORMAT_UNSUPPORTED_DRM instead.

See Also:Constant Field Values

- 

FORMAT_UNSUPPORTED_SUBTYPE

[@Deprecated](https://developer.android.com/reference/java/lang/Deprecated.html "class or interface in java.lang")static final int FORMAT_UNSUPPORTED_SUBTYPE

Deprecated. Use C.FORMAT_UNSUPPORTED_SUBTYPE instead.

See Also:Constant Field Values

- 

FORMAT_UNSUPPORTED_TYPE

[@Deprecated](https://developer.android.com/reference/java/lang/Deprecated.html "class or interface in java.lang")static final int FORMAT_UNSUPPORTED_TYPE

Deprecated. Use C.FORMAT_UNSUPPORTED_TYPE instead.

See Also:Constant Field Values

- 

ADAPTIVE_SUPPORT_MASK

static final int ADAPTIVE_SUPPORT_MASK

Deprecated.

A mask to apply to RendererCapabilities.Capabilities to obtain the RendererCapabilities.AdaptiveSupport only. See Also:Constant Field Values

- 

ADAPTIVE_SEAMLESS

static final int ADAPTIVE_SEAMLESS

Deprecated.

The Renderer can seamlessly adapt between formats. See Also:Constant Field Values

- 

ADAPTIVE_NOT_SEAMLESS

static final int ADAPTIVE_NOT_SEAMLESS

Deprecated.

The Renderer can adapt between formats, but may suffer a brief discontinuity (~50-100ms) when adaptation occurs. See Also:Constant Field Values

- 

ADAPTIVE_NOT_SUPPORTED

static final int ADAPTIVE_NOT_SUPPORTED

Deprecated.

The Renderer does not support adaptation between formats. See Also:Constant Field Values

- 

TUNNELING_SUPPORT_MASK

static final int TUNNELING_SUPPORT_MASK

Deprecated.

A mask to apply to RendererCapabilities.Capabilities to obtain RendererCapabilities.TunnelingSupport only. See Also:Constant Field Values

- 

TUNNELING_SUPPORTED

static final int TUNNELING_SUPPORTED

Deprecated.

The Renderer supports tunneled output. See Also:Constant Field Values

- 

TUNNELING_NOT_SUPPORTED

static final int TUNNELING_NOT_SUPPORTED

Deprecated.

The Renderer does not support tunneled output. See Also:Constant Field Values

- 

HARDWARE_ACCELERATION_SUPPORT_MASK

static final int HARDWARE_ACCELERATION_SUPPORT_MASK

Deprecated.

A mask to apply to RendererCapabilities.Capabilities to obtain RendererCapabilities.HardwareAccelerationSupport only. See Also:Constant Field Values

- 

HARDWARE_ACCELERATION_SUPPORTED

static final int HARDWARE_ACCELERATION_SUPPORTED

Deprecated.

The renderer is able to use hardware acceleration. See Also:Constant Field Values

- 

HARDWARE_ACCELERATION_NOT_SUPPORTED

static final int HARDWARE_ACCELERATION_NOT_SUPPORTED

Deprecated.

The renderer is not able to use hardware acceleration. See Also:Constant Field Values

- 

MODE_SUPPORT_MASK

static final int MODE_SUPPORT_MASK

Deprecated.

A mask to apply to RendererCapabilities.Capabilities to obtain RendererCapabilities.DecoderSupport only. See Also:Constant Field Values

- 

DECODER_SUPPORT_FALLBACK_MIMETYPE

static final int DECODER_SUPPORT_FALLBACK_MIMETYPE

Deprecated.

The format's MIME type is unsupported and the renderer may use a decoder for a fallback MIME type. See Also:Constant Field Values

- 

DECODER_SUPPORT_PRIMARY

static final int DECODER_SUPPORT_PRIMARY

Deprecated.

The renderer is able to use the primary decoder for the format's MIME type. See Also:Constant Field Values

- 

DECODER_SUPPORT_FALLBACK

static final int DECODER_SUPPORT_FALLBACK

Deprecated.

The format exceeds the primary decoder's capabilities but is supported by fallback decoder See Also:Constant Field Values

Method Detail

- 

create

static @com.google.android.exoplayer2.RendererCapabilities.Capabilities int create​([@FormatSupport](C.FormatSupport.html "annotation in com.google.android.exoplayer2")@com.google.android.exoplayer2.C.FormatSupport int formatSupport)

Deprecated.

Returns RendererCapabilities.Capabilities for the given C.FormatSupport.

RendererCapabilities.AdaptiveSupport is set to ADAPTIVE_NOT_SUPPORTED, RendererCapabilities.TunnelingSupport is set to TUNNELING_NOT_SUPPORTED, RendererCapabilities.HardwareAccelerationSupport is set to HARDWARE_ACCELERATION_NOT_SUPPORTED and RendererCapabilities.DecoderSupport is set to DECODER_SUPPORT_PRIMARY.

Parameters:formatSupport - The C.FormatSupport.Returns:The combined RendererCapabilities.Capabilities of the given C.FormatSupport, ADAPTIVE_NOT_SUPPORTED and TUNNELING_NOT_SUPPORTED.

- 

create

static @com.google.android.exoplayer2.RendererCapabilities.Capabilities int create​([@FormatSupport](C.FormatSupport.html "annotation in com.google.android.exoplayer2")@com.google.android.exoplayer2.C.FormatSupport int formatSupport,
                                                                                   @com.google.android.exoplayer2.RendererCapabilities.AdaptiveSupport int adaptiveSupport,
                                                                                   @com.google.android.exoplayer2.RendererCapabilities.TunnelingSupport int tunnelingSupport)

Deprecated.

Returns RendererCapabilities.Capabilities combining the given C.FormatSupport, RendererCapabilities.AdaptiveSupport and RendererCapabilities.TunnelingSupport.

RendererCapabilities.HardwareAccelerationSupport is set to HARDWARE_ACCELERATION_NOT_SUPPORTED and RendererCapabilities.DecoderSupport is set to DECODER_SUPPORT_PRIMARY.

Parameters:formatSupport - The C.FormatSupport.adaptiveSupport - The RendererCapabilities.AdaptiveSupport.tunnelingSupport - The RendererCapabilities.TunnelingSupport.Returns:The combined RendererCapabilities.Capabilities.

- 

create

static @com.google.android.exoplayer2.RendererCapabilities.Capabilities int create​([@FormatSupport](C.FormatSupport.html "annotation in com.google.android.exoplayer2")@com.google.android.exoplayer2.C.FormatSupport int formatSupport,
                                                                                   @com.google.android.exoplayer2.RendererCapabilities.AdaptiveSupport int adaptiveSupport,
                                                                                   @com.google.android.exoplayer2.RendererCapabilities.TunnelingSupport int tunnelingSupport,
                                                                                   @com.google.android.exoplayer2.RendererCapabilities.HardwareAccelerationSupport int hardwareAccelerationSupport,
                                                                                   @com.google.android.exoplayer2.RendererCapabilities.DecoderSupport int decoderSupport)

Deprecated.

Returns RendererCapabilities.Capabilities combining the given C.FormatSupport, RendererCapabilities.AdaptiveSupport, RendererCapabilities.TunnelingSupport, RendererCapabilities.HardwareAccelerationSupport and RendererCapabilities.DecoderSupport. Parameters:formatSupport - The C.FormatSupport.adaptiveSupport - The RendererCapabilities.AdaptiveSupport.tunnelingSupport - The RendererCapabilities.TunnelingSupport.hardwareAccelerationSupport - The RendererCapabilities.HardwareAccelerationSupport.decoderSupport - The RendererCapabilities.DecoderSupport.Returns:The combined RendererCapabilities.Capabilities.

- 

getFormatSupport

[@FormatSupport](C.FormatSupport.html "annotation in com.google.android.exoplayer2")static @com.google.android.exoplayer2.C.FormatSupport int getFormatSupport​(@com.google.android.exoplayer2.RendererCapabilities.Capabilities int supportFlags)

Deprecated.

Returns the C.FormatSupport from the combined RendererCapabilities.Capabilities. Parameters:supportFlags - The combined RendererCapabilities.Capabilities.Returns:The C.FormatSupport only.

- 

getAdaptiveSupport

static @com.google.android.exoplayer2.RendererCapabilities.AdaptiveSupport int getAdaptiveSupport​(@com.google.android.exoplayer2.RendererCapabilities.Capabilities int supportFlags)

Deprecated.

Returns the RendererCapabilities.AdaptiveSupport from the combined RendererCapabilities.Capabilities. Parameters:supportFlags - The combined RendererCapabilities.Capabilities.Returns:The RendererCapabilities.AdaptiveSupport only.

- 

getTunnelingSupport

static @com.google.android.exoplayer2.RendererCapabilities.TunnelingSupport int getTunnelingSupport​(@com.google.android.exoplayer2.RendererCapabilities.Capabilities int supportFlags)

Deprecated.

Returns the RendererCapabilities.TunnelingSupport from the combined RendererCapabilities.Capabilities. Parameters:supportFlags - The combined RendererCapabilities.Capabilities.Returns:The RendererCapabilities.TunnelingSupport only.

- 

getHardwareAccelerationSupport

static @com.google.android.exoplayer2.RendererCapabilities.HardwareAccelerationSupport int getHardwareAccelerationSupport​(@com.google.android.exoplayer2.RendererCapabilities.Capabilities int supportFlags)

Deprecated.

Returns the RendererCapabilities.HardwareAccelerationSupport from the combined RendererCapabilities.Capabilities. Parameters:supportFlags - The combined RendererCapabilities.Capabilities.Returns:The RendererCapabilities.HardwareAccelerationSupport only.

- 

getDecoderSupport

static @com.google.android.exoplayer2.RendererCapabilities.DecoderSupport int getDecoderSupport​(@com.google.android.exoplayer2.RendererCapabilities.Capabilities int supportFlags)

Deprecated.

Returns the RendererCapabilities.DecoderSupport from the combined RendererCapabilities.Capabilities. Parameters:supportFlags - The combined RendererCapabilities.Capabilities.Returns:The RendererCapabilities.DecoderSupport only.

- 

getName

[String](https://developer.android.com/reference/java/lang/String.html "class or interface in java.lang")getName()

Deprecated.

Returns the name of the Renderer.

- 

getTrackType

@com.google.android.exoplayer2.C.TrackType int getTrackType()

Deprecated.

Returns the track type that the Renderer handles. For example, a video renderer will return C.TRACK_TYPE_VIDEO, an audio renderer will return C.TRACK_TYPE_AUDIO, a text renderer will return C.TRACK_TYPE_TEXT, and so on. Returns:The track type.See Also:Renderer.getTrackType()

- 

supportsFormat

@com.google.android.exoplayer2.RendererCapabilities.Capabilities int supportsFormat​([Format](Format.html "class in com.google.android.exoplayer2")format)
                                                                             throws[ExoPlaybackException](ExoPlaybackException.html "class in com.google.android.exoplayer2")

Deprecated.

Returns the extent to which the Renderer supports a given format. Parameters:format - The format.Returns:The RendererCapabilities.Capabilities for this format.Throws:ExoPlaybackException - If an error occurs.

- 

supportsMixedMimeTypeAdaptation

@com.google.android.exoplayer2.RendererCapabilities.AdaptiveSupport int supportsMixedMimeTypeAdaptation()
                                                                                                 throws[ExoPlaybackException](ExoPlaybackException.html "class in com.google.android.exoplayer2")

Deprecated.

Returns the extent to which the Renderer supports adapting between supported formats that have different MIME types. Returns:The RendererCapabilities.AdaptiveSupport for adapting between supported formats that have different MIME types.Throws:ExoPlaybackException - If an error occurs.

- 

setListener

default void setListener​([RendererCapabilities.Listener](RendererCapabilities.Listener.html "interface in com.google.android.exoplayer2")listener)

Deprecated.

Sets the RendererCapabilities.Listener. Parameters:listener - The listener to be set.

- 

clearListener

default void clearListener()

Deprecated.

Clears the RendererCapabilities.Listener.