Photoshop png background shows layered in iPhone simulator - uiimageview

I created a gradient png in Photoshop CS6 which looks perfect on my windows box.
[I have mac as remote box so photo-editing is time-costly option on that box]
However as I put it on my development mac, I see so many layers unseen before.
It doesn't look pixelated, but it is not good for sure.
The image looks like Saturn Rings, with layers of gradient putting the beauty at stake.
It looks ugly.
It is sized 320X640, with 326 ppi.
I also made #2x (640X960) for ratina, but with same result.
[I also tried some of already available online backgrounds, but they all look same. Eventually, I want my own background as it has logo and everything placed as I wish]
What do I do?
(I have tried XCode IB View modes options (redraw, aspect fit etc. the whole list) already - and I am directly setting it in IB and from then on itself its ugly, so please do not ask how am I invoking it in XCode. Its equally ugly on mac Core Image Fun House software preview as well.)

Related

Are specific PNG compression types incompatible with macOS Cocoa apps?

We’ve had a recent issue with some asset images, where the Retina #2x version was being used on non-Retina devices. The Retina and non-Retina versions of the assets exist. We’ve tracked the problem down to compression, so we’re able avoid it for now, but if anyone has additional insights, I’d love to hear them.
The icons on the left show how they’re rendering inside the running app. The Retina assets are being used on a non-Retina screen, so they’re being scaled down to 50%, which is causing some blurry edges.
The icons on the right are the original assets.
This is only happening to some assets. Most of the app is okay. We’ve been using ImageOptim to compress the PNGs used in the app. ImageOptim is using a variety of compression combinations for the assets. These are the common best results:
PNGOUT
PNGOUT+AdvPNG
PNGOUT+Zopfli
AdvPNG+Zopfli
The assets that have problems all seem to be using PNGOUT+Zopfli, but not all assets with PNGOUT+Zopfli are bad. I am not 100% confident with this diagnosis though.
Given that the issue isn’t always easy to spot, and given I don’t know exactly what’s wrong, we’ve unfortunately decided to not compress our new PNGs used in Mac apps. This is a shame, because the space savings are good.
We’ve tried a few different Xcode project settings, including turning Combine High Resolution Artwork on and off.
I’d like some answers, but I am also posting here so there’s some information that may help others with this issue, even if I only have a partial solution.
Have you seen this issue before?
If you have seen it, do you have a solution?
By default, NSImage representations are chosen using color type and resolution [1]. In case of PNG files, there are situations when a more generic color type gives a smaller file. This is what causes the mixed color types between representations.
You need to set prefersColorMatch to NO. There are User Defined Runtime Attributes to do it without leaving Interface Builder. This will fix the issue.
How to set prefersColorMatch in Interface Builder
More information about the bug can be found here:
OS X doesn't like mixed types of PNGs.
Retina version of an image always used on non-retina display
It looks like there is no solution, except to force the same color_type for the PNG pairs.

iPhone 6(s) plus not scaling new application correctly for some users

I have a brand new Swift 2.0 XCode 7 Storyboard based application.
Target is set to 9.2. I'm currently supporting any device with GPS that can run ios 9.2
I started with the Tabbed View Template and I'm working in wAny and hAny and a single Storyboard.
It works fine in the simulator on a bunch of phones, both orientations and works fine on my 6s plus, 6s, 6 plus and a 5.
But for some users the scaling is wrong and everything comes out squished.
Even in landscape mode the TabBar Icons are very close to each other.
Narrower than even on my 6s plus in portrait.
I believe this is caused by my application not having a Launch bitmap.
My understanding is there are two ways to implement this.
Launcher .XIB/.NIB with half a dozen specific sized bitmaps attached. Or a StoryBoard Launcher with ... exactly what.
The "Or StoryBoard" is a little vague. But I wanted to keep things using the modern approach since this app is new and targeted users tend to have the latest device.
So I created my Launch Image set and tried to attached it to the UIImageView in the Launcher StoryBoard. It won't list items that are tagged as "Launcher Image Set". It will show other Image Sets and Icons. But not the ones specifically for Launcher. It shows an "L" in the xcassets list next to the Launcher Image set. I believe I have the build project setting set correctly and it looks perfect on many of the same exact devices.
After some digging, I read that if you use the "StoryBoard" method you don't need the 6 or so bitmaps anymore. You can put anything in the Storyboard Launcher View and treat it just like you would treat your main storyboard.
So I did that. I just centered a small image.png file in the View of the Launchers Storyboard. Works on all simulations and my iPhone 6s plus. I did not pin it to the edges because that would mess up the aspect ratio of the image.
A very small set of users still have the issue and one of them even uninstalled and reinstalled.
I tried playing with setting phone Zoomed, Normal, Text Size, Bold etc. They all work. Users also don't have anything out of the ordinary on these system settings.
So first, do I need the 6 proper sized bitmaps or not? I read conflicting info on this.
If I want to use the 6 images on a storyboard how to I get them in the UIImageView of the Launcher StoryBoard if they won't list? Should I put them in a regular image set. Does the "Launcher Image Set" only work for the for the Launcher.XIB?
If it's not the Launcher window, what else could it be causing this?
I know I could create a XIB/NIB with the 6 bitmaps. But that seems like I'm going backwards and I don't care about old OS versions or older phones.
I think I found my answer. When using a Storyboard Launcher you cannot use a "Launch Image Set" for your Launcher Storyboard. You have to use an Image Set.
This is the best Video I found that covers it A-Z.
https://www.youtube.com/watch?v=Vz6tCgXgZFo
It also didn't fix my initial problem. Which I'll post separately. It scales correct in Portrait but not in Landscape for hand full of users. Using the same hardware as others that it works fine on.

