| 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 <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include <cmath> | 9 #include <cmath> |
| 10 #include <limits> | 10 #include <limits> |
| (...skipping 370 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 381 settings.use_zero_copy = compositor_deps->IsZeroCopyEnabled(); | 381 settings.use_zero_copy = compositor_deps->IsZeroCopyEnabled(); |
| 382 settings.use_partial_raster = compositor_deps->IsPartialRasterEnabled(); | 382 settings.use_partial_raster = compositor_deps->IsPartialRasterEnabled(); |
| 383 settings.enable_elastic_overscroll = | 383 settings.enable_elastic_overscroll = |
| 384 compositor_deps->IsElasticOverscrollEnabled(); | 384 compositor_deps->IsElasticOverscrollEnabled(); |
| 385 settings.renderer_settings.use_gpu_memory_buffer_resources = | 385 settings.renderer_settings.use_gpu_memory_buffer_resources = |
| 386 compositor_deps->IsGpuMemoryBufferCompositorResourcesEnabled(); | 386 compositor_deps->IsGpuMemoryBufferCompositorResourcesEnabled(); |
| 387 settings.enable_color_correct_rasterization = | 387 settings.enable_color_correct_rasterization = |
| 388 cmd.HasSwitch(switches::kEnableColorCorrectRendering); | 388 cmd.HasSwitch(switches::kEnableColorCorrectRendering); |
| 389 settings.renderer_settings.enable_color_correct_rendering = | 389 settings.renderer_settings.enable_color_correct_rendering = |
| 390 cmd.HasSwitch(switches::kEnableColorCorrectRendering); | 390 cmd.HasSwitch(switches::kEnableColorCorrectRendering); |
| 391 settings.renderer_settings.buffer_to_texture_target_map = | 391 settings.buffer_to_texture_target_map = |
| 392 compositor_deps->GetBufferToTextureTargetMap(); | 392 compositor_deps->GetBufferToTextureTargetMap(); |
| 393 | 393 |
| 394 // Build LayerTreeSettings from command line args. | 394 // Build LayerTreeSettings from command line args. |
| 395 LayerTreeSettingsFactory::SetBrowserControlsSettings(settings, cmd); | 395 LayerTreeSettingsFactory::SetBrowserControlsSettings(settings, cmd); |
| 396 | 396 |
| 397 settings.use_layer_lists = cmd.HasSwitch(cc::switches::kEnableLayerLists); | 397 settings.use_layer_lists = cmd.HasSwitch(cc::switches::kEnableLayerLists); |
| 398 | 398 |
| 399 settings.renderer_settings.allow_antialiasing &= | 399 settings.renderer_settings.allow_antialiasing &= |
| 400 !cmd.HasSwitch(cc::switches::kDisableCompositedAntialiasing); | 400 !cmd.HasSwitch(cc::switches::kDisableCompositedAntialiasing); |
| 401 // The means the renderer compositor has 2 possible modes: | 401 // The means the renderer compositor has 2 possible modes: |
| (...skipping 829 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1231 const cc::LocalSurfaceId& local_surface_id) { | 1231 const cc::LocalSurfaceId& local_surface_id) { |
| 1232 layer_tree_host_->SetLocalSurfaceId(local_surface_id); | 1232 layer_tree_host_->SetLocalSurfaceId(local_surface_id); |
| 1233 } | 1233 } |
| 1234 | 1234 |
| 1235 void RenderWidgetCompositor::NotifySwapTime(ReportTimeCallback callback) { | 1235 void RenderWidgetCompositor::NotifySwapTime(ReportTimeCallback callback) { |
| 1236 QueueSwapPromise(base::MakeUnique<ReportTimeSwapPromise>( | 1236 QueueSwapPromise(base::MakeUnique<ReportTimeSwapPromise>( |
| 1237 std::move(callback), base::ThreadTaskRunnerHandle::Get())); | 1237 std::move(callback), base::ThreadTaskRunnerHandle::Get())); |
| 1238 } | 1238 } |
| 1239 | 1239 |
| 1240 } // namespace content | 1240 } // namespace content |
| OLD | NEW |