OLD | NEW |
---|---|
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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/tiles/tiling_set_raster_queue_all.h" | 5 #include "cc/tiles/tiling_set_raster_queue_all.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 | 8 |
9 #include <utility> | 9 #include <utility> |
10 | 10 |
(...skipping 182 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
193 if (!IsTileValid(tile)) { | 193 if (!IsTileValid(tile)) { |
194 current_tile_ = PrioritizedTile(); | 194 current_tile_ = PrioritizedTile(); |
195 return false; | 195 return false; |
196 } | 196 } |
197 current_tile_ = tiling_->MakePrioritizedTile(tile, priority_rect_type_); | 197 current_tile_ = tiling_->MakePrioritizedTile(tile, priority_rect_type_); |
198 return true; | 198 return true; |
199 } | 199 } |
200 | 200 |
201 bool TilingSetRasterQueueAll::OnePriorityRectIterator::IsTileValid( | 201 bool TilingSetRasterQueueAll::OnePriorityRectIterator::IsTileValid( |
202 const Tile* tile) const { | 202 const Tile* tile) const { |
203 if (!tile || !TileNeedsRaster(tile)) | 203 if (!tile) |
204 return false; | 204 return false; |
205 | |
206 // Occluded tiles are not processed for raster or image decodes. | |
207 if (tiling_->IsTileOccluded(tile)) | |
208 return false; | |
209 | |
210 if (!tile->draw_info().NeedsRaster() && | |
211 !tile->draw_info().is_checker_imaged()) | |
vmpstr
2017/03/29 19:11:46
braces and comment
Khushal
2017/03/31 04:31:01
Done.
| |
212 return false; | |
213 | |
205 // After the pending visible rect has been processed, we must return false | 214 // After the pending visible rect has been processed, we must return false |
206 // for pending visible rect tiles as tiling iterators do not ignore those | 215 // for pending visible rect tiles as tiling iterators do not ignore those |
207 // tiles. | 216 // tiles. |
208 if (priority_rect_type_ > PictureLayerTiling::PENDING_VISIBLE_RECT) { | 217 if (priority_rect_type_ > PictureLayerTiling::PENDING_VISIBLE_RECT) { |
209 gfx::Rect tile_bounds = tiling_data_->TileBounds(tile->tiling_i_index(), | 218 gfx::Rect tile_bounds = tiling_data_->TileBounds(tile->tiling_i_index(), |
210 tile->tiling_j_index()); | 219 tile->tiling_j_index()); |
211 if (pending_visible_rect_.Intersects(tile_bounds)) | 220 if (pending_visible_rect_.Intersects(tile_bounds)) |
212 return false; | 221 return false; |
213 } | 222 } |
214 return true; | 223 return true; |
(...skipping 223 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
438 current_tile_ = PrioritizedTile(); | 447 current_tile_ = PrioritizedTile(); |
439 return *this; | 448 return *this; |
440 } | 449 } |
441 current_tile_ = *eventually_iterator_; | 450 current_tile_ = *eventually_iterator_; |
442 break; | 451 break; |
443 } | 452 } |
444 return *this; | 453 return *this; |
445 } | 454 } |
446 | 455 |
447 } // namespace cc | 456 } // namespace cc |
OLD | NEW |