xhwang | c3a252b | 2016-05-23 02:35:48 | [diff] [blame] | 1 | // Copyright 2016 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 | |
| 5 | #ifndef MEDIA_CDM_CDM_PATHS_H_ |
| 6 | #define MEDIA_CDM_CDM_PATHS_H_ |
| 7 | |
| 8 | #include <string> |
| 9 | |
| 10 | #include "base/files/file_path.h" |
Ken Rockot | 315def7 | 2018-11-10 02:16:10 | [diff] [blame] | 11 | #include "base/token.h" |
xhwang | c3a252b | 2016-05-23 02:35:48 | [diff] [blame] | 12 | |
| 13 | namespace media { |
| 14 | |
thestig | 02c965b | 2016-06-14 18:52:23 | [diff] [blame] | 15 | // Name of the ClearKey CDM library. |
| 16 | extern const char kClearKeyCdmLibraryName[]; |
| 17 | |
Xiaohan Wang | 17d4ffa | 2017-06-06 19:10:11 | [diff] [blame] | 18 | extern const char kClearKeyCdmBaseDirectory[]; |
| 19 | |
Xiaohan Wang | 17d4ffa | 2017-06-06 19:10:11 | [diff] [blame] | 20 | // Display name for Clear Key CDM. |
| 21 | extern const char kClearKeyCdmDisplayName[]; |
| 22 | |
Xiaohan Wang | 32821857 | 2017-10-02 19:20:41 | [diff] [blame] | 23 | // The default GUID for Clear Key Cdm. |
Ken Rockot | 315def7 | 2018-11-10 02:16:10 | [diff] [blame] | 24 | extern const base::Token kClearKeyCdmGuid; |
Xiaohan Wang | 32821857 | 2017-10-02 19:20:41 | [diff] [blame] | 25 | |
| 26 | // A different GUID for Clear Key Cdm for testing running different types of |
| 27 | // CDMs in the system. |
Ken Rockot | 315def7 | 2018-11-10 02:16:10 | [diff] [blame] | 28 | extern const base::Token kClearKeyCdmDifferentGuid; |
Xiaohan Wang | 32821857 | 2017-10-02 19:20:41 | [diff] [blame] | 29 | |
John Rummell | f0ab981 | 2017-10-11 20:00:49 | [diff] [blame] | 30 | // Identifier used by the PluginPrivateFileSystem to identify the files stored |
| 31 | // for the Clear Key CDM. |
| 32 | extern const char kClearKeyCdmFileSystemId[]; |
| 33 | |
xhwang | c3a252b | 2016-05-23 02:35:48 | [diff] [blame] | 34 | // Returns the path of a CDM relative to DIR_COMPONENTS. |
| 35 | // On platforms where a platform specific path is used, returns |
| 36 | // |cdm_base_path|/_platform_specific/<platform>_<arch> |
| 37 | // e.g. WidevineCdm/_platform_specific/win_x64 |
| 38 | // Otherwise, returns an empty path. |
| 39 | // TODO(xhwang): Use this function in Widevine CDM component installer. |
John Rummell | 54c6ac50 | 2019-09-24 23:52:06 | [diff] [blame] | 40 | base::FilePath GetPlatformSpecificDirectory( |
| 41 | const base::FilePath& cdm_base_path); |
xhwang | c3a252b | 2016-05-23 02:35:48 | [diff] [blame] | 42 | base::FilePath GetPlatformSpecificDirectory(const std::string& cdm_base_path); |
| 43 | |
| 44 | } // namespace media |
| 45 | |
| 46 | #endif // MEDIA_CDM_CDM_PATHS_H_ |