SoResampleImageProcessing3d filter More...
#include <ImageViz/Engines/GeometryAndMatching/GeometricTransforms/SoResampleImageProcessing3d.h>
Public Types | |
enum | SamplingMode { AUTOMATIC = 0, MANUAL } |
enum | InterpolationType { NEAREST = 0, LINEAR } |
Public Member Functions | |
SoResampleImageProcessing3d () | |
Public Attributes | |
SoSFImageDataAdapter | inImage |
SoSFBox3f | subVolume |
SoSFMatrix | subVolumeTransform |
SoSFEnum | samplingMode |
SoSFVec3i32 | subVolumeDimension |
SoSFEnum | interpolationType |
SoSFDouble | paddingValue |
SoSFMatrix | transform |
SoImageVizEngineOutput < SoSFImageDataAdapter, SoImageDataAdapter * > | outImage |
The SoResampleImageProcessing3d engine allows to resample an input image into a new coordinate system applying a transform on it.
For instance it can be used to :
The resampled sub-volume is defined by an SbBox3f (axis aligned box) in 3D space and a SbMatrix that transforms the axis aligned box. The output voxel values are computed by interpolating the input image.
The SbMatrix that transforms the axis aligned box must only contain translation, rotation and scale (no shearing), otherwise an error is raised.
An additional transformation can be applied to each output voxel position before the interpolation. This is useful for re-sampling an image after a registration.
inImage | NULL |
subVolume | 0, 0, 0, 1, 1, 1 |
subVolumeTransform | 1 0 0 0 |
0 1 0 0 | |
0 0 1 0 | |
0 0 0 1 | |
samplingMode | AUTOMATIC |
subVolumeDimension | 1 1 1 |
interpolationType | LINEAR |
paddingValue | 0.0 |
transform | 1 0 0 0 |
0 1 0 0 | |
0 0 1 0 | |
0 0 0 1 |
SoSampleImageProcessing, SoProxyDataAdapter
This enum defines how the voxel size of the output image is computed.
AUTOMATIC |
The voxel size is automatically computed to be as close as possible to the input image. Note that this mode does not work if SoResampleImageProcessing3d::transform is not the identity (an error is raised) . |
MANUAL |
The user specifies the output image dimension (SoResampleImageProcessing3d::outputImageDimension) and thus the output voxel size. |
SoResampleImageProcessing3d::SoResampleImageProcessing3d | ( | ) |
Constructor.
The input image.
Default value is NULL. Supported types include: grayscale binary label.
The type of interpolation used for the re-sampling.
Default value is LINEAR. Use enum InterpolationType
SoImageVizEngineOutput<SoSFImageDataAdapter, SoImageDataAdapter*> SoResampleImageProcessing3d::outImage |
The output image.
The output value if an output voxel position is outside the bounding box of the input image.
Default value is 0.
Specifies how the voxel size is computed.
Default value is AUTOMATIC. Use enum SamplingMode
Specifies the input subvolume as an axis aligned box in 3D space.
Default is (0,0,0, 1,1,1). This box is (optionally) transformed by the subVolumeTransform to define the final input subvolume.
The dimensions of the output sub volume.
If the parameter SoResampleImageProcessing3d::samplingMode is not set to MANUAL this parameter is ignored. Default value is (1,1,1).
Specifies a transformation of the axis aligned box subVolume.
Default is identity.
This transformation is applied to all output voxel positions before the interpolation.
The default value is the identity.