Page MenuHomePhabricator

Fix 0.5-pixel offset issues
Closed, ResolvedPublic

Description

As a result of issue #2401, the interactive segmentation tools have difficulties now to detect the current slice of the image...

This must be fixed. Tobi, Ivo, can you summarize what you have changed?

Related Objects

Event Timeline

After discussion with Tobias and reading a part of the ITK discussion

http://www.itk.org/Bug/view.php?id=6558

I was able to fix the behavior of the manual segmentation tools. Ivo and Tobias, could you review these changes? Perhaps we can talk about my changes tomorrow?

[SVN revision 19782]
FIX (#2769): correction all the 0.5 pixel offset issues for manual segmentation tools

Setting to "normal" since issue seems to be fixed

Found that sometimes contours are not displayed unless the user performs reinit on the image (also Pic3D)

The reason behind this was:

  • Pic3D has a 3mm spacing in z direction
  • default world geometry is 1mm spacing in z direction
  • the effect is that after loading an image, MITK will sample 3 slices out of the image that all look the same (in the transversal view)
  • manual contouring tools determine the image slice (the same for all 3 views)
  • for user feedback a mitk::Contour object is created and filled with contour points
  • the contour points are centered at the current image slice
  • the ContourMapper2D only renders contours if they are closer than 1mm

--> contours are not rendered in some cases

Since the actual image slices to work on are determined correctly, I want to simply change the contour rendering, which can be easily done by using the "project" property. This property is already implemented and renders a projection of the contour to the current display geometry.

This is actually a different bug:

In the moment, an image has to be reinitialized to be rendered correctly.
There are also display issues in 3D and the cursor displacement Jochen reported in #2401. (see image there).

Markus, can you give a comment?

[SVN revision 19859]
FIX (#2769): project contour to 2D slice to make it visible in thick slices