Low performance when converting Blob to Bitmap

1

I'm using the following code:

BitmapFactory.Options options = new BitmapFactory.Options();
            options.inSampleSize = 4;
            bitmap = BitmapFactory.decodeStream(blob.getBinaryStream(), null, options);

The problem is that this is more time consuming than downloading the data itself! Is there a faster way to convert, or at least a 'BlobView'?

    
asked by anonymous 26.02.2016 / 15:53

1 answer

0

I do not know if it's faster, but I've always used this form:

 byte[] byteArray = cursor.getBlob(columIndex);
 Bitmap bm = BitmapFactory.decodeByteArray(byteArray, 0 ,byteArray.length);

And I've never had a problem with performance.

    
26.02.2016 / 16:44