OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef CONTENT_RENDERER_MEDIA_WEBRTC_WEBRTC_AUDIO_SINK_ADAPTER_H_ | 5 #ifndef CONTENT_RENDERER_MEDIA_WEBRTC_WEBRTC_AUDIO_SINK_ADAPTER_H_ |
6 #define CONTENT_RENDERER_MEDIA_WEBRTC_WEBRTC_AUDIO_SINK_ADAPTER_H_ | 6 #define CONTENT_RENDERER_MEDIA_WEBRTC_WEBRTC_AUDIO_SINK_ADAPTER_H_ |
7 | 7 |
| 8 #include <stdint.h> |
| 9 |
| 10 #include "base/macros.h" |
8 #include "base/memory/scoped_ptr.h" | 11 #include "base/memory/scoped_ptr.h" |
9 #include "content/public/renderer/media_stream_audio_sink.h" | 12 #include "content/public/renderer/media_stream_audio_sink.h" |
10 #include "media/audio/audio_parameters.h" | 13 #include "media/audio/audio_parameters.h" |
11 | 14 |
12 namespace webrtc { | 15 namespace webrtc { |
13 class AudioTrackSinkInterface; | 16 class AudioTrackSinkInterface; |
14 } // namespace webrtc | 17 } // namespace webrtc |
15 | 18 |
16 namespace content { | 19 namespace content { |
17 | 20 |
(...skipping 12 matching lines...) Expand all Loading... |
30 | 33 |
31 private: | 34 private: |
32 // MediaStreamAudioSink implementation. | 35 // MediaStreamAudioSink implementation. |
33 void OnData(const media::AudioBus& audio_bus, | 36 void OnData(const media::AudioBus& audio_bus, |
34 base::TimeTicks estimated_capture_time) override; | 37 base::TimeTicks estimated_capture_time) override; |
35 void OnSetFormat(const media::AudioParameters& params) override; | 38 void OnSetFormat(const media::AudioParameters& params) override; |
36 | 39 |
37 webrtc::AudioTrackSinkInterface* const sink_; | 40 webrtc::AudioTrackSinkInterface* const sink_; |
38 | 41 |
39 media::AudioParameters params_; | 42 media::AudioParameters params_; |
40 scoped_ptr<int16[]> interleaved_data_; | 43 scoped_ptr<int16_t[]> interleaved_data_; |
41 | 44 |
42 DISALLOW_COPY_AND_ASSIGN(WebRtcAudioSinkAdapter); | 45 DISALLOW_COPY_AND_ASSIGN(WebRtcAudioSinkAdapter); |
43 }; | 46 }; |
44 | 47 |
45 } // namespace content | 48 } // namespace content |
46 | 49 |
47 #endif // CONTENT_RENDERER_MEDIA_WEBRTC_WEBRTC_AUDIO_SINK_ADAPTER_H_ | 50 #endif // CONTENT_RENDERER_MEDIA_WEBRTC_WEBRTC_AUDIO_SINK_ADAPTER_H_ |
OLD | NEW |