Hello everyone,<br><br>I finally managed to get rid of the RGB and grayscale blending by simply switching the connection in the vtkImageBlend filter. However, I am still struggling with the vtkLookupTable and using it with&nbsp; the vtkImageMapToWindowLevelColors filter.
<br><br>So, I am creating the table as follows:<br><br>vtkImageMapToWindowLevelColors * iwlc = vtkImageMapToWindowLevelColors;<br>vtkLookupTable * lut = vtkLookupTable::New();<br><br>// Input is the input vtkImageData pointer.
<br>double * range = input-&gt;GetScalarRange();<br><br>lut-&gt;SetTableRange (range[0], range[1]); <br>lut-&gt;SetNumberOfTableValues(256);<br>lut-&gt;Build();<br><br>float r, g, b;<br>r = g = b = 0.0;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
<br>for (int i = 0; i &lt; 256; i++)<br>{<br>&nbsp;&nbsp;&nbsp;&nbsp; lut-&gt;SetTableValue(i, r/255.0f, g/255.0f, b/255.0f, 1.0);<br>}<br>iwlc-&gt;SetLookupTable(lut);<br>iwlc-&gt;SetInput(input);<br><br>Now, later when I get the output of the vtkImageMapToWindowLevelColors filter object as:
<br><br>iwic-&gt;GetOutput();<br><br>then the scalar range for the output data is always 0 - 0. I have tried using calls to update but to no avail. <br><br>I would really appreciate some help from experts who have experience using these filters.
<br><br>Thanks,<br><br>Luca<br>