Hi all,

I tried to get curved MPRs working in MITK and followed the instructions 
in earlier postings to this mailing list. However, I ran into a problem.

Currently I'm doing this:

/////
// begin code snipped
/////

     mitk::Image::ConstPointer refImage = GetReferenceImage();
     mitk::PointSet* data = ... // get point set

     if (data && refImage.GetPointer())
     {
         mitk::ThinPlateSplineCurvedGeometry::Pointer tpsGeometry =
                mitk::ThinPlateSplineCurvedGeometry::New();
         {
             mitk::Geometry3D* imagegeometry = refImage->GetGeometry();
             const mitk::PlaneGeometry *plane2 =
 
m_MultiWidget->GetRenderWindow2()->GetSliceNavigationController()->GetCurrentPlaneGeometry();

             // Set a reference 3D geometry (e.g. Geometry3D of an 
existing image volume)
             tpsGeometry->SetFrameGeometry(imagegeometry);
 
tpsGeometry->SetReferenceGeometry(plane2->GetReferenceGeometry());


             // Create projector class; target landmarks will be 
projected on
             // a plane to create source landmarks for thin plate spline
             // (plane is a mitk::PlaneGeometry, e.g. one of the standard
             // coronal, sagittal, or transversal planes)
             mitk::PlaneLandmarkProjector::Pointer planeLandmarkProjector =
                mitk::PlaneLandmarkProjector::New();
             mitk::PointSet::DataType::PointsContainer::Pointer 
targetLandmarks =
                data->GetPointSet()->GetPoints();

             planeLandmarkProjector->SetProjectionPlane( plane2 );
             planeLandmarkProjector->ProjectLandmarks(targetLandmarks);

             // Initialize TPS geometry with projector
             tpsGeometry->SetLandmarkProjector(planeLandmarkProjector);
             tpsGeometry->SetTargetLandmarks(targetLandmarks);
             tpsGeometry->ComputeGeometry();

         }


         mitk::BaseRenderer* mappingRenderer = 
mitk::BaseRenderer::GetInstance(m_MultiWidget->mitkWidget2->GetRenderWindow());
         mappingRenderer->SetWorldGeometry(tpsGeometry);


/////
// end code snipped
/////

The result is this (screenshot):
http://tinyurl.com/3wdcxbz

This is close to what I'd like to have, but the green (curved) MPR is 
for some reason cropped in the 3D view and does not cut the whole 
volume. The 2D views are all right. Does anybody have an idea how to 
make it go through the whole volume image in the 3D view?

Many thanks in advance,
Johannes

------------------------------------------------------------------------------
Storage Efficiency Calculator
This modeling tool is based on patent-pending intellectual property that
has been used successfully in hundreds of IBM storage optimization engage-
ments, worldwide.  Store less, Store more with what you own, Move data to 
the right place. Try It Now! http://www.accelacomm.com/jaw/sfnl/114/51427378/
_______________________________________________
mitk-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mitk-users

Reply via email to