[Insight-users] TransformPhysicalPointToIndex not what i expected

Ella Maria Kadas ella_kadas at yahoo.com
Thu Apr 7 10:05:33 EDT 2011

   I am trying to convert coordinates that a get from points in a roi from a DICOM series to pixelindexes. The Coordinates that i use to initialize pointTemp are the right ones but when i use TransformPhysicalPointToIndex the index coordinates are all the same. Please help:)Cheers,  Ella

Here is the code:
ImageType::IndexType pixelIndex;
				ImageType::PointType pointTemp;
				NSPoint roiP = [[roiPoints objectAtIndex:k] point];
				float clocs[3];
				[ pix convertPixX: roiP.x pixY: roiP.y toDICOMCoords: clocs ];
				pointTemp[0] = clocs[0];
				pointTemp[1] = clocs[1];
				pointTemp[2] = clocs[2];
				bool isInside = result->TransformPhysicalPointToIndex(pointTemp,pixelIndex);
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.itk.org/pipermail/insight-users/attachments/20110407/e152ab7e/attachment.htm>

More information about the Insight-users mailing list