I am working on developing a small tracking script to store specific tracking data, and in my specific case I need to track two tools at the same time. One of them is a pointer, and the other can be anything. Tracking works fine for both tools separately, and when they are both in view it also works fine, however, the first time the pointer tool enters in view it ruins the tracking for the other tool.
For some reason, the tracking from that moment onwards seems to be linked with the pointer tool. Anytime it is not in view, the other tool does not update its transform information anymore. The moment the pointer comes back into view, then everything works fine. I’m not sure if this behaviour is being caused by how the data is transmitted to slicer, or by the data handling from the module. Any tips or information on this would be really appreciated.
I am using Slicer 5.8 for this, however I get the same behaviour in 5.6.2
If there is anyway I can somehow get a trace of events that happen internally within the OpenIGTLinkIF module whenever handling tracking data, that would probably help to figure out the issue, is that possible without building from source?
A quick clarification, in the first part of the post I said “…the first time the pointer tool enters in view it ruins the tracking for the other tool.”, however I meant “the first time the pointer tool enters in view while the secondary is in view aswell it ruins the tracking for the other tool.”
After taking a closer look and printing out the contents of the query response (IGTLTrackingDataBundleNode) and the elements inside it (LinearTransformNode), there are no updates happening to the transform matrices of the secondary tool once the issue starts. If the secondary tool is in view on its own after the issue, the only thing that updates inside the LinearTransformNode is the MTime, which keeps going up as usual.
At first I thought this might be an issue with the device I am getting the tracking data from, however when trying to communicate to the device through a data recording script (the Example for Tracker Client Program in C++ provided by OpenIGTLink), I can see inside the TDATA that all of the transform data updates just fine.
This makes me think that there’s some issue with how the Slicer module is currently handling the data it receives, or maybe the checks it uses to update nodes. I haven’t been able to find anything in the C++ files that seems like it could cause this, but I am not as experienced in C++. Would really appreciate any help.