<br><font size=2 face="sans-serif">Thomas,</font>
<br>
<br><font size=2 face="sans-serif">Something doesn't sound right here.....you should have 27 voxels wth 27 associated scalars. When rendered, this should give you 27 voxels. I would not expect 8 voxels. Are you sure your image data is really 3x3x3? Perhaps sharing your short code would be helpful....john</font>
<br>
<br><font size=2 face="sans-serif">p.s Interpolation is for sampling scalars during rendering if I remember correctly....has nothing to do with interpolating to get more voxels</font>
<br>
<br>
<br>
<br>
<br>
<table width=100%>
<tr valign=top>
<td>
<td><font size=1 face="sans-serif"><b>Thomas Faust &lt;tf@thermoanalytics.com&gt;</b></font>
<br><font size=1 face="sans-serif">Sent by: vtkusers-admin@vtk.org</font>
<p><font size=1 face="sans-serif">05/06/2004 06:28 PM</font>
<br>
<td><font size=1 face="Arial">&nbsp; &nbsp; &nbsp; &nbsp; </font>
<br><font size=1 face="sans-serif">&nbsp; &nbsp; &nbsp; &nbsp; To: &nbsp; &nbsp; &nbsp; &nbsp;David Gobbi &lt;dgobbi@imaging.robarts.ca&gt;</font>
<br><font size=1 face="sans-serif">&nbsp; &nbsp; &nbsp; &nbsp; cc: &nbsp; &nbsp; &nbsp; &nbsp;vtkusers@vtk.org, (bcc: John Anast-JM/PGI)</font>
<br><font size=1 face="sans-serif">&nbsp; &nbsp; &nbsp; &nbsp; Subject: &nbsp; &nbsp; &nbsp; &nbsp;Re: [vtkusers] voxel values in vtkImageData</font></table>
<br>
<br>
<br><font size=2 face="Courier New"><br>
Thanks David, but this doesn't solve my problem at all.<br>
<br>
I was changing the interpolation method back and for, but the output didn't <br>
changed.<br>
<br>
I'm not dealing with values that are defined on the gridpoints; my values are <br>
the voxel itself. <br>
<br>
I'll give you (David and all out there) an example:<br>
My matrix is 3x3x3 with the values: 000 010 000 - 010 111 010 - 000 010 000<br>
Do I expect to much brain grease if i would ask you to picture this values in <br>
your imagination in 3D? Right, this is an 3D cross.<br>
But, if this is my vtkImageData I'll get a volume, that is just 2 voxels in <br>
each direction. Please give it a try. (I'll at the 15 line source code if you <br>
want me to)<br>
<br>
What I'd like to see as an output is an volume, that comes with 27 (3x3x3) <br>
voxel. This means that this volume would have 64 (4x4x4) gridpoints. What I <br>
told about interpolation is, that i can't interpolate these 64 gridpoints out <br>
of the 27 values to create my own new vtkImageData.<br>
It's all about the interpretation of values in vtkImageData by <br>
vtkVolumeMapper.<br>
<br>
Thanks for your efforts.<br>
Thomas<br>
<br>
On Thursday 06 May 2004 05:56 pm, you wrote:<br>
&gt; Hi Thomas,<br>
&gt;<br>
&gt; It looks like all you need to do is turn off interpolation:<br>
&gt;<br>
&gt; volume-&gt;GetProperty()-&gt;SetInterpolationTypeToNearest();<br>
&gt;<br>
&gt; On Thu, 6 May 2004, Thomas Faust wrote:<br>
&gt; &gt; Hi VTK users,<br>
&gt; &gt;<br>
&gt; &gt; Lately I'm confronted with volume rendering. I decided to use VTK as<br>
&gt; &gt; graphical tool to render a huge mass of data. So far, I'm impressed by<br>
&gt; &gt; the power and usability of VTK.<br>
&gt; &gt;<br>
&gt; &gt; My problem is the handling of vtkImageData in vtkVolumeMapper.<br>
&gt; &gt; My model is created by a collection of values in 3 directions (x,y,z).<br>
&gt; &gt; These are stored in vtkImageData.<br>
&gt; &gt; I expect a volume that extent 3 values(voxels) in each direction to be 3<br>
&gt; &gt; length units long. But it isn't (It's just 2). The reason for this is,<br>
&gt; &gt; that the vtkVolumeMapper interprets 3 points in one direction as 3 corner<br>
&gt; &gt; points (vertices) of voxels. So I end up with 2 voxels that are a mixture<br>
&gt; &gt; between my original values.<br>
&gt; &gt;<br>
&gt; &gt; The problem is that a interpolation between these values is not a option,</font>
<br><font size=2 face="Courier New">&gt; &gt; because two values that are even close together means totaly different<br>
&gt; &gt; things. (e.g. 0x40 is material A, 0x41 is material B)<br>
&gt; &gt;<br>
&gt; &gt; How can I change one of the vtkVolumeMappers to interpret the values in<br>
&gt; &gt; vtkImageData to be voxel-based and not vertex-based?<br>
&gt; &gt;<br>
&gt; &gt; Any comments are welcome and will be answered.<br>
&gt; &gt; Thanks in advance<br>
&gt; &gt; _______________________________________________<br>
&gt; &gt; This is the private VTK discussion list.<br>
&gt; &gt; Please keep messages on-topic. Check the FAQ at:<br>
&gt; &gt; &lt;http://public.kitware.com/cgi-bin/vtkfaq&gt; Follow this link to<br>
&gt; &gt; subscribe/unsubscribe:<br>
&gt; &gt; http://www.vtk.org/mailman/listinfo/vtkusers<br>
_______________________________________________<br>
This is the private VTK discussion list. <br>
Please keep messages on-topic. Check the FAQ at: &lt;http://public.kitware.com/cgi-bin/vtkfaq&gt;<br>
Follow this link to subscribe/unsubscribe:<br>
http://www.vtk.org/mailman/listinfo/vtkusers<br>
</font>
<br>
<br>