[IGSTK-Developers] calibration (followup to David and James'sdiscussion)

David Gobbi dgobbi at atamai.com
Tue Dec 6 18:17:35 EST 2005


Hui Zhang wrote:

> Hi, David,
>
> I have added some new functions to manually set the calibration matrix:
>
> RequestSetTranslation
> RequestSetQuaternion
> RequestSetRotationMatrix
> RequestSetToolPrinicipalAxis
> RequestSetToolPlaneNormal
>
> I am a bit not sure about turning the principal axis and plane normal 
> into quaternion. The quaternion means a rotation, not an absolute 
> orientation. Tool principalaxis/planenormal defines an absolute 
> orientation. So I set the default principalaxis/planenormal to 
> (0,0,1)/(0,1,0), and the quaternion is the rotation from the input 
> principalaxis/planenormal to the default one. I have commited the 
> recent code to sandbox, please feel free to check out and change the 
> code if that mathematic computation is not correct.

Sorry for taking so long to get back to you on this...

We do in fact want the principal axis and plane normal to define a 
rotation via a quaternion.  To be precise, we want to create a 
quaternion that will rotate the raw tool coordinates such that the 
principal axis (i.e. the tool shaft) becomes the local Z axis in spatial 
object coordinates and the plane normal (i.e. the minor axis or flattest 
direction) becomes the Y axis.

I have looked at your code, and it looks good, it even recomputes the 
normal to be perpendicular to the axis as it should.  The big danger, of 
course, is accidentally building the rotation matrix the wrong way 
around and ending up with the inverse rotation.

- David

> ----- Original Message ----- From: "David Gobbi" <dgobbi at atamai.com>
> To: "Hui Zhang" <zhang at isis.imac.georgetown.edu>
> Cc: "'IGSTK-developers'" <igstk-developers at public.kitware.com>
> Sent: Thursday, December 01, 2005 5:36 PM
> Subject: Re: [IGSTK-Developers] calibration (followup to David and 
> James'sdiscussion)
>
>
>> Yes, I think that the igstkReferenceCalibration should be added to 
>> the wiki.  I'm interested to see what the interface to the class will 
>> look like.
>>
>> Hui Zhang wrote:
>>
>>> Hi,
>>>
>>> This sounds good, I will put these two functions in the Wiki's class 
>>> requirement soon. Do we also need add that igstkReferenceCalibration 
>>> class in the Wiki? That is a general class to calculate the 
>>> reference transform between the object position/orientation to 
>>> reference position/orientation, which can also be used for Ziv's 
>>> proposed routine to get the rotation?
>>> Regards,
>>> James
>>> ----- Original Message ----- From: "David Gobbi" <dgobbi at atamai.com>
>>>
>>>>
>>>> We will need intuitive methods for setting the orientation, because 
>>>> not many people are familiar enough with quaternions.  So there 
>>>> could be two methods:
>>>>
>>>> SetToolPrincipalAxis(vx, vy, vz) -- set a vector that points along 
>>>> the tool axis towards the tool top
>>>> SetToolFaceNormal(nx, ny, nz) -- set a vector to define a  that 
>>>> "face" of the tool, this vector must be perpendicular to the tool axis
>>>>
>>>> The "tool face" is for when you want to use a pointer as a virtual 
>>>> ultrasound probe, it will define the orientation of the plane that 
>>>> you want to use as the virtual ultrasound plane.  This is only 
>>>> useful for 6DOF tools, not for 5DOF tools.
>>>>
>>>> These two vectors can be put together to create the quaternion that 
>>>> is used as the orientation.  The NDI tool architect software does 
>>>> something very similar to this.
>>>>
>>>> - David
>>>>
>>>>
>>>
>>>
>>>
>>
>>
>
>
>




More information about the IGSTK-Developers mailing list