OLD | NEW |
---|---|
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 REMOTING_HOST_AUDIO_CAPTURER_H_ | 5 #ifndef REMOTING_HOST_AUDIO_CAPTURER_H_ |
6 #define REMOTING_HOST_AUDIO_CAPTURER_H_ | 6 #define REMOTING_HOST_AUDIO_CAPTURER_H_ |
7 | 7 |
8 #include "base/callback.h" | 8 #include "base/callback.h" |
9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
10 | 10 |
(...skipping 14 matching lines...) Expand all Loading... | |
25 // PCM stereo format. Capturers may choose the number of frames per packet. | 25 // PCM stereo format. Capturers may choose the number of frames per packet. |
26 // Returns true on success. | 26 // Returns true on success. |
27 virtual bool Start(const PacketCapturedCallback& callback) = 0; | 27 virtual bool Start(const PacketCapturedCallback& callback) = 0; |
28 // Stops the audio capturer, and frees the OS-specific audio capture | 28 // Stops the audio capturer, and frees the OS-specific audio capture |
29 // resources. | 29 // resources. |
30 virtual void Stop() = 0; | 30 virtual void Stop() = 0; |
31 // Returns true if the audio capturer is running. | 31 // Returns true if the audio capturer is running. |
32 virtual bool IsRunning() = 0; | 32 virtual bool IsRunning() = 0; |
33 | 33 |
34 static bool IsValidSampleRate(int sample_rate); | 34 static bool IsValidSampleRate(int sample_rate); |
35 | |
36 static bool IsPacketOfSilence(const AudioPacket* packet); | |
Sergey Ulanov
2012/07/27 22:46:51
This shouldn't to be part of AudioCapturer interfa
kxing
2012/07/30 16:55:18
Done.
| |
35 }; | 37 }; |
36 | 38 |
37 } // namespace remoting | 39 } // namespace remoting |
38 | 40 |
39 #endif // REMOTING_HOST_AUDIO_CAPTURER_H_ | 41 #endif // REMOTING_HOST_AUDIO_CAPTURER_H_ |
OLD | NEW |