Class OpusLibrary


  • public final class OpusLibrary
    extends Object
    Configures and queries the underlying native library.
    • Method Detail

      • setLibraries

        public static void setLibraries​(Class<? extends ExoMediaCrypto> exoMediaCryptoType,
                                        String... libraries)
        Override the names of the Opus native libraries. If an application wishes to call this method, it must do so before calling any other method defined by this class, and before instantiating a LibopusAudioRenderer instance.
        Parameters:
        exoMediaCryptoType - The ExoMediaCrypto type expected for decoding protected content.
        libraries - The names of the Opus native libraries.
      • isAvailable

        public static boolean isAvailable()
        Returns whether the underlying library is available, loading it if necessary.
      • getVersion

        @Nullable
        public static String getVersion()
        Returns the version of the underlying library if available, or null otherwise.
      • matchesExpectedExoMediaCryptoType

        public static boolean matchesExpectedExoMediaCryptoType​(Class<? extends ExoMediaCrypto> exoMediaCryptoType)
        Returns whether the given ExoMediaCrypto type matches the one required for decoding protected content.
      • opusGetVersion

        public static String opusGetVersion()
      • opusIsSecureDecodeSupported

        public static boolean opusIsSecureDecodeSupported()