Daniel Sperl, developer of the Sparrow Framework, recently posted a performance comparison on the Apple Developer forum where Sparrow ran 2.5 times faster with MRC code than the version upgraded to ARC.
A curious finding though it seemed very far off from real world observations. Being a synthetic benchmark no less. I decided to do a similar test based on the same code comparing cocos2d v2 and v3.
Fortunately cocos2d-iphone v3 has made a similar switch from MRC (v2.1 and earlier) to ARC (v3 preview). Unfortunately the internals of cocos2d also changed to some extent, for example custom collection classes written in C were replaced by Core Foundation classes. I don’t have a full overview of the changes, but at least the renderer doesn’t seem to have changed in any significant way. Yet.
So while comparability is good, it’s not like Sparrow where truly the only changes made were converting the code from ARC back to MRC. Take the following benchmark results and comparisons with two grains of salt and pepper on the side.
ARC vs MRC
The original benchmark done with Sparrow has seen MRC perform 2.5 times better than ARC in a synthetic “draw as many sprites as possible until framerate has dropped consistently below 30 fps” test:
With yesterday’s release of iOS 7 and hence Sprite Kit, many cocos2d developers will face this question sooner or later: switch to Sprite Kit or Kobold Kit or stick with cocos2d-iphone or perhaps move on to cocos2d-x?
I’ll give you some guidance and things to consider …
Sprite Kit / Kobold Kit
Sprite Kit made quite the splash. There are new tutorials coming out by the minute. Two books will be available within days after release. Several high profile tutorial & starterkit authors have jumped on the bandwagon. Tool developers are hard at work adding Sprite Kit support. Instructors are already offering new mobile game development courses based on Sprite Kit. Heck I even started a new game engine based on Sprite Kit: Kobold Kit.
With almost everyone jumping ship, it seems a safe bet to jump ship, too. You’re guaranteed to get excellent documentation from Apple, plus a stability of the framework until at least iOS 7.1 and even then Apple is known to carry on supporting deprecated methods for several versions. It’s easy to learn, and once learned you won’t be thrown off guard by new releases. And the developer community will soon surpass that of cocos2d-iphone. Continue reading »
A new episode of the Cocos2D Podcast is now live. This time we’re joined by Daniel Sperl, author of the Sparrow Framework Objective-C game engine for iOS which is based on the ActionScript (Flash) API design.
Note: the Sparrow website is currently reported as “possibly malware” by Safari and Google. The culprit has been removed and the site is safe to visit. Read this blog post for more info about what happened.
Daniel has a secret he shared with us even though he couldn’t really say any details until the official announcement in a few weeks. Cocos2D also gets a couple honorable (or dishonorable) mentions as we compare it with Sparrow Framework, and come to the conclusion that documentation-wise it is leaps and bounds ahead of Cocos2D.
Cocos2D Podcast: Daniel Sperl (Sparrow Framework Developer)
Previous Cocos2D Podcast: Marketing your App
I forgot to blog about the previous Cocos2D Podcast in which Azam and I talk about marketing your iPhone app.
Cocos2D Podcast: Marketing your iPhone App
Unrelated but important: Steve Jobs resigns
In case you haven’t heard, Steve Jobs has resigned as CEO of Apple on August 24th, 2011. Here’s Steve’s (short and to the point) letter to the Board of Directors. Tim Cook was named as his successor. Read the press release.
I never really cared for who’s boss of a big company, just enough to get the ridicule. But Steve Jobs leaving .. I can’t help but feel sad.
I believe this is for one reason in particular: very, very few CEOs actually have a vision and follow it through. Or have the (will)power to follow it through without being bent or influenced through challenges and oppositions by corporate and outside politics. Steve was able to retain all of the drive, dedication and willpower that you have when you just start out as a company or individual trying to make a really great product that you believe in and want to be proud of.
Most large companies are simply unable to create such products because too many people work on each product, and there’s lots of money and risk involved in the process which, more often than not, turns potentially great companies into conservative, boring companies making lackluster products, following consumer trends. Apple under Steve Jobs has been the exception. Steve has repeatedly anticipated consumer trends, even created them through the power that is the Apple brand.
The really, really sad part however is what hasn’t been said. Steve being unable to meet his duties paints a grim outlook on his health. Not mentioning his health in his letter and Apple’s press release even more so. I just wish for him that it’s not as bad as one can imagine it to be if it forces someone of Steve’s caliber to resign from his position. Good luck and all the best, Steve!
In my book I explained how to create collision shapes for physic engines using the freely available version of VertexHelper Pro. Granted, it works, but as soon as you need to update your shapes frequently or you have many different shapes to edit it’s going to be a lot of manual work and error-prone copy & paste between VertexHelper’s code generator and your source code.
VertexHelper, meet your replacement: PhysicsEditor
PhysicsEditor was written by Andreas Löw, the author of the very popular TexturePacker tool. He has proved again that he can create powerful yet easy to use tools for game developers.
The greatest part about PhysicsEditor: it can automatically trace your shapes to generate collision shapes and it works flawlessly! You can even tweak the amount of vertices (and a lot of other things) as needed, for example if your physics engine has a limitation on how many vertices can be used for a collision shape (Box2D default: 8 vertices).
But it doesn’t just create the collision shapes, it also allows you to edit physics properties of a shape that often go along with it. Density, friction, “bouncyness”, and other parameters can be tweaked in the GUI.
As they say, an image speaks louder than words, so I suppose a video speaks in a thousand images:
Not just Cocos2D
PhysicsEditor currently exports to Cocos2D + Box2D (Chipmunk/SpaceManager support is forthcoming and should be available soon) and also to Sparrow Framework + Chipmunk and of course Corona SDK.
And it works on Windows, too! Which makes sense given that Corona supports Android development under Windows.
I also found this post about PhysicsEditor with a working Flash example (at the bottom). It seems that even exporting respectively using PhysicsEditor with Flash + Box2D seems to work well. Wow!
Brace for impact!
Check out the PhysicsEditor Features page to learn more about what this great tool can do for you! You can get PhysicsEditor alone for $17.94 but you can also grab a bundle deal which includes TexturePacker for $29.99, or almost 20% off.