I'm creating a new empty transparent Bitmap
and making some modifications to it.
Is there a way to clean up this (make transparent and empty again) without creating new instance of Bitmap
?
UPDATE: Thanks for your help. I have found answer.
// Fills the bitmap's pixels with the specified Color.
bitmap.eraseColor(somecolor);
Try this:
myBitmap.eraseColor(android.graphics.Color.TRANSPARENT);
The constant int value of TRANSPARENT is 0x00000000.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With