What should I consider to ensure seamless port of my iPhone apps to iPad? - iphone

Following iPad's announcement and its SDK (iPhone SDK 3.2), porting apps to iPad becomes an important issue. What guidelines I should follow in my iPhone apps to ensure I can port it to iPad as seamlessly as possible?
The different resolution is particularly an important issue. While the iPad runs iPhone apps unmodified, it's not really the desirable behavior for a native app. How can we make our iPhone apps resolution-independent so that they can run gracefully on all resolutions like most desktop apps?

If you've been using IB and setting the resize behaviors of elements properly, and also coding frame coordinates all relative to each other you are half-way to having a UI that can potentially scale to a larger screen.
From the screen shots there are new kinds of action-sheets as well, potentially attached to UI elements instead of floating - if you use overlays today they will probably work about the same but you may want to consider changing placement from the center on larger display.
UPDATE:
Now the event is over, and registered developers can download the SDK - although we cannot talk about specific features here just yet, read through ALL of the documents related to the new OS version as there are a number of things aimed at helping you transition to supporting both platforms. Also before you start using custom libraries for things take a look through the API changes to see what new abilities might be supported that are not today.
Generally speaking, what I said above about IB holds true, and also you should start thinking about how your apps today could use more space to present more information at once instead of being split out over multiple screens. Also if you are doing any projects right now that use images, make sure to initially design the images large enough that you can also use them for higher resolution tablet applications.

It is far more reasonable to expect users to input text (and larger amounts of it) than with a non-iPad device.

Nothing, it appears. Although we don't have the SDK quite yet. It will all existing run iPhone app without an issue, albeit at reduced resolution.
It remains to be seen how much of the existing iPhone SDK is shared with the iPad SDK UI wise.

Judging by what has been said, absolutely nothing. You will have to adapt to the new screen size and better hardware all together, if you want to take advantage of the features that the improved device offers. The lack of a 3g module is also something to consider if your app(s) rely on that functionality.

Related

Make iphone app ipad compatible

I have an iPhone/iPod app that I hired a contractor to make. Now I am asking same contractor to support iPad, and the contractor is quoting a ridiculously high price (the BD guy is). I think they know that since they have developed the app, they have some leverage and want to maximize their profit.
Some questions:
Is adding support for iPad mostly a UI job?
Is any coding needed except detecting device type?
Looking at their images/ folder, I can see that for every graphic, they have already made a "2x" version which is double in size. Could it be that they have already created the necessary artwork, as I have told them from the start that iPad support will likely follow the iPhone version?
If I were to use a different contractor now, as it is likely we will not come to a middle ground since we are so far apart in price, what are the things a different contractor would need to do the port?
In particular, I'm wondering if I need to fight to get the raw Photoshop files which contain the graphics, so they can be recreated for iPad, or will going by the eye be good enough? I personally don't mind if the artwork is slightly different.
This certainly makes me think twice about using contractors in the future.
Well here are some answer from my experience:
Yes mostly it just about changing the look of your app. But people are expecting a different user experience on the iPad, so not all view should be full screen for instance.
No most iPhone code will run fine on the iPad, if you are using stuff like UIImagePickerViewController then you need to change the way it is displayed.
NO the #x2 are for retina device NOT for iPad.
Source code and design would do I for me.
Having the original PSD would be nice, but you can do with out.
Just keep in mind that you just can scale up most applications and expect them to become fully excepted by users.
This really depends on the app but there are some differences for iphone and ipad.
Yes, it is mostly an UI job, and depending on screen content, porting one screen can be trivial (just checking if the autoresize functions do their job right), or though - making one from scratch. If your application has lots of complicated screens, I get why the price may be high.
Also - there are some differences in what controllers are available on each device, mostly the popovers or action sheets - that may require different code for each device.
As for the graphics - the 2x resources are actually for the retina capable devices (4th and 5th gen) - most people use them for the iPad too, but as the screen dimensions are not exactly the same, they get warped slightly. In most cases thats ok, but for really high quality, a separate set of graphics may be required.
Take these as generic answers, the complexity of the actual app may affect these answers quite a bit;
1) If the app isn't using any specific functionality on the iPhone that isn't always available on the iPad (GPS for example, or specific camera resolutions for image processing), then yes, it's mostly a UI job. That doesn't mean it's necessarily quick and easy, you may want to change the layout radically for the iPad (that, of course, is up to you though)
2) Most code except UI possibly related code mentioned above should not need much change. Exceptions if any are mostly related to different hardware on different models and depends on the complexity of the application.
3) 2x images are not for iPad, they're for the retina display on iPhone4 and later.
4) Almost impossible to answer without seeing the code or even the app, sorry. If it's a fairly simple application, everything needed should be contained in the XCode project.
5) Up to you, if you want a quick "fix" you may want to resize the 2x images from retina resolution to iPad resolution in Photoshop and use anti aliasing to make them look ok. Your judgement call though. Just check that your deal with the contractor does not give him all the rights to the artwork or you may get into trouble changing/reusing it.
It is. You'll require separate nibs for iPad UI, if you don't want different UI logic, so it's possible to use same view controllers.
View controllers will require logic branches if UI is different. It's mostly checks for user interface idiom though.
#2x versions are for retina display. They will be useful when iPad 3 with retina hits the shelves. Right now, low-res images will be enough for iPad UI.
Different contractor will require the complete code of your project along with all resources...
...so yes, get all the PSDs as well.
First off, I have well over a decade as a professional software engineer working for many clients both small and blue-chip, with broad experience of a variety languages/devices. With that said:
Please remember that the ipad version will need testing on ipad 1, ipad 2 and in a couple of weeks time on an ipad3. Testing takes time. The new version will also need to be tested again on all iphones too.
Also, you mention that this app is a game. The original code might have been coded in such a way as assuming certain screen resolution, and maybe even have hard-coded values throughout the code relating to screen positions etc. Particularly if the coder was not aware of a future ipad requirement. Also supporting ipad 3 might not be an insignificant task if it has x2 graphics depending upon original code and the game engine used (if there is one).
Some apps will cost the same to create an ipad version as the original iphone app.
If your original agreement didn't include IPR over the source you might have difficulty getting it. Some agencies and contractors default to providing source to clients, others charge extra for provision of the source.
Lastly, the contractor might have originally coded the iphone app at a loss, i.e. they might have quoted you and been paid for 3 days work when they actually spent 10 days on it. In which case they might be assuming the worst for the ipad version too.
There are a lot of questions to ask and be answered before you can say they are "trying to rob".

