Android code to crop/trim transparent border of a bitmap, returning a rectangle cropped image.
Work fast in my tests. The results are like the images bellow:
BEFORE | AFTER |
---|---|
##How to use
Bitmap bmp = BitmapFactory.decodeResource(getResources(), R.drawable.your_img);
CropTransparent ct = new CropTransparent();
imageView.setImageBitmap(ct.crop(bmp));
Easy to use, just add this class into your project and go ahead.
##Developed By Álvaro Menezes - alvaromenezes.inf@gmail.com
##License
FREE! Use as you like ;)