Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2852)

Unified Diff: cc/playback/filter_display_item.cc

Issue 1316243002: Define SK_SAVE_LAYER_BOUNDS_ARE_FILTERED for an upcoming Skia change. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add a TODO Created 5 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | skia/config/SkUserConfig.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/playback/filter_display_item.cc
diff --git a/cc/playback/filter_display_item.cc b/cc/playback/filter_display_item.cc
index fbed01509c80ff21641cf5083e9321315af56329..c155b68a64259e97e466eec07a940ea15f39de6a 100644
--- a/cc/playback/filter_display_item.cc
+++ b/cc/playback/filter_display_item.cc
@@ -43,9 +43,14 @@ void FilterDisplayItem::Raster(SkCanvas* canvas,
skia::RefPtr<SkImageFilter> image_filter =
RenderSurfaceFilters::BuildImageFilter(
filters_, gfx::SizeF(bounds_.width(), bounds_.height()));
+#ifdef SK_SAVE_LAYER_BOUNDS_ARE_FILTERED
+ // TODO(senorblanco): remove this once callsites updated (crbug.com/525748)
SkRect boundaries;
image_filter->computeFastBounds(
SkRect::MakeWH(bounds_.width(), bounds_.height()), &boundaries);
+#else
+ SkRect boundaries = SkRect::MakeWH(bounds_.width(), bounds_.height());
+#endif
SkPaint paint;
paint.setXfermodeMode(SkXfermode::kSrcOver_Mode);
« no previous file with comments | « no previous file | skia/config/SkUserConfig.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698