Advertise Books Events Forum News Social Networking Support Us

sdkIQ for iPhone
($4.99)

Shape Up
($0.99)

Your First iPhone App
($1.99)

iVidCam Free
(free)

Kid Art
($0.99)

iPUBQUIZ
(£1.19)

ArtStudio
($3.99)

Want your application or service advertised on iPhone Dev SDK?

Go Back   iPhone Dev SDK Forum > iPhone SDK Development Forums > iPhone SDK Development

Reply
 
LinkBack Thread Tools Display Modes
Old 04-23-2009, 10:50 PM   #1 (permalink)
Registered Member
 
Join Date: Apr 2009
Posts: 46
Default Image getting blured in iphone and not in ipod

hi,

i am sending image from myapplication.
when i send it through ipod it is getting send as it is.
but when i send it through iphone it is getting blurred

i am using .jpg image of dimensions 320*460

plz kindly help me if anyone have idea about it.

thanks in advance.

Last edited by smsawant; 04-24-2009 at 02:04 AM.
smsawant is offline   Reply With Quote
Old 04-24-2009, 01:01 AM   #2 (permalink)
New Member
 
Join Date: Jan 2009
Location: San Diego, CA
Posts: 405
Default

You could start by telling us what file format, size, etc.
jtara is offline   Reply With Quote
Old 04-24-2009, 01:54 AM   #3 (permalink)
Registered Member
 
Join Date: Apr 2009
Posts: 46
Default problem with image in iphone

Quote:
Originally Posted by jtara View Post
You could start by telling us what file format, size, etc.
i am using .jpg image of dimensions 320*460
smsawant is offline   Reply With Quote
Old 04-24-2009, 04:19 AM   #4 (permalink)
New Member
 
Join Date: Apr 2009
Posts: 12
Default

Help please!
Negativi is offline   Reply With Quote
Old 04-24-2009, 11:54 AM   #5 (permalink)
Registered Member
 
Join Date: Jan 2009
Location: Atlanta
Posts: 368
Default

By blurred, do you mean sent in a lower quality?
funkytaco is offline   Reply With Quote
Old 04-24-2009, 12:22 PM   #6 (permalink)
wdn
Registered Member
 
Join Date: Sep 2008
Posts: 28
Default

Is the status bar hidden on the iPhone for some reason? It may be trying to scale the image from 460 to 480 pixels. Also make sure you round your rects to integral values to avoid fuzzy images.
wdn is offline   Reply With Quote
Old 04-25-2009, 11:40 AM   #7 (permalink)
Registered Member
 
Join Date: Apr 2009
Posts: 46
Default Problem with image

Quote:
Originally Posted by funkytaco View Post
By blurred, do you mean sent in a lower quality?
i m taking screenshot of image and then send it.
image is getting blur when i send it through iphone
but when i send it through ipod - touch
image is ok.

plz reply if anyone got a same problem.
smsawant is offline   Reply With Quote
Old 04-25-2009, 01:36 PM   #8 (permalink)
New Member
 
Join Date: Jan 2009
Location: San Diego, CA
Posts: 405
Default

My screenshots are clear.

You need to be more clear and specific if you want to get help here. "It doesn't work" isn't going to get you much useful response. I still do not know just what you are doing. You said you are sending an image from your application. Then you said you are taking a screen shot. Which is it?

Have you examined the images your received? What pixel dimensions are they? How many bytes are they? Look at them in an image editor, view properties and see what is different. Zoom in and try to identify what is wrong. If the issue is JPEG compression, you should be able to identify the JPEG artifacts and see how they are different in the two cases.

If you need screenshots for the app store or your web site, this is a case of "doctor, doctor":

Patient: "Doctor, doctor, it hurts when I do this!"

Doctor: "So, stop doing that!"

Take your screen shots on the iPod Touch. Problem solved.

Better yet, take them in Organizer, because they will then be PNGs. You really don't want to be using JPEGs for the app store.

One possibility might be that image quality settings differ between the two devices, but I don't see any settings for that. Then again, you also don't say what version of the OS you are using. Perhaps you are running 3.0, and there are settings for screenshot JPEG quality in 3.0?
jtara is offline   Reply With Quote
Old 04-25-2009, 03:04 PM   #9 (permalink)
Registered Member
 
Join Date: Dec 2008
Posts: 143
Default

Quote:
Originally Posted by jtara View Post
You really don't want to be using JPEGs for the app store.
Actually, the App Store only accepts JPEGs or TIFFs, and not PNGs.
ambiensignal is offline   Reply With Quote
Old 04-25-2009, 03:52 PM   #10 (permalink)
New Member
 
Join Date: Jan 2009
Location: San Diego, CA
Posts: 405
Default

Quote:
Originally Posted by ambiensignal View Post
Actually, the App Store only accepts JPEGs or TIFFs, and not PNGs.
You can convert the PNGs to TIFFs, without loss.

JPEG is lossy, and will have nasty artifacts. It doesn't make sense to convert a JPG to a TIFF.

So, start with a PNG, which has only lossless compression, and convert to TIFF, which is also lossless.
jtara is offline   Reply With Quote
Old 04-25-2009, 04:12 PM   #11 (permalink)
Registered Member
 
Join Date: Dec 2008
Posts: 143
Default

Quote:
Originally Posted by jtara View Post
You can convert the PNGs to TIFFs, without loss.

JPEG is lossy, and will have nasty artifacts. It doesn't make sense to convert a JPG to a TIFF.

So, start with a PNG, which has only lossless compression, and convert to TIFF, which is also lossless.
...you can submit the JPG, no conversion needed.
ambiensignal is offline   Reply With Quote
Old 04-25-2009, 04:35 PM   #12 (permalink)
New Member
 