Icon with no transparent pixels gets funny tint in Mac's Finder

Is there any special requirement for icons used by Mac applications that such icons should have transparent pixels in the top-left corner or some other place?
I'm currently trying to prepare a Mac build of a Unity3D-based game and noticed that if the icon of the game is a full-bleed square with NO transparent pixels, it gets some funny green-red-yellow tint when shown in Finder in small size (when viewed in List, Columns or Cover Flow). The icon is displayed fine on Desktop or if the folder is viewed in "as Icons" mode.
If the icon has a transparent frame, no such problem happens. I don't know anything about Mac development and neither googling or searching here brought up anything helpful, but sorry if this is really a basic question. Is it maybe a bug of Finder on Mac? I have 10.7.5 and Mid-2012 13' MacBook Pro.
The issue happens with this icon:
But doesn't happen with this icon:
Make sure the texture you're using as the icon in Unity is set to "Automatic Truecolor." You could be getting artifacts from whatever texture compression you're using on the texture.

Weird anomaly of a graphic being with different color on one computer, but ok in another

Me and my colleague are facing a weird anomaly of one little graphic being purple in his computer and blue in mine. The file itself seems to okay and we have re-created it from PSD several times.
You would say that, the problem is local in his computer. However, our computers are fairly similar and there has never been this issue before. Also, if he checks the source-file its ok, meaning blue. His computer had a fresh install of Win7 and clean photoshop.
What could be the problem and what can we try to solve it?
More information:
He is using FF5. The image is in PNG format. There are no js related scripts, to alter any of the images.
Direct link
Live example
(In the image we are talking about the little arrow, that is purple in one image)
From my point of view:
From his point of view:
NOTE: I personally think the issue is local in his computer. But he of course doesn't accept this answer. So if it is local, then somebody could explain, how does it happen.
Your issue could be due to gamma correction and color correction for PNGs. Ran into a similar issue myself with PNGs a couple weeks ago. A PNG would display with the correct colors in one browser, and with different colors in another browser on the same computer.
See this stackoverflow question as well for more info: Firefox 3.5 color correction hack?
EDIT
I definitely think this is a color correction issue, take a look at the images in two different browsers (chrome 13 and firefox5) on my machine. The image in Firefox is displaying with different colors than the one in Chrome.
Check the color settings on your monitors. If you're using different color temperature (Kelvin) settings, or your RGB settings are non-default and different, or if your monitors are different makes/vintages, you might see things display in "different" colors.

iphone 4 - Application doesn't show image?

I've had this app on app store with no problem until iphone 4 came out.
My home page has an image covering the whole screen.
UIImageView added in interface builder, and image path added in interface builder.
In all phones this image shows up; however, the image does not show up in any iphone 4, and instead the user sees a blank screen like the following:
Anybody knows what's causing this? thanks
.
I only have 1 set of images with
normal resolution
This problem only happens to one of
the images in my application which is
the background for my home page
the graphic file should not be
corrupted because the exact same
image works for all other iphones and
itouches
my image is a jpg file
image size is 480x270, which in
interface builder i make it 563x330 to display only a part of it
I have no outlet to this uiimageview
so it cannot be changed in code
With devices with the new retina display, pixel sizes are different and you have to check for the following, in particular:
Do you provide two alternatives of the image, one at old resolution, one at double resolution (named myimage.png and myimage#2x.png)
If not, does your image scale up well in size with CoreGraphics's algorithms (there are some pathological cases, though you'd have to be quite unlucky)?
Have you checked what happens (at both resolutions) when your UIImageView size changes?
Is it just one image, or all?
Is your graphics file corrupted?
It's hard to tell if it's any of these points, or something else, because you provide so damn little detail, that I stick to generic things. Comment below (or edit your question) if you need more help.
I've got two things to add to FXs thorough answer:
Considering the information you added, I would take a look at your code for setting up that UIImageView. Perhaps you use some sort of detection code or something which wasn't implemented correctly.
Would you mind sharing some code snippets?
According to Apple's documentation, you don't need to provide the ".png" extension as of iOS 4. Perhaps that is causing the problem.
Again, code snippets would help here. Specifically where you deal with loading up your image file.
EDIT:
Try re-saving the image and replacing it. I've occasionally corrupted files in Photoshop. This has to do with file extensions and how Mac OS ignores them, but Photoshop still uses them.
Also, it could have to do with where the image is in your XCode project. Check what Group it is in. Make sure everything is in place and then Clean and Rebuild. Remove the app from the iPhone4 (reboot) and try reinstalling.
I hope this helps.
Good luck!
If this was my code, I'd write a tiny app just to display the image in question. If it still fails it would be easier to get help debugging the problem.

Resources