Interface PlaybackSettings

  • All Implemented Interfaces:

    
    public interface PlaybackSettings
    
                        

    The playback settings.

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
    • Field Summary

      Fields 
      Modifier and Type Field Description
    • Constructor Summary

      Constructors 
      Constructor Description
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
    • Method Summary

      Modifier and Type Method Description
      abstract void useFastStartup(boolean useFastStartup) The player starts the playback as soon as the first video data is available related to the initial playback position.
      abstract void setDecoderSelectionHelper(@Nullable() DecoderSelectionHelper decoderSelectionHelper) This helper manages whether the specified codec is usable for decoding on the current device.
      abstract String getDecoderName(DecoderType decoderType, String mimeType, boolean secure) Returns the decoder name that would be selected for a media with the specified properties.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

    • Method Detail

      • useFastStartup

         abstract void useFastStartup(boolean useFastStartup)

        The player starts the playback as soon as the first video data is available related to the initial playback position.

        • Using this feature will sacrifice the accuracy of the initial seek position
        • This API is in an experimental stage and may be subject to breaking changes.
        Parameters:
        useFastStartup - Whether fast startup is enabled.
      • setDecoderSelectionHelper

         abstract void setDecoderSelectionHelper(@Nullable() DecoderSelectionHelper decoderSelectionHelper)

        This helper manages whether the specified codec is usable for decoding on the current device.

        • The player by default always tries to use the preferred decoder by the device.
        • In some cases these decoders are not the best for certain playback use-cases, so this methods gives the decoder selection logic into your hands.
        • This is a global setting for all player instances. Strongly suggest you to only flip this flag when it is really needed, per device basis.
        • This API is in an experimental stage and may be subject to breaking changes.
        Parameters:
        decoderSelectionHelper - the helper that decides based on the decoder name if it can be used on the device.
      • getDecoderName

        @Nullable() abstract String getDecoderName(DecoderType decoderType, String mimeType, boolean secure)

        Returns the decoder name that would be selected for a media with the specified properties.

        • Will return null if there is no supported decoder.
        Parameters:
        decoderType - The decoder type, weather it's a Video or an Audio.
        mimeType - The mimeType of the media.
        secure - Whether the media is DRM protected or not.
        Returns:

        The decoder name to be used for the specified media. (Nullable)