OLD | NEW |
(Empty) | |
| 1 // Copyright 2015 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_TEST_TEST_VIDEO_RENDERER_H_ |
| 6 #define REMOTING_TEST_TEST_VIDEO_RENDERER_H_ |
| 7 |
| 8 #include "base/callback.h" |
| 9 #include "base/memory/scoped_ptr.h" |
| 10 #include "remoting/client/video_renderer.h" |
| 11 #include "remoting/protocol/video_stub.h" |
| 12 |
| 13 namespace remoting { |
| 14 namespace test { |
| 15 |
| 16 // Processes video packets as they are received from the remote host. |
| 17 class TestVideoRenderer : public VideoRenderer, public protocol::VideoStub { |
| 18 public: |
| 19 TestVideoRenderer(); |
| 20 ~TestVideoRenderer() override; |
| 21 |
| 22 // VideoRenderer interface. |
| 23 void OnSessionConfig(const protocol::SessionConfig& config) override; |
| 24 ChromotingStats* GetStats() override; |
| 25 protocol::VideoStub* GetVideoStub() override; |
| 26 |
| 27 private: |
| 28 // protocol::VideoStub interface. |
| 29 void ProcessVideoPacket(scoped_ptr<remoting::VideoPacket> video_packet, |
| 30 const base::Closure& done) override; |
| 31 |
| 32 // Track the number of populated video frames which have been received. |
| 33 int video_frames_processed_; |
| 34 |
| 35 DISALLOW_COPY_AND_ASSIGN(TestVideoRenderer); |
| 36 }; |
| 37 |
| 38 } // namespace test |
| 39 } // namespace remoting |
| 40 |
| 41 #endif // REMOTING_TEST_TEST_VIDEO_RENDERER_H_ |
OLD | NEW |