<div style="line-height:1.7;color:#000000;font-size:14px;font-family:Arial"><div>Hi,</div><div>    I want to write some jpg (gray level) images into color image to display different intensities, the range of the intensities in the input image is 0~255.And the code I wrote is as below:</div><div><br></div><div><div>typedef itk::Image< OutputPixelType, 2 >  OutputImageType;</div><div><br></div><div> typedef itk::ScalarToRGBColormapImageFilter< jpgScalarImageType, OutputImageType >  RGBFilterType;</div><div><br></div><div>  RGBFilterType::Pointer colormapImageFilter = RGBFilterType::New();</div><div><br></div><div>  colormapImageFilter->SetColormap( RGBFilterType::Hot );</div><div><br></div><div>  colormapImageFilter->SetInput( InputImage );</div><div>  try</div><div>    {</div><div>    colormapImageFilter->Update();</div><div>    }</div><div>  catch ( itk::ExceptionObject &err )</div><div>    {</div><div>    std::cerr << err << std::endl;</div><div><br></div><div>    //return EXIT_FAILURE;</div><div>    }</div></div><div><br></div><div>OutputImageType::Pointer outputImage = colormapImageFilter->GetOutput();</div><div><br></div><div>But after I write the outputImage ,it is all black.Did I miss something ,or is there any other solution to write a grey image into a color image?<span style="line-height: 1.7;">Thank you!</span></div><div><span style="line-height: 1.7;"><br></span></div><div>Best regards!</div><div><br></div><div>Tina</div></div><br><br><span title="neteasefooter"><span id="netease_mail_footer"></span></span>