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

Side by Side Diff: remoting/host/client_session.h

Issue 372943002: Add video frame recording capability to Chromoting hosts. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Working implementation. Created 6 years, 5 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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_HOST_CLIENT_SESSION_H_ 5 #ifndef REMOTING_HOST_CLIENT_SESSION_H_
6 #define REMOTING_HOST_CLIENT_SESSION_H_ 6 #define REMOTING_HOST_CLIENT_SESSION_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/memory/ref_counted.h" 10 #include "base/memory/ref_counted.h"
(...skipping 26 matching lines...) Expand all
37 37
38 namespace remoting { 38 namespace remoting {
39 39
40 class AudioEncoder; 40 class AudioEncoder;
41 class AudioScheduler; 41 class AudioScheduler;
42 class DesktopEnvironment; 42 class DesktopEnvironment;
43 class DesktopEnvironmentFactory; 43 class DesktopEnvironmentFactory;
44 class InputInjector; 44 class InputInjector;
45 class ScreenControls; 45 class ScreenControls;
46 class VideoEncoder; 46 class VideoEncoder;
47 class VideoFrameRecorder;
47 class VideoScheduler; 48 class VideoScheduler;
48 49
49 // A ClientSession keeps a reference to a connection to a client, and maintains 50 // A ClientSession keeps a reference to a connection to a client, and maintains
50 // per-client state. 51 // per-client state.
51 class ClientSession 52 class ClientSession
52 : public base::NonThreadSafe, 53 : public base::NonThreadSafe,
53 public protocol::HostStub, 54 public protocol::HostStub,
54 public protocol::ConnectionToClient::EventHandler, 55 public protocol::ConnectionToClient::EventHandler,
55 public ClientSessionControl { 56 public ClientSessionControl {
56 public: 57 public:
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after
158 protocol::ConnectionToClient* connection() const { 159 protocol::ConnectionToClient* connection() const {
159 return connection_.get(); 160 return connection_.get();
160 } 161 }
161 162
162 bool is_authenticated() { return auth_input_filter_.enabled(); } 163 bool is_authenticated() { return auth_input_filter_.enabled(); }
163 164
164 const std::string* client_capabilities() const { 165 const std::string* client_capabilities() const {
165 return client_capabilities_.get(); 166 return client_capabilities_.get();
166 } 167 }
167 168
169 // Manages an optional VideoFrameRecorder, used to record session content
170 // The recorder must be set before the ClientSession becomes authenticated.
171 void set_video_frame_recorder(scoped_ptr<VideoFrameRecorder> recorder);
172 VideoFrameRecorder* video_frame_recorder() const;
173
168 private: 174 private:
169 typedef ScopedVector<HostExtensionSession> HostExtensionSessionList; 175 typedef ScopedVector<HostExtensionSession> HostExtensionSessionList;
170 176
171 // Creates a proxy for sending clipboard events to the client. 177 // Creates a proxy for sending clipboard events to the client.
172 scoped_ptr<protocol::ClipboardStub> CreateClipboardProxy(); 178 scoped_ptr<protocol::ClipboardStub> CreateClipboardProxy();
173 179
174 // Creates an audio encoder for the specified configuration. 180 // Creates an audio encoder for the specified configuration.
175 static scoped_ptr<AudioEncoder> CreateAudioEncoder( 181 static scoped_ptr<AudioEncoder> CreateAudioEncoder(
176 const protocol::SessionConfig& config); 182 const protocol::SessionConfig& config);
177 183
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
256 262
257 // Used to apply client-requested changes in screen resolution. 263 // Used to apply client-requested changes in screen resolution.
258 scoped_ptr<ScreenControls> screen_controls_; 264 scoped_ptr<ScreenControls> screen_controls_;
259 265
260 // The pairing registry for PIN-less authentication. 266 // The pairing registry for PIN-less authentication.
261 scoped_refptr<protocol::PairingRegistry> pairing_registry_; 267 scoped_refptr<protocol::PairingRegistry> pairing_registry_;
262 268
263 // Used to proxy gnubby auth traffic. 269 // Used to proxy gnubby auth traffic.
264 scoped_ptr<GnubbyAuthHandler> gnubby_auth_handler_; 270 scoped_ptr<GnubbyAuthHandler> gnubby_auth_handler_;
265 271
272 // Used to record sequences of video frames.
273 scoped_ptr<VideoFrameRecorder> video_frame_recorder_;
274
266 // Host extension sessions, used to handle extension messages. 275 // Host extension sessions, used to handle extension messages.
267 HostExtensionSessionList extension_sessions_; 276 HostExtensionSessionList extension_sessions_;
268 277
269 DISALLOW_COPY_AND_ASSIGN(ClientSession); 278 DISALLOW_COPY_AND_ASSIGN(ClientSession);
270 }; 279 };
271 280
272 } // namespace remoting 281 } // namespace remoting
273 282
274 #endif // REMOTING_HOST_CLIENT_SESSION_H_ 283 #endif // REMOTING_HOST_CLIENT_SESSION_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698