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

Unified Diff: webrtc/modules/audio_device/android/opensles_common.h

Issue 2119633004: Adds support for OpenSL ES based audio capture on Android (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Fixing presubmit warnings Created 4 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 side-by-side diff with in-line comments
Download patch
Index: webrtc/modules/audio_device/android/opensles_common.h
diff --git a/webrtc/modules/audio_device/android/opensles_common.h b/webrtc/modules/audio_device/android/opensles_common.h
index 5ff295b69df093177df95f3cce4f6796c1036a35..b0859c2b6af7fbebed6a53735e98e4e5ffd98ae0 100644
--- a/webrtc/modules/audio_device/android/opensles_common.h
+++ b/webrtc/modules/audio_device/android/opensles_common.h
@@ -11,17 +11,19 @@
#ifndef WEBRTC_MODULES_AUDIO_DEVICE_ANDROID_OPENSLES_COMMON_H_
#define WEBRTC_MODULES_AUDIO_DEVICE_ANDROID_OPENSLES_COMMON_H_
+#include <stddef.h>
#include <SLES/OpenSLES.h>
-#include "webrtc/base/checks.h"
-
namespace webrtc {
// Returns a string representation given an integer SL_RESULT_XXX code.
// The mapping can be found in <SLES/OpenSLES.h>.
const char* GetSLErrorString(size_t code);
-SLDataFormat_PCM CreatePcmConfiguration(int sample_rate);
+// Configures an SL_DATAFORMAT_PCM structure based on native audio parameters.
+SLDataFormat_PCM CreatePCMConfiguration(size_t channels,
+ int sample_rate,
+ size_t bits_per_sample);
// Helper class for using SLObjectItf interfaces.
template <typename SLType, typename SLDerefType>
@@ -53,6 +55,6 @@ class ScopedSLObject {
typedef ScopedSLObject<SLObjectItf, const SLObjectItf_*> ScopedSLObjectItf;
-} // namespace webrtc_opensl
+} // namespace webrtc
#endif // WEBRTC_MODULES_AUDIO_DEVICE_ANDROID_OPENSLES_COMMON_H_

Powered by Google App Engine
This is Rietveld 408576698