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 2038 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2049 resource_provider_.reset(); | 2049 resource_provider_.reset(); |
2050 output_surface_.reset(); | 2050 output_surface_.reset(); |
2051 | 2051 |
2052 if (!output_surface->BindToClient(this)) | 2052 if (!output_surface->BindToClient(this)) |
2053 return false; | 2053 return false; |
2054 | 2054 |
2055 output_surface_ = output_surface.Pass(); | 2055 output_surface_ = output_surface.Pass(); |
2056 resource_provider_ = | 2056 resource_provider_ = |
2057 ResourceProvider::Create(output_surface_.get(), | 2057 ResourceProvider::Create(output_surface_.get(), |
2058 shared_bitmap_manager_, | 2058 shared_bitmap_manager_, |
| 2059 proxy_->blocking_main_thread_task_runner(), |
2059 settings_.highp_threshold_min, | 2060 settings_.highp_threshold_min, |
2060 settings_.use_rgba_4444_textures, | 2061 settings_.use_rgba_4444_textures, |
2061 settings_.texture_id_allocation_chunk_size, | 2062 settings_.texture_id_allocation_chunk_size, |
2062 settings_.use_distance_field_text); | 2063 settings_.use_distance_field_text); |
2063 | 2064 |
2064 if (output_surface_->capabilities().deferred_gl_initialization) | 2065 if (output_surface_->capabilities().deferred_gl_initialization) |
2065 EnforceZeroBudget(true); | 2066 EnforceZeroBudget(true); |
2066 | 2067 |
2067 CreateAndSetRenderer(); | 2068 CreateAndSetRenderer(); |
2068 | 2069 |
(...skipping 1283 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3352 } | 3353 } |
3353 | 3354 |
3354 void LayerTreeHostImpl::UnregisterPictureLayerImpl(PictureLayerImpl* layer) { | 3355 void LayerTreeHostImpl::UnregisterPictureLayerImpl(PictureLayerImpl* layer) { |
3355 std::vector<PictureLayerImpl*>::iterator it = | 3356 std::vector<PictureLayerImpl*>::iterator it = |
3356 std::find(picture_layers_.begin(), picture_layers_.end(), layer); | 3357 std::find(picture_layers_.begin(), picture_layers_.end(), layer); |
3357 DCHECK(it != picture_layers_.end()); | 3358 DCHECK(it != picture_layers_.end()); |
3358 picture_layers_.erase(it); | 3359 picture_layers_.erase(it); |
3359 } | 3360 } |
3360 | 3361 |
3361 } // namespace cc | 3362 } // namespace cc |
OLD | NEW |