Index: remoting/protocol/audio_source.h |
diff --git a/remoting/host/audio_capturer.h b/remoting/protocol/audio_source.h |
similarity index 53% |
copy from remoting/host/audio_capturer.h |
copy to remoting/protocol/audio_source.h |
index c79949903ca892247fae2bcf84b459566dcf366d..d36d378b4f8bb3781b7199c76436f0518dc8231b 100644 |
--- a/remoting/host/audio_capturer.h |
+++ b/remoting/protocol/audio_source.h |
@@ -1,9 +1,9 @@ |
-// Copyright (c) 2012 The Chromium Authors. All rights reserved. |
+// Copyright 2016 The Chromium Authors. All rights reserved. |
// Use of this source code is governed by a BSD-style license that can be |
// found in the LICENSE file. |
-#ifndef REMOTING_HOST_AUDIO_CAPTURER_H_ |
-#define REMOTING_HOST_AUDIO_CAPTURER_H_ |
+#ifndef REMOTING_PROTOCOL_AUDIO_SOURCE_H_ |
+#define REMOTING_PROTOCOL_AUDIO_SOURCE_H_ |
#include <memory> |
@@ -13,26 +13,22 @@ namespace remoting { |
class AudioPacket; |
-class AudioCapturer { |
+namespace protocol { |
+ |
+class AudioSource { |
public: |
typedef base::Callback<void(std::unique_ptr<AudioPacket> packet)> |
PacketCapturedCallback; |
- virtual ~AudioCapturer() {} |
- |
- // Returns true if audio capturing is supported on this platform. If this |
- // returns true, then Create() must not return nullptr. |
- static bool IsSupported(); |
- static std::unique_ptr<AudioCapturer> Create(); |
+ virtual ~AudioSource() {} |
// Capturers should sample at a 44.1 or 48 kHz sampling rate, in uncompressed |
// PCM stereo format. Capturers may choose the number of frames per packet. |
// Returns true on success. |
virtual bool Start(const PacketCapturedCallback& callback) = 0; |
- |
- static bool IsValidSampleRate(int sample_rate); |
}; |
+} // namespace protocol |
} // namespace remoting |
-#endif // REMOTING_HOST_AUDIO_CAPTURER_H_ |
+#endif // REMOTING_PROTOCOL_AUDIO_SOURCE_H_ |