Moseycode is an augmented reality barcode system that I’ve been developing for the Android platform. As the project’s profile slowly grows, I’ve had a number of people ask me about the suitability of Android for similar projects. I’ve decided to put my comments, such as they are - limited by my own narrow experience - into a post so that I can refer future enquiries here.
I started developing Moseycode when the Android SDK first became available - before any Android powered phones were available - so much of the early development of Moseycode was done using a PC, a webcam and the JMF framework. None of the image processing I’ve been focusing on has required high resolution capture, but webcams are really very problematic - especially since they usually lack any focus control. The upside is that if you get your algorithms working reliably with webcam captured footage, you should be pleasantly surprised by the results from anything else!
Though I’m a huge fan of the Android platform, I think it has some drawbacks at present for this sort of development:
Generally I would rate the image capture quality of the G1 as fairly poor. This is probably hardware related but I’d speculate that some of it may be due to underdeveloped drivers. I can’t comment on the image quality from other phones. The auto focus though is a major boon to barcode capture.
I like the SDK (I’m an experienced Java developer) but real-time image processing won’t fly with the current Dalvik interpreter; the C/C++ support in the form of the NDK is very focused on compatibility and not features (which is definitely the right call) so consequentially the available libraries are quite minimal and this might cause difficulties porting over existing image processing libraries (though I’m not sure - I haven’t had to try).
The camera APIs within the Android framework are weak. I always feel I have to qualify this by saying that (1) this is simply my opinion, check out them out for yourself and form your own opinion, and (2) there are many reasons that poor APIs arise, most of which are not the responsibility of the engineers who craft them. That said, there are some serious structural problems in the APIs that thwart attempts to write portable and performant applications. Many of the problems are documented in the public issue tracker. My bĂȘte noire is issue 2794. I’ve got as far as posting an outline proposal for how things could be improved but I’m unlikely to find the time to attempt an implementation until the first release of Moseycode is out of the way.
There is no effective API available for parsing and and rendering 3D object models. I don’t necessarily expect one to be provided within the standard framework, it’s simply unfortunate that, at this time, the platform is not sufficiently mature that any such libraries are available. Perhaps if/when OpenGL ES is directly accessible from native code it will be possible to port an established C library.
All those niggles notwithstanding, it’s exciting being able to capture and process live image data on a mobile phone, something that’s so central to people’s lives. Combined with Android’s powerful abstractions that support collaborative applications it’s really exciting.
I’ll end by saying that I’m currently working towards releasing Moseycode as an open-source platform that developers will be able to re-use at a number of levels. Android might be a more inviting target for augmented reality applications when that is available since it will provide a jumping-off point for developers to build their own applications.