OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 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 "cc/resources/image_raster_worker_pool.h" | 5 #include "cc/resources/image_raster_worker_pool.h" |
6 | 6 |
7 #include "base/debug/trace_event.h" | 7 #include "base/debug/trace_event.h" |
8 #include "base/values.h" | 8 #include "base/values.h" |
9 #include "cc/debug/traced_value.h" | 9 #include "cc/debug/traced_value.h" |
10 #include "cc/resources/resource.h" | 10 #include "cc/resources/resource.h" |
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
52 const Reply reply_; | 52 const Reply reply_; |
53 | 53 |
54 DISALLOW_COPY_AND_ASSIGN(ImageWorkerPoolTaskImpl); | 54 DISALLOW_COPY_AND_ASSIGN(ImageWorkerPoolTaskImpl); |
55 }; | 55 }; |
56 | 56 |
57 } // namespace | 57 } // namespace |
58 | 58 |
59 ImageRasterWorkerPool::ImageRasterWorkerPool( | 59 ImageRasterWorkerPool::ImageRasterWorkerPool( |
60 ResourceProvider* resource_provider, | 60 ResourceProvider* resource_provider, |
61 ContextProvider* context_provider, | 61 ContextProvider* context_provider, |
62 size_t num_threads, | |
63 GLenum texture_target) | 62 GLenum texture_target) |
64 : RasterWorkerPool(resource_provider, context_provider, num_threads), | 63 : RasterWorkerPool(resource_provider, context_provider), |
65 texture_target_(texture_target), | 64 texture_target_(texture_target), |
66 raster_tasks_pending_(false), | 65 raster_tasks_pending_(false), |
67 raster_tasks_required_for_activation_pending_(false) { | 66 raster_tasks_required_for_activation_pending_(false) { |
68 } | 67 } |
69 | 68 |
70 ImageRasterWorkerPool::~ImageRasterWorkerPool() { | 69 ImageRasterWorkerPool::~ImageRasterWorkerPool() { |
71 DCHECK_EQ(0u, image_tasks_.size()); | 70 DCHECK_EQ(0u, image_tasks_.size()); |
72 } | 71 } |
73 | 72 |
74 void ImageRasterWorkerPool::ScheduleTasks(RasterTask::Queue* queue) { | 73 void ImageRasterWorkerPool::ScheduleTasks(RasterTask::Queue* queue) { |
(...skipping 163 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
238 if (is_required_for_activation) { | 237 if (is_required_for_activation) { |
239 raster_required_for_activation_finished_node->add_dependency(); | 238 raster_required_for_activation_finished_node->add_dependency(); |
240 image_node->add_dependent(raster_required_for_activation_finished_node); | 239 image_node->add_dependent(raster_required_for_activation_finished_node); |
241 } | 240 } |
242 | 241 |
243 raster_finished_node->add_dependency(); | 242 raster_finished_node->add_dependency(); |
244 image_node->add_dependent(raster_finished_node); | 243 image_node->add_dependent(raster_finished_node); |
245 } | 244 } |
246 | 245 |
247 } // namespace cc | 246 } // namespace cc |
OLD | NEW |