OLD | NEW |
---|---|
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef MEDIA_BASE_VIDEO_FRAME_METADATA_H_ | 5 #ifndef MEDIA_BASE_VIDEO_FRAME_METADATA_H_ |
6 #define MEDIA_BASE_VIDEO_FRAME_METADATA_H_ | 6 #define MEDIA_BASE_VIDEO_FRAME_METADATA_H_ |
7 | 7 |
8 #include <string> | |
9 | |
8 #include "base/compiler_specific.h" | 10 #include "base/compiler_specific.h" |
9 #include "base/time/time.h" | 11 #include "base/time/time.h" |
10 #include "base/values.h" | 12 #include "base/values.h" |
11 #include "media/base/media_export.h" | 13 #include "media/base/media_export.h" |
12 | 14 |
13 namespace media { | 15 namespace media { |
14 | 16 |
15 class MEDIA_EXPORT VideoFrameMetadata { | 17 class MEDIA_EXPORT VideoFrameMetadata { |
16 public: | 18 public: |
17 enum Key { | 19 enum Key { |
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
70 // maximum sustainable utilization. Greater than 1.0 indicates the consumer | 72 // maximum sustainable utilization. Greater than 1.0 indicates the consumer |
71 // is likely to stall or drop frames if the data volume is not reduced. | 73 // is likely to stall or drop frames if the data volume is not reduced. |
72 // | 74 // |
73 // Example: In a system that encodes and transmits video frames over the | 75 // Example: In a system that encodes and transmits video frames over the |
74 // network, this value can be used to indicate whether sufficient CPU | 76 // network, this value can be used to indicate whether sufficient CPU |
75 // is available for encoding and/or sufficient bandwidth is available for | 77 // is available for encoding and/or sufficient bandwidth is available for |
76 // transmission over the network. The maximum of the two utilization | 78 // transmission over the network. The maximum of the two utilization |
77 // measurements would be used as feedback. | 79 // measurements would be used as feedback. |
78 RESOURCE_UTILIZATION, | 80 RESOURCE_UTILIZATION, |
79 | 81 |
82 // This is a boolean that signals that the video capture engine detects | |
83 // interactive content. One possible optimization that this signal can help | |
84 // with is adjusting end-to-end latency based on whether the mode is turned | |
miu
2015/12/03 21:26:23
For a bit more clarity for those unfamiliar with m
Irfan
2015/12/04 22:45:37
Done.
| |
85 // on or off. | |
86 // | |
87 // Use Get/SetBoolean for this key. | |
88 INTERACTIVE_MODE, | |
miu
2015/12/03 21:26:23
1. naming nit: How about INTERACTIVE_CONTENT? (i.
Irfan
2015/12/04 22:45:37
Done.
| |
89 | |
80 NUM_KEYS | 90 NUM_KEYS |
81 }; | 91 }; |
82 | 92 |
83 VideoFrameMetadata(); | 93 VideoFrameMetadata(); |
84 ~VideoFrameMetadata(); | 94 ~VideoFrameMetadata(); |
85 | 95 |
86 bool HasKey(Key key) const; | 96 bool HasKey(Key key) const; |
87 | 97 |
88 void Clear() { dictionary_.Clear(); } | 98 void Clear() { dictionary_.Clear(); } |
89 | 99 |
(...skipping 28 matching lines...) Expand all Loading... | |
118 const base::BinaryValue* GetBinaryValue(Key key) const; | 128 const base::BinaryValue* GetBinaryValue(Key key) const; |
119 | 129 |
120 base::DictionaryValue dictionary_; | 130 base::DictionaryValue dictionary_; |
121 | 131 |
122 DISALLOW_COPY_AND_ASSIGN(VideoFrameMetadata); | 132 DISALLOW_COPY_AND_ASSIGN(VideoFrameMetadata); |
123 }; | 133 }; |
124 | 134 |
125 } // namespace media | 135 } // namespace media |
126 | 136 |
127 #endif // MEDIA_BASE_VIDEO_FRAME_METADATA_H_ | 137 #endif // MEDIA_BASE_VIDEO_FRAME_METADATA_H_ |
OLD | NEW |