Code example for Paint

Methods: setDithersetFilterBitmap

0
        init(); 
    } 
 
    private void init() { 
        setScaleType(ImageView.ScaleType.MATRIX);
        mPaint.setDither(true);
        mPaint.setFilterBitmap(true);
    } 
 
    protected float getValue(Matrix matrix, int whichValue) {
        matrix.getValues(mMatrixValues);
        return mMatrixValues[whichValue];
    } 
     
    // Get the scale factor out of the matrix. 
    protected float getScale(Matrix matrix) {
        return getValue(matrix, Matrix.MSCALE_X);
    } 
 
    protected float getScale() {