Path: news.mathworks.com!newsfeed-00.mathworks.com!newsfeed2.dallas1.level3.net!news.level3.com!postnews.google.com!r38g2000vbi.googlegroups.com!not-for-mail
From: ImageAnalyst <imageanalyst@mailinator.com>
Newsgroups: comp.soft-sys.matlab
Subject: Re: point cloud generation
Date: Sat, 3 Jan 2009 10:42:30 -0800 (PST)
Organization: http://groups.google.com
Lines: 23
Message-ID: <a1495900-8c7f-4a9f-b615-95a03a21bc1b@r38g2000vbi.googlegroups.com>
References: <gjemqe$2bq$1@fred.mathworks.com> <gjeqcp$6kj$1@fred.mathworks.com> 
	<7a888811-3ce0-4434-a4ef-5d1edf8806d4@f3g2000vbf.googlegroups.com> 
	<gjo61h$g9e$1@fred.mathworks.com>
NNTP-Posting-Host: 75.186.70.56
Mime-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
X-Trace: posting.google.com 1231008151 19597 127.0.0.1 (3 Jan 2009 18:42:31 GMT)
X-Complaints-To: groups-abuse@google.com
NNTP-Posting-Date: Sat, 3 Jan 2009 18:42:31 +0000 (UTC)
Complaints-To: groups-abuse@google.com
Injection-Info: r38g2000vbi.googlegroups.com; posting-host=75.186.70.56; 
	posting-account=0rLUzAkAAABojYSRC64DkTbtiSCX77HH
User-Agent: G2/1.0
X-HTTP-UserAgent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; .NET 
	CLR 1.1.4322; .NET CLR 2.0.50727; .NET CLR 3.0.04506.648; .NET CLR 
	3.5.21022),gzip(gfe),gzip(gfe)
Xref: news.mathworks.com comp.soft-sys.matlab:509679


I wasn't talking about using 3 arrays.

I'm talking about using ONE 3D array where you have 3 indexed
dimensions, one for x, one for y, and one for z.  Or you could have
just one 2D array (if you can't fit the whole 3D image into memory at
one time), just so long as you know what the slice number (z index) of
the current slice is.  Then the "coordinates of the points" (sic, her
words) are just simply the x,y,z coordinates (units are in pixels,
voxels) or in mm if you can convert the x,y,z into mm.  Sven just
paraphrased what I said, so we're in complete agreement.  For example
if you have 0.5 mm per pixel, and you're looking at pixel (100, 200,
50) then in millimeters that would be (50, 100, 25).  It's as simple
as that.  Or it can be.  It can get a little more complex if the z
calibration (slice separation) is not the same as the x,y lateral
resolution, plus the fact that you have to image an object of known
dimensions to determine your spatial calibration in all 3 directions,
not to mention partial volume averaging, beam hardening, and
reconstruction artifacts that complicate things.  But I doubt maya
needs to worry about any of those latter things yet.  You may be able
to read the spatial calibrations out of the header of the (DICOM or
whatever-format) file (if you trust it), or calculate it on your own
using your object of known dimensions (I have seen discrepancies
between the two methods).