<html>
<head>
<style>
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
FONT-SIZE: 10pt;
FONT-FAMILY:Tahoma
}
</style>
</head>
<body class='hmmessage'><div style="text-align: left;"><br>After typing a gigantic email showing all the test results, and the fact that the new stuff did nothing; I decided to try flipping the vtk Dicom object's Z axis once more. I had tried it previously and it did nothing. To my surprise it actually worked this time! I don't understand why I have to flip BOTH the y axis and the z axis, but at least it does what its supposed to now.<br><br>Maybe it was a combination of things. I don't know.<br><br>I've just got 1 question. I've changed my images to OrientedImages, just because I thought that might help. I don't see how it's oriented though, because in all the examples nothing is ever set in order to orientate them to anything. How are they different to normal Images?<br><br>Thanks heaps for your help Luis. It actually helped me understand that my problem wasn't, in order for me to figure out what it was.<br></div><br><div></div><br><br><hr id="stopSpelling">> Date: Wed, 14 May 2008 14:43:53 -0400<br>> From: luis.ibanez@kitware.com<br>> To: w_e_b_m_a_s_t_e_r_6_9@hotmail.com<br>> CC: insight-users@itk.org<br>> Subject: Re: [Insight-users] 3D Segmentation Mask<br>> <br>> <br>> <br>> Hi Cameron,<br>> <br>> Thanks for the additional comments.<br>> <br>> The flipping of the Y axis should be ok, since<br>> it takes care of matching VTK and ITK coordinates.<br>> (but it is good to keep it in mind, in case it<br>> is producing secondary effects...)<br>> <br>> <br>> ------<br>> <br>> I'm concerned about your comment indicating that<br>> you change the image origin both after reading it<br>> and after converting it to VTK.<br>> <br>> If you are doing this "manually", this may be<br>> part of the problem.<br>> <br>> When an image is produced as the output of a filter<br>> you shouldn't modify its metadata, unless you first<br>> disconnect the image from the filter.<br>> <br>> If the image is produced by a filter, then you should<br>> use the ChangeInformationImageFilter.<br>> <br>> -----<br>> <br>> Direction cosines are used in ITK (and DICOM) for<br>> indicating the orientation of the image slices<br>> with respect to an base coordinate system. In your<br>> case they are set to identity, so... they are not<br>> involved in the problem that you are observing.<br>> <br>> <br>> -----<br>> <br>> <br>> The print out of the image->Print() methods looks<br>> fine. The relevant pieces are:<br>> <br>> BufferedRegion:<br>> Dimension: 3<br>> Index: [0, 0, 0]<br>> Size: [512, 512, 342]<br>> <br>> Spacing: [0.468, 0.468, 1]<br>> Origin: [0, 0, 0]<br>> Direction:<br>> 1 0 0<br>> 0 1 0<br>> 0 0 1<br>> <br>> ---<br>> <br>> Now what we will need is a chain of print outs<br>> of coordinates of your seed point from the moment<br>> that you acquire it in VTK to the moment you use<br>> it to query the PhysicalPointToIndex() method of<br>> the image.<br>> <br>> In one of those steps the proper coordinates<br>> of the seed point are getting lost.<br>> <br>> Please insert print out for those coordinates<br>> in your code, and set to the mailing list<br>> what you find.<br>> <br>> <br>> Thanks<br>> <br>> <br>> Luis<br>> <br><br><br /><hr />Hotmail on your mobile. <a href='http://www.livelife.ninemsn.com.au/article.aspx?id=343869' target='_new'>Never miss another e-mail with </a></body>
</html>