| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (c) 2010 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2010 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 |
| 11 // Implementation file of class VideoCapturer. | 11 // Implementation file of class VideoCapturer. |
| 12 | 12 |
| 13 #include "webrtc/media/base/videocapturer.h" | 13 #include "webrtc/media/base/videocapturer.h" |
| 14 | 14 |
| 15 #include <algorithm> | 15 #include <algorithm> |
| 16 | 16 |
| 17 #include "libyuv/scale_argb.h" | 17 #include "libyuv/scale_argb.h" |
| 18 #include "webrtc/base/common.h" | 18 #include "webrtc/base/common.h" |
| 19 #include "webrtc/base/logging.h" | 19 #include "webrtc/base/logging.h" |
| 20 #include "webrtc/base/systeminfo.h" | 20 #include "webrtc/base/systeminfo.h" |
| 21 #include "webrtc/media/base/videoframefactory.h" | 21 #include "webrtc/media/base/videoframefactory.h" |
| 22 | 22 |
| 23 #if defined(HAVE_WEBRTC_VIDEO) | 23 #if defined(HAVE_WEBRTC_VIDEO) |
| 24 #include "webrtc/media/webrtc/webrtcvideoframe.h" | 24 #include "webrtc/media/engine/webrtcvideoframe.h" |
| 25 #include "webrtc/media/webrtc/webrtcvideoframefactory.h" | 25 #include "webrtc/media/engine/webrtcvideoframefactory.h" |
| 26 #endif // HAVE_WEBRTC_VIDEO | 26 #endif // HAVE_WEBRTC_VIDEO |
| 27 | 27 |
| 28 namespace cricket { | 28 namespace cricket { |
| 29 | 29 |
| 30 namespace { | 30 namespace { |
| 31 | 31 |
| 32 // TODO(thorcarpenter): This is a BIG hack to flush the system with black | 32 // TODO(thorcarpenter): This is a BIG hack to flush the system with black |
| 33 // frames. Frontends should coordinate to update the video state of a muted | 33 // frames. Frontends should coordinate to update the video state of a muted |
| 34 // user. When all frontends to this consider removing the black frame business. | 34 // user. When all frontends to this consider removing the black frame business. |
| 35 const int kNumBlackFramesOnMute = 30; | 35 const int kNumBlackFramesOnMute = 30; |
| (...skipping 666 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 702 void VideoCapturer::GetVariableSnapshot( | 702 void VideoCapturer::GetVariableSnapshot( |
| 703 const rtc::RollingAccumulator<T>& data, | 703 const rtc::RollingAccumulator<T>& data, |
| 704 VariableInfo<T>* stats) { | 704 VariableInfo<T>* stats) { |
| 705 stats->max_val = data.ComputeMax(); | 705 stats->max_val = data.ComputeMax(); |
| 706 stats->mean = data.ComputeMean(); | 706 stats->mean = data.ComputeMean(); |
| 707 stats->min_val = data.ComputeMin(); | 707 stats->min_val = data.ComputeMin(); |
| 708 stats->variance = data.ComputeVariance(); | 708 stats->variance = data.ComputeVariance(); |
| 709 } | 709 } |
| 710 | 710 |
| 711 } // namespace cricket | 711 } // namespace cricket |
| OLD | NEW |