I’ve been working on an interesting project for early 2011 using augmented reality (AR) and Animata (from Kitchen Budapest). I’ve looked at using Processing for it, and Flash, but nothing really speaks to me as far as speed and reliability and flexibility of development. So I looked into OpenFrameworks and ARToolKitPlus, which was recommended to me today in a total coincidence involving our flat’s heater breaking and forcing me to work in the London Hackspace. So, I randomly and luckily met Tasos Varoudis, who teaches at UCL and knows a lot about AR, and was kind enough to help me find the required code to get started. Which was not easy! All the links I could find were either broken or half-working.
So, dear reader, in the spirit of openness, I offer you a download of the ofxARToolKitPlus addon and a working example (you will need to modify it slightly for Windows and Linux – see the comment in setup() in testApp.cpp). This works with the newest OpenFrameworks version 0062.
Happy Reality Augmenting!
19 responses to “ARToolKitPlus in OpenFrameworks”
Thank you ! You saved me a lot of time !
Thank you for this great example, but wondering where can I get the marker from, I can’t find in the source folder.
Thanks Again
There should be a file called “spec_marker.pdf” included that you can print off, but it will track most of the built-in ARToolKitPlus markers. Look at markerboard.cfg (it’s a text file) to see a list of the markers, they’re organized by index, and you can find all of them to print at the ARToolKitPlus page – download here http://studierstube.icg.tu-graz.ac.at/handheld_ar/download/ARToolKitPlus_2.1.1.zip and look in the “id-markers/simple” folder for pngs of all of them (look for the ones numbered like the markerboard.cfg).
I am really sorry, i am new to artoolkit+. Here is my issue now i didn’t find the (spec_marker.pdf) but i downloaded all the marker and printed three of them, 480,481,482 .. but nothing is happening on the screen ??? i know i missing a fundamental part. Do you know what it could be ?
Thanks Again
Thanks man! This is the first AR code that has worked, but am also having trouble with the markers, cant get any to work. The one’s I downloaded from http://studierstube.icg.tu-graz.ac.at/handheld_ar/download/ARToolKitPlus_2.1.1.zip , are really small so I resized them. could this be the problem? Let me know
Hmm… the problem is that there are a few different places to find markers from, and using them isn’t straightforward at all.
One place is to get the original ARToolkitplus project from sourceforge, in there you’ll find a subfolder called “patterns” where there are templates for the pictorial markers.
The other markers I’ve used are specified in the markers.cfg file, if you open it in a plain text editor (TextEdit or Notepad or whatever) you’ll see a bunch of entries which tell you which markers the program should detect:
# marker 0
480
40.0
0.0 0.0
1.0000 0.0000 0.0000 -100.0
0.0000 1.0000 0.0000 75.0
0.0000 0.0000 1.0000 0.0
The top-most entry is “480” in this example, which corresponds to marker # 480 in the ARToolkitPlus download package, in the “id-markers->bch” folder, called “BCH_Thin_0480.png”
Hopefully that helps… let us know how you get on!
Also, when you print the markers they need to be whatever size you specified in the “markers.cfg” file, in this case 40mm wide by 40mm tall (the 2nd line in your marker entry, after the marker id number).
Thanks for the example. Works perfectly!
I interesting about ar in openframeworks very much.
Hi,
Many thanks for posting this. I can get the code to execute without complaints. But what am I menat to print and hold infront of the camera? Where do I sepcify the marker?
I found the online too to create my own, but then, what do I do with it?
Which one are you using?
Thank you in advance
Cheers
/Philip
sorry its me again,
Read through all the comments. Downloaded the Zip, printed the 480 marker at 40 x 40 mm, but still no reaction when holding it infront of the web cam?
Tahnks in advance
@Phillip – did you print the marker from the “bch” folder? This version only uses the bch markers. Those should work. Try printing the first one “BchThin_0000.png” on white paper (make sure to leave a white border around it, and don’t obscure the marker or the border at all)
hey evan – did you ever get any results from trying to make the standalone animata player? thanks for any info! rob
I did – I’m going to post something on it very soon.