Aug 2, 2011

Getting started with iOS development

So... In the last couple of weeks, I've been researching iOS development - reading some blogs, going to some lectures or watching them on iTunes U, searching for answers to common questions on stackoverflow, etc.
This doesn't make me an expert on the subject, but I think if like me - you're thinking about starting with iOS development or mobile development in general, this post might save you some time and make sure you're not missing any of the important technologies available today (August 2011), and the information you need to know in order to get started.

Before You Start...

Do I have to own a Mac in order to develop for iOS?


  • In a word: YES.
  • There might be frameworks that will let you develop the applications without a Mac, but when you'll want to deploy on a real device, or to the app-store, you're going to need a Mac for that.
  • Even if you succeeded in creating a Hackintosh on a VM (I personally had a really hard time trying to do so...), it is not recommended - as you are going to have troubles once you'll need to update your software/OS version, etc.
  • I tried to find online solutions for "Mac for rent", and found macincloud.com, but 2 days after sending a request for a trial they announced they closed the site for new users.



Does it cost me money to develop iOS applications?


  • The iOS Developer Program costs 99$/year. It lets you have the development environment for free, and the ability to install your apps on up to 100 personal device, and deploying them to the App Store.
  • You can however, obtain xCode (the development environment) for 5$ in the Mac App Store, or get the 4.1 version comes free if you have OS X Lion. This will let you develop apps freely, and test them on the iPhone/iPad simulators. If you'd like to test them on a real device as well without paying the 99$, you'll have to jailbreak it first (which is a big No No if you're planning on deploying it to the App Store in the future).
I'm considering deploying my app to android or other platforms as well.
What kind of options do I have?



  • Well, it seems as if the most popular choice is simply to re-write your app for the other platforms using the platform's native framework + SDK. This might sound surprising, but understandable once you think about the downsides of the cross-platform solutions available today.
  • Notice that because both Java (Android) and Objective-C (iOS) can integrate with C/C++ code, writing at least some layers of your application in C/C++ will make it easier to port it to other platforms.
  • This is also true about web applications. Nowadays, all smartphones and tablets have the capability of displaying web content such as HTML5/CSS3/Javascript. Therefore, writing your app as a web application or at least having a web container that runs web content as part of your native app, will make it available for other platforms freely, or at a very low cost. There are also some frameworks that will facilitate your efforts writing such apps, that will be discussed later on this post.
  • Even though there are some downsides, there is a variety of available frameworks for developing cross-platform apps, and I'm going to discuss all the notable ones later on this post.
So, what are the downsides of using a cross-platform solution?
  • Native Features: Most of the available cross-platform solutions won't let you access all the native features of the hardware. For instance, if you want to record real-time data from your microphone or camera, you'll have to write native code that does it, even if your basic framework is cross-platform.
  • Performance: Like cross-platform solutions on the PC, a cross-platform solution in mobile devices comes with a performance overhead, some more than others.
  • User Experience: Your UI will fail to address the special look-and-feel and the specific features of a given platform, like the 4 physical buttons that exist in Android vs. the single home button in iPhone, which will surely feel awkward to the user.
Why iOS and not Android?


  • While following smule, a great music-related iOS app developers, I found an interesting post they shared about why they don't develop applications to Android:
    http://tech.fortune.cnn.com/2011/05/27/why-its-harder-to-make-money-on-android-than-on-apples-ios/
  • Another thing they claimed, is that it's impossible to do real-time audio processing in Android due to high latency: "right now if you create an app for android that just routes the audio from the microphone to the speaker, there will be a noticeable delay, even on the devices with fast processors. This is a problem because if you want to make an app like 'I Am T-Pain' then it becomes impossible from a user experience standpoint to do live vocal processing. Put another way, hearing your voice come out of the speaker delayed creates a user experience that is not on par with that which we've been able to create on iOS. - this is a major problem if -- like I do -- you want to include real-time audio processing in your applications.
  • On the other hand, it seems that the majority of the mobile devices in the market is soon going to be Android's: http://www.mofonu.com/2011/07/15/android-devices-130-million-and-growing-%E2%80%93-550000-devices-activated-everyday/
Native iOS Development Technologies

Some useful links to get you started
Objective-C
  • An additional layer to C that introduces objects
  • Syntax is ugly (smalltalk like), but not something you can't get used to
  • Memory management is better than C, but you still need to be very aware, unlike modern languages. However, iOS 5 will support Automatic Reference Counting (ARC), so this should alleviate the pain. (See http://developer.apple.com/technologies/ios5/)
  • Has some very features of modern languages, like automatic getters&setters, nil objects that do not causes a crash if referenced, and dynamic language features - altering existing classes, invoking methods dynamically, etc.
  • The iPhone SDK and all APIs are written in Objective-C (Including the UI layers), and as said before - you are probably going to write at least one layer of your application in it, so you definitely should learn Objective-C if you are planning on developing for iOS.
  • A GREAT summary about Objective-C's basics: http://www.otierney.net/objective-c.html
IDE (xCode)


  • Basically, it's like VisualStudio for iPhone applications. Seems like a decent tool - autocompletion works very nicely, and there are built-in UnitTests support which is great (no green bar though...)
  • Comes with a set of tools, like the iPhone simulator which is a very good way to feel how your app is going to appear on the device without actually deploying it, and other important tools like a profiler, a memory debugger, etc.
  • Will take some time to adjust to, and from first look - it's powerful, but lacks some advanced refactoring features IDEs like Eclipse have.
  • I heard some that claimed that even if you develop in other IDEs, you'll still have to compile them eventually in xCode before submitting to Apple. However, I guess this was true prior to a change in Apple's policy regarding development tools, in September 2010.
  • One prominent alternative for xCode is Appcode by JetBrains (IntelliJ dudes): http://www.jetbrains.com/objc/ - haven't thoroughly checked it out yet, so no review.
OpenGL ES


  • Official website: http://www.khronos.org/opengles/
  • OpenGL ES is a subset of the OpenGL 3D graphics API, designed for embedded devices, including mobile phones. A subset - meaning some of the features of OpenGL such as floating point operations might not be available, and you'll have to replace them with alternatives if you're planning on porting an existing desktop OpenGL application.
  • The upside of developing in OpenGL ES, besides being a strong and popular 3D graphics engine, is that it supports many platforms. Implementations always have a platform-specific part, and the OpenGL API which is the same on all platforms for a specific OpenGL API version (which unfortunately may differ between the Android SDK and the iOS SDK). So while your code won't be 100% cross-platform, it should be easily portable, especially if you create proper abstractions between the platform-specific and non platform-specific part.
  • A great set of OpenGL ES tutorials for iPhone can be found at http://iphonedevelopment.blogspot.com/2009/05/opengl-es-from-ground-up-table-of.html
Cocos2D


  • Link: http://www.cocos2d-iphone.org/
  • An open source objective-C based framework for easily developing 2D games for iOS and Mac. Based on OpenGL ES.
  • Contains nice features such as scene managements, menus and buttons, tile map support, high score server, and many more.
  • Very popular - has a large community and lots of cool games created with the framework.
  • The tutorial in the official site seems very effective, and there are lots of other books and tutorials out there.
Cross-Platform Solutions

Web Based Cross-Platform Solutions


  • There are a lot of platforms that let you develop native apps in html5/javascript/etc.
  • This is a good solution for developers who already experienced in web, and do not wish to learn objective-c or other similar technologies.
  • On the other hand, although some of these frameworks allow you access to the hardware of the devices, it is limited in comparison to real native apps. Also, there are major performance limitations, and of course there's the native look-and-feel issue I mentioned earlier.
  • The most popular examples of such frameworks are: PhoneGap and Appcelerator Titanium. I must admit my research less focused on them so I can't really say how they are, but I do know they are popular and has a large community, and on the other hand - they have the known limitations mentioned earlier.
  • To sum it up, here's a nice presentation by Onavo about the dilema of Native apps vs. Web Apps:  http://www.slideshare.net/onavo/advanced-ios-engineering-the-junction-talk
Rhodes Rhomobile


  • Link: http://rhomobile.com/
  • A bit similar to the rest of the web-based cross platforms solution, except that it's Ruby based, and should be more powerful regarding hardware capabilities.
  • Personally I'm more of a python guy, but from the little I know, ruby is a really fun dynamic language.
  • According to their claim, apps written with rhodes are faster than Android apps written in Java, because it's written 
  • Hardware capabilities currently include access to GPS, camera (only still pictures), bluetooth, audio playback, barcode recognition, and more. Audio/Video capture is planned in future releases.
  • Integrates nicely to all popular IDEs, with a built in unit-testing framework, etc.
  • All in all, seems like a good option if your app doesn't require intensive graphics or performance, and you like ruby, or at least prefer it over objective-C.
Marmalade


  • Link: http://www.madewithmarmalade.com/
  • Until recently known as 'Airplay SDK'
  • A cross-platform infrastructure in C++ - mainly targeting game development but according to them "Marmalade’s sweet spot is 'rich' apps, by which we mean any combination of: great graphics; audio processing; use of device APIs such as camera, GPS, and microphone; deep C/C++ codebase; or anything else that raises your app above the level of a simple mobile website wrapper"
  • They have a plugin for the existing IDEs: either Visual Studio in Windows, or xCode in Mac - which makes it very comfortable to develop.
  • The support for platform-specific code (called EDK) gives an automatic layer of abstraction that makes it very easy to write a cross-platform app that takes advantage of native features.
  • There is a very impressive portfolio of games developed with this SDK, like games by Electronic Arts, or PES by Konami.
  • All in all, this looks like one of the top choices for developing cross-platform applications.
Unity


  • Seems like a very powerful cross-platform game engine. Has good documentation and a good community of Q&A. http://unity3d.com/
  • Most of the development is done with an editor, and the engine supports scripts in Javascript, C# and Boo. There are also many native plugins in the Pro version, and you can write them yourself in c/c++ / objective-c / java, etc. (but using it will make your game non-cross-platform of course).
  • In general, seems like this is a very strong option for game development, especially if you are developing 3D games for multiple platforms. However, accessing the microphone/camera of the mobile device + other advanced features will require using native plugins.
Flash CS5


Corona SDK


  • Link: http://www.anscamobile.com/corona
  • Based on the Lua scripting language, should be similar to ActionScript. There's a nice blogpost regarding how to port a Flash application to Corona: http://blog.anscamobile.com/2011/01/flash-to-corona-porting-guide/
  • Claims to focus on performance and from the showcase seems like there are very impressive games developed with Corona.
  • Has access to many of the device capabilities, including camera, microphone, GPS, etc.
  • There's a free unlimited trial, but you need to buy a subscription in order to distribute apps.
Afterword

That's about all I have researched and can share with you currently. I hope that with time, after gaining some hands-on experience, I'll have some more useful knowledge to share in this blog. So if you're interested - stay tuned: subscribe to the blog, or follow me on twitter.

I would like to welcome any comments you have about the information written here: if you feel I left some important information out, if you spotted a mistake or two in the data, or if you have a personal opinion about some of the frameworks I mentioned. Please leave your comments as a reply to this post. I promise to take them into account.

Edit: Thanks @philxan for mentioning I forgot about MonoTouch

  • Official Site: http://ios.xamarin.com/
  • Part of the Mono Project (http://www.mono-project.com/Main_Page) - a solution that allows you to write cross-platform C# application.
  • Basically, it's a C# framework that integrates with the desktop Mono SDK and the iPhone SDK and lets you create native applications in C# and the .NET framework. Should be interesting mostly if you're looking to port an existing C# application for iOS, or if you're an experienced C# developer and want to save yourself the efforts of learning and adapting to new technologies.
  • The IDE is MonoDevelop for OS X - looks a solid IDE, but I can't say I tried it personally.
  • Cost begins at 399$ for a personal license...
  • Has a version for Android (and naturally Windows Phone) as well
  • Here's a good site with code samples: http://monotouchexamples.com

62 comments:

  1. Just thought I'd throw this in there too, as someone fairly new to iOS. From a game development point of view, the tutorials at

    http://www.71squared.com/iphone-tutorials/

    are extremely helpful. Really walk you through things and give you a good basis for a 2D opengl es iOS game.

    ReplyDelete
  2. macincloud : you cannot install applications for macincloud without the sysadmin sayso. limited for developers i think.

    ReplyDelete
  3. HTML5 Development is very essential to ensure that web sites and mobile internet sites are easy and enjoyable to use.

    ReplyDelete
  4. SharePoint Development gives to maintain the information more effectively. It is like a web server that can host a number of applications.

    ReplyDelete
  5. This comment has been removed by a blog administrator.

    ReplyDelete
  6. This comment has been removed by a blog administrator.

    ReplyDelete
  7. Hi there. Nice blog. You have shared useful information. Keep up the good work! This blog is really interesting and gives good details all about iphone apps development which is the trend to have iphone for business or individual purpose so it requires more and more developers .

    iphone development companies

    ReplyDelete
  8. Windows Phone Development
    may be the latest smart phone platform, but it has already taken significant market share and poses a big aggressive threat to iPhone, Android, and BlackBerry.

    ReplyDelete
  9. Excellent ! it is very useful post. Keep it up .

    iphone developers

    ReplyDelete
  10. Thanks for sharing this post.I found so many useful tips that I can share with my friends who are just starting to learn from ios development. Sounds pretty awesome and worth reading. - click here for full details about push notification -

    ReplyDelete
  11. Loudable information shared on iOS development. As per the iOS development concern I would like to say that there are some other options existing such as Android development, PHP development and windows application development. Thanks for sharing.

    iPhone app developer

    ReplyDelete
  12. I think for developing any iOS app, iPhone app, select the best iPhone designer to achieve your iOS Applications Development Needs. Hire an iOS App Developers online with sound knowledge in this perspective.

    ReplyDelete
  13. ipad Applications Development has changed the way individuals contemplate Applications. For the ipad Application Developers ordinary is a requesting and trialing errand. With regards to the advancement of ipad Applications, a different advantage that Seasia have is our long standing connection with the ios stage.


    iOS Applications Development

    ReplyDelete
  14. In today's Era Android Applications Development is undoubtedly an administration that no association can overlook. It's a blast for all Android Application Developers.

    Android Applications Development

    ReplyDelete
  15. Our ios App Development runs from basic diversions, to multifaceted applications – we have all in our kitty. Continuously a guide with the innovation, this is evidently the improvement group you can depend.

    iOS App Developers

    ReplyDelete
  16. Many thanks for the exciting blog posting! Simply put your blog post to my favorite blog list and will look forward for additional updates. Simply wanted to write down a word in order to say thanks to you for those wonderful tips
    Android Apps Development

    ReplyDelete
  17. Awesome, that's definitely what I was searching for! Your post just saved me alot of searching around I'll make sure to put this in good use!
    iPhone App Development

    ReplyDelete
  18. I am an iPhone engineer. I was changed over my numerous iPhone Application into ipad Application. Next time I'll utilize your code. Trust this code will help me to make widespread requisition that will runs locally both on the ipad and the iPhone.
    iPhone Application Development // Andriod Applications
    Development
    // iPhone APPS

    ReplyDelete
  19. Hi This is very nice blog thanks for sharing

    For More Information You Can Visit This Website Windows Application Development Solutions

    ReplyDelete
  20. This comment has been removed by the author.

    ReplyDelete
  21. There are a number of top branded companies that are working on making iOS features apps but the increase in the number of companies are also increase that are making their own apps either for earning revenue or just promoting their brand name. In fact, many companies are thinking of apps for their business and it has become a necessity nowadays.

    ReplyDelete
  22. Great representation. Thanks for sharing information about to iPhone Development. your blog is rich of information.

    ReplyDelete
  23. I like to read your all posts and i subscribed you. Keep sharing nice information.IOS development is growing day by day and people are going to hire development companies for their new mobile business apps.

    ReplyDelete
  24. Mobile application development, which developed in windows operating system take lesser time as compare to others. However, android and iphone applications are more famous but these are more expensive but peoples used them.

    ReplyDelete
  25. wow, great post! your post is really informative and helpful. thanks for sharing.

    ReplyDelete
  26. I am reading your post from the beginning, it was so interesting to read & I feel thanks to you for posting such a good blog, keep updates regularly..

    IOS Development for Kids

    ReplyDelete
  27. Thanks to post this article. Mobile Application Development is play great role in business.Great job.keep it up.

    ReplyDelete
  28. Thanks for this information.I really appreciate your work, keep it up. Nowadays, with a variety of uses sky is the limit for mobile applications.

    ReplyDelete
  29. I’m really amazed with your posting skills as well as with the layout on your blog site. Is this a paid style or did you modify it yourself? Either way keep up the pleasant quality writing, it is rare to see a great site such as this one these days.
    custom website development company usa

    ReplyDelete
  30. I like the way you are writing. Your Article covers many area of marketing which includes Mobile app development. Visit Here: IOS Applications Development in Bangalore.

    ReplyDelete
  31. Wonderful blog.. Thanks for sharing informative blog.. its very useful to me..

    Mobile App Development

    ReplyDelete

  32. Thanks for sharing such informative post keep updating. Keep updating.
    Snap on our tags to know more about us,

    Web Design company in Hubli | web designing in Hubli | SEO company in Hubli

    ReplyDelete
  33. You have provided an nice article, Thank you very much for this one. And i hope this will be useful for many people.. and i am waiting for your next post keep on updating these kinds of knowledgeable things...

    Mobile App Development Company
    Mobile App Development Company
    Mobile app Development Companies

    ReplyDelete
  34. Good article write and good Information share this Article. Android app Development company In India

    ReplyDelete
  35. Nice, I would like to add one more leading application development company that offers end-to-end digital product development solutions and services for businesses of all sizes.

    ReplyDelete
  36. Thanks for sharing information I must say very informative blog post. Keep it up!!

    Taxi Dispatch Solution | Trucking App Solution

    ReplyDelete
  37. This information is impressive. I am inspired with your post writing style & how continuously you describe this topic. Eagerly waiting for your new blog keep doing more.
    ccna Course in Bangalor
    ccna Coaching Centres in Bangalore
    ccna Certification Course in Bangalore
    ccna Certification Training in Bangalore

    ReplyDelete
  38. Thanks for sharing great information about app development. We are premiere top mobile app development company with a proven track record for building high quality mobile apps.If any requirement regarding iOS app development contact iOS app development company.

    ReplyDelete
  39. Thanks for sharing this valuable information and we collected some information from this blog.
    IOS Training in Noida

    IOS Training institute in Noida

    ReplyDelete
  40. 1. many peoples want to join random whatsapp groups . On this website you can join unlimited groups . click and get unlimited whatsapp group links 18+

    ReplyDelete



  41. The strategy you have posted on this technology helped me to get into the next level and had lot of information in it. The angular js programming language is very popular which are most widely used.




    Dot Net Training in Chennai | Dot Net Training in anna nagar | Dot Net Training in omr | Dot Net Training in porur | Dot Net Training in tambaram | Dot Net Training in velachery










    ReplyDelete
  42. It is truly graciousness to foil across the informational content like the one which you have written. I am highly amazed by your excellent writing abilities.
    Data Science training in Mumbai
    Data Science course in Mumbai
    SAP training in Mumbai

    ReplyDelete
  43. Thanks mate. I am really impressed with your writing talents and also with the layout on your weblog. Appreciate, Is this a paid subject matter or did you customize it yourself? Either way keep up the nice quality writing, it is rare to peer a nice weblog like this one nowadays. Thank you, check also event marketing and How To Get More People To Download Your Event App

    ReplyDelete
  44. You have provided a nice article, Thank you very much for this one. And I hope this will be useful for many people. And I am waiting for your next post keep on updating these kinds of knowledgeable things
    DevOps Training in Chennai

    DevOps Course in Chennai

    ReplyDelete
  45. Thanks for sharing this informational blog post. This blog is something different from the other blog posts on the same topic.
    Taxi app development company

    ReplyDelete
  46. Very Informative blog thank you for sharing. Keep sharing.

    Best software training institute in Chennai. Make your career development the best by learning software courses.

    power bi certification training
    rpa training in chennai
    uipath training in chennai

    ReplyDelete
  47. Nice article I was really impressed by seeing this blog, it was very interesting and it is very useful for me. Informative blog! It was very useful for me. We are the Top Mobile App Development Company in India.
    Also Visits
    Top Android App Developers
    Top iPhone app development company
    Top Android app development company in India

    ReplyDelete
  48. IDM speed is in actuality remarkable. You to situate the tempo of downloads to your hold preference. You will find currently numerous IDM Free Download are accessible and the IDM patch is accessible.. IDM Crack Download 64 Bit 2022

    ReplyDelete
  49. Diving into iOS development can be an interesting venture, considering the capabilities and numerous tools available today. Starting from Swift programming to the utilization of Xcode, it’s a vast ground to cover. And if you're designing life insurance lead capture page, employing these iOS skills can help improve the usability side of the lead capture page for your prospective clients. Everything revolves around how one mixes the technical capabilities with design to achieve an impactful outcome.

    ReplyDelete