[Paraview] Use separate arrays for colormap and opacity
Sankhesh Jhaveri
sankhesh.jhaveri at kitware.com
Thu Jun 29 14:29:26 EDT 2017
Hi Evan,
This is already supported in VTK for the volume mapper. You can have a
single array with either 2 components and set them as dependent components
via vtkVolumeProperty
<http://www.vtk.org/doc/nightly/html/classvtkVolumeProperty.html#aea26cdad334f47cf078c3ab9f1b70764>.
This feature is not exposed in ParaView but it would just be a matter of
creating the GUI elements and adding a filtering step to combine two arrays
into a single two-component array.
For polygonal data, can’t think of a better route than the one suggested by
Utkarsh i.e. manually map the arrays through the lookup tables and create
an RGBA array. Make sure to uncheck Map Scalars to use the RGBA values
directly. Having said that, this can also be implemented as a feature on
the vtkPolyDataMapper similar to the volume mapper.
Hope that helps,
Sankhesh
From: Utkarsh Ayachit
[utkarsh.ayachit at kitware.com](mailto:utkarsh.ayachit at kitware.com)
<http://mailto:[utkarsh.ayachit@kitware.com](mailto:utkarsh.ayachit at kitware.com)>
To: Evan Kao [tossin at gmail.com](mailto:tossin at gmail.com)
<http://mailto:[tossin@gmail.com](mailto:tossin at gmail.com)>
Cc: ParaView [paraview at paraview.org](mailto:paraview at paraview.org)
<http://mailto:[paraview@paraview.org](mailto:paraview at paraview.org)>
Bcc:
Date: Thu, 29 Jun 2017 10:55:45 -0400
Subject: Re: [Paraview] Use separate arrays for colormap and opacity
One option is to use “Python Programmable Filter” to generate an RGBA
array in which you do the color and opacity mapping yourself. You
won’t have access to the color and opacity transfer ParaView sets up,
but you can create your own internally. Not the most elegant solution
— but a solution, nonetheless.
Utkarsh
--
Sankhesh Jhaveri *Sr. Research & Development Engineer* | Kitware
<http://www.kitware.com/> | (518) 881-4417
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/paraview/attachments/20170629/12faf1c2/attachment.html>
More information about the ParaView
mailing list