I've been looking at the source for several open-source image loaders, and am comparing the approaches. Looks like when processing the image data, most involve URL.openStream, but from there it looks like there are a couple different ways of decoding that stream to a Bitmap:
1. URL.openStream, then BitmapFactory.decodeStream 2. URL.openStream, then Drawable.createFromStream 3. URL.openConnection().getInputStream() then convert to byteArray, then BitmapFactory.decodeByteArray I see there's a slight difference between #2 and the others - you get a Drawable, but you don't get to specify decoding or sampling, so this seems less preferable (you can always wrap the bitmap in BitmapDrawable later, and inPreferredConfig can be critical). Anything else? What about the difference between #1 and #3 - is there any benefit to converting to a byteArray first, then decoding that? And as regards the first part - is there any difference between URL.openStream and URl.openConnection().getInputStream()? They both just return the same InputStream, no? TYIA. -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en

