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 #ifndef CC_RESOURCES_RASTER_WORKER_POOL_H_ | 5 #ifndef CC_RESOURCES_RASTER_WORKER_POOL_H_ |
6 #define CC_RESOURCES_RASTER_WORKER_POOL_H_ | 6 #define CC_RESOURCES_RASTER_WORKER_POOL_H_ |
7 | 7 |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "base/hash_tables.h" | 10 #include "base/hash_tables.h" |
(...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
130 | 130 |
131 RasterTask(); | 131 RasterTask(); |
132 RasterTask(PicturePileImpl* picture_pile, | 132 RasterTask(PicturePileImpl* picture_pile, |
133 const Resource* resource, | 133 const Resource* resource, |
134 const Callback& callback, | 134 const Callback& callback, |
135 const Reply& reply, | 135 const Reply& reply, |
136 Task::Set* dependencies); | 136 Task::Set* dependencies); |
137 ~RasterTask(); | 137 ~RasterTask(); |
138 | 138 |
139 // Returns true if Task is null (doesn't refer to anything). | 139 // Returns true if Task is null (doesn't refer to anything). |
140 bool is_null() const { return !internal_; } | 140 bool is_null() const { return !internal_.get(); } |
141 | 141 |
142 // Returns the Task into an uninitialized state. | 142 // Returns the Task into an uninitialized state. |
143 void Reset(); | 143 void Reset(); |
144 | 144 |
145 protected: | 145 protected: |
146 friend class PixelBufferRasterWorkerPool; | 146 friend class PixelBufferRasterWorkerPool; |
147 friend class RasterWorkerPool; | 147 friend class RasterWorkerPool; |
148 | 148 |
149 scoped_refptr<internal::RasterWorkerPoolTask> internal_; | 149 scoped_refptr<internal::RasterWorkerPoolTask> internal_; |
150 }; | 150 }; |
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
196 } | 196 } |
197 | 197 |
198 private: | 198 private: |
199 ResourceProvider* resource_provider_; | 199 ResourceProvider* resource_provider_; |
200 RasterTask::Queue::TaskVector raster_tasks_; | 200 RasterTask::Queue::TaskVector raster_tasks_; |
201 }; | 201 }; |
202 | 202 |
203 } // namespace cc | 203 } // namespace cc |
204 | 204 |
205 #endif // CC_RESOURCES_RASTER_WORKER_POOL_H_ | 205 #endif // CC_RESOURCES_RASTER_WORKER_POOL_H_ |
OLD | NEW |