Wiimote Project
Wiimote Projects => Wiimote Desktop VR/Head Tracking => Topic started by: Anhar Miah on June 03, 2008, 09:22:03 AM

Hey Guys,
My name is Anhar and as a personal project I’ve been trying to build a simple head tracker, after Googling this is the closest I’ve come to it (excluding TrackIR and FreeTrack, since they do not show their source codes)
I need to ask for some guidance, I was trying to code my own program using a webcam (with film filter) and some LEDs.
I’ve broken the problem down as thus far:
(1) Initial Blob detection greyscale line scanning (thresh holding)
(2) Generate Centroid (using intensity weight based method)
(3) Implement POSIT algorithm <<  (This is the problem)
The first two parts I understand how to implement in terms of coding, the last POSIT algorithm is what I’m having trouble with.
I have read up on Daniel DeMenthon papers (POSIT in 25 lines of Code), the problem is I don’t understand the maths clearly enough, they don’t have a numerical example, and my memory of Matrixes is really fuzzy :D
The bits I do understand thus far, is that one takes the 2d points from the CCD/CMOS in pixels, this is the “screen coordinates” and then projects this back to reach the real world points, I guess this is the SOP part (Scale orthographic Projection) and then somehow you can then calculate the pose from this which is the POS part (Pose from Orthographic Projection) after that you just iterate to reduce the error.
Can some one please give a step by step Numerical example of how this is calculated, that’s all I need, once I understand that and how its actually calculated I should be able to code it.
I’m sure this would also serve as a tremendous source of help for other wishing to code their own stuff.
Thanking you in advanced
Anhar

There is an implementation of POSIT in the openCV library, do some research on that. The library is open source so you should be able to find some code there...
Also, freetrack is open source as well. They give out most of their source code, but not everything needed to compile it by yourself. If you can manage having to look through delphi, give it a look, they have their own implementation of the POSIT algorithm.
You are going to have trouble finding the wii remote's IR camera intrinsic parameters though (focal length, pixel size and there's 12 more I forget).