<!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.6000.16825" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT face=Arial>Hi folks</FONT></DIV>
<DIV><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial>It is me again. I got some progress. When I added the 
following sentence to realice2 and reslice3. Finally I can see part of the image 
in some slices. </FONT></DIV>
<DIV><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial>&nbsp;&nbsp; 
reslice3-&gt;SetOutputExtent(0,255,0,255,0,255);<BR>&nbsp;&nbsp; 
reslice3-&gt;SetOutputSpacing(1, 1, 1);</FONT></DIV>
<DIV><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial>It seems that the images are not on the center of the 
viewer. I guess the reson is wrong rotation origin. but I do not know how to set 
it. Also the output is not correct.</FONT></DIV>
<DIV><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial>I will appreciate your help so much if you will give me a 
hand on following setting for a series of dicom files.</FONT></DIV>
<DIV><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial>SetDataOrigin </FONT></DIV>
<DIV><FONT face=Arial>SetOutputSpacing</FONT></DIV>
<DIV><FONT face=Arial>SetOutputExtent</FONT></DIV>
<DIV><EM><FONT face=Arial></FONT></EM>&nbsp;</DIV>
<DIV><FONT face=Arial>Thanks.</FONT></DIV>
<DIV><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial>Regards</FONT></DIV>
<DIV><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial>Liang</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<BLOCKQUOTE 
style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
  <DIV style="FONT: 10pt arial">----- Original Message ----- </DIV>
  <DIV 
  style="BACKGROUND: #e4e4e4; FONT: 10pt arial; font-color: black"><B>From:</B> 
  <A title=leo@esit.com href="mailto:leo@esit.com">Liang Ma</A> </DIV>
  <DIV style="FONT: 10pt arial"><B>To:</B> <A title=vtkusers@vtk.org 
  href="mailto:vtkusers@vtk.org">vtkusers@vtk.org</A> </DIV>
  <DIV style="FONT: 10pt arial"><B>Sent:</B> Saturday, April 18, 2009 4:17 
  PM</DIV>
  <DIV style="FONT: 10pt arial"><B>Subject:</B> [vtkusers] How to SetDataOrigin 
  when I use vtkImageReslice to getsagittal and coronal images?</DIV>
  <DIV><BR></DIV>
  <DIV><FONT face=Arial size=2>Hi all,</FONT></DIV>
  <DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
  <DIV><FONT face=Arial size=2>I want to get axial, sagittal and coronal images 
  from a series of dicom files.&nbsp;And then get the 3D coordinate of a point 
  in the image.</FONT><FONT face=Arial size=2>&nbsp;Now I can see the axial 
  image. But The sagittal and coronal images seem not correct. Most of them are 
  black. I can only see a band on&nbsp;sagittal's&nbsp;bottom and&nbsp;coronal's 
  left in few slices.&nbsp;</FONT></DIV>
  <DIV>&nbsp;</DIV>
  <DIV><FONT face=Arial size=2>(1) I guess the reason is I did not use&nbsp; 
  SetDataOrigin function. I tried but do not know how to choose the parameters. 
  And when I use&nbsp; SetDataOrigin, the program become very slow.</FONT></DIV>
  <DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
  <DIV><FONT face=Arial size=2>(2) In the sample program, a vtkVolume16Reader is 
  created to read the Dicom files. I got a error:</FONT></DIV>
  <DIV><FONT face=Arial size=2>ERROR: In E:\vtk-5.0.3\IO\vtkVolume16Reader.cxx, 
  line 384<BR>vtkVolume16Reader (0x023250E0): Error reading raw pgm 
  data!</FONT></DIV>
  <DIV><FONT face=Arial size=2>So I use vtkDICOMImageReader to read the dicom 
  images. Is it a problem?</FONT></DIV>
  <DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
  <DIV><FONT face=Arial size=2>(3) Is there any other parameters to be 
  set?</FONT></DIV>
  <DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
  <DIV><FONT face=Arial size=2>Thanks</FONT></DIV>
  <DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
  <DIV><FONT face=Arial size=2>Liang</FONT></DIV>
  <P>
  <HR>

  <P></P>_______________________________________________<BR>Powered by 
  www.kitware.com<BR><BR>Visit other Kitware open-source projects at 
  http://www.kitware.com/opensource/opensource.html<BR><BR>Please keep messages 
  on-topic and check the VTK FAQ at: 
  http://www.vtk.org/Wiki/VTK_FAQ<BR><BR>Follow this link to 
  subscribe/unsubscribe:<BR>http://www.vtk.org/mailman/listinfo/vtkusers<BR></BLOCKQUOTE></BODY></HTML>