OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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_PROTOCOL_PROTOBUF_VIDEO_WRITER_H_ | 5 #ifndef REMOTING_PROTOCOL_PROTOBUF_VIDEO_WRITER_H_ |
6 #define REMOTING_PROTOCOL_PROTOBUF_VIDEO_WRITER_H_ | 6 #define REMOTING_PROTOCOL_PROTOBUF_VIDEO_WRITER_H_ |
7 | 7 |
8 #include "base/ref_counted.h" | 8 #include "base/ref_counted.h" |
9 #include "remoting/protocol/video_writer.h" | 9 #include "remoting/protocol/video_writer.h" |
10 | 10 |
11 namespace remoting { | 11 namespace remoting { |
12 | 12 |
| 13 namespace protocol { |
| 14 class Session; |
| 15 } // namespace protocol |
| 16 |
13 class BufferedSocketWriter; | 17 class BufferedSocketWriter; |
14 | 18 |
15 class ProtobufVideoWriter : public VideoWriter { | 19 class ProtobufVideoWriter : public VideoWriter { |
16 public: | 20 public: |
17 ProtobufVideoWriter(); | 21 ProtobufVideoWriter(); |
18 virtual ~ProtobufVideoWriter(); | 22 virtual ~ProtobufVideoWriter(); |
19 | 23 |
20 // VideoWriter interface. | 24 // VideoWriter interface. |
21 virtual void Init(ChromotocolConnection* connection); | 25 virtual void Init(protocol::Session* session); |
22 virtual void SendPacket(const VideoPacket& packet); | 26 virtual void SendPacket(const VideoPacket& packet); |
23 virtual int GetPendingPackets(); | 27 virtual int GetPendingPackets(); |
24 virtual void Close(); | 28 virtual void Close(); |
25 | 29 |
26 private: | 30 private: |
27 scoped_refptr<BufferedSocketWriter> buffered_writer_; | 31 scoped_refptr<BufferedSocketWriter> buffered_writer_; |
28 | 32 |
29 DISALLOW_COPY_AND_ASSIGN(ProtobufVideoWriter); | 33 DISALLOW_COPY_AND_ASSIGN(ProtobufVideoWriter); |
30 }; | 34 }; |
31 | 35 |
32 } // namespace remoting | 36 } // namespace remoting |
33 | 37 |
34 #endif // REMOTING_PROTOCOL_PROTOBUF_VIDEO_WRITER_H_ | 38 #endif // REMOTING_PROTOCOL_PROTOBUF_VIDEO_WRITER_H_ |
OLD | NEW |