Page MenuHomePhabricator

NavigationData to PointSet filter for MITK-IGT
Closed, ResolvedPublic

Description

Design and implement a filter that stores the positions (and maybe orientations?) from incoming NavigationData objects in either multiple 3D pointsets or one 4D pointset (optimally both methods would be possible, either in two separate filters or configurable in one filter).

Event Timeline

optionally, but with low priority: write a PointSet to NavigationData filter, that does the reverse transformation

A first version of the filter was submitted. There are two operation modes.

3D Mode:
The current input NavigationData is converted to ONE pointset with just one timestep.

4D Mode:
The current input is added to a 4D pointset. The number of timestamps are adjusted with the method SetRingBufferSize(int).

All features are implemented

I will change/enhance this filter.

3D Mode should append points when updated, not overwrite the point. it should also create multiple pointsets as output. This will allow to show trajectories of tool movement.

I changed the NavigationDataToPointSetFilter 3D mode:

  • It will create one output Pointset per input NavigationData
  • On each Update(), it will insert the position of the input NavigationData into the corresponding output PointSet
  • It does not yet use the Ringbuffer to limit the size of the pointsets. To do that, it should remove the oldest points from the pointset if more points than ringbuffer size are inserted.

I also changed the behavior of the PointSetVtkMapper3D:

  • Introduced a new BoolProperty: "updateDataOnRender" - Only if set to true, Update() will be called on the input pointset. Previous default behavior was to always call Update(). If the Pointset was still connected to a pipeline (as is generally the case with NavigationDataToPointSetFilter), the pipeline would be executed on every render.

--> revision #16819 contains the changes.

revision #16821 contains a fix to the unit test.

Current version is ready for 0.12 release,
Ringbuffer feature will be added later (documented in revision #16999).

Therefore removing from 0.12 target milestone.

Added empty implementation of GenerateOutputInformation() to avoid NavigationData <--> BaseData casting exception originating from recent changes in BaseData, added check for IsDataValid() in GenerateData() to avoid adding invalid points.
changes are in revision #1795.