OLD | NEW |
(Empty) | |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef REMOTING_PROTOCOL_FAKE_VIDEO_RENDERER_H_ |
| 6 #define REMOTING_PROTOCOL_FAKE_VIDEO_RENDERER_H_ |
| 7 |
| 8 #include <list> |
| 9 |
| 10 #include "remoting/protocol/video_renderer.h" |
| 11 #include "remoting/protocol/video_stub.h" |
| 12 |
| 13 namespace remoting { |
| 14 namespace protocol { |
| 15 |
| 16 class FakeVideoStub : public VideoStub { |
| 17 public: |
| 18 FakeVideoStub(); |
| 19 ~FakeVideoStub() override; |
| 20 |
| 21 // VideoStub interface. |
| 22 void ProcessVideoPacket(scoped_ptr<VideoPacket> video_packet, |
| 23 const base::Closure& done) override; |
| 24 private: |
| 25 std::list<scoped_ptr<VideoPacket>> received_packets_; |
| 26 }; |
| 27 |
| 28 class FakeVideoRenderer : public VideoRenderer { |
| 29 public: |
| 30 FakeVideoRenderer(); |
| 31 ~FakeVideoRenderer() override; |
| 32 |
| 33 // VideoRenderer interface. |
| 34 void OnSessionConfig(const SessionConfig& config) override; |
| 35 FakeVideoStub* GetVideoStub() override; |
| 36 FrameConsumer* GetFrameConsumer() override; |
| 37 |
| 38 private: |
| 39 FakeVideoStub video_stub_; |
| 40 }; |
| 41 |
| 42 } // namespace protocol |
| 43 } // namespace remoting |
| 44 |
| 45 #endif // REMOTING_PROTOCOL_FAKE_VIDEO_RENDERER_H_ |
OLD | NEW |