Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Java Development

Reply
Developer
zinzinzan
Posts: 90
Registered: ‎04-03-2012
My Device: 9100
Accepted Solution

Resize Bitmap and get background changed =/....

hi there i have a simple code for reize  a bitmap but, when i get the new resized Bitmap this one have a  black background ??? and i dont want it =/. here is the code.

public class ImageUtils {

	public static Bitmap resizeImage(Bitmap originalImage, int newWidth, int newHeight) {
 	    Bitmap newImage = new Bitmap(newWidth, newHeight);
 	    originalImage.scaleInto(newImage, Bitmap.FILTER_BILINEAR, Bitmap.SCALE_TO_FILL);
 	    return newImage;
 	}
}

 

Developer
peter_strange
Posts: 19,610
Registered: ‎07-14-2008
My Device: Not Specified

Re: Resize Bitmap and get background changed =/....

Developer
zinzinzan
Posts: 90
Registered: ‎04-03-2012
My Device: 9100

Re: Resize Bitmap and get background changed =/....

thx i implemented and work fine like magic :smileywink: