graphics - BlackBerry - How to resize and store image? -


I need to minimize the image and store that image in blackberry device (as a small image) is required?

Image is straightforward to scale, if image is packed, or network Or file system is also done

  public encoded image scale image (encoded image source, need is width, int required) ()); Int Required WidthFixed32 = Fixed 32.toFP (Required Width); Int scaleXFixed32 = fixed 32.div (current WidthFixed32, required WidthFixed32); Int presentHyphix 32 = Fixed 32.to FP (source.getHeight ()); Integer Required Hypothesis 32 = Fixed 32.to FP (Required Hight); Int scale wifix 32 = fixed 32.div (current whitefixed 32, expected hexfixed 32); Return source.scaleImage32 (scaleXFixed32, scaleYFixed32); }  

This gives a copy of the image, it is scaled according to width and height that you want.


Comments