Join Date: Jan 2009
Location: San Diego, CA
Posts: 405
Default

Quote:
...you can submit the JPG, no conversion needed.
You CAN, but it's better if you don't. Why send an inferior image?

Apple may resize/convert for the App Store. They may change their mind about size/format in the future. Give them a full, lossless image to work with. You are going to lose quality starting with lossy compression like JPEG.

Take a screenshot on the iPhone and email it to yourself. Take a screenshot with Organizer. Zoom in on each one. Which one do you want to send to Apple?
jtara is offline   Reply With Quote
Old 04-25-2009, 08:34 PM   #13 (permalink)
Registered Member
 
Join Date: Dec 2008
Posts: 143
Default

Quote:
Originally Posted by jtara View Post
You CAN, but it's better if you don't. Why send an inferior image?
Okay, there's something you clearly don't understand.
You take a picture, starting in JPEG (an "inferior image").
You take a picture, starting in PNG, then convert it to JPEG (an "inferior image").

Same thing.

No one cares if PNG has lossless compression because you aren't sending that to Apple. You're sending the "converted version", which would give you a JPEG representation, which, according to you, has lossy compression. Or you send the JPEG representation, which according to you, has lossy compression.

You're sending lossy compression either way.

Quote:
Originally Posted by jtara View Post
Give them a full, lossless image to work with. ... Take a screenshot on the iPhone and email it to yourself. Take a screenshot with Organizer. Zoom in on each one. Which one do you want to send to Apple?
Oh, definitely I'd send the PNG, it's much better and we can all agree on that. TOO BAD YOU CAN'T SEND THAT VERSION TO APPLE.
ambiensignal is offline   Reply With Quote
Old 04-25-2009, 09:20 PM   #14 (permalink)
New Member
 
Join Date: Jan 2009
Location: San Diego, CA
Posts: 405
Default

Quote:
No one cares if PNG has lossless compression because you aren't sending that to Apple. You're sending the "converted version", which would give you a JPEG representation
Maybe YOU are sending them JPEG. I am sending the TIFF. They take either JPEG or TIFF.

TIFF is lossless. You're conveniently skipping over that part.

I reiterate: since they take two formats, one lossy, one lossless, why on earth would you send them the lossy format, given a choice? Since we do have a choice, I'll send them the lossless version, thank you!

Last edited by jtara; 04-25-2009 at 09:23 PM.
jtara is offline   Reply With Quote
Old 04-25-2009, 09:26 PM   #15 (permalink)
Registered Member
 
Join Date: Dec 2008
Posts: 143
Default

Oops, I just checked iTunes Connect. They seem to take PNG's now too. Wasn't there before
ambiensignal is offline   Reply With Quote
Old 04-25-2009, 10:03 PM   #16 (permalink)
Tutorial Author
 
Join Date: Jan 2009
Posts: 142
Default

Since the ipod uses wifi, the image isn't compressed. Otherwise, when you send data, the iPhone automatically compresses it to optimize speed. It's annoying. Try zipping the file, sending it, and then unzipping it on the server side.
meowmix23F is offline   Reply With Quote
Old 04-25-2009, 11:32 PM   #17 (permalink)
New Member
 
Join Date: Jan 2009
Location: San Diego, CA
Posts: 405
Default

Quote:
Since the ipod uses wifi, the image isn't compressed. Otherwise, when you send data, the iPhone automatically compresses it to optimize speed
Aha! Mystery solved!

It's interesting that the iPhone doesn't send it uncompressed when on WiFi. I know this to be the case, because I sent myself a test screenshot while on WiFi. I wasn't really thinking about WiFi as a factor at the time, though. (Unless it just uses different levels of JPEG compression? I am assuming the Touch sends PNG, and the iPhone sends JPEG? I don't have a Touch, so dunno.)

I assume the OP is just taking a screenshot by pressing the home and wake buttons, so he doesn't have the option of Zipping it. Or can an app take a screenshot?

I don't think zipping it will help with size. (The OP wasn't complaining about size, anyway - just the difference in quality between the two devices.) The PNG is already losslessly compressed, and it uses an algorithm optimized for images. I doubt that Zip would compress it further. If anything, it is likely to grow ever so slightly.
jtara is offline   Reply With Quote
Old 04-25-2009, 11:39 PM   #18 (permalink)
Tutorial Author
 
Join Date: Jan 2009
Posts: 142
Default

Zipping it and unzipping it is so that the iphone is tricked into thinking your data *isnt* an image, when in fact it is, so that it doesn't compress it for you (and therefore lessen the quality of the image)
meowmix23F is offline   Reply With Quote
Old 04-26-2009, 04:34 AM   #19 (permalink)
New Member
 
Join Date: Jan 2009
Location: San Diego, CA
Posts: 405
Default

Quote:
Originally Posted by meowmix23F View Post
Zipping it and unzipping it is so that the iphone is tricked into thinking your data *isnt* an image, when in fact it is, so that it doesn't compress it for you (and therefore lessen the quality of the image)
I wouldn't think that it's compressed during transmission, but when it's taken.

And, again, if we are talking about screen shots taken by pressing home and wake, (or whatever the button on top is called...), your app has no control over that anyway - there's no way you could zip it.

I'd be VERY surprised if it would change any data that an application sends.
jtara is offline   Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Enter the iPhone App Challenge!  Win $500!
» Advertisements
» Stats
Members: 24,224
Threads: 39,002
Posts: 171,077
Top Poster: smasher (2,570)
Welcome to our newest member, SpeJohn613
Powered by vBadvanced CMPS v3.1.0

All times are GMT -5. The time now is 11:32 PM.
Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0