Introducing the BlackBerry Target for NME

At 12:20 PM on Tuesday (two days ago), a BlackBerry PlayBook arrived on my door step.

I bought it with the suspicion that it would not be too difficult to target BlackBerry’s new QNX-based platform. At 11:16 this morning, I was glad to announce that NME was running (albeit in software), and at 6:45 this evening, I was glad to announce two happy but simple words:

“It works!”

Some features remain to be supported, such as the accelerometer, or checking the screen DPI, but otherwise NME is alive and running on RIM’s platform. Fonts, animation, bitmaps, sound, filters, hardware acceleration — the “Pirate Pig” sample works flawlessly.

Some of you may feel that adding another target is investing time in something which is not as valuable as perfecting the targets which already exist, and which arguably have larger market share. I was recently told that BlackBerry App World grosses #2 in the world for mobile markets. There may be a lot of Android devices, but that does not necessarily mean that developers are reaping large profits. I was also told that only 1% of iOS developers make more than $1000 a year. If you take into account the cost of becoming a developer or purchasing Apple hardware, that becomes even less, so App World might be even more profitable for you than the App Store.

In my mind, one of the greatest strengths of NME is having options. I don’t want your business to be limited by your technology. Opening the doors to native applications on the BlackBerry platform opens doors for you to have more options when you decide how to market and sell your applications. Since the target uses SDL, just like webOS, Windows, Mac and Linux, it only helps to make NME more flexible, and does not pull our time into creating a lot of unique code for only one platform.

  • Hoseyhosey

    Awesome!  Nice work.  Keeping all options open is the beauty of haxe/nme

    1 issue.  Sdl-static on SVN is not updated with blackberry.  Do I need to compile it or are you updating it?

    haxlib run hxcpp Build -Dblackberry
    cannot open file ../…/sdl-static/lib/BlackBerry/libfreetype.lib

  • You can get my patches to hxcpp and sdl-static, here:

    There are also ZIP files which include binaries, compiled for BlackBerry. If you add the files and patch both libraries, you should be able to use NME from SVN just like normal

  • Arnoud

    Wow! you are a machine! (in the good way of course). Really impressed. I’m digging into haXe and haxe-nme lately and i feel like alice in programmers wonderland 🙂 Every door i open there is more incredible stuff! Great community and people like you are pushing this thing so quickly forward. Mucho respect!


  • aaulia

     So Josh I use the SVN version, I saw the commits, do I need the patch also ? Secondly, I installed and configured the whole NME pipeline manually (this is before  “setup ” was introduced), and I kind of like it to stay that way, so the question is does “setup blackberry” works and if it is will it interfere with my own configuration ? It would be nice to know what config should I set and what things to download to manually setup the blackberry target.

  • The patches are for hxcpp and sdl-static. My changes are already in the NME SVN, so no patches are needed there if you are current. There’s nothing scary about “nme setup blackberry” … it asks if you want to download and install the Native SDK, then if you say yes, gives you the option of opening your web browser to download it (since we can’t link to it directly)

    It then prompts for where the Native SDK is installed, where your debug token is located, the IP address of your development device and your device password. These are used to install and launch the application after compiling.

    It doesn’t help you set up a new debug token, but I’d be glad to help if you have any trouble doing it (since it is a little tricky)

  • great work as always joshua!  

    I tested it out with my app- most things seem to be in order.  one minor thing is it failed to copy my icons, i’ll look at how it handles that (bar descriptor had ‘icon.png’ which didn’t exist.)

    it crashes eventually for me, but i think it’s crashing when it gets to the sharedobject / state saving bits which i assume we’ll need to implement for bb.

    really promising.  only other thing i notice is the performance seems laggy, looks slower than when i use the air target (though i haven’t benchmarked.)  Is it possible its still running in software? Anyway to confirm its using gpu?

  • luk

    Great work Joshua!

    Performance is great on my PlayBook but not everything works.
    I’ve tried bunnyMark demo and I can’t see textFields with framerate and bunnies count.
    There is no alpha transition on moving bunnies too.

    Is there any way You could fix it.
    Or maybe I didn’t configure NME correctly (I am using v3.3.0). 

    Anyway thanks for this. Looks great!

  • Oz

    I see that playbook and the new bb10 is like a mobile game console (with excellent hardware and software) and the trend goes there if we see that WP8 is going to be like that. I’m happy found nme just yesterday to achieve making multiplatform game just great and focus on gameplay, game design