Vinyl
    Preparing search index...

    Interface CommonMediaKeys

    This provides a common interface for MediaKeys EME implementations.

    interface CommonMediaKeys {
        keySystem: DrmKeySystem;
        clearFromElement(element: HTMLMediaElement): Promise<void>;
        createSession(
            mimeType: string,
            initDataType: string,
            initData: EncryptedInitData,
        ): CommonMediaKeySession;
        setOnElement(element: HTMLMediaElement): Promise<void>;
        setServerCertificate(certificate: BufferSource): Promise<boolean>;
    }

    Implemented by

    Index

    Properties

    keySystem: DrmKeySystem

    Methods

    • Clears the media keys from the given element. This is only allowed if the element's src isn't set. https://bugs.chromium.org/p/chromium/issues/detail?id=462365#c7

      Parameters

      • element: HTMLMediaElement

      Returns Promise<void>

    • Sets the media keys on the given element.

      Parameters

      • element: HTMLMediaElement

      Returns Promise<void>

    • Sets the server certificate on the media keys.

      A Promise that resolves to a boolean. If the Key System implementation represented by this object's content decryption module's implementation value does not support server certificates, return a promise resolved with false.

      Parameters

      • certificate: BufferSource

        The server certificate data.

      Returns Promise<boolean>