Paint paint = new Paint(); paint.setFilterBitmap(true); // Enable bitmap filtering
Paint paint = new Paint(); paint.setFilterBitmap(false); // Disable bitmap filteringIn the first example, the Paint object is created and then the setFilterBitmap method is called with the argument true to enable bitmap filtering. In the second example, the same Paint object is used with the setFilterBitmap method called with the argument false to disable bitmap filtering. This method is part of the android.graphics package library.