Changed to 16 bit for image visualisation
This commit is contained in:
@ -1576,8 +1576,6 @@ void itkImageProcessor::InitializeProjector()
|
||||
imageDRT2In = filter2->GetOutput();
|
||||
|
||||
|
||||
// std::cout<< "itkImageProcessor::InitializeProjector() END" <<std::endl;
|
||||
|
||||
}
|
||||
|
||||
|
||||
@ -2236,12 +2234,12 @@ void itkImageProcessor::Write2DImages(){
|
||||
|
||||
vtkImageData* itkImageProcessor::GetLocalizer1VTK()
|
||||
{
|
||||
// Rescale the intensity of the projection images to 0-255 for output.
|
||||
// Rescale the intensity of the projection images to 0-32768 for output.
|
||||
using RescaleFilterType = itk::RescaleIntensityImageFilter<InternalImageType, OutputImageType>;
|
||||
|
||||
RescaleFilterType::Pointer rescaler1 = RescaleFilterType::New();
|
||||
rescaler1->SetOutputMinimum(0);
|
||||
rescaler1->SetOutputMaximum(255);
|
||||
rescaler1->SetOutputMaximum(32768);
|
||||
rescaler1->SetInput(m_PASourceDupli->GetOutput());
|
||||
|
||||
rescaler1->Update();
|
||||
@ -2296,12 +2294,12 @@ vtkImageData* itkImageProcessor::GetLocalizer2VTK()
|
||||
{
|
||||
|
||||
|
||||
// Rescale the intensity of the projection images to 0-255 for output.
|
||||
// Rescale the intensity of the projection images to 0-32768 for output.
|
||||
using RescaleFilterType = itk::RescaleIntensityImageFilter<InternalImageType, OutputImageType>;
|
||||
|
||||
RescaleFilterType::Pointer rescaler2 = RescaleFilterType::New();
|
||||
rescaler2->SetOutputMinimum(0);
|
||||
rescaler2->SetOutputMaximum(255);
|
||||
rescaler2->SetOutputMaximum(32768);
|
||||
rescaler2->SetInput(m_LATSourceDupli ->GetOutput());
|
||||
|
||||
rescaler2->Update();
|
||||
@ -2356,16 +2354,30 @@ vtkImageData* itkImageProcessor::GetLocalizer2VTK()
|
||||
|
||||
vtkImageData* itkImageProcessor::GetProjection1VTK()
|
||||
{
|
||||
// Rescale the intensity of the projection images to 0-255 for output.
|
||||
// Rescale the intensity of the projection images to 0-32768 for output.
|
||||
using RescaleFilterType = itk::RescaleIntensityImageFilter<InternalImageType, OutputImageType>;
|
||||
|
||||
RescaleFilterType::Pointer rescaler1 = RescaleFilterType::New();
|
||||
rescaler1->SetOutputMinimum(0);
|
||||
rescaler1->SetOutputMaximum(255);
|
||||
rescaler1->SetOutputMaximum(32768);
|
||||
rescaler1->SetInput( imageDRT1In );
|
||||
|
||||
rescaler1->Update();
|
||||
|
||||
// using ImageCalculatorFilterType = itk::MinimumMaximumImageCalculator<InternalImageType>;
|
||||
// auto imageCalculatorFilter = ImageCalculatorFilterType::New();
|
||||
// imageCalculatorFilter->SetImage(imageDRT1In);
|
||||
// imageCalculatorFilter->Compute();
|
||||
|
||||
// std::cout<< "itkImageProcessor::imageDRT1In() " <<
|
||||
// imageCalculatorFilter <<std::endl;
|
||||
|
||||
// using ImageCalculatorFilterType2 = itk::MinimumMaximumImageCalculator<OutputImageType>;
|
||||
// auto imageCalculatorFilter2 = ImageCalculatorFilterType2::New();
|
||||
// imageCalculatorFilter2->SetImage(rescaler1->GetOutput());
|
||||
// imageCalculatorFilter2->Compute();
|
||||
// std::cout<< "itkImageProcessor::imageDRT2In() " <<
|
||||
// imageCalculatorFilter2 <<std::endl;
|
||||
|
||||
toVTK2D1->SetInput(rescaler1->GetOutput());
|
||||
toVTK2D1->Update();
|
||||
|
||||
@ -2471,12 +2483,12 @@ vtkMatrix4x4 * itkImageProcessor::GetProjection2VTKTransform()
|
||||
|
||||
vtkImageData* itkImageProcessor::GetProjection2VTK()
|
||||
{
|
||||
// Rescale the intensity of the projection images to 0-255 for output.
|
||||
// Rescale the intensity of the projection images to 0-32768 for output.
|
||||
using RescaleFilterType = itk::RescaleIntensityImageFilter<InternalImageType, OutputImageType>;
|
||||
|
||||
RescaleFilterType::Pointer rescaler2 = RescaleFilterType::New();
|
||||
rescaler2->SetOutputMinimum(0);
|
||||
rescaler2->SetOutputMaximum(255);
|
||||
rescaler2->SetOutputMaximum(32768);
|
||||
rescaler2->SetInput( imageDRT2In );
|
||||
|
||||
rescaler2->Update();
|
||||
|
@ -160,7 +160,7 @@ protected:
|
||||
using InternalPixelType = float;
|
||||
using PixelType2D = short;
|
||||
using PixelType3D = short;
|
||||
using OutputPixelType = unsigned char;
|
||||
using OutputPixelType = unsigned short;
|
||||
|
||||
using ImageType3D = itk::Image<PixelType3D, Dimension>;
|
||||
using InternalImageType = itk::Image<InternalPixelType, Dimension>;
|
||||
|
Reference in New Issue
Block a user