| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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_PLUGIN_PEPPER_VIDEO_RENDERER_2D_H_ | 5 #ifndef REMOTING_CLIENT_PLUGIN_PEPPER_VIDEO_RENDERER_2D_H_ |
| 6 #define REMOTING_CLIENT_PLUGIN_PEPPER_VIDEO_RENDERER_2D_H_ | 6 #define REMOTING_CLIENT_PLUGIN_PEPPER_VIDEO_RENDERER_2D_H_ |
| 7 | 7 |
| 8 #include <list> | 8 #include <list> |
| 9 | 9 |
| 10 #include "base/compiler_specific.h" | 10 #include "base/compiler_specific.h" |
| (...skipping 26 matching lines...) Expand all Loading... |
| 37 | 37 |
| 38 // Video renderer that wraps SoftwareVideoRenderer and displays it using Pepper | 38 // Video renderer that wraps SoftwareVideoRenderer and displays it using Pepper |
| 39 // 2D graphics API. | 39 // 2D graphics API. |
| 40 class PepperVideoRenderer2D : public PepperVideoRenderer, | 40 class PepperVideoRenderer2D : public PepperVideoRenderer, |
| 41 public protocol::FrameConsumer { | 41 public protocol::FrameConsumer { |
| 42 public: | 42 public: |
| 43 PepperVideoRenderer2D(); | 43 PepperVideoRenderer2D(); |
| 44 ~PepperVideoRenderer2D() override; | 44 ~PepperVideoRenderer2D() override; |
| 45 | 45 |
| 46 // PepperVideoRenderer interface. | 46 // PepperVideoRenderer interface. |
| 47 bool Initialize(pp::Instance* instance, | 47 bool InitializePepper(pp::Instance* instance, |
| 48 const ClientContext& context, | 48 const ClientContext& context, |
| 49 EventHandler* event_handler, | 49 EventHandler* event_handler, |
| 50 protocol::PerformanceTracker* perf_tracker) override; | 50 protocol::PerformanceTracker* perf_tracker) override; |
| 51 void OnViewChanged(const pp::View& view) override; | 51 void OnViewChanged(const pp::View& view) override; |
| 52 void EnableDebugDirtyRegion(bool enable) override; | 52 void EnableDebugDirtyRegion(bool enable) override; |
| 53 | 53 |
| 54 // VideoRenderer interface. | 54 // VideoRenderer interface. |
| 55 void OnSessionConfig(const protocol::SessionConfig& config) override; | 55 void OnSessionConfig(const protocol::SessionConfig& config) override; |
| 56 protocol::VideoStub* GetVideoStub() override; | 56 protocol::VideoStub* GetVideoStub() override; |
| 57 protocol::FrameConsumer* GetFrameConsumer() override; | 57 protocol::FrameConsumer* GetFrameConsumer() override; |
| 58 | 58 |
| 59 private: | 59 private: |
| 60 // protocol::FrameConsumer implementation. | 60 // protocol::FrameConsumer implementation. |
| (...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 104 | 104 |
| 105 pp::CompletionCallbackFactory<PepperVideoRenderer2D> callback_factory_; | 105 pp::CompletionCallbackFactory<PepperVideoRenderer2D> callback_factory_; |
| 106 base::WeakPtrFactory<PepperVideoRenderer2D> weak_factory_; | 106 base::WeakPtrFactory<PepperVideoRenderer2D> weak_factory_; |
| 107 | 107 |
| 108 DISALLOW_COPY_AND_ASSIGN(PepperVideoRenderer2D); | 108 DISALLOW_COPY_AND_ASSIGN(PepperVideoRenderer2D); |
| 109 }; | 109 }; |
| 110 | 110 |
| 111 } // namespace remoting | 111 } // namespace remoting |
| 112 | 112 |
| 113 #endif // REMOTING_CLIENT_PLUGIN_PEPPER_VIDEO_RENDERER_2D_H_ | 113 #endif // REMOTING_CLIENT_PLUGIN_PEPPER_VIDEO_RENDERER_2D_H_ |
| OLD | NEW |