SkPaint paint; paint.setFilterBitmap(false); canvas->drawBitmap(bitmap, matrix, &paint);
SkPaint paint; paint.setFilterBitmap(true); canvas->drawBitmap(bitmap, matrix, &paint);In this example, we create a new SkPaint object and call setFilterBitmap with the value true. Then we use the canvas->drawBitmap method to draw a bitmap on the canvas with a matrix transformation. Because filtering is enabled, the bitmap will be drawn with interpolated edges, giving it a smoother appearance. These examples were written using the Skia library, which is typically included as part of the Google Android NDK for mobile development. However, Skia is also available as a standalone library for desktop applications.