Stop using retina-only images

What will happen if I do the following:
I substitute all non-retina assets with the retina assets
I delete all retina assets in my project ( All the ...#2x.pngs etc.)
Why do I want to do this:
There will be less and less non-retina iPhones in the future (also due to minimal OS requirements etc.)
I get a lighter binary
I don't have so many "quasi-duplicate" files in my project which I have to maintain separately.
Now:
Will the iPhone 3GS scale down the image and display it properly (with a little bit of processing overhead of course)
Will a "retina-enabled" Phone be able to display the image properly even though it does no longer have the #2x suffix in the filename.
In 99% of cases this will work fine. However there are cases where images won't scale correctly (usually depending on the contentMode).
I worked with someone who did this exact thing and never noticed a problem, although I think it is terrible practice.
You will get a lighter binary, but you are asking the older devices (with less memory) to do more work. If you don't want to support these devices then don't, I think this is better than giving users a potentially broken app.
There are better ways to reduce the size of images in your app, reusing them wherever possible, stretching, tiling etc.
3GS and iPhone 4 will both display the image improperly.
The fact is 3GS won't scale down the image. So it won't display the image properly. iPhone 4 will scale the non-#2x image (scale it twice) so it won't display the image properly too.
Nothing will happen if you decide to do this. Older devices will try, but if you allow the device to even run your app, you will have quite a bit of work just to deal with the scaling issues. If you allow older devices to install your app, you will have to be prepared to get approved from Apple on older devices too. If the images don't work right on older devices, you won't get approved. You are also right that there are fewer and fewer retina displayed devices in service.
But... there are still quite a few non-retina devices still in service. Maintaining both is good for your users. Yes it adds a little extra heft to your binary, but with today's speeds on a variety of networks, that isn't the issue like it used to be.
While it is your right to choose which users to support, and there are many developers that share your sentiment, it is still up to you to decide which group of users you ultimately want to support. If you are fine drawing the line with retina displays, so be it.
I could finger-wag at you and tell you that you should support every single user, but I'm sure you've thought of that. If you are fine supporting retina devices only, go for it. If you are prepared to answer questions on why this one device is supported and another isn't, go for it. The good news is, no matter what you decide, you'll be right...eventually. Good luck.

Building an iOS app with Adobe Flex Builder - Performance Issues

I'm building an app for iOS with Adobe Flex builder and compiling it into an .ipa using Adobe's tools.
Through initial testing, I see that the end result isn't as rich as native code, nor is it as fast or smooth.
Without simply saying 'why dont you just use objective-c', are there any documentation as to the overhead to building an app this way?
Specifically, what kind of performance hit can you expect when using Adobe's platform instead?
Make sure you are using the latest AIR 3.0 SDK for iOS packaging. It is notably higher performance.
Consider best practices when developing your app:
http://www.adobe.com/devnet/flash/articles/optimize_content_ios.html
http://help.adobe.com/en_US/as3/mobile/flashplatform_optimizing_content.pdf
http://www.mikechambers.com/blog/files/presentations/fitc_amsterdam_2010/flash_iphone_fitc_2010.pdf
Blanket comparisons to native Objective-C is a wide topic, to which capability of Flash ubiquitous deployment to multiple platforms should also be considered if you're targeting Android and BlackBerry.
Perhaps citing specific issues of your implementation would help yield insight.
I too have been developing a Flash-based iOS app. My initial prototype was useless in an iPad 1. I had to look for ways to optimize. My second prototype is performing quite well. So here are some pointers.
1) Don't use timers. I had to write my own utility "FrameWorker" Singleton class to manage and delegate all my animations, or even delayed actions to a single enterFrame event. This alone will give you a huge speed boost.
2) Don't use many enterFrame events on different objects. As I said on point one, find a way to use a single enterFrame that you can add and remove processes to.
3) Avoid vectors as much as possible-use images. If you need to draw objects in the Flash IDE or via action script, use cacheAsBitmap = true.
4) Don't use visual objects that are much larger than the screen area. If you need to use large objects across the screen, then manage them off the display list and learn blitting techniques to draw to the screen ONLY the rect that will be display at that time. Lee Brimlow has a couple of good starter tutorials.
5) Be very disciplined about managing events. Make sure you always remove listeners that are not necessary anymore for instance.
6) Distribute your app's load to different frames. Don't do too many intensive things on a single frame.
If you follow these pointers your app will be as fast as any out there.

