| 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 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
| (...skipping 269 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 280 settings.gpu_rasterization_enabled = | 280 settings.gpu_rasterization_enabled = |
| 281 compositor_deps_->IsGpuRasterizationEnabled(); | 281 compositor_deps_->IsGpuRasterizationEnabled(); |
| 282 | 282 |
| 283 settings.can_use_lcd_text = compositor_deps_->IsLcdTextEnabled(); | 283 settings.can_use_lcd_text = compositor_deps_->IsLcdTextEnabled(); |
| 284 settings.use_distance_field_text = | 284 settings.use_distance_field_text = |
| 285 compositor_deps_->IsDistanceFieldTextEnabled(); | 285 compositor_deps_->IsDistanceFieldTextEnabled(); |
| 286 settings.use_zero_copy = compositor_deps_->IsZeroCopyEnabled(); | 286 settings.use_zero_copy = compositor_deps_->IsZeroCopyEnabled(); |
| 287 settings.use_one_copy = compositor_deps_->IsOneCopyEnabled(); | 287 settings.use_one_copy = compositor_deps_->IsOneCopyEnabled(); |
| 288 settings.enable_elastic_overscroll = | 288 settings.enable_elastic_overscroll = |
| 289 compositor_deps_->IsElasticOverscrollEnabled(); | 289 compositor_deps_->IsElasticOverscrollEnabled(); |
| 290 settings.use_image_texture_target = compositor_deps_->GetImageTextureTarget(); | 290 settings.map_image_texture_target = |
| 291 compositor_deps_->GetMapImageTextureTarget(); |
| 292 settings.persistent_map_image_texture_target = |
| 293 compositor_deps_->GetPersistentMapImageTextureTarget(); |
| 291 settings.gather_pixel_refs = compositor_deps_->IsGatherPixelRefsEnabled(); | 294 settings.gather_pixel_refs = compositor_deps_->IsGatherPixelRefsEnabled(); |
| 292 | 295 |
| 293 if (cmd->HasSwitch(cc::switches::kTopControlsShowThreshold)) { | 296 if (cmd->HasSwitch(cc::switches::kTopControlsShowThreshold)) { |
| 294 std::string top_threshold_str = | 297 std::string top_threshold_str = |
| 295 cmd->GetSwitchValueASCII(cc::switches::kTopControlsShowThreshold); | 298 cmd->GetSwitchValueASCII(cc::switches::kTopControlsShowThreshold); |
| 296 double show_threshold; | 299 double show_threshold; |
| 297 if (base::StringToDouble(top_threshold_str, &show_threshold) && | 300 if (base::StringToDouble(top_threshold_str, &show_threshold) && |
| 298 show_threshold >= 0.f && show_threshold <= 1.f) | 301 show_threshold >= 0.f && show_threshold <= 1.f) |
| 299 settings.top_controls_show_threshold = show_threshold; | 302 settings.top_controls_show_threshold = show_threshold; |
| 300 } | 303 } |
| (...skipping 663 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 964 return; | 967 return; |
| 965 provider->ContextGL()->RateLimitOffscreenContextCHROMIUM(); | 968 provider->ContextGL()->RateLimitOffscreenContextCHROMIUM(); |
| 966 } | 969 } |
| 967 | 970 |
| 968 void RenderWidgetCompositor::SetSurfaceIdNamespace( | 971 void RenderWidgetCompositor::SetSurfaceIdNamespace( |
| 969 uint32_t surface_id_namespace) { | 972 uint32_t surface_id_namespace) { |
| 970 layer_tree_host_->set_surface_id_namespace(surface_id_namespace); | 973 layer_tree_host_->set_surface_id_namespace(surface_id_namespace); |
| 971 } | 974 } |
| 972 | 975 |
| 973 } // namespace content | 976 } // namespace content |
| OLD | NEW |