Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(901)

Side by Side Diff: webrtc/video_frame.h

Issue 1311533012: Add histogram for percentage of sent frames that are limited in resolution due to bandwidth. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2014 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2014 The WebRTC project authors. All Rights Reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
(...skipping 163 matching lines...) Expand 10 before | Expand all | Expand 10 after
174 kSkipFrame = 4 174 kSkipFrame = 4
175 }; 175 };
176 176
177 // TODO(pbos): Rename EncodedFrame and reformat this class' members. 177 // TODO(pbos): Rename EncodedFrame and reformat this class' members.
178 class EncodedImage { 178 class EncodedImage {
179 public: 179 public:
180 EncodedImage() : EncodedImage(nullptr, 0, 0) {} 180 EncodedImage() : EncodedImage(nullptr, 0, 0) {}
181 EncodedImage(uint8_t* buffer, size_t length, size_t size) 181 EncodedImage(uint8_t* buffer, size_t length, size_t size)
182 : _buffer(buffer), _length(length), _size(size) {} 182 : _buffer(buffer), _length(length), _size(size) {}
183 183
184 struct AdaptReason {
185 AdaptReason()
186 : bw_available(false),
187 bw_resolutions_disabled(0) {}
188
189 bool bw_available; // True if |bw_resolutions_disabled| is provided.
190 int bw_resolutions_disabled; // Number of resolutions that are not sent
191 // due to bandwidth for this frame.
192 };
184 uint32_t _encodedWidth = 0; 193 uint32_t _encodedWidth = 0;
185 uint32_t _encodedHeight = 0; 194 uint32_t _encodedHeight = 0;
186 uint32_t _timeStamp = 0; 195 uint32_t _timeStamp = 0;
187 // NTP time of the capture time in local timebase in milliseconds. 196 // NTP time of the capture time in local timebase in milliseconds.
188 int64_t ntp_time_ms_ = 0; 197 int64_t ntp_time_ms_ = 0;
189 int64_t capture_time_ms_ = 0; 198 int64_t capture_time_ms_ = 0;
190 // TODO(pbos): Use webrtc::FrameType directly (and remove VideoFrameType). 199 // TODO(pbos): Use webrtc::FrameType directly (and remove VideoFrameType).
191 VideoFrameType _frameType = kDeltaFrame; 200 VideoFrameType _frameType = kDeltaFrame;
192 uint8_t* _buffer; 201 uint8_t* _buffer;
193 size_t _length; 202 size_t _length;
194 size_t _size; 203 size_t _size;
195 bool _completeFrame = false; 204 bool _completeFrame = false;
205 AdaptReason adapt_reason_;
196 }; 206 };
197 207
198 } // namespace webrtc 208 } // namespace webrtc
199 #endif // WEBRTC_VIDEO_FRAME_H_ 209 #endif // WEBRTC_VIDEO_FRAME_H_
OLDNEW
« webrtc/video/send_statistics_proxy.cc ('K') | « webrtc/video/send_statistics_proxy.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698