Interface AssetLoader

  • All Known Implementing Classes:
    ExoPlayerAssetLoader, ImageAssetLoader, TextureAssetLoader

    public interface AssetLoader
    Deprecated. 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.

    • Field Detail


        static final int SUPPORTED_OUTPUT_TYPE_ENCODED
        Indicates that the asset loader can output encoded samples.
        See Also:
        Constant Field Values

        static final int SUPPORTED_OUTPUT_TYPE_DECODED
        Indicates that the asset loader can output decoded samples.
        See Also:
        Constant Field Values
    • Method Detail

      • start

        void start()
        Starts the asset loader.
      • release

        void release()
        Stops loading data and releases all resources associated with the asset loader.