media_foundation_cdm_util.h 1.0 KB

123456789101112131415161718192021222324252627282930313233
  1. // Copyright 2022 The Chromium Authors. All rights reserved.
  2. // Use of this source code is governed by a BSD-style license that can be
  3. // found in the LICENSE file.
  4. #ifndef MEDIA_CDM_WIN_MEDIA_FOUNDATION_CDM_UTIL_H_
  5. #define MEDIA_CDM_WIN_MEDIA_FOUNDATION_CDM_UTIL_H_
  6. #include <stdint.h>
  7. #include <vector>
  8. #include <mfcontentdecryptionmodule.h>
  9. #include <wrl/client.h>
  10. #include "base/files/file_path.h"
  11. #include "base/unguessable_token.h"
  12. #include "media/base/cdm_config.h"
  13. #include "media/base/media_export.h"
  14. #include "third_party/abseil-cpp/absl/types/optional.h"
  15. namespace media {
  16. MEDIA_EXPORT HRESULT CreateMediaFoundationCdm(
  17. Microsoft::WRL::ComPtr<IMFContentDecryptionModuleFactory> cdm_factory,
  18. const CdmConfig& cdm_config,
  19. const base::UnguessableToken& cdm_origin_id,
  20. const absl::optional<std::vector<uint8_t>>& cdm_client_token,
  21. const base::FilePath& cdm_store_path_root,
  22. Microsoft::WRL::ComPtr<IMFContentDecryptionModule>& mf_cdm);
  23. } // namespace media
  24. #endif // MEDIA_CDM_WIN_MEDIA_FOUNDATION_CDM_UTIL_H_