diff options
author | 2016-08-18 09:30:44 -0700 | |
---|---|---|
committer | 2016-08-18 09:30:44 -0700 | |
commit | 7c1235457f7ef69d3bde48306e9be528718da7e6 (patch) | |
tree | 0c495d7c91f194507d7d5063ddbd50cc0a5e089e /src/core | |
parent | 6d391b6c37c66770913aaecc50ddb466705dde31 (diff) |
remove disable aa/dither flags from Props -- never used
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2257643003
TBR=bsalomon
Review-Url: https://codereview.chromium.org/2257643003
Diffstat (limited to 'src/core')
-rw-r--r-- | src/core/SkCanvas.cpp | 24 |
1 files changed, 0 insertions, 24 deletions
diff --git a/src/core/SkCanvas.cpp b/src/core/SkCanvas.cpp index 539fd36028..09c50c69b0 100644 --- a/src/core/SkCanvas.cpp +++ b/src/core/SkCanvas.cpp @@ -175,19 +175,6 @@ void SkCanvas::predrawNotify(const SkRect* rect, const SkPaint* paint, /////////////////////////////////////////////////////////////////////////////// -static uint32_t filter_paint_flags(const SkSurfaceProps& props, uint32_t flags) { - const uint32_t propFlags = props.flags(); - if (propFlags & SkSurfaceProps::kDisallowDither_Flag) { - flags &= ~SkPaint::kDither_Flag; - } - if (propFlags & SkSurfaceProps::kDisallowAntiAlias_Flag) { - flags &= ~SkPaint::kAntiAlias_Flag; - } - return flags; -} - -/////////////////////////////////////////////////////////////////////////////// - /* This is the record we keep for each SkBaseDevice that the user installs. The clip/matrix/proc are fields that reflect the top of the save/restore stack. Whenever the canvas changes, it marks a dirty flag, and then before @@ -507,15 +494,6 @@ public: // can we be marked as simple? fIsSimple = !fFilter && !fTempLayerForImageFilter; } - - uint32_t oldFlags = paint.getFlags(); - fNewPaintFlags = filter_paint_flags(props, oldFlags); - if (fIsSimple && (fNewPaintFlags != oldFlags)) { - SkPaint* paint = set_if_needed(&fLazyPaintInit, fOrigPaint); - paint->setFlags(fNewPaintFlags); - fPaint = paint; - // if we're not simple, doNext() will take care of calling setFlags() - } } ~AutoDrawLooper() { @@ -549,7 +527,6 @@ private: SkDrawFilter* fFilter; const SkPaint* fPaint; int fSaveCount; - uint32_t fNewPaintFlags; bool fTempLayerForImageFilter; bool fDone; bool fIsSimple; @@ -566,7 +543,6 @@ bool AutoDrawLooper::doNext(SkDrawFilter::Type drawType) { SkPaint* paint = fLazyPaintPerLooper.set(fLazyPaintInit.isValid() ? *fLazyPaintInit.get() : fOrigPaint); - paint->setFlags(fNewPaintFlags); if (fTempLayerForImageFilter) { paint->setImageFilter(nullptr); |