Hi,

> You are resaving a JPEG. You'll be compressing twice.
>
> Why don't you try to directly save the data obtained from the URL to a
> file on the SDCard. Don't do any compressing. Just a direct save of
> the JPG file from Flickr.

Thanks for the suggestion!

However, saving the bitmap to a JPEG file was really just to
illustrate the pixelation problem - I assumed there would be no
quality loss with the quality parameter set to 100. What I'm actually
doing is to draw the bitmap downloaded from Flickr onto a canvas in
the onDraw method of my View class:

Paint paint = new Paint(Paint.ANTI_ALIAS_FLAG |
Paint.FILTER_BITMAP_FLAG);
canvas.drawBitmap(bitmap, 0, 0, paint);

Pixelation similar to that shown in my example pictures then occurs.
Any idea why this would be the case?

Note that bitmaps loaded from my project resources draw just fine
using this approach; although if I downscale using the
Bitmap.createScaledBitmap() method, a similar pixelation problem
occurs. This problem was discussed e.g. here:

http://stackoverflow.com/questions/2041207/android-quality-of-the-images-resized-in-runtime

but none of the suggested solutions seem to improve the situation in
my case.

Thanks again for your suggestions, I really hope there is a solution
to this issue.
Best,
Michael.

-- 
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

Reply via email to