| OLD | NEW |
| 1 // Copyright 2011 The Chromium Authors. All rights reserved. | 1 // Copyright 2011 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 "cc/trees/layer_tree_host_impl.h" | 5 #include "cc/trees/layer_tree_host_impl.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <limits> | 8 #include <limits> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| (...skipping 2021 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2032 resource_provider_.get()); | 2032 resource_provider_.get()); |
| 2033 return; | 2033 return; |
| 2034 } | 2034 } |
| 2035 | 2035 |
| 2036 if (use_gpu_rasterization_) { | 2036 if (use_gpu_rasterization_) { |
| 2037 *resource_pool = | 2037 *resource_pool = |
| 2038 ResourcePool::Create(resource_provider_.get(), GL_TEXTURE_2D); | 2038 ResourcePool::Create(resource_provider_.get(), GL_TEXTURE_2D); |
| 2039 | 2039 |
| 2040 *tile_task_worker_pool = GpuTileTaskWorkerPool::Create( | 2040 *tile_task_worker_pool = GpuTileTaskWorkerPool::Create( |
| 2041 task_runner, TileTaskWorkerPool::GetTaskGraphRunner(), | 2041 task_runner, TileTaskWorkerPool::GetTaskGraphRunner(), |
| 2042 resource_provider_.get()); | 2042 static_cast<GpuRasterizer*>(rasterizer_.get())); |
| 2043 return; | 2043 return; |
| 2044 } | 2044 } |
| 2045 | 2045 |
| 2046 if (GetRendererCapabilities().using_image) { | 2046 if (GetRendererCapabilities().using_image) { |
| 2047 unsigned image_target = settings_.use_image_texture_target; | 2047 unsigned image_target = settings_.use_image_texture_target; |
| 2048 DCHECK_IMPLIES( | 2048 DCHECK_IMPLIES( |
| 2049 image_target == GL_TEXTURE_RECTANGLE_ARB, | 2049 image_target == GL_TEXTURE_RECTANGLE_ARB, |
| 2050 context_provider->ContextCapabilities().gpu.texture_rectangle); | 2050 context_provider->ContextCapabilities().gpu.texture_rectangle); |
| 2051 DCHECK_IMPLIES( | 2051 DCHECK_IMPLIES( |
| 2052 image_target == GL_TEXTURE_EXTERNAL_OES, | 2052 image_target == GL_TEXTURE_EXTERNAL_OES, |
| (...skipping 1453 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3506 (*it)->OnSetNeedsRedrawOnImpl(); | 3506 (*it)->OnSetNeedsRedrawOnImpl(); |
| 3507 } | 3507 } |
| 3508 | 3508 |
| 3509 void LayerTreeHostImpl::NotifySwapPromiseMonitorsOfForwardingToMainThread() { | 3509 void LayerTreeHostImpl::NotifySwapPromiseMonitorsOfForwardingToMainThread() { |
| 3510 std::set<SwapPromiseMonitor*>::iterator it = swap_promise_monitor_.begin(); | 3510 std::set<SwapPromiseMonitor*>::iterator it = swap_promise_monitor_.begin(); |
| 3511 for (; it != swap_promise_monitor_.end(); it++) | 3511 for (; it != swap_promise_monitor_.end(); it++) |
| 3512 (*it)->OnForwardScrollUpdateToMainThreadOnImpl(); | 3512 (*it)->OnForwardScrollUpdateToMainThreadOnImpl(); |
| 3513 } | 3513 } |
| 3514 | 3514 |
| 3515 } // namespace cc | 3515 } // namespace cc |
| OLD | NEW |