<html>
<head>
<style>
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 10pt;
font-family:Verdana
}
</style>
</head>
<body class='hmmessage'>
&nbsp;<BR>
&nbsp;<BR>
Hi all.<BR>
&nbsp;<BR>
I'm working in a project where I need to know the positions in 3D of each marker (reflective sphere) of a passive tool.<BR>
I have some problems with this.<BR>
The tool is intented to be referenced to a static tool (the reference tool provided with the tracking system).<BR>
The problem is that when I try to get the transformations of each marker, there is no consistent&nbsp;data.<BR>
&nbsp;<BR>
My design tool have three spheres(ellipses), like this:<BR><FONT color=#008000 size=2><FONT color=#008000 size=2>
/////////////Desing Tool03<BR></FONT></FONT><FONT size=2>
translation[0] = 0;<BR>
translation[1] = 0;<BR>
translation[2] = 0;<BR>
rotation.Set( 0.0, 0.0, 0.0, 1.0 );<BR>
transform.SetTranslationAndRotation(translation, rotation, errorValue, validityTimeInMilliseconds );<BR>
Tool03Ellip1-&gt;RequestSetTransformAndParent( transform, Tool03 );<BR>
&nbsp;<BR>
translation[0] = 50;<BR>
transform.SetTranslationAndRotation(translation, rotation, errorValue, validityTimeInMilliseconds );<BR>
Tool03Ellip2-&gt;RequestSetTransformAndParent( transform, Tool03 );<BR>
&nbsp;<BR>
translation[0] = 32.07;<BR>
translation[1] = 58.83;<BR>
transform.SetTranslationAndRotation(translation, rotation, errorValue, validityTimeInMilliseconds );<BR>
Tool03Ellip3-&gt;RequestSetTransformAndParent( transform, Tool03 );<BR></FONT>
&nbsp;<BR>
&nbsp;<BR>
<FONT size=2>I set some observers to&nbsp;each ellipse:</FONT><BR>
<FONT size=2>T3Ellip1Observer = ObserverType::New();<BR>
T3Ellip1Observer-&gt;ObserveTransformEventsFrom( Tool03Ellip1 );<BR>
T3Ellip2Observer = ObserverType::New();<BR>
T3Ellip2Observer-&gt;ObserveTransformEventsFrom( Tool03Ellip2 );<BR>
T3Ellip3Observer = ObserverType::New();<BR>
T3Ellip3Observer-&gt;ObserveTransformEventsFrom( Tool03Ellip3 );<BR></FONT>
&nbsp;<BR>
And I get the transformations:<BR><FONT size=2>
TT3Ellip01=T3Ellip1Observer-&gt;GetTransform();<BR><FONT size=2>
translation=TT3Ellip01.GetTranslation();<BR>
T3RotE1=TT3Ellip01.GetRotation(); <BR>
///... &nbsp;for&nbsp; each ellipse<BR></FONT></FONT>
&nbsp;<BR>
With the transformations data&nbsp;I try to apply the rotation and translation to each position marker&nbsp;taked from origin of coordinate system (reference tool), but the positions that i get seems to be incorrect.<BR>
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.<BR>
&nbsp;<BR>
I undesrtand that to get the transformations referenced to&nbsp;the static tool need to apply:<BR>
T= (Mreg) (Tref^-1) (Traw)&nbsp;(Mcal)&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;... (IGSTK The book for release 2.0, Chap 8.2.5 Coordinate Transformations, pp 105)<BR>
In this case, there is no Mreg and Mcal. When&nbsp;i try to get the referenced transformation of the ellispes, i use this code:<BR><FONT size=2>
TAbs01=TAbs01.TransformCompose(TRef.GetInverse(),TT3Ellip01);&nbsp; //...&nbsp; for&nbsp; each ellipse<BR></FONT>
But the data is incorrect.<BR>
&nbsp;<BR>
I plot the data&nbsp;with matlab to emulate the movement of the tool, thats why i can see the incorrect transformations.<BR>
Considering all this&nbsp;long process :s my question is How can i get the three marker positions??? What i need to do with the rotations???<BR>
There is something that i'm doing bad?? Some idea????<BR>
Please, I hope&nbsp;someone can help me.<BR>
&nbsp;<BR>
Thanks.<BR>
&nbsp;<BR>
&nbsp;<BR>
Eric LB<BR>
&nbsp;<BR>
&nbsp;<BR>
&nbsp;<BR><br /><hr />Estás a un clic para ganar premios <a href='http://www.actualizatuperfil.com.mx/' target='_new'>con Windows Live</a></body>
</html>