Commit c076c61b authored by Stefan Zager's avatar Stefan Zager Committed by Commit Bot

[SquashAfterPaint] Refactor raster invalidation to pass function

This is CL is a pure refactor with no functional change. The change to
plumb a RasterInvalidationFunction through RasterInvalidator::Generate
will be needed for SquashAfterPaint, when the call path into raster
invalidation will involve calls through both ContentLayerClientImpl and
GraphicsLayer.

BUG=548184

Change-Id: Ic3003369f8e66f8c74f6ca884352ded60e827775
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2082482Reviewed-by: default avatarPhilip Rogers <pdr@chromium.org>
Commit-Queue: Stefan Zager <szager@chromium.org>
Cr-Commit-Position: refs/heads/master@{#746018}
parent a844e412
...@@ -24,7 +24,7 @@ namespace blink { ...@@ -24,7 +24,7 @@ namespace blink {
ContentLayerClientImpl::ContentLayerClientImpl() ContentLayerClientImpl::ContentLayerClientImpl()
: cc_picture_layer_(cc::PictureLayer::Create(this)), : cc_picture_layer_(cc::PictureLayer::Create(this)),
raster_invalidator_( raster_invalidation_function_(
base::BindRepeating(&ContentLayerClientImpl::InvalidateRect, base::BindRepeating(&ContentLayerClientImpl::InvalidateRect,
base::Unretained(this))), base::Unretained(this))),
layer_state_(PropertyTreeState::Uninitialized()) {} layer_state_(PropertyTreeState::Uninitialized()) {}
...@@ -85,8 +85,8 @@ scoped_refptr<cc::PictureLayer> ContentLayerClientImpl::UpdateCcPictureLayer( ...@@ -85,8 +85,8 @@ scoped_refptr<cc::PictureLayer> ContentLayerClientImpl::UpdateCcPictureLayer(
if (layer_state != layer_state_) if (layer_state != layer_state_)
cc_picture_layer_->SetSubtreePropertyChanged(); cc_picture_layer_->SetSubtreePropertyChanged();
raster_invalidator_.Generate(paint_artifact, paint_chunks, layer_bounds, raster_invalidator_.Generate(raster_invalidation_function_, paint_artifact,
layer_state); paint_chunks, layer_bounds, layer_state);
layer_state_ = layer_state; layer_state_ = layer_state;
// Note: cc::Layer API assumes the layer bounds start at (0, 0), but the // Note: cc::Layer API assumes the layer bounds start at (0, 0), but the
......
...@@ -74,6 +74,8 @@ class PLATFORM_EXPORT ContentLayerClientImpl : public cc::ContentLayerClient, ...@@ -74,6 +74,8 @@ class PLATFORM_EXPORT ContentLayerClientImpl : public cc::ContentLayerClient,
scoped_refptr<cc::PictureLayer> cc_picture_layer_; scoped_refptr<cc::PictureLayer> cc_picture_layer_;
scoped_refptr<cc::DisplayItemList> cc_display_item_list_; scoped_refptr<cc::DisplayItemList> cc_display_item_list_;
RasterInvalidator raster_invalidator_; RasterInvalidator raster_invalidator_;
RasterInvalidator::RasterInvalidationFunction raster_invalidation_function_;
PropertyTreeState layer_state_; PropertyTreeState layer_state_;
String debug_name_; String debug_name_;
......
...@@ -78,7 +78,10 @@ GraphicsLayer::GraphicsLayer(GraphicsLayerClient& client) ...@@ -78,7 +78,10 @@ GraphicsLayer::GraphicsLayer(GraphicsLayerClient& client)
painted_(false), painted_(false),
painting_phase_(kGraphicsLayerPaintAllWithOverflowClip), painting_phase_(kGraphicsLayerPaintAllWithOverflowClip),
parent_(nullptr), parent_(nullptr),
mask_layer_(nullptr) { mask_layer_(nullptr),
raster_invalidation_function_(
base::BindRepeating(&GraphicsLayer::SetNeedsDisplayInRect,
base::Unretained(this))) {
// TODO(crbug.com/1033240): Debugging information for the referenced bug. // TODO(crbug.com/1033240): Debugging information for the referenced bug.
// Remove when it is fixed. // Remove when it is fixed.
CHECK(&client_); CHECK(&client_);
...@@ -331,6 +334,7 @@ bool GraphicsLayer::Paint(GraphicsContext::DisabledMode disabled_mode) { ...@@ -331,6 +334,7 @@ bool GraphicsLayer::Paint(GraphicsContext::DisabledMode disabled_mode) {
// Generate raster invalidations for SPv1. // Generate raster invalidations for SPv1.
IntRect layer_bounds(layer_state_->offset, IntSize(Size())); IntRect layer_bounds(layer_state_->offset, IntSize(Size()));
EnsureRasterInvalidator().Generate( EnsureRasterInvalidator().Generate(
raster_invalidation_function_,
GetPaintController().GetPaintArtifactShared(), layer_bounds, GetPaintController().GetPaintArtifactShared(), layer_bounds,
layer_state_->state, VisualRectSubpixelOffset(), this); layer_state_->state, VisualRectSubpixelOffset(), this);
...@@ -462,9 +466,7 @@ void GraphicsLayer::SetContentsTo(scoped_refptr<cc::Layer> layer, ...@@ -462,9 +466,7 @@ void GraphicsLayer::SetContentsTo(scoped_refptr<cc::Layer> layer,
RasterInvalidator& GraphicsLayer::EnsureRasterInvalidator() { RasterInvalidator& GraphicsLayer::EnsureRasterInvalidator() {
if (!raster_invalidator_) { if (!raster_invalidator_) {
raster_invalidator_ = raster_invalidator_ = std::make_unique<RasterInvalidator>();
std::make_unique<RasterInvalidator>(base::BindRepeating(
&GraphicsLayer::SetNeedsDisplayInRect, base::Unretained(this)));
raster_invalidator_->SetTracksRasterInvalidations( raster_invalidator_->SetTracksRasterInvalidations(
client_.IsTrackingRasterInvalidations()); client_.IsTrackingRasterInvalidations());
} }
......
...@@ -47,6 +47,7 @@ ...@@ -47,6 +47,7 @@
#include "third_party/blink/renderer/platform/graphics/image_orientation.h" #include "third_party/blink/renderer/platform/graphics/image_orientation.h"
#include "third_party/blink/renderer/platform/graphics/paint/display_item_client.h" #include "third_party/blink/renderer/platform/graphics/paint/display_item_client.h"
#include "third_party/blink/renderer/platform/graphics/paint/paint_controller.h" #include "third_party/blink/renderer/platform/graphics/paint/paint_controller.h"
#include "third_party/blink/renderer/platform/graphics/paint/raster_invalidator.h"
#include "third_party/blink/renderer/platform/graphics/paint_invalidation_reason.h" #include "third_party/blink/renderer/platform/graphics/paint_invalidation_reason.h"
#include "third_party/blink/renderer/platform/graphics/squashing_disallowed_reasons.h" #include "third_party/blink/renderer/platform/graphics/squashing_disallowed_reasons.h"
#include "third_party/blink/renderer/platform/heap/handle.h" #include "third_party/blink/renderer/platform/heap/handle.h"
...@@ -335,6 +336,7 @@ class PLATFORM_EXPORT GraphicsLayer : public DisplayItemClient, ...@@ -335,6 +336,7 @@ class PLATFORM_EXPORT GraphicsLayer : public DisplayItemClient,
std::unique_ptr<LayerState> contents_layer_state_; std::unique_ptr<LayerState> contents_layer_state_;
std::unique_ptr<RasterInvalidator> raster_invalidator_; std::unique_ptr<RasterInvalidator> raster_invalidator_;
RasterInvalidator::RasterInvalidationFunction raster_invalidation_function_;
DOMNodeId owner_node_id_ = kInvalidDOMNodeId; DOMNodeId owner_node_id_ = kInvalidDOMNodeId;
CompositingReasons compositing_reasons_ = CompositingReason::kNone; CompositingReasons compositing_reasons_ = CompositingReason::kNone;
......
...@@ -136,7 +136,8 @@ void DisplayItemRasterInvalidator::AddRasterInvalidation( ...@@ -136,7 +136,8 @@ void DisplayItemRasterInvalidator::AddRasterInvalidation(
if (r.IsEmpty()) if (r.IsEmpty())
return; return;
invalidator_.AddRasterInvalidation(r, client, reason, old_or_new); invalidator_.AddRasterInvalidation(raster_invalidation_function_, r, client,
reason, old_or_new);
} }
void DisplayItemRasterInvalidator::GenerateRasterInvalidation( void DisplayItemRasterInvalidator::GenerateRasterInvalidation(
......
...@@ -15,13 +15,16 @@ class DisplayItemRasterInvalidator { ...@@ -15,13 +15,16 @@ class DisplayItemRasterInvalidator {
STACK_ALLOCATED(); STACK_ALLOCATED();
public: public:
DisplayItemRasterInvalidator(RasterInvalidator& invalidator, DisplayItemRasterInvalidator(
const PaintArtifact& old_paint_artifact, RasterInvalidator& invalidator,
const PaintArtifact& new_paint_artifact, RasterInvalidator::RasterInvalidationFunction function,
const PaintChunk& old_chunk, const PaintArtifact& old_paint_artifact,
const PaintChunk& new_chunk, const PaintArtifact& new_paint_artifact,
const ChunkToLayerMapper& mapper) const PaintChunk& old_chunk,
const PaintChunk& new_chunk,
const ChunkToLayerMapper& mapper)
: invalidator_(invalidator), : invalidator_(invalidator),
raster_invalidation_function_(function),
old_paint_artifact_(old_paint_artifact), old_paint_artifact_(old_paint_artifact),
new_paint_artifact_(new_paint_artifact), new_paint_artifact_(new_paint_artifact),
old_chunk_(old_chunk), old_chunk_(old_chunk),
...@@ -58,6 +61,7 @@ class DisplayItemRasterInvalidator { ...@@ -58,6 +61,7 @@ class DisplayItemRasterInvalidator {
PaintInvalidationReason reason); PaintInvalidationReason reason);
RasterInvalidator& invalidator_; RasterInvalidator& invalidator_;
RasterInvalidator::RasterInvalidationFunction raster_invalidation_function_;
const PaintArtifact& old_paint_artifact_; const PaintArtifact& old_paint_artifact_;
const PaintArtifact& new_paint_artifact_; const PaintArtifact& new_paint_artifact_;
const PaintChunk& old_chunk_; const PaintChunk& old_chunk_;
......
...@@ -19,12 +19,12 @@ using ::testing::UnorderedElementsAre; ...@@ -19,12 +19,12 @@ using ::testing::UnorderedElementsAre;
class DisplayItemRasterInvalidatorTest : public PaintControllerTestBase, class DisplayItemRasterInvalidatorTest : public PaintControllerTestBase,
public PaintTestConfigurations { public PaintTestConfigurations {
protected: protected:
DisplayItemRasterInvalidatorTest() : invalidator_(base::DoNothing()) {} DisplayItemRasterInvalidatorTest() = default;
Vector<RasterInvalidationInfo> GenerateRasterInvalidations() { Vector<RasterInvalidationInfo> GenerateRasterInvalidations() {
GetPaintController().CommitNewDisplayItems(); GetPaintController().CommitNewDisplayItems();
invalidator_.Generate( invalidator_.Generate(
GetPaintController().GetPaintArtifactShared(), base::DoNothing(), GetPaintController().GetPaintArtifactShared(),
// The layer rect is big enough not to clip display item raster // The layer rect is big enough not to clip display item raster
// invalidation rects. // invalidation rects.
IntRect(0, 0, 20000, 20000), PropertyTreeState::Root()); IntRect(0, 0, 20000, 20000), PropertyTreeState::Root());
......
...@@ -171,6 +171,7 @@ bool ShouldSkipForRasterInvalidation(const PaintArtifact& paint_artifact, ...@@ -171,6 +171,7 @@ bool ShouldSkipForRasterInvalidation(const PaintArtifact& paint_artifact,
// common cases that most of the chunks can be matched in-order, the complexity // common cases that most of the chunks can be matched in-order, the complexity
// is slightly larger than O(n). // is slightly larger than O(n).
void RasterInvalidator::GenerateRasterInvalidations( void RasterInvalidator::GenerateRasterInvalidations(
RasterInvalidationFunction function,
const PaintArtifact& new_paint_artifact, const PaintArtifact& new_paint_artifact,
const PaintChunkSubset& new_chunks, const PaintChunkSubset& new_chunks,
const PropertyTreeState& layer_state, const PropertyTreeState& layer_state,
...@@ -198,18 +199,18 @@ void RasterInvalidator::GenerateRasterInvalidations( ...@@ -198,18 +199,18 @@ void RasterInvalidator::GenerateRasterInvalidations(
} }
if (!new_chunk.is_cacheable) { if (!new_chunk.is_cacheable) {
AddRasterInvalidation(new_chunk_info.bounds_in_layer, new_chunk.id.client, AddRasterInvalidation(
PaintInvalidationReason::kChunkUncacheable, function, new_chunk_info.bounds_in_layer, new_chunk.id.client,
kClientIsNew); PaintInvalidationReason::kChunkUncacheable, kClientIsNew);
continue; continue;
} }
auto matched_old_index = MatchNewChunkToOldChunk(new_chunk, old_index); auto matched_old_index = MatchNewChunkToOldChunk(new_chunk, old_index);
if (matched_old_index == kNotFound) { if (matched_old_index == kNotFound) {
// The new chunk doesn't match any old chunk. // The new chunk doesn't match any old chunk.
AddRasterInvalidation(new_chunk_info.bounds_in_layer, new_chunk.id.client, AddRasterInvalidation(
PaintInvalidationReason::kChunkAppeared, function, new_chunk_info.bounds_in_layer, new_chunk.id.client,
kClientIsNew); PaintInvalidationReason::kChunkAppeared, kClientIsNew);
continue; continue;
} }
...@@ -233,10 +234,10 @@ void RasterInvalidator::GenerateRasterInvalidations( ...@@ -233,10 +234,10 @@ void RasterInvalidator::GenerateRasterInvalidations(
// Invalidate both old and new bounds of the chunk if the chunk's paint // Invalidate both old and new bounds of the chunk if the chunk's paint
// properties changed, or is moved backward and may expose area that was // properties changed, or is moved backward and may expose area that was
// previously covered by it. // previously covered by it.
AddRasterInvalidation(old_chunk_info.bounds_in_layer, new_chunk.id.client, AddRasterInvalidation(function, old_chunk_info.bounds_in_layer,
reason, kClientIsNew); new_chunk.id.client, reason, kClientIsNew);
if (old_chunk_info.bounds_in_layer != new_chunk_info.bounds_in_layer) { if (old_chunk_info.bounds_in_layer != new_chunk_info.bounds_in_layer) {
AddRasterInvalidation(new_chunk_info.bounds_in_layer, AddRasterInvalidation(function, new_chunk_info.bounds_in_layer,
new_chunk.id.client, reason, kClientIsNew); new_chunk.id.client, reason, kClientIsNew);
} }
// Ignore the display item raster invalidations because we have fully // Ignore the display item raster invalidations because we have fully
...@@ -250,12 +251,12 @@ void RasterInvalidator::GenerateRasterInvalidations( ...@@ -250,12 +251,12 @@ void RasterInvalidator::GenerateRasterInvalidations(
old_chunk_info.chunk_to_layer_transform; old_chunk_info.chunk_to_layer_transform;
if (reason == PaintInvalidationReason::kIncremental) { if (reason == PaintInvalidationReason::kIncremental) {
IncrementallyInvalidateChunk(old_chunk_info, new_chunk_info, IncrementallyInvalidateChunk(function, old_chunk_info, new_chunk_info,
new_chunk.id.client); new_chunk.id.client);
} }
if (&new_paint_artifact != old_paint_artifact_) { if (&new_paint_artifact != old_paint_artifact_) {
DisplayItemRasterInvalidator(*this, *old_paint_artifact_, DisplayItemRasterInvalidator(*this, function, *old_paint_artifact_,
new_paint_artifact, old_chunk, new_chunk, new_paint_artifact, old_chunk, new_chunk,
mapper) mapper)
.Generate(); .Generate();
...@@ -277,19 +278,20 @@ void RasterInvalidator::GenerateRasterInvalidations( ...@@ -277,19 +278,20 @@ void RasterInvalidator::GenerateRasterInvalidations(
auto reason = old_chunk.is_cacheable auto reason = old_chunk.is_cacheable
? PaintInvalidationReason::kChunkDisappeared ? PaintInvalidationReason::kChunkDisappeared
: PaintInvalidationReason::kChunkUncacheable; : PaintInvalidationReason::kChunkUncacheable;
AddRasterInvalidation(old_paint_chunks_info_[i].bounds_in_layer, AddRasterInvalidation(function, old_paint_chunks_info_[i].bounds_in_layer,
old_chunk.id.client, reason, kClientIsOld); old_chunk.id.client, reason, kClientIsOld);
} }
} }
void RasterInvalidator::IncrementallyInvalidateChunk( void RasterInvalidator::IncrementallyInvalidateChunk(
RasterInvalidationFunction function,
const PaintChunkInfo& old_chunk_info, const PaintChunkInfo& old_chunk_info,
const PaintChunkInfo& new_chunk_info, const PaintChunkInfo& new_chunk_info,
const DisplayItemClient& client) { const DisplayItemClient& client) {
SkRegion diff(old_chunk_info.bounds_in_layer); SkRegion diff(old_chunk_info.bounds_in_layer);
diff.op(new_chunk_info.bounds_in_layer, SkRegion::kXOR_Op); diff.op(new_chunk_info.bounds_in_layer, SkRegion::kXOR_Op);
for (SkRegion::Iterator it(diff); !it.done(); it.next()) { for (SkRegion::Iterator it(diff); !it.done(); it.next()) {
AddRasterInvalidation(IntRect(it.rect()), client, AddRasterInvalidation(function, IntRect(it.rect()), client,
PaintInvalidationReason::kIncremental, kClientIsNew); PaintInvalidationReason::kIncremental, kClientIsNew);
} }
} }
...@@ -312,16 +314,19 @@ RasterInvalidationTracking& RasterInvalidator::EnsureTracking() { ...@@ -312,16 +314,19 @@ RasterInvalidationTracking& RasterInvalidator::EnsureTracking() {
} }
void RasterInvalidator::Generate( void RasterInvalidator::Generate(
RasterInvalidationFunction raster_invalidation_function,
scoped_refptr<const PaintArtifact> new_paint_artifact, scoped_refptr<const PaintArtifact> new_paint_artifact,
const gfx::Rect& layer_bounds, const gfx::Rect& layer_bounds,
const PropertyTreeState& layer_state, const PropertyTreeState& layer_state,
const FloatSize& visual_rect_subpixel_offset, const FloatSize& visual_rect_subpixel_offset,
const DisplayItemClient* layer_client) { const DisplayItemClient* layer_client) {
Generate(new_paint_artifact, new_paint_artifact->PaintChunks(), layer_bounds, Generate(raster_invalidation_function, new_paint_artifact,
layer_state, visual_rect_subpixel_offset, layer_client); new_paint_artifact->PaintChunks(), layer_bounds, layer_state,
visual_rect_subpixel_offset, layer_client);
} }
void RasterInvalidator::Generate( void RasterInvalidator::Generate(
RasterInvalidationFunction raster_invalidation_function,
scoped_refptr<const PaintArtifact> new_paint_artifact, scoped_refptr<const PaintArtifact> new_paint_artifact,
const PaintChunkSubset& paint_chunks, const PaintChunkSubset& paint_chunks,
const gfx::Rect& layer_bounds, const gfx::Rect& layer_bounds,
...@@ -356,7 +361,8 @@ void RasterInvalidator::Generate( ...@@ -356,7 +361,8 @@ void RasterInvalidator::Generate(
layer_client ? *layer_client : paint_chunks[0].id.client); layer_client ? *layer_client : paint_chunks[0].id.client);
} }
} else { } else {
GenerateRasterInvalidations(*new_paint_artifact, paint_chunks, layer_state, GenerateRasterInvalidations(raster_invalidation_function,
*new_paint_artifact, paint_chunks, layer_state,
visual_rect_subpixel_offset, new_chunks_info); visual_rect_subpixel_offset, new_chunks_info);
} }
......
...@@ -27,10 +27,7 @@ class PLATFORM_EXPORT RasterInvalidator { ...@@ -27,10 +27,7 @@ class PLATFORM_EXPORT RasterInvalidator {
using RasterInvalidationFunction = using RasterInvalidationFunction =
base::RepeatingCallback<void(const IntRect&)>; base::RepeatingCallback<void(const IntRect&)>;
RasterInvalidator(RasterInvalidationFunction raster_invalidation_function) RasterInvalidator() = default;
: raster_invalidation_function_(std::move(raster_invalidation_function)) {
DCHECK(!raster_invalidation_function_.is_null());
}
void SetTracksRasterInvalidations(bool); void SetTracksRasterInvalidations(bool);
RasterInvalidationTracking* GetTracking() const { RasterInvalidationTracking* GetTracking() const {
...@@ -41,7 +38,8 @@ class PLATFORM_EXPORT RasterInvalidator { ...@@ -41,7 +38,8 @@ class PLATFORM_EXPORT RasterInvalidator {
// Generate raster invalidations for all of the changed paint chunks and // Generate raster invalidations for all of the changed paint chunks and
// display items in the paint artifact. // display items in the paint artifact.
void Generate(scoped_refptr<const PaintArtifact>, void Generate(RasterInvalidationFunction,
scoped_refptr<const PaintArtifact>,
const gfx::Rect& layer_bounds, const gfx::Rect& layer_bounds,
const PropertyTreeState& layer_state, const PropertyTreeState& layer_state,
const FloatSize& visual_rect_subpixel_offset = FloatSize(), const FloatSize& visual_rect_subpixel_offset = FloatSize(),
...@@ -49,7 +47,8 @@ class PLATFORM_EXPORT RasterInvalidator { ...@@ -49,7 +47,8 @@ class PLATFORM_EXPORT RasterInvalidator {
// Generate raster invalidations for a subset of the paint chunks in the // Generate raster invalidations for a subset of the paint chunks in the
// paint artifact. // paint artifact.
void Generate(scoped_refptr<const PaintArtifact>, void Generate(RasterInvalidationFunction,
scoped_refptr<const PaintArtifact>,
const PaintChunkSubset&, const PaintChunkSubset&,
const gfx::Rect& layer_bounds, const gfx::Rect& layer_bounds,
const PropertyTreeState& layer_state, const PropertyTreeState& layer_state,
...@@ -96,7 +95,8 @@ class PLATFORM_EXPORT RasterInvalidator { ...@@ -96,7 +95,8 @@ class PLATFORM_EXPORT RasterInvalidator {
SkMatrix chunk_to_layer_transform; SkMatrix chunk_to_layer_transform;
}; };
void GenerateRasterInvalidations(const PaintArtifact&, void GenerateRasterInvalidations(RasterInvalidationFunction,
const PaintArtifact&,
const PaintChunkSubset&, const PaintChunkSubset&,
const PropertyTreeState& layer_state, const PropertyTreeState& layer_state,
const FloatSize& visual_rect_subpixel_offset, const FloatSize& visual_rect_subpixel_offset,
...@@ -107,6 +107,7 @@ class PLATFORM_EXPORT RasterInvalidator { ...@@ -107,6 +107,7 @@ class PLATFORM_EXPORT RasterInvalidator {
wtf_size_t old_index) const; wtf_size_t old_index) const;
ALWAYS_INLINE void IncrementallyInvalidateChunk( ALWAYS_INLINE void IncrementallyInvalidateChunk(
RasterInvalidationFunction,
const PaintChunkInfo& old_chunk_info, const PaintChunkInfo& old_chunk_info,
const PaintChunkInfo& new_chunk_info, const PaintChunkInfo& new_chunk_info,
const DisplayItemClient&); const DisplayItemClient&);
...@@ -115,13 +116,14 @@ class PLATFORM_EXPORT RasterInvalidator { ...@@ -115,13 +116,14 @@ class PLATFORM_EXPORT RasterInvalidator {
// get DebugName() directly or should get from |tracking_info_ // get DebugName() directly or should get from |tracking_info_
// ->old_client_debug_names|. // ->old_client_debug_names|.
enum ClientIsOldOrNew { kClientIsOld, kClientIsNew }; enum ClientIsOldOrNew { kClientIsOld, kClientIsNew };
void AddRasterInvalidation(const IntRect& rect, void AddRasterInvalidation(RasterInvalidationFunction function,
const IntRect& rect,
const DisplayItemClient& client, const DisplayItemClient& client,
PaintInvalidationReason reason, PaintInvalidationReason reason,
ClientIsOldOrNew old_or_new) { ClientIsOldOrNew old_or_new) {
if (rect.IsEmpty()) if (rect.IsEmpty())
return; return;
raster_invalidation_function_.Run(rect); function.Run(rect);
if (tracking_info_) if (tracking_info_)
TrackRasterInvalidation(rect, client, reason, old_or_new); TrackRasterInvalidation(rect, client, reason, old_or_new);
} }
...@@ -146,7 +148,6 @@ class PLATFORM_EXPORT RasterInvalidator { ...@@ -146,7 +148,6 @@ class PLATFORM_EXPORT RasterInvalidator {
void TrackImplicitFullLayerInvalidation(const DisplayItemClient&); void TrackImplicitFullLayerInvalidation(const DisplayItemClient&);
RasterInvalidationFunction raster_invalidation_function_;
gfx::Rect layer_bounds_; gfx::Rect layer_bounds_;
Vector<PaintChunkInfo> old_paint_chunks_info_; Vector<PaintChunkInfo> old_paint_chunks_info_;
scoped_refptr<const PaintArtifact> old_paint_artifact_; scoped_refptr<const PaintArtifact> old_paint_artifact_;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment