docs/doc/reference/com/google/android/exoplayer2/transformer/AssetLoader.html
Package com.google.android.exoplayer2.transformer
ExoPlayerAssetLoader, ImageAssetLoader, TextureAssetLoader[@Deprecated](https://developer.android.com/reference/java/lang/Deprecated.html "class or interface in java.lang")public interfaceAssetLoader
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.
Provides media data to a Transformer.
The output samples can be encoded or decoded.
Only audio and video samples are supported. Both audio and video tracks can be provided by a single asset loader, but outputting multiple tracks of the same type is not supported.
An asset loader is responsible for removing audio or video if requested.
If slow motion flattening is requested, the asset loader should flatten the video track for media containing slow motion markers. This is usually done prior to decoding. The audio samples are flattened after they are output by the AssetLoader, because this is done on decoded samples.
Nested Classes | Modifier and Type | Interface | Description |
| --- | --- | --- |
| static interface | AssetLoader.Factory |
Deprecated.
A factory for AssetLoader instances.
|
| static interface | AssetLoader.Listener |
Deprecated.
A listener of AssetLoader events.
|
| static interface | AssetLoader.SupportedOutputTypes |
Deprecated.
Supported output types of an asset loader. |
Fields | Modifier and Type | Field | Description |
| --- | --- | --- |
| static int | SUPPORTED_OUTPUT_TYPE_DECODED |
Deprecated.
Indicates that the asset loader can output decoded samples.
|
| static int | SUPPORTED_OUTPUT_TYPE_ENCODED |
Deprecated.
Indicates that the asset loader can output encoded samples. |
All Methods Instance Methods Abstract Methods Deprecated Methods | Modifier and Type | Method | Description |
| --- | --- | --- |
| ImmutableMap<Integer,String> | getDecoderNames() |
Deprecated.
Return the used decoders' names.
|
| @com.google.android.exoplayer2.transformer.Transformer.ProgressState int | getProgress(ProgressHolder progressHolder) |
Deprecated.
Returns the current Transformer.ProgressState and updates progressHolder with the current progress if it is available.
|
| void | release() |
Deprecated.
Stops loading data and releases all resources associated with the asset loader.
|
| void | start() |
Deprecated.
Starts the asset loader. |
-
static final int SUPPORTED_OUTPUT_TYPE_ENCODED
Deprecated.
Indicates that the asset loader can output encoded samples. See Also:Constant Field Values
-
static final int SUPPORTED_OUTPUT_TYPE_DECODED
Deprecated.
Indicates that the asset loader can output decoded samples. See Also:Constant Field Values
-
void start()
Deprecated.
Starts the asset loader.
-
@com.google.android.exoplayer2.transformer.Transformer.ProgressState int getProgress([ProgressHolder](ProgressHolder.html "class in com.google.android.exoplayer2.transformer")progressHolder)
Deprecated.
Returns the current Transformer.ProgressState and updates progressHolder with the current progress if it is available.
Parameters:progressHolder - A ProgressHolder, updated to hold the percentage progress if available.Returns:The Transformer.ProgressState.
-
[ImmutableMap](https://guava.dev/releases/31.1-android/api/docs/com/google/common/collect/ImmutableMap.html?is-external=true "class or interface in com.google.common.collect")<[Integer](https://developer.android.com/reference/java/lang/Integer.html "class or interface in java.lang"),[String](https://developer.android.com/reference/java/lang/String.html?is-external=true "class or interface in java.lang")> getDecoderNames()
Deprecated.
Return the used decoders' names. Returns:The decoders' names keyed by track type.
-
void release()
Deprecated.
Stops loading data and releases all resources associated with the asset loader.