This is modified “Ballance” game released by Alternativa3D team in november, with FLARToolkit used to control camera instead of mouse. Unfortunately, due to GPL2 section 2 clause B I cannot distribute stuff including both FLARToolkit and Alternativa3D for free, so no SWF for you to play with atm, sorry. But, if anyone is interested in sponsorship to enable this thing to go online, contact me.

On the technical side (aka “how the hell was it done”), bad news are that neither object transformation matrix nor camera projection matrix cannot be directly set in Alternativa3D, so we have to resort to mind-f@#king tricks to get it working, and the result is only approximate match. Good news are that this approximation is, obviously, good enough and useable. An example of what has to be done to make it work can be found here (I believe my single AS file does not contain FLARToolkit, and so I can distribute it, under whatever license I want).

hey makc, i’d like to roll in support for other 3D engines into FLARManager. was taking a look at your SimpleTest.as, and i noticed that you translate a FLAR matrix into a new matrix for use with Alternativa3D, but then you manually set props on a Camera3D instance like rotationX, etc, rather than directly applying that matrix to an Object3D.

why is this? is this an idiosyncrasy of Alternativa3D? i.e. is it not possible to just apply a matrix to an object like you can in PV3D / flash?

although this post was made more than a year ago, when alternativa was still 5th version, I think “the work around” is pretty much the same today, you calculate approximate scales/rotations/translations from matrix values. try same bit of code; but keep in mind that things like axes signs and rotations order might have changed.

Ive been looking at the code but Im not sure where you are getting the FLARTransMatResult from the augmented marker?

Ive been looking at your SimpleTest.as and have come up with the following to use flash.geom.matrix3d

but its quiet right… and its seriously slow!

if (detector.detectMarkerLite(raster, _threshold) && detector.getConfidence() > 0.5)
{
//Get the transfomration matrix for the current marker position
this.detector.getTransformMatrix(flarTransMatResult);

I see you already have found right bit of code and started playing around with it – from here to your end result it is supposed to be played in solo :) I can’t really help you here as long as we aren’t sitting in the same room. One thing I can say, your performance problem is not in this code.

Hi! Great work you have here!
I saw above that you calculate scales, even if m is not scaled. (That is, scaleX and scaleY are 1). Well, I was wondering… but how is the 3D object scaled anyway? Supposing I want to overlap a rectangle over the marker. How can I scale it?