When and how can we start forgetting about non-retina display iPhones and iPod Touches?

Now more than one year passed since a retina display device appeared. Does anyone know some numbers how many users still suffer under the low-resolution devices? How long do they use their iPhones or iPods until they realize that a retina display is so much better?
I'm sick of having to create every graphic two times, trashing the binary with all these low-resolution files. I wonder if anyone has stopped supporting low resolution hardware without a big loss.
And: If I wanted to stop supporting low resolution devices, what kind of settings in the info.plist must I make? And what would happen if a low-res device still installs my retina-only app?
Why do people still use IE 6? or why do some people still have Windows XP? Simply b/c they can't afford new ones. Money is to blame. There is no simple answer as to when should you stop supporting certain technology. In the technology world you should usually wait for a big company (like Facebook) to stop supporting certain devices. Only those big sharks can force people to switch.
If you want your users to be happy and want your software to be great you should always support all available devices/versions if possible. Little work for you is a big benefit for your users.
In the end you don't have to do anything you don't want to. But your software will resemble it.
You can at least wait for Apple to stop providing iOS updates to low-resolution devices (i.e. iPhone 3G S) since it is capable of running iOS 5
Maybe its not possible right now as it isnt yet supported here.
But releasing your app with a iOS deployment target of iOS 4.2 may reduce the number of non-retina display users to a great extent.
And the main reason for users not switching to new devices is explained perfectly in the previous answer. :)

which features do you look forward to the most in iPhone SDK 3?

Which of the new features are you looking forward to the most in iPhone SDK 3.0?
Is it one of the main advertised six new things, or something smaller? Something in the "1,000 new APIs", perhaps?
Phone to phone communication via bluetooth seems like it will terribly useful for some apps I am writing. No longer do you have to input all the data you want to store yourself, you can share some of it with other iPhone users.
not really a feature, but the best thing about developing the iPhone SDK further is the great frameworks that arise. there are some really, really great frameworks out there already (like the Three20 project) which will become even better with the new 3.0 SDK.
my real excitement will take over once they let us run background processes. maybe in 4.0?
Video! The ability to write decent tools for mobile video uploads is a big draw.
MapKit by far will bring the biggest change sweeping across the app space.
My personal favorite is that we can finally easily track upload progress of large files (like images).
I really, really want to see fixes in the camera API so that it isn't either broken (2.2.1) or forcing a switch to portrait (3.0).
Apart from that, the most useful features to me are:
push notifications. Great for making an app more sticky - you can let the user know that something of interest to them has happened.
CoreData - I've been using a third-party SQL layer, but it's a little buggy and no longer supported.
Peer-peer bluetooth, as the poster above said, is also useful for local data exchange.
And the least useful? Cut and paste. I actually want to disable it in my app (to discourage people from copying content) - and it doesn't look as though you can (yet).
Bluetooth phone-to-phone communication with GameKit will enable a host of currently impossible applications. Multiplayer games with no WiFi network needed and data exchange between two phones are obvious use-cases.
I'd also like to see - not currently included in the betas - a decent camera API that allowed us to customize the appearance of the capture screen, and as another poster said, have it work properly in landscape and portrait mode.