I had tried vtkImageCast but I guess its output was not compatible to my requirement and so used the shiftScale and got things working. :)<br><br><div class="gmail_quote">On Wed, Jul 14, 2010 at 12:36 PM, Jothy <span dir="ltr"><<a href="mailto:jothybasu@gmail.com">jothybasu@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div dir="ltr">I don't think shift will do that, instead that's for translation I think. I used vtkImageCast and I worked.<br>
<br>Of course, you can do that with vtkImageShiftScale!<br><font color="#888888"><br>Jothy</font><div><div></div><div class="h5"><br><br><div class="gmail_quote">
On Wed, Jul 14, 2010 at 5:32 PM, Preeti Bindu <span dir="ltr"><<a href="mailto:preetibindu@gmail.com" target="_blank">preetibindu@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Hi,<br><br>Use vtkImageShiftScale to shift your data from signed to unsigned. <br><br>Hope it helps,<br><br><div class="gmail_quote"><div><div></div><div>On Wed, Jul 14, 2010 at 11:59 AM, Jothy <span dir="ltr"><<a href="mailto:jothybasu@gmail.com" target="_blank">jothybasu@gmail.com</a>></span> wrote:<br>
</div></div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div><div></div><div><div dir="ltr">Used vtkImageCast.<br><br>jothy<br>
<br><div class="gmail_quote">On Wed, Jul 14, 2010 at 4:53 PM, Jothy <span dir="ltr"><<a href="mailto:jothybasu@gmail.com" target="_blank">jothybasu@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div dir="ltr">Hi all,<br><br>I am trying to volume render a vtkImageData, but it throws an error stating only unsigned char/unsigned short can be rendered not float.<br><br>How to convert the data type?<br><br>Thanks,<br>
<br>Jothy<br></div>
</blockquote></div><br></div>
<br></div></div><div>_______________________________________________<br>
Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Please keep messages on-topic and check the VTK FAQ at: <a href="http://www.vtk.org/Wiki/VTK_FAQ" target="_blank">http://www.vtk.org/Wiki/VTK_FAQ</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://www.vtk.org/mailman/listinfo/vtkusers" target="_blank">http://www.vtk.org/mailman/listinfo/vtkusers</a><br>
<br></div></blockquote></div><br><br clear="all"><br>-- <br>Regards,<br><font color="#888888">Preeti Bindu<br><br>
</font></blockquote></div><br></div></div></div>
</blockquote></div><br><br clear="all"><br>-- <br>Regards,<br>Preeti Bindu<br><br>