[vtkusers] Colormap unstructured grid by vector magnitude

Peter Schmitt pschmitt at gmail.com
Wed Jul 13 17:20:29 EDT 2005


Thanks, that seems to work!
-Pete

On 7/13/05, John Platt <jcplatt at lineone.net> wrote:
> Hi Pete,
> 
> Have you tried
> 
> vtkScalarsToColors::SetVectorModeToMagnitude()
> 
> You probably have to set the mapper's ScalarMode to UsePointFieldData
> and select the vector array using SelectColorArray().
> 
> HTH
> 
> John.
> 
> 
> -----Original Message-----
> From: vtkusers-bounces+jcplatt=lineone.net at vtk.org
> [mailto:vtkusers-bounces+jcplatt=lineone.net at vtk.org] On Behalf Of Peter
> Schmitt
> Sent: 13 July 2005 20:49
> To: vtkusers at vtk.org
> Subject: [vtkusers] Colormap unstructured grid by vector magnitude
> 
> Hi,
> I have data stored as an unstructured grid.  Each point has a vector
> associated with it.  I want to color each point in my grid according
> to vector magnitude.
> 
> vtkMapper has lots of options for colormaps, but it only seems to look
> at scalar data.  Is it possible to have vtk determine the magnitude of
> the vectors on the fly & color accordingly?
> 
> If I were working with Glyphs, it would be easy to do colormaps with
> SetColorModeToColorByVector... I was hoping there would be something
> similar for the vtkMapper class.
> 
> Thanks!
> Pete
> _______________________________________________
> This is the private VTK discussion list.
> Please keep messages on-topic. Check the FAQ at:
> http://www.vtk.org/Wiki/VTK_FAQ
> Follow this link to subscribe/unsubscribe:
> http://www.vtk.org/mailman/listinfo/vtkusers
> 
> 
> 


-- 
Pete



More information about the vtkusers mailing list