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

Side by Side Diff: content/browser/renderer_host/compositor_impl_android.cc

Issue 1177033008: cc: Turn impl_side_painting and use_one_copy on in LayerTreeSettings. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: implon: fixwebkittests Created 5 years, 6 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
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 "content/browser/renderer_host/compositor_impl_android.h" 5 #include "content/browser/renderer_host/compositor_impl_android.h"
6 6
7 #include <android/bitmap.h> 7 #include <android/bitmap.h>
8 #include <android/native_window_jni.h> 8 #include <android/native_window_jni.h>
9 9
10 #include "base/android/jni_android.h" 10 #include "base/android/jni_android.h"
(...skipping 413 matching lines...) Expand 10 before | Expand all | Expand 10 after
424 DCHECK(!host_); 424 DCHECK(!host_);
425 DCHECK(!WillCompositeThisFrame()); 425 DCHECK(!WillCompositeThisFrame());
426 needs_composite_ = false; 426 needs_composite_ = false;
427 pending_swapbuffers_ = 0; 427 pending_swapbuffers_ = 0;
428 cc::LayerTreeSettings settings; 428 cc::LayerTreeSettings settings;
429 settings.renderer_settings.refresh_rate = 60.0; 429 settings.renderer_settings.refresh_rate = 60.0;
430 settings.renderer_settings.allow_antialiasing = false; 430 settings.renderer_settings.allow_antialiasing = false;
431 settings.renderer_settings.highp_threshold_min = 2048; 431 settings.renderer_settings.highp_threshold_min = 2048;
432 settings.impl_side_painting = true; 432 settings.impl_side_painting = true;
433 settings.use_zero_copy = true; 433 settings.use_zero_copy = true;
434 settings.use_one_copy = false;
434 435
435 base::CommandLine* command_line = base::CommandLine::ForCurrentProcess(); 436 base::CommandLine* command_line = base::CommandLine::ForCurrentProcess();
436 settings.initial_debug_state.SetRecordRenderingStats( 437 settings.initial_debug_state.SetRecordRenderingStats(
437 command_line->HasSwitch(cc::switches::kEnableGpuBenchmarking)); 438 command_line->HasSwitch(cc::switches::kEnableGpuBenchmarking));
438 settings.initial_debug_state.show_fps_counter = 439 settings.initial_debug_state.show_fps_counter =
439 command_line->HasSwitch(cc::switches::kUIShowFPSCounter); 440 command_line->HasSwitch(cc::switches::kUIShowFPSCounter);
440 // TODO(enne): Update this this compositor to use the scheduler. 441 // TODO(enne): Update this this compositor to use the scheduler.
441 settings.single_thread_proxy_scheduler = false; 442 settings.single_thread_proxy_scheduler = false;
442 443
443 if (command_line->HasSwitch( 444 if (command_line->HasSwitch(
(...skipping 313 matching lines...) Expand 10 before | Expand all | Expand 10 after
757 758
758 void CompositorImpl::SetNeedsAnimate() { 759 void CompositorImpl::SetNeedsAnimate() {
759 needs_animate_ = true; 760 needs_animate_ = true;
760 if (!host_) 761 if (!host_)
761 return; 762 return;
762 763
763 host_->SetNeedsAnimate(); 764 host_->SetNeedsAnimate();
764 } 765 }
765 766
766 } // namespace content 767 } // namespace content
OLDNEW
« no previous file with comments | « cc/trees/tree_synchronizer_unittest.cc ('k') | content/test/web_layer_tree_view_impl_for_testing.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698