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

Unified Diff: src/gpu/GrPictureUtils.cpp

Issue 513983002: Try out scalar picture sizes (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Update to ToT again Created 6 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 | « src/effects/SkPictureImageFilter.cpp ('k') | src/utils/SkDumpCanvas.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/GrPictureUtils.cpp
diff --git a/src/gpu/GrPictureUtils.cpp b/src/gpu/GrPictureUtils.cpp
index 521160ac8afd172d34b4d79ab8914fbbb2e20102..4b0f77f3864abbfc91f22938d96463d1347f6b07 100644
--- a/src/gpu/GrPictureUtils.cpp
+++ b/src/gpu/GrPictureUtils.cpp
@@ -23,10 +23,11 @@ public:
CollectLayers(const SkPicture* pict, GrAccelData* accelData)
: fPictureID(pict->uniqueID())
, fCTM(&SkMatrix::I())
- , fCurrentClipBounds(SkIRect::MakeXYWH(0, 0, pict->width(), pict->height()))
, fSaveLayersInStack(0)
, fAccelData(accelData) {
+ pict->cullRect().roundOut(&fCurrentClipBounds);
+
if (NULL == pict->fRecord.get()) {
return;
}
@@ -255,7 +256,7 @@ private:
// GPUOptimize is only intended to be called within the context of SkGpuDevice's
// EXPERIMENTAL_optimize method.
const GrAccelData* GPUOptimize(const SkPicture* pict) {
- if (NULL == pict || 0 == pict->width() || 0 == pict->height()) {
+ if (NULL == pict || pict->cullRect().isEmpty()) {
return NULL;
}
« no previous file with comments | « src/effects/SkPictureImageFilter.cpp ('k') | src/utils/SkDumpCanvas.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698