Creating a new coordinate system

You can define a coordinate system using a markups plane node:

The advantage of using this instead of a transform that you can conveniently place the node using 3 points and then further adjust its position and orientation using interaction handles.

Once you have defined the plane, you can get the the transform between this coordinate system and the RAS coordinate system like this:

planeToWorld = vtk.vtkMatrix4x4()
getNode('P').GetObjectToWorldMatrix(planeToWorld)

If you concatenate this transform with the result of the model registration then you’ll get the rotation and translation between the bones in the plane coordinate system.

2 Likes