>First, I'd like to thank Chris Pelkie and the other people who sent me
>ideias on how to put together some MR scans and make a 3D model of the brain.
>
>But now I'm having throuble importing the RGB image files with the import
>tool. When I use the readimage tool, the image appears ok, but with the
>import tool, the image is doubled.
>
>What are the best parameters to import a RGB image with the import tool?
>To give my numbers, my image has a geometry of 512x512, and the color is 24
>bit depth (I still don't know how to reduce the colors using the ImageMagick
>utility).
>
>If anyone has had the same problems with RGB files, please write to me.
>
>Thank you,
>
>Julio Dal Poz
>
Since ReadImage works, consider this. DX thinks an image is a 2D grid of
3-vector floats (RGB) mapped one to each grid point as the "colors"
component.
So once you have the image read in, you could Export it, using the format
"dx ieee 2". This pushes all the boring data into a binary file (foo.bin)
but also writes a nice readable ASCII header file (foo.dx) that you can
study to see how DX thinks such a file is organized. (Of course, once you
know how, YOU can write such files to operate on raw RGB images, but not
TIFFs, because they have all that other muck in them, which ReadImage has
nicely pulled out before the Export).
But you'd like to do "data" operations on these values so you have to make
DX think these are the "data". This is done with the Mark module.
So a three-module net: ReadImage->Mark("colors")->Export.
Then, use Import in another net to read in the exported .dx file.
Since RGB 3-vector is kind of a weird thing to try to make an isosurface
from (your brain reconstruction), you may also want to insert one more
module before Export (or after the Import in the second net):
Compute(expression left to the reader)
to convert RGB to luminance or some other scalar. I hope you know a
reasonable formula for this. Then when you Export, you'll be writing out a
scalar data component instead of a 3-vector colors component.
Chris Pelkie
Vice President/Scientific Visualization Producer
Conceptual Reality Presentations, Inc.
30 West Meadow Drive
Ithaca, NY 14850
[EMAIL PROTECTED]
(607) 257-8335 or (607) 254-8794