<div>Thanks for the answer. <br><br>Here is the bug report :</div><a href="http://vtk.org/Bug/view.php?id=11391">http://vtk.org/Bug/view.php?id=11391</a><div><br></div><div><a href="http://vtk.org/Bug/view.php?id=11391"></a>I'll try to experiment with the 'manual' image resample to see if we can get some improvment.</div>
<div><br></div><div>-Simon</div><div><br><br><div class="gmail_quote">On Mon, Nov 1, 2010 at 04:55, Karthik Krishnan <span dir="ltr"><<a href="mailto:karthik.krishnan@kitware.com">karthik.krishnan@kitware.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">Simon:<br>
<br>
Thanks. Please log a bug report at <a href="http://vtk.org/Bug" target="_blank">vtk.org/Bug</a>, so we don't forget<br>
about it. We should be querying the available VRAM (as is done in the<br>
GPURaycast mapper) and the MAX_3D_TEXTURE_SIZE to compute the<br>
decimated extents.<br>
<br>
On a side note, you may want to experiment with seeing if you can<br>
perform the "resample" faster using vtkImageResample. The 3D texture<br>
mapper uses its own resampling, which is smart, but not multi-threaded<br>
unlike vtkImageReslice. The gradient pre-computation and resampling<br>
can be done a lot faster than it is now. You can log a feature request<br>
/ (contribute a patch :) ) for the same.<br>
<br>
--<br>
karthik<br>
<div><div></div><div class="h5"><br>
<br>
On Fri, Oct 29, 2010 at 8:13 PM, Simon ESNEAULT <<a href="mailto:sesneault@gmail.com">sesneault@gmail.com</a>> wrote:<br>
> Hi All,<br>
> Since vtk 5.6 is out, we have some trouble using vtkVolumeTextureMapper3D.<br>
> With VTK 5.4 rendering a volume of 512x512x366 consumes around 500 Mo and<br>
> needs one or two seconds to load. The interactivity is good (20 fps)<br>
> With VTK 5.6, rendering the same volume consumes 1700 Mo and needs more than<br>
> 30 seconds to load. And the interactivity is unusable. (~1 fps)<br>
> Test done on an intel i7 870 cpu, with an nvidia gtx 260, Ubuntu Linux 64<br>
> bits (same result on windows 7).<br>
> After some investigation, it appears that the pb, is the use of<br>
> MAX_3D_TEXTURE_SIZE in the file vtkOpenGLVolumeTextureMapper3D.cxx instead<br>
> of an harcoded max texture size (128*256*256) as it used to be in vtk 5.4.<br>
> In the documentation it is said that all the volume will be resampled to a<br>
> 128*256*256 volume, but it's no longer true in > 5.4.<br>
> As a rough hack, if we changed the code around line 1970 of the<br>
> file vtkOpenGLVolumeTextureMapper3D.cxx :<br>
> int vtkOpenGLVolumeTextureMapper3D::IsTextureSizeSupported(int<br>
> size[3], components)<br>
> {<br>
> GLint maxSize;<br>
> glGetIntegerv(vtkgl::MAX_3D_TEXTURE_SIZE,&maxSize);<br>
> if(size[0]>maxSize || size[1]>maxSize || size[2]>maxSize)<br>
> {<br>
> return 0;<br>
> }<br>
> ... into ...<br>
> int vtkOpenGLVolumeTextureMapper3D::IsTextureSizeSupported(int<br>
> size[3], components)<br>
> {<br>
> GLint maxSize;<br>
> glGetIntegerv(vtkgl::MAX_3D_TEXTURE_SIZE,&maxSize);<br>
> maxSize = 256;<br>
> if(size[0]>maxSize || size[1]>maxSize || size[2]>maxSize)<br>
> {<br>
> return 0;<br>
> }<br>
> ... we get back the good old behavior of this 3D volume mapper.<br>
> Maybe this can be set as an option, something like<br>
> mapper->Max3DTextureSizeOn(), to prevent that problem.<br>
><br>
> Thanks for listening, and thanks a lot for VTK.<br>
> -Simon<br>
><br>
> --<br>
> ------------------------------------------------------------------<br>
> Simon Esneault - Therenva<br>
> Centre d'Innovation Technologique<br>
> Centre Cardio-Pneumologique<br>
> CHU Pontchaillou<br>
> Rennes, France<br>
> Tel : +33 (0)6 64 61 30 94<br>
> Mail : <a href="mailto:simon.esneault@therenva.com">simon.esneault@therenva.com</a><br>
> ------------------------------------------------------------------<br>
><br>
</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<br>
> <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:<br>
> <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>
><br>
</blockquote></div><br><br clear="all"><br>-- <br>------------------------------------------------------------------<br>Simon Esneault - Therenva<br>Centre d'Innovation Technologique<br>Centre Cardio-Pneumologique<br>
CHU Pontchaillou<br>Rennes, France<br>Tel : +33 (0)6 64 61 30 94<br>Mail : <a href="mailto:simon.esneault@therenva.com">simon.esneault@therenva.com</a><br>------------------------------------------------------------------<br>
</div>