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

Side by Side Diff: remoting/client/audio_decode_scheduler.h

Issue 2052723002: Adding an interface to allow extention of the audio player for CRD and iOS. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Ran git cl format. Created 4 years, 6 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 unified diff | Download patch
OLDNEW
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_CLIENT_AUDIO_DECODE_SCHEDULER_H_ 5 #ifndef REMOTING_CLIENT_AUDIO_DECODE_SCHEDULER_H_
6 #define REMOTING_CLIENT_AUDIO_DECODE_SCHEDULER_H_ 6 #define REMOTING_CLIENT_AUDIO_DECODE_SCHEDULER_H_
7 7
8 #include <memory> 8 #include <memory>
9 9
10 #include "base/macros.h" 10 #include "base/macros.h"
11 #include "base/memory/ref_counted.h" 11 #include "base/memory/ref_counted.h"
12 #include "remoting/protocol/audio_stub.h" 12 #include "remoting/protocol/audio_stub.h"
13 13
14 namespace base { 14 namespace base {
15 class SingleThreadTaskRunner; 15 class SingleThreadTaskRunner;
16 } // namespace base 16 } // namespace base
17 17
18 namespace remoting { 18 namespace remoting {
19 19
20 namespace protocol { 20 namespace protocol {
21 class SessionConfig; 21 class SessionConfig;
22 } // namespace protocol 22 } // namespace protocol
23 23
24 class AudioDecoder; 24 class AudioDecoder;
25 class AudioPacket; 25 class AudioPacket;
26 class AudioPlayer; 26 class AudioConsumer;
27 27
28 class AudioDecodeScheduler : public protocol::AudioStub { 28 class AudioDecodeScheduler : public protocol::AudioStub {
29 public: 29 public:
30 AudioDecodeScheduler( 30 AudioDecodeScheduler(
31 scoped_refptr<base::SingleThreadTaskRunner> main_task_runner, 31 scoped_refptr<base::SingleThreadTaskRunner> main_task_runner,
32 scoped_refptr<base::SingleThreadTaskRunner> audio_decode_task_runner, 32 scoped_refptr<base::SingleThreadTaskRunner> audio_decode_task_runner,
33 std::unique_ptr<AudioPlayer> audio_player); 33 AudioConsumer* audio_consumer);
34 ~AudioDecodeScheduler() override; 34 ~AudioDecodeScheduler() override;
35 35
36 // Initializes decoder with the information from the protocol config. 36 // Initializes decoder with the information from the protocol config.
37 void Initialize(const protocol::SessionConfig& config); 37 void Initialize(const protocol::SessionConfig& config);
38 38
39 // AudioStub implementation. 39 // AudioStub implementation.
40 void ProcessAudioPacket(std::unique_ptr<AudioPacket> packet, 40 void ProcessAudioPacket(std::unique_ptr<AudioPacket> packet,
41 const base::Closure& done) override; 41 const base::Closure& done) override;
42 42
43 private: 43 private:
44 class Core; 44 class Core;
45 45
46 scoped_refptr<Core> core_; 46 scoped_refptr<Core> core_;
47 47
48 DISALLOW_COPY_AND_ASSIGN(AudioDecodeScheduler); 48 DISALLOW_COPY_AND_ASSIGN(AudioDecodeScheduler);
49 }; 49 };
50 50
51 } // namespace remoting 51 } // namespace remoting
52 52
53 #endif // REMOTING_CLIENT_AUDIO_DECODE_SCHEDULER_H_ 53 #endif // REMOTING_CLIENT_AUDIO_DECODE_SCHEDULER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698