• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1Streams in the following container formats can be played directly by ExoPlayer.
2The contained audio and video sample formats must also be supported (see the
3[sample formats](supported-formats.html#sample-formats) section for details).
4
5| Container format | Supported    | Comments             |
6|------------------|:------------:|:---------------------|
7| MP4 | YES ||
8| M4A | YES ||
9| FMP4 | YES ||
10| WebM| YES ||
11| Matroska| YES ||
12| MP3 | YES | Some streams only seekable using constant bitrate seeking** |
13| Ogg | YES | Containing Vorbis, Opus and FLAC |
14| WAV | YES ||
15| MPEG-TS | YES ||
16| MPEG-PS | YES ||
17| FLV | YES | Not seekable* |
18| ADTS (AAC) | YES | Only seekable using constant bitrate seeking** |
19| FLAC | YES | Using the [FLAC extension][] or the FLAC extractor in the [core library][]*** |
20| AMR | YES | Only seekable using constant bitrate seeking** |
21| JPEG motion photo | YES | Only the MP4 content is extracted |
22
23\* Seeking is unsupported because the container does not provide metadata (e.g.,
24a sample index) to allow a media player to perform a seek in an efficient way.
25If seeking is required, we suggest using a more appropriate container format.
26
27\*\* These extractors have `FLAG_ENABLE_CONSTANT_BITRATE_SEEKING` flags for
28enabling approximate seeking using a constant bitrate assumption. This
29functionality is not enabled by default. The simplest way to enable this
30functionality for all extractors that support it is to use
31`DefaultExtractorsFactory.setConstantBitrateSeekingEnabled`, as described
32[here](customization.html#enabling-constant-bitrate-seeking).
33
34\*\*\* The [FLAC extension][] extractor outputs raw audio, which can be handled
35by the framework on all API levels. The [core library][] FLAC extractor outputs
36FLAC audio frames and so relies on having a FLAC decoder (e.g., a `MediaCodec`
37decoder that handles FLAC (required from API level 27), or the
38[FFmpeg extension][] with FLAC enabled). The `DefaultExtractorsFactory` uses the
39extension extractor if the application was built with the [FLAC extension][].
40Otherwise, it uses the [core library][] extractor.
41
42[FLAC extension]: {{ site.release_v2 }}/extensions/flac
43[core library]: {{ site.release_v2 }}/library/core
44[FFmpeg extension]: {{ site.release_v2 }}/extensions/ffmpeg
45