Hi-res PNG file in ipad's safari - ipad

I have some asp.net site that shows png images that converted from hi-res tiff files.
The image is shown via simple img tag. The problem is that wneh png has a big resolution - it does not shown properly in ipad's safari browser, but the most of png files are ok.
What it can be?
Thank you

The iPad cannot display images with a w*h larger than 3*1024*1024 (3145728)
So if your image is 2048x2048 then w*h = 4194304 which is larger than 3145728.
Source: https://developer.apple.com/library/safari/documentation/AppleApplications/Reference/SafariWebContent/CreatingContentforSafarioniPhone/CreatingContentforSafarioniPhone.html#//apple_ref/doc/uid/TP40006482-SW15

Related

Bad quality on tabBarItem image

I am adding image for my tabBarItem
playerViewController.tabBarItem.image = UIImage(named: "Icon-Small")
"Icon-small" it's 29 × 29 PNG image
And when I'm running my app quality of this image in tabBarItem very low.
If I'm using 50x50 it's too big and also low quality.
All icons prepared from 512x512 PNG with Prepo Mac application.
Are you using 2x and 3x images? If not then try with it.
Another solution is to use .pdf file in vector format. It will stretch your image as needed.

PDF vector graphic smaller than the png at same size

I converted some SVG images into PDF and png files for my iOS app. When adding them to the UIImageView, the pdf images look smaller than the png equivalent. The scale type was set to center, so no scaling happens at runtime.
btw, the pdf and png look the same when I open them in preview and adobe reader
Anyone had same issue and got a solution for that?
When converting an SVG to PDF, make sure the DPI is set to 72. That way, the size will match with the PNG resource that you have. Xcode actually expects vector-based resources to be 1x in size.

Large sizes in iOS Universal apps due to a million images

Ok, I have a universal app, which means it has to have an iPhone non-retina launch image, retina image, and iPhone 5+ size retina image. It also has to have non-retina iPad launch for portrait and landscape, retina for portrait and landscape, and then alternate versions as well with slight changes to dimensions. For example, on iPad I have to have a 768 x 1024 and a 768 x 1004. With 8 images required just for the iPad launch image, the file size of my app is huge, as each iPad launch image is between 1.5MB and 5MB. Any suggestions for how I can keep the size down, since it is only high due to large launch images?
Here is what I mean by all the images required for iPad. 8 images???
What you can do to reduce the size greatly is provide jpeg images instead of png. Yeah, I know, Apple asks for png, but you can submit an app with jpg images (I did this for my iPad app).
Use Preview to open the images. save them as JPEGs with a really low quality - or experiment with the quality setting. You will be amazed at how nice a really compressed JPG image can look.
Oh, your launch time might increase by a few milliseconds due to Apple translating the jpg to png during launch.
My experience was submitting when iOS5 was out, so its possible that not using PNG will be a blocker with iOS7. However, I even have a solution if that is needed. Do as I suggest - save the images as highly compressed jpg images first. Then convert THOSE images to pngs - the jpg compression done first should make it easier for png to compress the those images, reducing the size.
There are several PNG "crushers" - programs to reduce PNG size - that work great. Just make sure that you unselect the option to have Xcode "reduce the PNG sizes" - since it actually increases their size!

Are there known issues with PNG and JPEG images generated on iOS?

I got the brilliant idea to generate the app store screen shots for my app from... and app! This works great, except for the fact that some of the PNG or JPEG images are not recognized as valid screen shots when I try to upload them. I checked with image viewer, and they have the required size, colorspace and pixel density.
Is there perhaps some strange issues with PNG and/or JPEG images generated on iOS?

iTunes connect does not accept my large app icon

I have submitted a large app icon to iTunes Connect that meets all the specifications: .png file, 1024x1024 pixels, etc. and yet I still get the
error:
"The large app icon you uploaded is not valid. It must be a .jpeg, .jpg, .tif, .tiff, or .png file that is 1024 x 1024 pixels, at least 72 DPI, and in the RGB color space."
I created it using Photoshop Elements. Any guidance is greatly appreciated.
Update - problem solved:
I have tried it again. It worked. Did not need to se exported as PNG or TIF and I am not sure exactly what was different this time (after 4 hours of trying), but it uploaded.
The command below is a hack to base-line PNG images and format them "them
Apple way". Use the following in command line (Terminal), changing "/path/to/image/folder/" to match the location of your PNG files:
sips --deleteColorManagementProperties /path/to/image/folder/*.png
Notice the part about the RGB color space in the requirements. Maybe your file was saved as CMYK originally?
This error may occur if you changed the extension of image by changing name (forcefully from image.jpg to image.png) and you have not exported image to that format.
Simply exporting the image to that format will resolve your issue. You can use 512x512 or 1024x1024 RGB color space image with 72dpi.
Save it with "Not Interlaced" option cos I think it doesn't accept Interlaced PNGs
For those who have noscript or else active. Allow apple.com or otherwise you will just get "Your file could not be loaded. Try again." over and over again.
I had the same problem, tried a lot of different image sizes 1024, 512, jpg, png... First they were all in wrong CMYK color mode. Then I tried jpg with RGB, did not work
and FINALLY:
.PNG 1024x1024px with color mode "RGB" worked
Your Icon File has to be saved with the configuration below:
size 1024 x 1024 pixel with resolution max 72 dpi
your image / picture has no alpha colour (uncheck the alpha checklist)
no transparency, no rounded corner
save in PNG or JPEG format

Resources