<html>
<head>
<style>
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
FONT-SIZE: 9pt;
FONT-FAMILY:Tahoma
}
</style>
</head>
<body class='hmmessage'>
hallo everyone, ich have the question, i have the surface and image, i want to cut a part of image with surface, i use this :<br><br><br> (vtkLinearTransform) transform = surface->GetTimeSlicedGeometry()->GetGeometry3D(0)->GetVtkTransform();<br> (vtkTransformPolyDataFilter) transformFilter->SetInput(surface->GetVtkPolyData());<br> transformFilter->SetTransform(transform);<br> transformFilter->Update(); <br><br> <br> dataToStencil->SetInput( transformFilter->GetOutput());<br> stencilData = dataToStencil->GetOutput();<br> stencil->SetStencil(stencilData);<br> stencil->SetBackgroundValue( 0 );<br> stencil->ReverseStencilOff();<br><br> vtkImageData *vtkimage =(mitkImage) img->GetVtkImageData();<br> stencil->SetInput( vtkimage );<br> stencil->Update();<br> vtkimage = stencil->GetOutput();<br><br>i can cut the image with surface, but this neu cutted image is not in good position, i want to show this neu cutted image looked like original image, that means in the mittel,but not at the corner of all. how can i do that?<br><br>best regards<br><br><br><br><div>
<BR></div><br /><hr />使用新一代 Windows Live Messenger 轻松交流和共享! <a href='http://messenger.live.cn/' target='_new'>立即体验!</a></body>
</html>