[vtkusers] vtk.js image volume issues

Richard Frank rickfrank at me.com
Fri Jul 20 17:57:38 EDT 2018

Ah, yes thanks that makes sense.





From: Sebastien Jourdain <sebastien.jourdain at kitware.com> 
Sent: Friday, July 20, 2018 5:54 PM
To: rickfrank at me.com
Cc: vtkusers at public.kitware.com
Subject: Re: [vtkusers] vtk.js image volume issues


You need to disable those lines as your data is homogeneous.


        // this.actor.getProperty().setUseGradientOpacity(0, true);

        // this.actor.getProperty().setGradientOpacityMinimumValue(0, 15);

        // this.actor.getProperty().setGradientOpacityMinimumOpacity(0, 0.0);

        // this.actor.getProperty().setGradientOpacityMaximumValue(0, 100);

        // this.actor.getProperty().setGradientOpacityMaximumOpacity(0, 1.0);

        // this.actor.getProperty().setShade(true);


On Fri, Jul 20, 2018 at 3:28 PM Richard Frank via vtkusers <vtkusers at public.kitware.com <mailto:vtkusers at public.kitware.com> > wrote:




I’m creating a simple volume from vtkImageData using vtk.js.


I create an empty 3d vtkImageData and set it up with a mapper and actor, and add it to the renderer.


I create a transfer function that has 0 = blue, 100 = red, 1000 = green.


I’m trying to set pixels directly in the volume.


There’s two problems – 


The first is that when I click anywhere on the screen the volume disappears…it shows on the first render call.


I have a button that is used to trigger the voxel setting. This seems to work only on the first slice of voxels, and the rest seem to not “stick”.

Regardless, however, the render call makes the volume disappear.


My code is here:




and can be built with the installation instructions like the other examples (this was cribbed from an example).


Anyone have any suggestions as to why the volume disappears, and / or ways to debug this?









Powered by www.kitware.com <http://www.kitware.com> 

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the VTK FAQ at: http://www.vtk.org/Wiki/VTK_FAQ

Search the list archives at: http://markmail.org/search/?q=vtkusers

Follow this link to subscribe/unsubscribe:

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://public.kitware.com/pipermail/vtkusers/attachments/20180720/df8a333b/attachment.html>

More information about the vtkusers mailing list