tags:

views:

492

answers:

1

Hiya,

I am downloading a JPEG image from a server and assigning it to an image object in my iPhone app using an NSURLConnection.

All works fine when I'm on a Wifi connection, but as soon as I switch to 3G, the quality of the JPEG downloaded reduces dramatically.

Has anyone else experienced this?

Does anyone know of a way to force the iPhone to download the full quality JPEG?

Thanks in advance! Nick.

+6  A: 

If it's the 3G provider that compresses data on the fly I don't think you can do anything about it. Download the image with Safari via 3G -> if the image looks bad (and I expect it will) then it's the provider that compresses it.

To workaround this problem zip the image on the server and unzip it in the application -> this should bypass the compression on the 3G side.

diciu
Genius. Thanks so much diciu for this!Nick.
Nick Cartwright
PS: You're right - in Safari, the image looks terrible also!
Nick Cartwright