diff options
Diffstat (limited to 'libs/hwui/VectorDrawable.cpp')
| -rw-r--r-- | libs/hwui/VectorDrawable.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/libs/hwui/VectorDrawable.cpp b/libs/hwui/VectorDrawable.cpp index 6030c36add7a..4a21ad6ab945 100644 --- a/libs/hwui/VectorDrawable.cpp +++ b/libs/hwui/VectorDrawable.cpp @@ -507,10 +507,12 @@ void Tree::draw(SkCanvas* canvas, const SkRect& bounds, const SkPaint& inPaint) sk_sp<SkImage> cachedBitmap = getBitmapUpdateIfDirty().makeImage(); + // HWUI always draws VD with bilinear filtering. + auto sampling = SkSamplingOptions(SkFilterMode::kLinear); int scaledWidth = SkScalarCeilToInt(mProperties.getScaledWidth()); int scaledHeight = SkScalarCeilToInt(mProperties.getScaledHeight()); canvas->drawImageRect(cachedBitmap, SkRect::MakeWH(scaledWidth, scaledHeight), bounds, - &paint, SkCanvas::kFast_SrcRectConstraint); + sampling, &paint, SkCanvas::kFast_SrcRectConstraint); } void Tree::updateBitmapCache(Bitmap& bitmap, bool useStagingData) { |
