blackberry java backgroung image resize -
how automatically set size of image ?(for different screen size of different phone's)
bitmap bitmaporig = bitmap.getbitmapresource("icon.png"); // create bitmap of arbitrary size int scaledx = 360; int scaledy = 415; bitmap bitmapscaled = new bitmap(scaledx, scaledy); bitmaporig.scaleinto(bitmapscaled , bitmap.filter_lanczos); bitmaporig.scaleinto(bitmapscaled , bitmap.filter_bilinear, bitmap.scale_to_fill); bitmapfield bitmapfieldscaled2 = new bitmapfield(bitmapscaled , field.focusable);
check these links:
Comments
Post a Comment