| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2012 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 #include "webrtc/modules/video_processing/content_analysis.h" | 10 #include "webrtc/modules/video_processing/content_analysis.h" |
| 11 | 11 |
| 12 #include <math.h> | 12 #include <math.h> |
| 13 #include <stdlib.h> | 13 #include <stdlib.h> |
| 14 | 14 |
| 15 #include "webrtc/system_wrappers/include/cpu_features_wrapper.h" | 15 #include "webrtc/system_wrappers/include/cpu_features_wrapper.h" |
| 16 #include "webrtc/system_wrappers/include/tick_util.h" | |
| 17 | 16 |
| 18 namespace webrtc { | 17 namespace webrtc { |
| 19 | 18 |
| 20 VPMContentAnalysis::VPMContentAnalysis(bool runtime_cpu_detection) | 19 VPMContentAnalysis::VPMContentAnalysis(bool runtime_cpu_detection) |
| 21 : orig_frame_(NULL), | 20 : orig_frame_(NULL), |
| 22 prev_frame_(NULL), | 21 prev_frame_(NULL), |
| 23 width_(0), | 22 width_(0), |
| 24 height_(0), | 23 height_(0), |
| 25 skip_num_(1), | 24 skip_num_(1), |
| 26 border_(8), | 25 border_(8), |
| (...skipping 245 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 272 content_metrics_->spatial_pred_err = spatial_pred_err_; | 271 content_metrics_->spatial_pred_err = spatial_pred_err_; |
| 273 content_metrics_->spatial_pred_err_h = spatial_pred_err_h_; | 272 content_metrics_->spatial_pred_err_h = spatial_pred_err_h_; |
| 274 content_metrics_->spatial_pred_err_v = spatial_pred_err_v_; | 273 content_metrics_->spatial_pred_err_v = spatial_pred_err_v_; |
| 275 // Motion metric: normalized temporal difference (MAD). | 274 // Motion metric: normalized temporal difference (MAD). |
| 276 content_metrics_->motion_magnitude = motion_magnitude_; | 275 content_metrics_->motion_magnitude = motion_magnitude_; |
| 277 | 276 |
| 278 return content_metrics_; | 277 return content_metrics_; |
| 279 } | 278 } |
| 280 | 279 |
| 281 } // namespace webrtc | 280 } // namespace webrtc |
| OLD | NEW |