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

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

Issue 872433005: Move capture scheduling logic from VideoScheduler to CaptureScheduler. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 10 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/host/capture_scheduler_unittest.cc ('k') | remoting/host/video_scheduler.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 (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 #include "remoting/host/client_session.h" 5 #include "remoting/host/client_session.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "base/message_loop/message_loop_proxy.h" 9 #include "base/message_loop/message_loop_proxy.h"
10 #include "remoting/base/capabilities.h" 10 #include "remoting/base/capabilities.h"
(...skipping 446 matching lines...) Expand 10 before | Expand all | Expand 10 after
457 video_capture_task_runner_, 457 video_capture_task_runner_,
458 video_encode_task_runner_, 458 video_encode_task_runner_,
459 network_task_runner_, 459 network_task_runner_,
460 video_capturer.Pass(), 460 video_capturer.Pass(),
461 desktop_environment_->CreateMouseCursorMonitor(), 461 desktop_environment_->CreateMouseCursorMonitor(),
462 video_encoder.Pass(), 462 video_encoder.Pass(),
463 connection_->client_stub(), 463 connection_->client_stub(),
464 &mouse_clamping_filter_); 464 &mouse_clamping_filter_);
465 465
466 // Apply video-control parameters to the new scheduler. 466 // Apply video-control parameters to the new scheduler.
467 video_scheduler_->Pause(pause_video_);
468 video_scheduler_->SetLosslessEncode(lossless_video_encode_); 467 video_scheduler_->SetLosslessEncode(lossless_video_encode_);
469 video_scheduler_->SetLosslessColor(lossless_video_color_); 468 video_scheduler_->SetLosslessColor(lossless_video_color_);
470 469
471 // Start capturing the screen. 470 // Start capturing the screen.
472 video_scheduler_->Start(); 471 video_scheduler_->Start();
472
473 // Pause capturing if necessary.
474 video_scheduler_->Pause(pause_video_);
473 } 475 }
474 476
475 void ClientSession::SetGnubbyAuthHandlerForTesting( 477 void ClientSession::SetGnubbyAuthHandlerForTesting(
476 GnubbyAuthHandler* gnubby_auth_handler) { 478 GnubbyAuthHandler* gnubby_auth_handler) {
477 DCHECK(CalledOnValidThread()); 479 DCHECK(CalledOnValidThread());
478 gnubby_auth_handler_.reset(gnubby_auth_handler); 480 gnubby_auth_handler_.reset(gnubby_auth_handler);
479 } 481 }
480 482
481 scoped_ptr<protocol::ClipboardStub> ClientSession::CreateClipboardProxy() { 483 scoped_ptr<protocol::ClipboardStub> ClientSession::CreateClipboardProxy() {
482 DCHECK(CalledOnValidThread()); 484 DCHECK(CalledOnValidThread());
(...skipping 30 matching lines...) Expand all
513 return make_scoped_ptr(new AudioEncoderVerbatim()); 515 return make_scoped_ptr(new AudioEncoderVerbatim());
514 } else if (audio_config.codec == protocol::ChannelConfig::CODEC_OPUS) { 516 } else if (audio_config.codec == protocol::ChannelConfig::CODEC_OPUS) {
515 return make_scoped_ptr(new AudioEncoderOpus()); 517 return make_scoped_ptr(new AudioEncoderOpus());
516 } 518 }
517 519
518 NOTREACHED(); 520 NOTREACHED();
519 return nullptr; 521 return nullptr;
520 } 522 }
521 523
522 } // namespace remoting 524 } // namespace remoting
OLDNEW
« no previous file with comments | « remoting/host/capture_scheduler_unittest.cc ('k') | remoting/host/video_scheduler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698