Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d9512a30 authored by Mike Reed's avatar Mike Reed
Browse files

default dithering to ON (cheap, looks good)

officially ignore filtering (expensive, no real improvement)
parent dc9555fb
Loading
Loading
Loading
Loading
+10 −0
Original line number Diff line number Diff line
@@ -193,6 +193,14 @@ public class NinePatchDrawable extends Drawable {
        getPaint().setDither(dither);
    }

    @Override
    public void setFilterBitmap(boolean filter) {
        // at the moment, we see no quality improvement, but a big slowdown
        // with filtering, so ignore this call for now
        //
        //getPaint().setFilterBitmap(filter);
    }

    @Override
    public void inflate(Resources r, XmlPullParser parser, AttributeSet attrs)
            throws XmlPullParserException, IOException {
@@ -247,6 +255,8 @@ public class NinePatchDrawable extends Drawable {
    public Paint getPaint() {
        if (mPaint == null) {
            mPaint = new Paint();
            // dithering helps a lot, and is pretty cheap, so default on
            mPaint.setDither(true);
        }
        return mPaint;
    }