1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
media / mojo / mojom / output_protection.mojom [blame]
// Copyright 2016 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
module media.mojom;
// An interface to query output protection status and enable output protection
// on links that support it.
interface OutputProtection {
[Stable, Extensible]
enum ProtectionType {
[Default] NONE = 0,
HDCP = 1,
};
// Video output link types.
[Stable, Extensible]
enum LinkType {
[Default] NONE = 0,
UNKNOWN = 1,
INTERNAL = 2,
VGA = 4,
HDMI = 8,
DVI = 16,
DISPLAYPORT = 32,
NETWORK = 64,
};
// Queries link status and protection status.
// Clients need to query status periodically in order to detect changes.
//
// - success: Whether the query succeeded. If false, values of |link_mask| and
// |protection_mask| should be ignored.
// - link_mask: The type of connected output links, which is a bit-mask of the
// LinkType values.
// - protection_mask: The type of enabled protections, which is a bit-mask of
// the ProtectionType values.
QueryStatus() => (bool success, uint32 link_mask, uint32 protection_mask);
// Sets desired protection methods.
//
// When the desired protection method(s) have been applied to all applicable
// output links, the relevant bit(s) of the |protection_mask| returned by
// QueryStatus() will be set. Otherwise, the relevant bit(s) of
// |protection_mask| will not be set; there is no separate error code or
// callback.
//
// Protections will be disabled if no longer desired by all instances.
//
// - desired_protection_mask: The desired protection methods, which
// is a bit-mask of the ProtectionType values.
// - success: True when the protection request has been made. This may be
// before the protection have actually been applied. Call QueryStatus() to
// get protection status. False if it failed to make the protection request,
// and in this case there is no need to call QueryStatus().
EnableProtection(uint32 desired_protection_mask) => (bool success);
};