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
Posts: 112
Registered: ‎09-23-2009
My Device: Not Specified

FASTJPEG: Progressive decoding is not supported

Hi All,

Anyone could describe what's the meaning of "FASTJPEG: Progressive decoding is not supported". This text is often written in my Eclipse console.

 

Thanks in advance. 

New Contributor
Posts: 3
Registered: ‎12-12-2010
My Device: Not Specified

Re: FASTJPEG: Progressive decoding is not supported

I also encountered the same problem and I don't know how to find a solution. Please post here if you found the right solution. Thanks!

Highlighted
Contributor
Posts: 11
Registered: ‎10-06-2010
My Device: 9550
My Carrier: mtn

Re: FASTJPEG: Progressive decoding is not supported

I sort of found a "Temporary" solution to the problem...Please let me know if it works for you. I believe the problem is as a result of JPEG support (the images that cause that error are most likely .jpg images)

 

First: following the steps in http://supportforums.blackberry.com/t5/Java-Development/How-to-resize-Bitmap-at-runtime/m-p/231262#M...

with a couple of tweaks...as below:

  • Bitmap _bmp = Bitmap.createBitmapFromBytes(data, 0, data.length, 1); //creates the bitmap first
  • PNGEncodedImage _png = PNGEncodedImage.encode(_bmp);//encode the bitmap as a PNGEncoded image
  • EncodedImage _imgEnc = (EncodedImage) _png;//
  • EncodedImage _imgEnc = EncodedImage.createEncodedImage(data, 0, data.length);//creates the image resource
  • EncodedImage _resizd = Constants.scaleImageToWidth(_imgEnc, 50);//resize the image to about 50px
  1. The first thing is to convert the byte array for the image "data" to a valid bitmap (or if you already have a bitmap resource skip this step)
  2. The second step is to then create a PNGEncodedImage from the bitmap resources (since PNG has more suport than JPEG)
  3. type cast it to an EncodedImage resource...then continue with the steps...

Good luck