GetDefaultContentDecryptionModuleFactory 函式 (comppkgsup.h)

重要

有些資訊與發行前版本產品有關,在正式發行前可能會大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。

針對內建至 Windows 的指定索引鍵系統,傳回 IMFContentDecryptionModuleFactory 的實作。

語法

HRESULT GetDefaultContentDecryptionModuleFactory(
  [in]  PCWSTR                            keySystem,
  [out] IMFContentDecryptionModuleFactory **contentDecryptionModuleFactory
);

參數

[in] keySystem

PCWSTR,識別傳回解密模組的金鑰系統。

[out] contentDecryptionModuleFactory

如果找到指定的索引鍵系統,則會收到 IMFContentDecryptionModuleFactory 實作的指標;否則為 NULL。

傳回值

包含下列值的 HRESULT:

描述
S_OK 成功。 即使找不到指定的索引鍵系統,但在此情況下, contentDecryptionModuleFactory 參數仍會傳回成功。
CO_E_NOTINITIALIZED 呼叫函式之前,未初始化 COM

備註

GetDefaultContentDescryptionModuleFactory 只考慮內建至 Windows 的爭用解密模塊處理站,而且不會考慮從 Microsoft Store 下載的內容解密模組處理站。

建議應用程式使用 IMFMediaEngineClassFactory4::CreateContentDecryptionModuleFactory,因為此方法會先呼叫 GetDefaultContentDecryptionModuleFactory ,但接著也會搜尋任何可能已從 Microsoft Store 下載之 IMFContentDecryptionModuleFactory 的相符實作。

規格需求

需求
最低支援的用戶端 Windows 11 版本 24H2
標頭 comppkgsup.h
程式庫 Comppkgsup.lib
Dll Comppkgsup.dll