<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=gb2312">
<META content="MSHTML 6.00.2900.2802" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT face="Bookman Old Style">Hi,</FONT></DIV>
<DIV><FONT face="Bookman Old Style"></FONT> </DIV>
<DIV><FONT face="Bookman Old Style">I built a pipeline as shown
below,</FONT></DIV>
<DIV><FONT face="Bookman Old Style"></FONT> </DIV>
<DIV><FONT face="Bookman Old Style">//use itk to read dicom series</FONT></DIV>
<DIV><FONT face="Bookman Old Style">dicomReader =
ReaderType_Short::New();//itk<BR></FONT><FONT
face="Bookman Old Style">dicomReader->SetFileNames( fileNames
); <BR>dicomReader->Update();<BR></FONT></DIV>
<DIV><FONT face="Bookman Old Style"></FONT> </DIV>
<DIV><FONT face="Bookman Old Style"> //convert itk image to vtk
image<BR> connectorMRI =
ConnectorType::New();<BR> connectorMRI->SetInput(dicomReader->GetOutput());<BR> try<BR> { <BR> connectorMRI->Update();<BR> }<BR> catch(
itk::ExceptionObject & excp )<BR> {<BR> std::cerr <<
"Error reading the series " << std::endl;<BR> std::cerr
<< excp << std::endl;<BR> }</FONT></DIV>
<DIV><FONT face="Bookman Old Style"></FONT> </DIV>
<DIV><FONT face="Bookman Old Style">//shift image from short to unsigned short
type for vtk visualization</FONT></DIV>
<DIV><FONT
face="Bookman Old Style">shift->SetInput(connectorMRI->GetOutput());</FONT></DIV>
<DIV><FONT face="Bookman Old Style">shift->ReleaseDataFlagOn();</FONT></DIV>
<DIV><FONT face="Bookman Old Style">shift->Update();</FONT></DIV>
<DIV><FONT face="Bookman Old Style"></FONT> </DIV>
<DIV><FONT face="Bookman Old Style">//Generate a vtk volume</FONT></DIV>
<DIV><FONT face="Bookman Old Style">volume =
GenerateVTKVolume(shift->GetOutput());</FONT></DIV>
<DIV><FONT face="Bookman Old Style"></FONT> </DIV>
<DIV><FONT face="Bookman Old Style">I read a dicoms series, which needs
about 100M memory. I take a look at the memory that ITKImage holds 100M
and the shift holds another 100M. However, I set the release data flag to On in
shift. Why does it not release the memory ?</FONT></DIV>
<DIV><FONT face="Bookman Old Style"></FONT> </DIV>
<DIV><FONT face="Bookman Old Style">Regards,</FONT></DIV>
<DIV><FONT face="Bookman Old Style"></FONT> </DIV>
<DIV><FONT face="Bookman Old Style">Yixun Liu</DIV>
<DIV><BR></DIV></FONT>
<DIV><FONT face="Bookman Old Style"></FONT> </DIV></BODY></HTML>