OLD | NEW |
1 /* Copyright (c) 2015 The WebRTC project authors. All Rights Reserved. | 1 /* Copyright (c) 2015 The WebRTC project authors. All Rights Reserved. |
2 * | 2 * |
3 * Use of this source code is governed by a BSD-style license | 3 * Use of this source code is governed by a BSD-style license |
4 * that can be found in the LICENSE file in the root of the source | 4 * that can be found in the LICENSE file in the root of the source |
5 * tree. An additional intellectual property rights grant can be found | 5 * tree. An additional intellectual property rights grant can be found |
6 * in the file PATENTS. All contributing project authors may | 6 * in the file PATENTS. All contributing project authors may |
7 * be found in the AUTHORS file in the root of the source tree. | 7 * be found in the AUTHORS file in the root of the source tree. |
8 */ | 8 */ |
9 | 9 |
| 10 #include <algorithm> |
10 #include "webrtc/modules/video_coding/codecs/vp9/screenshare_layers.h" | 11 #include "webrtc/modules/video_coding/codecs/vp9/screenshare_layers.h" |
11 #include <algorithm> | 12 #include "webrtc/base/checks.h" |
12 #include "webrtc/rtc_base/checks.h" | |
13 | 13 |
14 namespace webrtc { | 14 namespace webrtc { |
15 | 15 |
16 ScreenshareLayersVP9::ScreenshareLayersVP9(uint8_t num_layers) | 16 ScreenshareLayersVP9::ScreenshareLayersVP9(uint8_t num_layers) |
17 : num_layers_(num_layers), | 17 : num_layers_(num_layers), |
18 start_layer_(0), | 18 start_layer_(0), |
19 last_timestamp_(0), | 19 last_timestamp_(0), |
20 timestamp_initialized_(false) { | 20 timestamp_initialized_(false) { |
21 RTC_DCHECK_GT(num_layers, 0); | 21 RTC_DCHECK_GT(num_layers, 0); |
22 RTC_DCHECK_LE(num_layers, kMaxVp9NumberOfSpatialLayers); | 22 RTC_DCHECK_LE(num_layers, kMaxVp9NumberOfSpatialLayers); |
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
84 | 84 |
85 settings.layer[num_layers_ - 1].upd_buf = num_layers_ - 1; | 85 settings.layer[num_layers_ - 1].upd_buf = num_layers_ - 1; |
86 settings.is_keyframe = is_keyframe; | 86 settings.is_keyframe = is_keyframe; |
87 settings.start_layer = start_layer_; | 87 settings.start_layer = start_layer_; |
88 settings.stop_layer = num_layers_ - 1; | 88 settings.stop_layer = num_layers_ - 1; |
89 last_timestamp_ = timestamp; | 89 last_timestamp_ = timestamp; |
90 return settings; | 90 return settings; |
91 } | 91 } |
92 | 92 |
93 } // namespace webrtc | 93 } // namespace webrtc |
OLD | NEW |