World of the Week: Is there Life on Mars?

Life on Mars. A question that has been pondered by scientists, songwriters, and television producers for years. As noted in our announcement of the Is there Life on Mars world, we’re all big fans of extraterrestrial … well, anything, and so the timing of the Mars Curiosity Rover landing couldn’t have been better!

Normally during our World of the Week feature, I take a look at some extra special worlds within Wikitude and point out the top of the top for you. This week, I’d like to have a look at the Is there Life on Mars world, but instead of highlighting the wide ranging and various features (as the Life on Mars world only has one feature), I thought it might be an appropriate time to take a look under the hood, or code, as it were. In addition to providing our regular readers with a bit of “here’s how this works,” knowledge, I’d also like demonstrate to developers just how quick and easy creating an Image Recognition based Augmented Reality world with the Wikitude SDK can be.

Being of limited programming skills, I had a chat with our very own Christian Ebner and Wolfgang Damm about the process involved in creating the Life on Mars world.

The Idea

Chris and Wolfgang took an “extended” lunch break a few weeks back, and returned to the office with a (more or less) completed project. Total time? Well Wolfgang estimates less than an hour, but I’d say he has an unfair advantage, as he’s one of the primary folks involved in driving Wikitude’s underlying technology.

Having said that, I showed a few non-Wikitude developer friends of mine the world, alongside the SDK documentation, and all three of them echoed Wolfgang’s statement, with one even proclaiming, “Lock me in a room with no windows and a full pot of coffee, and I could do this in 38.5 minutes!” Wolfgang’s response? “Challenge accepted!”

The Image

AR on MarsOnce it was decided to use the Image Recognition capabilities present within the Wikitude SKD 1.1, team Chrisgang had to create a dataset specific to the selected NASA image.

After noting my blank stare, Wolfgang quickly pointed me to the Wikitude SDK documentation forum (nice work Phil!) which provides step by step instructions on how to create a dataset from a specific referenced image. To make a long story short (and simple), creating a dataset requires a few elements:

  • Creating the name and dimensions of your trackable image
  • Uploading the target image
  • Check the rating of the image to ensure that it is suited for Image Recognition
  • Download the .zip file that will be needed to reference within the ARchitect world

Total Time: 5 mins (“If you know what you’re doing,” – Wolfgang) With this statement, I’d estimate 10-15 mins if you don’t know what you’re doing – i.e. the time it took me to do this.

The Assets

Right. Now that we have the image and the code needed to recognize this image, let’s start having some fun with what we want the reference image to trigger. For our Is There Life on Mars world, we calling a waving alien image from a rendered animated 3D model, and a very simple audio file.

Chris informs me that animating and rendering the alien was the most time consuming part of the entire process, thus if you’re only calling for 2D images or simple text displays, the creation process could go even faster. Once animated, he’s packed all the frames inside one large image. For us non-coders, think of our Alien as an animated .gif; a number of variations on an image, compiled together to make a moving image.

For the audio file, team Chrisgang went the super simple route and used a standard text to speech engine, and then did some minor processing on the sound to give it that “other worldly” effect.

The ARchitect

Wikitude-SDK-LogoImage Recognition trigger, check. Animated alien and sound, check. We’re halfway there! As this is our guys’ internal speciality, the creation of an ARchitect world was done with their eyes closed (or at least one eye on the code, the other on the inbox).

After setting up the initial ARchitect world framework, team Chrisgang inserted two lines of Image Recognition dependent code; create tracker and trackable2dObject.

If you have no idea what that means, fear not, you’re not alone. Again, Wolfgang pointed me towards another section of the Wikitude SDK documentation that outlines the step-by-step procedure involved in creating an Image Recognition trackable.

The last SDK specific action to take is to specify what triggers are called when the image is recognized. As noted above, we’ve used an animated alien, and a sound file for our Is there Life on Mars World. Within this world, once the image is recognized, the specified variables are called into action. In this case, we’re calling for the animation file, as well as the audio file. Team Chrisgang informs me that multiple events can be called for any one tracker.

The Icing on the Cupcake

WikitudeCakeThat’s it! Well, sort of. If you’ve made it this far, you’ve successfully built an Image Recognition capable world, now you just need to put the icing on the cupcake. Meaning, what you’ve built thus far is akin to the car engine. To build the shiny, glossy body around the engine, you’ll need nothing more than some HTML skills and a vivid imagination to create additional information to display.

In our case, it’s the simple inclusion of some explanatory text and a link back the the original Life on Mars blogpost. Obviously nothing too complex, and you can use this functionality in a number of ways. Perhaps drive shoppers to an exclusive offer, or provide a link to a specific landpage, Facebook page, etc. If you can do it with HTML, you can do it with Wikitude!

I have to admit, after sitting with Team Chrisgang, I’m fully confident that I too, could build my very own Image Recognition based world. The SDK documentation provides step-by-step instructions, and while I might not completely understand what’s going on in the background, in my opinion, as long as the desired outcome is achieved, I’m not sure I absolutely have to understand what’s going on.

The Wikitude SDK 1.1 is now available from the Wikitude Store. If you’d like to try things out for yourself, our SDK is free for non-commercial based projects, and provides up to 100 unique device installs, all free of charge.

Get started building your own Augmented Reality experiences with Wiktiude today!

Leave a Reply

Your Email Address is private. * Required Fields