Now that you understand how to create completely custom views, it is helpful to understand some advanced drawing techniques. This chapter will show different methods of image compositing using a custom view as well as a method for using a custom
Shader to change the shape of an image by using a custom
Drawable. Both the image compositing techniques and the
Shader techniques can be used in your own views,
Drawables, and even custom utility classes to achieve effects that aren’t readily supported by Android’s default classes.
Behind the scenes, Android is using Skia, an excellent 2D C++ graphics library. Most of the drawing-related code you use in Android directly ...