<DIV>hello everyone,</DIV>
<DIV> I use dicom2 to convert 002.dcm....123.dcm to 002.dcm.raw....123.dcm.raw,and use the vtkVolume16Reader to read the raw files,but the v16.SetFilePattern("%s%3d.dcm.raw") has something wrong, In the output window:can not find d:\rawdata\ 2.dcm.raw ,how to set the patterns?Let d:\rawdata\002.dcm.raw could be readed.</DIV>
<DIV> </DIV>
<DIV>here are the codes.I use Java language</DIV>
<DIV>//////////////////////////////////////////////////////////////</DIV>
<DIV>vtkDICOMImageReader dicomReader = new vtkDICOMImageReader();<BR> dicomReader.SetDirectoryName("d:/dicom");<BR> dicomReader.Update(); <BR> double[] dataSpacing = dicomReader.GetDataSpacing();<BR> System.out.println(dataSpacing[0] + ":" + dataSpacing[1] + ":" + dataSpacing[2]);<BR> vtkVolume16Reader v16 = new vtkVolume16Reader();<BR> v16.SetDataByteOrderToLittleEndian();<BR> v16.SetFilePrefix("d:/rawdata/");<BR> v16.SetFilePattern("%s%3d.dcm.raw");<BR> v16.SetImageRange(2, 123);<BR> v16.GetOutput().ReleaseDataFlagOn();<BR> v16.SetDataSpacing(dicomReader.GetDataSpacing());<BR> v16.SetDataDimensions(dicomReader.GetOutput().GetDimensions());<BR> v16.Update();<BR> <BR> Thread.sleep(10000);<BR> vtkImageGaussianSmooth GaussianSmooth = new vtkImageGaussianSmooth();<BR> GaussianSmooth.SetInput(v16.GetOutput());<BR> GaussianSmooth.SetDimensionality (3);<BR> GaussianSmooth.SetStandardDeviations(0.0,4.0);<BR> vtkContourFilter skinExtractor = new vtkContourFilter();<BR> skinExtractor.SetInput((vtkDataSet)GaussianSmooth.GetOutput());<BR> skinExtractor.SetValue(0, 500);<BR> skinExtractor.Update();</DIV>
<DIV> vtkSmoothPolyDataFilter smoother=new vtkSmoothPolyDataFilter();<BR> smoother.SetInput(skinExtractor.GetOutput());<BR> smoother.SetNumberOfIterations(70);</DIV>
<DIV> vtkPolyDataNormals skinNormals = new vtkPolyDataNormals();<BR> skinNormals.SetInput(smoother.GetOutput());<BR> skinNormals.SetFeatureAngle(60.0);</DIV>
<DIV><BR> vtkPolyDataWriter pdw=new vtkPolyDataWriter();<BR> pdw.SetInput(skinNormals.GetOutput());<BR> pdw.SetFileName("d:/out.vtk");<BR> pdw.Write();</DIV>
<DIV> </DIV>
<DIV> </DIV>
<DIV>/////////////////////////////////////////</DIV>
<DIV > </DIV><br><!-- footer --><br><div style="border-bottom:1px solid #999"></div><br>
        <font color="black" style="font-size:14.8px"> 昨 天 和 女 友 b u y 疯 了 ! ! ! </font>
        <br>
         <a href="http://adtaobao.allyes.com/main/adfclick?db=adtaobao&bid=600,597,58&cid=29985,198,1&sid=32501&show=ignore&url=http://www.taobao.com/theme/lucky_new_year/index.php" target="_blank" style="font-size:13px;line-height:160%;color:blue"> 年 末 万 种 精 品 大 促 销 , 8 0 万 大 奖 天 天 送 ( 绝 对 保 真 )
</a>