OLD | NEW |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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/renderer/gpu/render_widget_compositor.h" | 5 #include "content/renderer/gpu/render_widget_compositor.h" |
6 | 6 |
7 #include <limits> | 7 #include <limits> |
8 | 8 |
9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
10 #include "base/logging.h" | 10 #include "base/logging.h" |
(...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
124 | 124 |
125 settings.max_untiled_layer_size = gfx::Size(max_untiled_layer_width, | 125 settings.max_untiled_layer_size = gfx::Size(max_untiled_layer_width, |
126 max_untiled_layer_height); | 126 max_untiled_layer_height); |
127 | 127 |
128 settings.right_aligned_scheduling_enabled = | 128 settings.right_aligned_scheduling_enabled = |
129 cmd->HasSwitch(cc::switches::kEnableRightAlignedScheduling); | 129 cmd->HasSwitch(cc::switches::kEnableRightAlignedScheduling); |
130 settings.impl_side_painting = cc::switches::IsImplSidePaintingEnabled(); | 130 settings.impl_side_painting = cc::switches::IsImplSidePaintingEnabled(); |
131 settings.use_cheapness_estimator = | 131 settings.use_cheapness_estimator = |
132 !cmd->HasSwitch(cc::switches::kDisableCheapnessEstimator); | 132 !cmd->HasSwitch(cc::switches::kDisableCheapnessEstimator); |
133 settings.use_color_estimator = | 133 settings.use_color_estimator = |
134 cmd->HasSwitch(cc::switches::kUseColorEstimator); | 134 !cmd->HasSwitch(cc::switches::kDisableColorEstimator); |
135 settings.prediction_benchmarking = | 135 settings.prediction_benchmarking = |
136 cmd->HasSwitch(cc::switches::kEnablePredictionBenchmarking); | 136 cmd->HasSwitch(cc::switches::kEnablePredictionBenchmarking); |
137 | 137 |
138 settings.calculate_top_controls_position = | 138 settings.calculate_top_controls_position = |
139 cmd->HasSwitch(cc::switches::kEnableTopControlsPositionCalculation); | 139 cmd->HasSwitch(cc::switches::kEnableTopControlsPositionCalculation); |
140 if (cmd->HasSwitch(cc::switches::kTopControlsHeight)) { | 140 if (cmd->HasSwitch(cc::switches::kTopControlsHeight)) { |
141 std::string controls_height_str = | 141 std::string controls_height_str = |
142 cmd->GetSwitchValueASCII(cc::switches::kTopControlsHeight); | 142 cmd->GetSwitchValueASCII(cc::switches::kTopControlsHeight); |
143 double controls_height; | 143 double controls_height; |
144 if (base::StringToDouble(controls_height_str, &controls_height) && | 144 if (base::StringToDouble(controls_height_str, &controls_height) && |
(...skipping 406 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
551 return RenderThreadImpl::current()->OffscreenContextProviderForMainThread(); | 551 return RenderThreadImpl::current()->OffscreenContextProviderForMainThread(); |
552 } | 552 } |
553 | 553 |
554 scoped_refptr<cc::ContextProvider> | 554 scoped_refptr<cc::ContextProvider> |
555 RenderWidgetCompositor::OffscreenContextProviderForCompositorThread() { | 555 RenderWidgetCompositor::OffscreenContextProviderForCompositorThread() { |
556 return RenderThreadImpl::current()-> | 556 return RenderThreadImpl::current()-> |
557 OffscreenContextProviderForCompositorThread(); | 557 OffscreenContextProviderForCompositorThread(); |
558 } | 558 } |
559 | 559 |
560 } // namespace content | 560 } // namespace content |
OLD | NEW |