[IGSTK-Users] Tool positions or Tools Translations?

Jason YEE famousyi at hotmail.com
Thu Jun 25 17:20:09 EDT 2009


 

Hello Eric,


I am sorry that I have no idea about your code. But as I remeber, if you want to get the position of a single marker, the API command sent to the tracking system is different. And there is just position information but no roatation information for a single marker (I use polaris I am not sure about other tracking systems). 

 

Hope it helps,

 

Regards,

 

Jason


From: eric_lb at hotmail.com
To: igstk-users at public.kitware.com
Date: Thu, 25 Jun 2009 20:59:23 +0000
Subject: [IGSTK-Users] Tool positions or Tools Translations?



 
 
Hi all.
 
I'm working in a project where I need to know the positions in 3D of each marker (reflective sphere) of a passive tool.
I have some problems with this.
The tool is intented to be referenced to a static tool (the reference tool provided with the tracking system).
The problem is that when I try to get the transformations of each marker, there is no consistent data.
 
My design tool have three spheres(ellipses), like this:
/////////////Desing Tool03
translation[0] = 0;
translation[1] = 0;
translation[2] = 0;
rotation.Set( 0.0, 0.0, 0.0, 1.0 );
transform.SetTranslationAndRotation(translation, rotation, errorValue, validityTimeInMilliseconds );
Tool03Ellip1->RequestSetTransformAndParent( transform, Tool03 );
 
translation[0] = 50;
transform.SetTranslationAndRotation(translation, rotation, errorValue, validityTimeInMilliseconds );
Tool03Ellip2->RequestSetTransformAndParent( transform, Tool03 );
 
translation[0] = 32.07;
translation[1] = 58.83;
transform.SetTranslationAndRotation(translation, rotation, errorValue, validityTimeInMilliseconds );
Tool03Ellip3->RequestSetTransformAndParent( transform, Tool03 );
 
 
I set some observers to each ellipse:
T3Ellip1Observer = ObserverType::New();
T3Ellip1Observer->ObserveTransformEventsFrom( Tool03Ellip1 );
T3Ellip2Observer = ObserverType::New();
T3Ellip2Observer->ObserveTransformEventsFrom( Tool03Ellip2 );
T3Ellip3Observer = ObserverType::New();
T3Ellip3Observer->ObserveTransformEventsFrom( Tool03Ellip3 );
 
And I get the transformations:
TT3Ellip01=T3Ellip1Observer->GetTransform();
translation=TT3Ellip01.GetTranslation();
T3RotE1=TT3Ellip01.GetRotation(); 
///...  for  each ellipse
 
With the transformations data I try to apply the rotation and translation to each position marker taked from origin of coordinate system (reference tool), but the positions that i get seems to be incorrect.
Then, I decided to take directly the translation as the position, with no rotation, and the result were better, but with positions not aligned to the coordinated system (rotated). If i apply the rotation to each marker, the result is again bad.
 
I undesrtand that to get the transformations referenced to the static tool need to apply:
T= (Mreg) (Tref^-1) (Traw) (Mcal)     ... (IGSTK The book for release 2.0, Chap 8.2.5 Coordinate Transformations, pp 105)
In this case, there is no Mreg and Mcal. When i try to get the referenced transformation of the ellispes, i use this code:
TAbs01=TAbs01.TransformCompose(TRef.GetInverse(),TT3Ellip01);  //...  for  each ellipse
But the data is incorrect.
 
I plot the data with matlab to emulate the movement of the tool, thats why i can see the incorrect transformations.
Considering all this long process :s my question is How can i get the three marker positions??? What i need to do with the rotations???
There is something that i'm doing bad?? Some idea????
Please, I hope someone can help me.
 
Thanks.
 
 
Eric LB
 
 
 



Estás a un clic para ganar premios con Windows Live
_________________________________________________________________
More than messages–check out the rest of the Windows Live™.
http://www.microsoft.com/windows/windowslive/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/igstk-users/attachments/20090626/e5dd7b64/attachment.html>


More information about the IGSTK-Users mailing list