[IGSTK-Users] IGSTK Oblique Slicing

Mark Cachia m_cachia at hotmail.com
Tue Nov 29 16:12:09 EST 2011


Hello all,

I'm relatively new at IGSTK and am trying to accomplish tool driven oblique slicing. What I want to do is have the coronal, axial and sagittal slices in a render window and reslice them depending on where the tool is. I can get the slices to appear in my render window, but when I move the tool nothing happens. I've included the relevant code: 

m_imageResliceRepresentation3D.resize(3);
m_reslicerPlaneSpatialObject3D.resize(3);

for( int p  = 0; p < 3; p++ ){
    m_imageResliceRepresentation3D[p] = ImageResliceRepresentationType::New();
    m_imageResliceRepresentation3D[p]->RequestSetImageSpatialObject( m_ImageSpatialObject );
    
    m_reslicerPlaneSpatialObject3D[p] = ReslicerPlaneType::New();
    m_reslicerPlaneSpatialObject3D[p]->RequestSetReslicingMode( ReslicerPlaneType::Oblique );
    m_reslicerPlaneSpatialObject3D[p]->RequestSetOrientationType( ReslicerPlaneType::PlaneOrientationWithZAxesNormal );
    m_reslicerPlaneSpatialObject3D[p]->RequestSetBoundingBoxProviderSpatialObject( m_ImageSpatialObject );
}


igstk::Transform identity;
identity.SetToIdentity( igstk::TimeStamp::GetLongestPossibleTime() );

m_ImageSpatialObject->RequestSetTransformAndParent( identity, m_WorldReference );

for( int p = 0; p < 3; p++ ){
    m_reslicerPlaneSpatialObject3D[p]->RequestSetTransformAndParent( identity, m_WorldReference );
    m_imageResliceRepresentation3D[p]->RequestSetReslicePlaneSpatialObject( m_reslicerPlaneSpatialObject3D[p] );
}

for( int p = 0; p < 3; p++ ){
    m_reslicerPlaneSpatialObject3D[p]->RequestSetToolSpatialObject( m_PolarisToolObject );
}

m_Views[idx3D]->RequestAddObject( m_imageResliceRepresentation3D[idxObl] );
m_reslicerPlaneSpatialObject3D[idxNormal]->RequestSetOrientationType( ReslicerPlaneType::PlaneOrientationWithXAxesNormal );
m_reslicerPlaneSpatialObject3D[idxHorizontal]->RequestSetOrientationType( ReslicerPlaneType::PlaneOrientationWithYAxesNormal );
m_reslicerPlaneSpatialObject3D[idxVertical]->RequestSetOrientationType( ReslicerPlaneType::PlaneOrientationWithZAxesNormal );

Any help would be greatly appreciated! Thank you very much.
 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/igstk-users/attachments/20111129/04ff6c38/attachment-0001.html>


More information about the IGSTK-Users mailing list