Created
October 30, 2014 14:02
-
-
Save jibbo/20faef467837746bdb89 to your computer and use it in GitHub Desktop.
How to set a Painter to erase content on a canvas.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Paint e = new Paint(); | |
e.setColor(Color.TRANSPARENT); | |
e.setAlpha(0); | |
e.setAntiAlias(true); | |
e.setXfermode(new PorterDuffXfermode(PorterDuff.Mode.CLEAR)); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment