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

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

Issue 1559023003: Move VideoRenderer to remoting/protocol (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 11 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
« no previous file with comments | « remoting/client/plugin/pepper_video_renderer.h ('k') | remoting/client/video_renderer.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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_SOFTWARE_VIDEO_RENDERER_H_ 5 #ifndef REMOTING_CLIENT_SOFTWARE_VIDEO_RENDERER_H_
6 #define REMOTING_CLIENT_SOFTWARE_VIDEO_RENDERER_H_ 6 #define REMOTING_CLIENT_SOFTWARE_VIDEO_RENDERER_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
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 "base/memory/scoped_ptr.h" 12 #include "base/memory/scoped_ptr.h"
13 #include "base/memory/weak_ptr.h" 13 #include "base/memory/weak_ptr.h"
14 #include "base/threading/thread_checker.h" 14 #include "base/threading/thread_checker.h"
15 #include "remoting/client/video_renderer.h"
16 #include "remoting/protocol/performance_tracker.h" 15 #include "remoting/protocol/performance_tracker.h"
16 #include "remoting/protocol/video_renderer.h"
17 #include "remoting/protocol/video_stub.h" 17 #include "remoting/protocol/video_stub.h"
18 #include "third_party/webrtc/modules/desktop_capture/desktop_geometry.h" 18 #include "third_party/webrtc/modules/desktop_capture/desktop_geometry.h"
19 19
20 namespace base { 20 namespace base {
21 class SingleThreadTaskRunner; 21 class SingleThreadTaskRunner;
22 } // namespace base 22 } // namespace base
23 23
24 namespace webrtc { 24 namespace webrtc {
25 class DesktopFrame; 25 class DesktopFrame;
26 } // namespace webrtc 26 } // namespace webrtc
27 27
28 namespace remoting { 28 namespace remoting {
29 29
30 class FrameConsumer; 30 class FrameConsumer;
31 class VideoDecoder; 31 class VideoDecoder;
32 32
33 namespace protocol { 33 namespace protocol {
34 class PerformanceTracker; 34 class PerformanceTracker;
35 } // namespace protocol 35 } // namespace protocol
36 36
37 // Implementation of VideoRenderer interface that decodes frame on CPU (on a 37 // Implementation of VideoRenderer interface that decodes frame on CPU (on a
38 // decode thread) and then passes decoded frames to a FrameConsumer. 38 // decode thread) and then passes decoded frames to a FrameConsumer.
39 class SoftwareVideoRenderer : public VideoRenderer, 39 class SoftwareVideoRenderer : public protocol::VideoRenderer,
40 public protocol::VideoStub { 40 public protocol::VideoStub {
41 public: 41 public:
42 // All methods must be called on the same thread the renderer is created. The 42 // All methods must be called on the same thread the renderer is created. The
43 // |decode_task_runner_| is used to decode the video packets. |perf_tracker| 43 // |decode_task_runner_| is used to decode the video packets. |perf_tracker|
44 // must outlive the renderer. |perf_tracker| may be nullptr, performance 44 // must outlive the renderer. |perf_tracker| may be nullptr, performance
45 // tracking is disabled in that case. 45 // tracking is disabled in that case.
46 SoftwareVideoRenderer( 46 SoftwareVideoRenderer(
47 scoped_refptr<base::SingleThreadTaskRunner> decode_task_runner, 47 scoped_refptr<base::SingleThreadTaskRunner> decode_task_runner,
48 FrameConsumer* consumer, 48 FrameConsumer* consumer,
49 protocol::PerformanceTracker* perf_tracker); 49 protocol::PerformanceTracker* perf_tracker);
(...skipping 25 matching lines...) Expand all
75 base::ThreadChecker thread_checker_; 75 base::ThreadChecker thread_checker_;
76 76
77 base::WeakPtrFactory<SoftwareVideoRenderer> weak_factory_; 77 base::WeakPtrFactory<SoftwareVideoRenderer> weak_factory_;
78 78
79 DISALLOW_COPY_AND_ASSIGN(SoftwareVideoRenderer); 79 DISALLOW_COPY_AND_ASSIGN(SoftwareVideoRenderer);
80 }; 80 };
81 81
82 } // namespace remoting 82 } // namespace remoting
83 83
84 #endif // REMOTING_CLIENT_SOFTWARE_VIDEO_RENDERER_H_ 84 #endif // REMOTING_CLIENT_SOFTWARE_VIDEO_RENDERER_H_
OLDNEW
« no previous file with comments | « remoting/client/plugin/pepper_video_renderer.h ('k') | remoting/client/video_renderer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698