Page MenuHomePhabricator

Transversal Slider in Image Navigator
Closed, ResolvedPublic

Description

The transversal slider in the image navigator returns the invers slice value to the status bar, slice 0 in image navigator is max slice in status bar and vice versa

Event Timeline

In SliceNavigationController::Update() the update behaviour is different for the view direction being "Transversal". This results in the wrong slice number for the transversal slice.
Removing this distinction seems to solve this problem.

Does anybody know why this distinction was made?

In mitkSliceNavigationController:

void SliceNavigationController::Update()
{

if ( !m_BlockUpdate )
{

if ( m_ViewDirection == Transversal )
{
this->Update( Transversal, false, false, true );
}
else
{

this->Update( m_ViewDirection );

// }

}

}

I talked to Mathias yesterday. Because the slices can be rotated freely it's difficult to define a universal behaviour.
He agreed, that in the default case the image navigator and the index position should be the same. Just commenting out those lines won't help as the transveral slice will be shown wrong (top and bottom swapped). The solution would be to adapt the index of the transversal slider according to the maximal slice number.

(In reply to comment #2)

In SliceNavigationController::Update() the update behaviour is different for
the view direction being "Transversal". This results in the wrong slice number
for the transversal slice.
Removing this distinction seems to solve this problem.

Does anybody know why this distinction was made?

What I cannot remember (or understand anymore), is why the name of the method is "Update" ... it is rather something like Create(), isn't it? From a real update I would expect that nothing is changed, thus no "Set..." methods should be called (only the last 4 lines of the Update(...) method).
Anywhy:
SliceNavigationController::Update() creates ("updates") a WorldGeometry with default settings for the parameters top, frontside and rotated. The default setting of "rotated" for "viewDirection==Transversal" is "rotated==true" - otherwise the patient would lie on his stomach in the transversal view (for "viewDirection==sagittal" or "coronal" the setting "rotated==false" results in the expected behavior). The origin of this behavior is the definition of the dicom coordinate system.

See also the implementation of
void PlaneGeometry::InitializeStandardPlane( mitk::ScalarType width,

ScalarType height, const AffineTransform3D* transform,
PlaneGeometry::PlaneOrientation planeorientation, ScalarType zPosition,
bool frontside, bool rotated )

[SVN revision 21973]
FIX (#3402): added flag InverseDirection in QmitkSliderNavigatorWidget in order to change direction of slice navigation for transversal slice when using the ImageNavigatorView.

Merging "applicazion modules" component with "ExtApp plugins"