| 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/paint/display_item_list.h" | 5 #include "cc/paint/display_item_list.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 470 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 481 DiscardableImageMap::ScopedMetadataGenerator generator( | 481 DiscardableImageMap::ScopedMetadataGenerator generator( |
| 482 &image_map_, gfx::Size(bounds.right(), bounds.bottom())); | 482 &image_map_, gfx::Size(bounds.right(), bounds.bottom())); |
| 483 auto* canvas = generator.canvas(); | 483 auto* canvas = generator.canvas(); |
| 484 for (const auto& item : items_) | 484 for (const auto& item : items_) |
| 485 RasterItem(item, canvas, nullptr); | 485 RasterItem(item, canvas, nullptr); |
| 486 } | 486 } |
| 487 | 487 |
| 488 void DisplayItemList::GetDiscardableImagesInRect( | 488 void DisplayItemList::GetDiscardableImagesInRect( |
| 489 const gfx::Rect& rect, | 489 const gfx::Rect& rect, |
| 490 float contents_scale, | 490 float contents_scale, |
| 491 const gfx::ColorSpace& target_color_space, |
| 491 std::vector<DrawImage>* images) { | 492 std::vector<DrawImage>* images) { |
| 492 image_map_.GetDiscardableImagesInRect(rect, contents_scale, images); | 493 image_map_.GetDiscardableImagesInRect(rect, contents_scale, |
| 494 target_color_space, images); |
| 493 } | 495 } |
| 494 | 496 |
| 495 gfx::Rect DisplayItemList::GetRectForImage(ImageId image_id) const { | 497 gfx::Rect DisplayItemList::GetRectForImage(ImageId image_id) const { |
| 496 return image_map_.GetRectForImage(image_id); | 498 return image_map_.GetRectForImage(image_id); |
| 497 } | 499 } |
| 498 | 500 |
| 499 } // namespace cc | 501 } // namespace cc |
| OLD | NEW |