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

Side by Side Diff: remoting/test/protocol_perftest.cc

Issue 893353002: Rename VideoScheduler->VideoFramePipe. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@scheduler_cleanup
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/remoting_test.gypi ('k') | no next file » | 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 #include "base/base64.h" 5 #include "base/base64.h"
6 #include "base/files/file_util.h" 6 #include "base/files/file_util.h"
7 #include "base/message_loop/message_loop.h" 7 #include "base/message_loop/message_loop.h"
8 #include "base/rand_util.h" 8 #include "base/rand_util.h"
9 #include "base/run_loop.h" 9 #include "base/run_loop.h"
10 #include "base/single_thread_task_runner.h" 10 #include "base/single_thread_task_runner.h"
11 #include "base/synchronization/waitable_event.h" 11 #include "base/synchronization/waitable_event.h"
12 #include "base/thread_task_runner_handle.h" 12 #include "base/thread_task_runner_handle.h"
13 #include "jingle/glue/thread_wrapper.h" 13 #include "jingle/glue/thread_wrapper.h"
14 #include "net/base/test_data_directory.h" 14 #include "net/base/test_data_directory.h"
15 #include "net/url_request/url_request_context_getter.h" 15 #include "net/url_request/url_request_context_getter.h"
16 #include "remoting/base/rsa_key_pair.h" 16 #include "remoting/base/rsa_key_pair.h"
17 #include "remoting/client/audio_player.h" 17 #include "remoting/client/audio_player.h"
18 #include "remoting/client/chromoting_client.h" 18 #include "remoting/client/chromoting_client.h"
19 #include "remoting/client/client_context.h" 19 #include "remoting/client/client_context.h"
20 #include "remoting/client/client_user_interface.h" 20 #include "remoting/client/client_user_interface.h"
21 #include "remoting/client/video_renderer.h" 21 #include "remoting/client/video_renderer.h"
22 #include "remoting/host/chromoting_host.h" 22 #include "remoting/host/chromoting_host.h"
23 #include "remoting/host/chromoting_host_context.h" 23 #include "remoting/host/chromoting_host_context.h"
24 #include "remoting/host/fake_desktop_environment.h" 24 #include "remoting/host/fake_desktop_environment.h"
25 #include "remoting/host/video_scheduler.h" 25 #include "remoting/host/video_frame_pump.h"
26 #include "remoting/protocol/jingle_session_manager.h" 26 #include "remoting/protocol/jingle_session_manager.h"
27 #include "remoting/protocol/libjingle_transport_factory.h" 27 #include "remoting/protocol/libjingle_transport_factory.h"
28 #include "remoting/protocol/me2me_host_authenticator_factory.h" 28 #include "remoting/protocol/me2me_host_authenticator_factory.h"
29 #include "remoting/protocol/negotiating_client_authenticator.h" 29 #include "remoting/protocol/negotiating_client_authenticator.h"
30 #include "remoting/protocol/session_config.h" 30 #include "remoting/protocol/session_config.h"
31 #include "remoting/signaling/fake_signal_strategy.h" 31 #include "remoting/signaling/fake_signal_strategy.h"
32 #include "remoting/test/fake_network_dispatcher.h" 32 #include "remoting/test/fake_network_dispatcher.h"
33 #include "remoting/test/fake_port_allocator.h" 33 #include "remoting/test/fake_port_allocator.h"
34 #include "remoting/test/fake_socket_factory.h" 34 #include "remoting/test/fake_socket_factory.h"
35 #include "testing/gtest/include/gtest/gtest.h" 35 #include "testing/gtest/include/gtest/gtest.h"
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
74 : public testing::Test, 74 : public testing::Test,
75 public testing::WithParamInterface<NetworkPerformanceParams>, 75 public testing::WithParamInterface<NetworkPerformanceParams>,
76 public ClientUserInterface, 76 public ClientUserInterface,
77 public VideoRenderer, 77 public VideoRenderer,
78 public HostStatusObserver { 78 public HostStatusObserver {
79 public: 79 public:
80 ProtocolPerfTest() 80 ProtocolPerfTest()
81 : host_thread_("host"), 81 : host_thread_("host"),
82 capture_thread_("capture"), 82 capture_thread_("capture"),
83 encode_thread_("encode") { 83 encode_thread_("encode") {
84 VideoScheduler::EnableTimestampsForTests(); 84 VideoFramePump::EnableTimestampsForTests();
85 host_thread_.StartWithOptions( 85 host_thread_.StartWithOptions(
86 base::Thread::Options(base::MessageLoop::TYPE_IO, 0)); 86 base::Thread::Options(base::MessageLoop::TYPE_IO, 0));
87 capture_thread_.Start(); 87 capture_thread_.Start();
88 encode_thread_.Start(); 88 encode_thread_.Start();
89 } 89 }
90 90
91 virtual ~ProtocolPerfTest() { 91 virtual ~ProtocolPerfTest() {
92 host_thread_.message_loop_proxy()->DeleteSoon(FROM_HERE, host_.release()); 92 host_thread_.message_loop_proxy()->DeleteSoon(FROM_HERE, host_.release());
93 host_thread_.message_loop_proxy()->DeleteSoon(FROM_HERE, 93 host_thread_.message_loop_proxy()->DeleteSoon(FROM_HERE,
94 host_signaling_.release()); 94 host_signaling_.release());
(...skipping 389 matching lines...) Expand 10 before | Expand all | Expand 10 after
484 << "ms Encode: " << last_video_packet_->encode_time_ms() 484 << "ms Encode: " << last_video_packet_->encode_time_ms()
485 << "ms Capture: " << last_video_packet_->capture_time_ms() 485 << "ms Capture: " << last_video_packet_->capture_time_ms()
486 << "ms"; 486 << "ms";
487 sum += latency; 487 sum += latency;
488 } 488 }
489 489
490 LOG(INFO) << "Average: " << (sum / kFrames).InMillisecondsF(); 490 LOG(INFO) << "Average: " << (sum / kFrames).InMillisecondsF();
491 } 491 }
492 492
493 } // namespace remoting 493 } // namespace remoting
OLDNEW
« no previous file with comments | « remoting/remoting_test.gypi ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698