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

Side by Side Diff: webrtc/modules/audio_processing/ns/noise_suppression.c

Issue 1227213002: Update audio code to use size_t more correctly, webrtc/modules/audio_processing/ (Closed) Base URL: https://chromium.googlesource.com/external/webrtc@master
Patch Set: Resync Created 5 years, 4 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) 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
(...skipping 23 matching lines...) Expand all
34 int WebRtcNs_set_policy(NsHandle* NS_inst, int mode) { 34 int WebRtcNs_set_policy(NsHandle* NS_inst, int mode) {
35 return WebRtcNs_set_policy_core((NoiseSuppressionC*)NS_inst, mode); 35 return WebRtcNs_set_policy_core((NoiseSuppressionC*)NS_inst, mode);
36 } 36 }
37 37
38 void WebRtcNs_Analyze(NsHandle* NS_inst, const float* spframe) { 38 void WebRtcNs_Analyze(NsHandle* NS_inst, const float* spframe) {
39 WebRtcNs_AnalyzeCore((NoiseSuppressionC*)NS_inst, spframe); 39 WebRtcNs_AnalyzeCore((NoiseSuppressionC*)NS_inst, spframe);
40 } 40 }
41 41
42 void WebRtcNs_Process(NsHandle* NS_inst, 42 void WebRtcNs_Process(NsHandle* NS_inst,
43 const float* const* spframe, 43 const float* const* spframe,
44 int num_bands, 44 size_t num_bands,
45 float* const* outframe) { 45 float* const* outframe) {
46 WebRtcNs_ProcessCore((NoiseSuppressionC*)NS_inst, spframe, num_bands, 46 WebRtcNs_ProcessCore((NoiseSuppressionC*)NS_inst, spframe, num_bands,
47 outframe); 47 outframe);
48 } 48 }
49 49
50 float WebRtcNs_prior_speech_probability(NsHandle* handle) { 50 float WebRtcNs_prior_speech_probability(NsHandle* handle) {
51 NoiseSuppressionC* self = (NoiseSuppressionC*)handle; 51 NoiseSuppressionC* self = (NoiseSuppressionC*)handle;
52 if (handle == NULL) { 52 if (handle == NULL) {
53 return -1; 53 return -1;
54 } 54 }
55 if (self->initFlag == 0) { 55 if (self->initFlag == 0) {
56 return -1; 56 return -1;
57 } 57 }
58 return self->priorSpeechProb; 58 return self->priorSpeechProb;
59 } 59 }
OLDNEW
« no previous file with comments | « webrtc/modules/audio_processing/ns/include/noise_suppression.h ('k') | webrtc/modules/audio_processing/ns/ns_core.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698