| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (c) 2013 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2013 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 #ifndef WEBRTC_MODULES_AUDIO_DEVICE_ANDROID_AUDIO_TRACK_JNI_H_ | 11 #ifndef WEBRTC_MODULES_AUDIO_DEVICE_ANDROID_AUDIO_TRACK_JNI_H_ |
| 12 #define WEBRTC_MODULES_AUDIO_DEVICE_ANDROID_AUDIO_TRACK_JNI_H_ | 12 #define WEBRTC_MODULES_AUDIO_DEVICE_ANDROID_AUDIO_TRACK_JNI_H_ |
| 13 | 13 |
| 14 #include <memory> | 14 #include <memory> |
| 15 | 15 |
| 16 #include <jni.h> | 16 #include <jni.h> |
| 17 | 17 |
| 18 #include "webrtc/base/thread_checker.h" |
| 18 #include "webrtc/modules/audio_device/android/audio_common.h" | 19 #include "webrtc/modules/audio_device/android/audio_common.h" |
| 19 #include "webrtc/modules/audio_device/android/audio_manager.h" | 20 #include "webrtc/modules/audio_device/android/audio_manager.h" |
| 21 #include "webrtc/modules/audio_device/include/audio_device_defines.h" |
| 20 #include "webrtc/modules/audio_device/audio_device_generic.h" | 22 #include "webrtc/modules/audio_device/audio_device_generic.h" |
| 21 #include "webrtc/modules/audio_device/include/audio_device_defines.h" | |
| 22 #include "webrtc/modules/utility/include/helpers_android.h" | 23 #include "webrtc/modules/utility/include/helpers_android.h" |
| 23 #include "webrtc/modules/utility/include/jvm_android.h" | 24 #include "webrtc/modules/utility/include/jvm_android.h" |
| 24 #include "webrtc/rtc_base/thread_checker.h" | |
| 25 | 25 |
| 26 namespace webrtc { | 26 namespace webrtc { |
| 27 | 27 |
| 28 // Implements 16-bit mono PCM audio output support for Android using the Java | 28 // Implements 16-bit mono PCM audio output support for Android using the Java |
| 29 // AudioTrack interface. Most of the work is done by its Java counterpart in | 29 // AudioTrack interface. Most of the work is done by its Java counterpart in |
| 30 // WebRtcAudioTrack.java. This class is created and lives on a thread in | 30 // WebRtcAudioTrack.java. This class is created and lives on a thread in |
| 31 // C++-land, but decoded audio buffers are requested on a high-priority | 31 // C++-land, but decoded audio buffers are requested on a high-priority |
| 32 // thread managed by the Java class. | 32 // thread managed by the Java class. |
| 33 // | 33 // |
| 34 // An instance must be created and destroyed on one and the same thread. | 34 // An instance must be created and destroyed on one and the same thread. |
| (...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 146 // Raw pointer handle provided to us in AttachAudioBuffer(). Owned by the | 146 // Raw pointer handle provided to us in AttachAudioBuffer(). Owned by the |
| 147 // AudioDeviceModuleImpl class and called by AudioDeviceModule::Create(). | 147 // AudioDeviceModuleImpl class and called by AudioDeviceModule::Create(). |
| 148 // The AudioDeviceBuffer is a member of the AudioDeviceModuleImpl instance | 148 // The AudioDeviceBuffer is a member of the AudioDeviceModuleImpl instance |
| 149 // and therefore outlives this object. | 149 // and therefore outlives this object. |
| 150 AudioDeviceBuffer* audio_device_buffer_; | 150 AudioDeviceBuffer* audio_device_buffer_; |
| 151 }; | 151 }; |
| 152 | 152 |
| 153 } // namespace webrtc | 153 } // namespace webrtc |
| 154 | 154 |
| 155 #endif // WEBRTC_MODULES_AUDIO_DEVICE_ANDROID_AUDIO_TRACK_JNI_H_ | 155 #endif // WEBRTC_MODULES_AUDIO_DEVICE_ANDROID_AUDIO_TRACK_JNI_H_ |
| OLD | NEW |