sorry, been a while since i've dug into the code, maybe makc or others can provide more suggestions...
I assume you are referring to
http://www.hitl.washington.edu/artoolkit/Papers/ART02-Tutorial.pdf
page 14
There is public var error:Number in NyARTransMatResult that
FLARTransMatResult extends. It is set in NyARTransMat's optimize()
method; if you look into its source, you can see this:
for (var i:int = 0;i<5; i++) {
...
var err:Number=errRate(rot,io_transvec, i_offset_3d, i_2d_vertex,4,vertex_3d);
//System.out.println("E:"+err);
...
min_err=err;
}
//System.out.println("END");
return min_err;
so, these error values are not preserved, and you only have last one
of them. If you need them all, you will have to modify FLARToolKit.
or, if you just need large sample for statistics, replace line
//System.out.println("E:"+err);
with
trace(err)
and you will have them in flash log file. then you can copy-paste to
spreadsheet app and do your magic
Good evening,
I would suggest dispatching a custom event with that local variable as data appended to it, and listen to it in the main app (if this class extends an eventdispatcher).
daniel.
if these lines are log file you're referring to, you're looking into wrong file.
see google for flash log location:
http://www.google.com/search?q=flash+log+location
also make sure you have debug player, or it will not log anything
http://www.google.com/search?q=installing+debug+flash+player
no but compile and run this program:
package {
import flash.display.*;
public class Test extends Sprite {
public function Test () {
addEventListener ("enterFrame", test);
}
public function test (e:*):void {
trace (123);
}
}
}
it will fill log file with 123 so you could be positive you are
looking at the right place. then go back to messing with your hacked
flartoolkit source.