[vtkusers] vtkColorTransferFunction question

vlibertiaux vlibertiaux at gmail.com
Fri Apr 8 20:33:13 EDT 2011


Hello everyone,

I use a colortransferfunction to be able to set an "out of color bar value"
for an exclusion value.

My exclusion value is -1 and my actual values range from 0 to 0.5.

I build the colortransferfunction like this:

		color->AddRGBPoint(-1, 0.5,0.5,0.5,1,1);
		color->AddRGBPoint(smin,0,0,1);
		color->AddRGBPoint( (smax+smin)/2,0,1,0);
		color->AddRGBPoint(smax,1,0,0);

so that I have gray values from -1 to smin and my actual colorbar from smin
to smax.

The problem is that this color bar is linear, so I have a large gray portion
on my scalarbar.  

What can I do to have a non linear scalar bar, i.e. make the -1, smin part
shorter than the smin, smax part on the bar ?

Thank you very much for your answers !

Best regards,

V.

--
View this message in context: http://vtk.1045678.n5.nabble.com/vtkColorTransferFunction-question-tp4292172p4292172.html
Sent from the VTK - Users mailing list archive at Nabble.com.



More information about the vtkusers mailing list