The VOLUME RENDERING quality of `vtkGPUVolumeRayCastMapper`

Hi there, I have a question for vtkGPUVolumeRayCastMapper rendering, for I tried to use this kind of mapper for MIP, but seems getting the very low resolution rendered result like this:
5a9cbc14854013a21f7d40d2f6b9dfa2
08c07678418f63f3a55a61627c9b2174

As you can see the voxels are treated as hexagon, not very smooth. Could you please give me a hand? I have no idea how to improve the resolution of the MIP rendering result.

I am using VTK8.2 in Visual studio2015, X64.
Here is the MIP mode setting:

void MyProject::SetMIP() {
	mapper->AutoAdjustSampleDistancesOff();
	mapper->LockSampleDistanceToInputSpacingOn();
	mapper->SetImageSampleDistance(1);

	vtkSmartPointer<vtkPiecewiseFunction> opacity = vtkSmartPointer<vtkPiecewiseFunction>::New();

	opacity ->AddPoint(minValue, 0.00);
	opacity ->AddPoint(m_nMipLevel, 0.30);
	opacity ->AddPoint(maxValue, 1.00);
	property->SetScalarOpacity(opacity );

	mapper->SetInputData(m_pImageData->GetImageData());
	mapper->SetBlendModeToMaximumIntensity();
	volume->SetMapper(mapper);
	property->Modified();
	volume->SetProperty(property);

	renderer->SetViewport(0, 0, 1, 1);
	renderer->SetBackground(0, 0, 0);
	renderer->AddVolume(volume);

	InitMyCamera();

}

Here is one of refering Dicom Viewer’s result, seems much more better!!:

I tried to comment out these code:

	//mapper->AutoAdjustSampleDistancesOff();
	//mapper->LockSampleDistanceToInputSpacingOn();
	//mapper->SetImageSampleDistance(1);

but not work, can I just set some parameters for resample the volumes or some stuff? great thanks!

This apperance looks normal. You can adjust your transfer functions and projection parameters (e.g., switch to parallel projection) to reduce the noise. You can also reduce resample the input volume to have 1.5-4x smaller spacing to make individual cubes less recognizable.

The “Dicom Viewer’s result” in the last screenshot does not look like MIP.

1 Like