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

Side by Side Diff: webrtc/modules/video_processing/frame_preprocessor.h

Issue 1466763002: Standalone denoiser (off by default). (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 5 years, 1 month 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) 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 10
11 /* 11 /*
12 * frame_preprocessor.h 12 * frame_preprocessor.h
13 */ 13 */
14 #ifndef WEBRTC_MODULES_VIDEO_PROCESSING_FRAME_PREPROCESSOR_H_ 14 #ifndef WEBRTC_MODULES_VIDEO_PROCESSING_FRAME_PREPROCESSOR_H_
15 #define WEBRTC_MODULES_VIDEO_PROCESSING_FRAME_PREPROCESSOR_H_ 15 #define WEBRTC_MODULES_VIDEO_PROCESSING_FRAME_PREPROCESSOR_H_
16 16
17 #include "webrtc/modules/video_processing/include/video_processing.h" 17 #include "webrtc/modules/video_processing/include/video_processing.h"
18 #include "webrtc/modules/video_processing/content_analysis.h" 18 #include "webrtc/modules/video_processing/content_analysis.h"
19 #include "webrtc/modules/video_processing/spatial_resampler.h" 19 #include "webrtc/modules/video_processing/spatial_resampler.h"
20 #include "webrtc/modules/video_processing/video_decimator.h" 20 #include "webrtc/modules/video_processing/video_decimator.h"
21 #include "webrtc/modules/video_processing/video_denoiser.h"
21 #include "webrtc/typedefs.h" 22 #include "webrtc/typedefs.h"
22 23
23 namespace webrtc { 24 namespace webrtc {
24 25
25 class VPMFramePreprocessor { 26 class VPMFramePreprocessor {
26 public: 27 public:
27 VPMFramePreprocessor(); 28 VPMFramePreprocessor();
28 ~VPMFramePreprocessor(); 29 ~VPMFramePreprocessor();
29 30
30 void Reset(); 31 void Reset();
(...skipping 27 matching lines...) Expand all
58 int32_t PreprocessFrame(const VideoFrame& frame, 59 int32_t PreprocessFrame(const VideoFrame& frame,
59 VideoFrame** processed_frame); 60 VideoFrame** processed_frame);
60 VideoContentMetrics* ContentMetrics() const; 61 VideoContentMetrics* ContentMetrics() const;
61 62
62 private: 63 private:
63 // The content does not change so much every frame, so to reduce complexity 64 // The content does not change so much every frame, so to reduce complexity
64 // we can compute new content metrics every |kSkipFrameCA| frames. 65 // we can compute new content metrics every |kSkipFrameCA| frames.
65 enum { kSkipFrameCA = 2 }; 66 enum { kSkipFrameCA = 2 };
66 67
67 VideoContentMetrics* content_metrics_; 68 VideoContentMetrics* content_metrics_;
69 VideoFrame denoised_frame_;
68 VideoFrame resampled_frame_; 70 VideoFrame resampled_frame_;
69 VPMSpatialResampler* spatial_resampler_; 71 VPMSpatialResampler* spatial_resampler_;
70 VPMContentAnalysis* ca_; 72 VPMContentAnalysis* ca_;
71 VPMVideoDecimator* vd_; 73 VPMVideoDecimator* vd_;
74 VideoDenoiser* vdn_;
stefan-webrtc 2015/11/23 10:12:53 I would prefer to call this video_denoiser_ instea
jackychen 2015/11/23 19:44:59 Done.
72 bool enable_ca_; 75 bool enable_ca_;
76 bool enable_denoise_;
stefan-webrtc 2015/11/23 10:12:52 enable_denoising_
jackychen 2015/11/23 19:44:59 Done.
73 int frame_cnt_; 77 int frame_cnt_;
74 78
75 }; 79 };
76 80
77 } // namespace webrtc 81 } // namespace webrtc
78 82
79 #endif // WEBRTC_MODULES_VIDEO_PROCESSING_FRAME_PREPROCESSOR_H_ 83 #endif // WEBRTC_MODULES_VIDEO_PROCESSING_FRAME_PREPROCESSOR_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698