VolumeProjection3d flattens a 3D volume into an image with only two representative dimensions.
Each output pixel is assigned by browsing a selected axis and retaining the value corresponding to a
projection criterion; for example, the maximal intensity.
The output image can be considered either as a 2D image or a 3D image.
Choosing a 3D output space is almost relevant for raising ambiguity when the selected axis is not Z and
the result has to be displayed in a 3D viewer.
For instance, considering that the projection is performed along X:
If the output space is 2D, the output image has two axes: X and Y. X corresponds to the Y input axis and
Y to the Z input axis.
If the output space is 3D, the output image has three axes: X, Y, and Z. The X size is 1. All axis are
consistent with the input volume.
An optional output can be enabled to get a map representing the slice index of each selected pixel.
This map is not available in mean projection mode since, in this case, the output value is computed from all
browsed intensities.
(a)
(b)
(c)
Figure 1. Mean Intensity projection: (a) The input volume,
(b) the mean projection along the Z axis, (c) mean projection along the Y axis
This algorithm is similar to ImageStackProjection3d, the main differences are:
Only the intensity minimum, maximum, and mean projection modes are available.
The projection axis can be user-defined (X, Y, or Z) and is not necessarily the Z axis.
The output space can be set to 3D to preserve the original coordinate system of the input volume.
This function returns a VolumeProjection3dOutput structure containing outputImage and outputMapImage.
// Output structure of the volumeProjection3d function.structVolumeProjection3dOutput{/// The output image representing the volume projection according to the selected criterion.
std::shared_ptr< iolink::ImageView> outputImage;/// Output image indicating the selected plane in INTENSITY_MINIMUM or INTENSITY_MAXIMUM mode (not available in INTENSITY_MEAN mode).
std::shared_ptr< iolink::ImageView> outputMapImage;};// Function prototype VolumeProjection3dOutput
volumeProjection3d( std::shared_ptr< iolink::ImageView> inputImage,VolumeProjection3d::AxisDirection axisDirection,VolumeProjection3d::ProjectionMode projectionMode,VolumeProjection3d::DimensionalSpace dimensionalSpace,bool createMapImage,
std::shared_ptr< iolink::ImageView> outputImage = NULL,
std::shared_ptr< iolink::ImageView> outputMapImage = NULL );
This function returns a VolumeProjection3dOutput structure containing outputImage and outputMapImage.
/// Output structure of the VolumeProjection3d function.publicstructVolumeProjection3dOutput{/// /// The output image representing the volume projection according to the selected criterion./// publicIOLink.ImageView outputImage;/// /// Output image indicating the selected plane in INTENSITY_MINIMUM or INTENSITY_MAXIMUM mode (not available in INTENSITY_MEAN mode)./// publicIOLink.ImageView outputMapImage;};// Function prototype.publicstaticVolumeProjection3dOutputVolumeProjection3d(IOLink.ImageView inputImage,VolumeProjection3d.AxisDirection axisDirection =ImageDev.VolumeProjection3d.AxisDirection.Z_AXIS,VolumeProjection3d.ProjectionMode projectionMode =ImageDev.VolumeProjection3d.ProjectionMode.INTENSITY_MEAN,VolumeProjection3d.DimensionalSpace dimensionalSpace =ImageDev.VolumeProjection3d.DimensionalSpace.SPACE_2D,bool createMapImage =false,IOLink.ImageView outputImage =null,IOLink.ImageView outputMapImage =null);
Class Syntax
// Command constructor.VolumeProjection3d();/// Gets the inputImage parameter./// The 3D input image.
std::shared_ptr< iolink::ImageView> inputImage()const;/// Sets the inputImage parameter./// The 3D input image.void setInputImage( std::shared_ptr< iolink::ImageView> inputImage );/// Gets the axisDirection parameter./// The axis along which slices are projected.VolumeProjection3d::AxisDirection axisDirection()const;/// Sets the axisDirection parameter./// The axis along which slices are projected.void setAxisDirection(constVolumeProjection3d::AxisDirection& axisDirection );/// Gets the projectionMode parameter./// The projection criterion (the rule used to transform a stack of pixels into a single pixel).VolumeProjection3d::ProjectionMode projectionMode()const;/// Sets the projectionMode parameter./// The projection criterion (the rule used to transform a stack of pixels into a single pixel).void setProjectionMode(constVolumeProjection3d::ProjectionMode& projectionMode );/// Gets the dimensionalSpace parameter./// Define the dimensional space of the output image.VolumeProjection3d::DimensionalSpace dimensionalSpace()const;/// Sets the dimensionalSpace parameter./// Define the dimensional space of the output image.void setDimensionalSpace(constVolumeProjection3d::DimensionalSpace& dimensionalSpace );/// Gets the createMapImage parameter./// This parameter indicates whether the algorithm creates an output map image.bool createMapImage()const;/// Sets the createMapImage parameter./// This parameter indicates whether the algorithm creates an output map image.void setCreateMapImage(constbool& createMapImage );/// Gets the outputImage parameter./// The output image representing the volume projection according to the selected criterion.
std::shared_ptr< iolink::ImageView> outputImage()const;/// Sets the outputImage parameter./// The output image representing the volume projection according to the selected criterion.void setOutputImage( std::shared_ptr< iolink::ImageView> outputImage );/// Gets the outputMapImage parameter./// Output image indicating the selected plane in INTENSITY_MINIMUM or INTENSITY_MAXIMUM mode (not available in INTENSITY_MEAN mode).
std::shared_ptr< iolink::ImageView> outputMapImage()const;/// Sets the outputMapImage parameter./// Output image indicating the selected plane in INTENSITY_MINIMUM or INTENSITY_MAXIMUM mode (not available in INTENSITY_MEAN mode).void setOutputMapImage( std::shared_ptr< iolink::ImageView> outputMapImage );// Method to launch the command.void execute();
# Property of the inputImage parameter.VolumeProjection3d.input_image
# Property of the axisDirection parameter.VolumeProjection3d.axis_direction
# Property of the projectionMode parameter.VolumeProjection3d.projection_mode
# Property of the dimensionalSpace parameter.VolumeProjection3d.dimensional_space
# Property of the createMapImage parameter.VolumeProjection3d.create_map_image
# Property of the outputImage parameter.VolumeProjection3d.output_image
# Property of the outputMapImage parameter.VolumeProjection3d.output_map_image
// Method to launch the command.
execute()
// Command constructor.VolumeProjection3d()// Property of the inputImage parameter.VolumeProjection3d.inputImage
// Property of the axisDirection parameter.VolumeProjection3d.axisDirection
// Property of the projectionMode parameter.VolumeProjection3d.projectionMode
// Property of the dimensionalSpace parameter.VolumeProjection3d.dimensionalSpace
// Property of the createMapImage parameter.VolumeProjection3d.createMapImage
// Property of the outputImage parameter.VolumeProjection3d.outputImage
// Property of the outputMapImage parameter.VolumeProjection3d.outputMapImage
// Method to launch the command.Execute()
Parameters
Parameter Name
Description
Type
Supported Values
Default Value
inputImage
The 3D input image.
Color and grayscale images are accepted. The type of the image can be integer or float.
Image
Grayscale or Multispectral
nullptr
axisDirection
The axis along which slices are projected.
If axis direction is set to X, YZ slices are projected.
X_AXIS
The YZ slices are projected.
Y_AXIS
The XZ slices are projected.
Z_AXIS
The XY slices are projected.
Enumeration
Z_AXIS
projectionMode
The projection criterion (the rule used to transform a stack of pixels into a single pixel).
INTENSITY_MAXIMA
The pixel of highest intensity is selected in the stack. The map output is available with this mode.
INTENSITY_MINIMA
The pixel of lowest intensity is selected in the stack. The map output is available with this mode.
INTENSITY_MEAN
The pixels of the stack are averaged along the selected axis. The map output is not available with this mode.
Enumeration
INTENSITY_MEAN
dimensionalSpace
Define the dimensional space of the output image.
If axis direction is set to X and space to 2D, the output X (resp. Y) axis corresponds to the Y (resp. Z)
axis. If axis direction is set to X and space to 3D, the output X axis is one pixel thick.
SPACE_2D
The output image is a 2D image.
SPACE_3D
The output image is a 3D image.
Enumeration
SPACE_2D
createMapImage
This parameter indicates whether the algorithm creates an output map image.
This parameter is ignored in INTENSITY_MEAN projection mode.
Bool
false
outputImage
The output image representing the volume projection according to the selected criterion.
This image can be either 2D or 3D of one pixel thickness in the selected axis direction.
Its type is identical to the input image.
Image
nullptr
outputMapImage
Output image indicating the selected plane in INTENSITY_MINIMUM or INTENSITY_MAXIMUM mode (not available in INTENSITY_MEAN mode).
The output map image can be either 2D or 3D of one pixel thickness in the selected axis direction.
Its type is integer 32 bits.
Image
nullptr
Parameter Name
Description
Type
Supported Values
Default Value
input_image
The 3D input image.
Color and grayscale images are accepted. The type of the image can be integer or float.
image
Grayscale or Multispectral
None
axis_direction
The axis along which slices are projected.
If axis direction is set to X, YZ slices are projected.
X_AXIS
The YZ slices are projected.
Y_AXIS
The XZ slices are projected.
Z_AXIS
The XY slices are projected.
enumeration
Z_AXIS
projection_mode
The projection criterion (the rule used to transform a stack of pixels into a single pixel).
INTENSITY_MAXIMA
The pixel of highest intensity is selected in the stack. The map output is available with this mode.
INTENSITY_MINIMA
The pixel of lowest intensity is selected in the stack. The map output is available with this mode.
INTENSITY_MEAN
The pixels of the stack are averaged along the selected axis. The map output is not available with this mode.
enumeration
INTENSITY_MEAN
dimensional_space
Define the dimensional space of the output image.
If axis direction is set to X and space to 2D, the output X (resp. Y) axis corresponds to the Y (resp. Z)
axis. If axis direction is set to X and space to 3D, the output X axis is one pixel thick.
SPACE_2D
The output image is a 2D image.
SPACE_3D
The output image is a 3D image.
enumeration
SPACE_2D
create_map_image
This parameter indicates whether the algorithm creates an output map image.
This parameter is ignored in INTENSITY_MEAN projection mode.
bool
False
output_image
The output image representing the volume projection according to the selected criterion.
This image can be either 2D or 3D of one pixel thickness in the selected axis direction.
Its type is identical to the input image.
image
None
output_map_image
Output image indicating the selected plane in INTENSITY_MINIMUM or INTENSITY_MAXIMUM mode (not available in INTENSITY_MEAN mode).
The output map image can be either 2D or 3D of one pixel thickness in the selected axis direction.
Its type is integer 32 bits.
image
None
Parameter Name
Description
Type
Supported Values
Default Value
inputImage
The 3D input image.
Color and grayscale images are accepted. The type of the image can be integer or float.
Image
Grayscale or Multispectral
null
axisDirection
The axis along which slices are projected.
If axis direction is set to X, YZ slices are projected.
X_AXIS
The YZ slices are projected.
Y_AXIS
The XZ slices are projected.
Z_AXIS
The XY slices are projected.
Enumeration
Z_AXIS
projectionMode
The projection criterion (the rule used to transform a stack of pixels into a single pixel).
INTENSITY_MAXIMA
The pixel of highest intensity is selected in the stack. The map output is available with this mode.
INTENSITY_MINIMA
The pixel of lowest intensity is selected in the stack. The map output is available with this mode.
INTENSITY_MEAN
The pixels of the stack are averaged along the selected axis. The map output is not available with this mode.
Enumeration
INTENSITY_MEAN
dimensionalSpace
Define the dimensional space of the output image.
If axis direction is set to X and space to 2D, the output X (resp. Y) axis corresponds to the Y (resp. Z)
axis. If axis direction is set to X and space to 3D, the output X axis is one pixel thick.
SPACE_2D
The output image is a 2D image.
SPACE_3D
The output image is a 3D image.
Enumeration
SPACE_2D
createMapImage
This parameter indicates whether the algorithm creates an output map image.
This parameter is ignored in INTENSITY_MEAN projection mode.
Bool
false
outputImage
The output image representing the volume projection according to the selected criterion.
This image can be either 2D or 3D of one pixel thickness in the selected axis direction.
Its type is identical to the input image.
Image
null
outputMapImage
Output image indicating the selected plane in INTENSITY_MINIMUM or INTENSITY_MAXIMUM mode (not available in INTENSITY_MEAN mode).
The output map image can be either 2D or 3D of one pixel thickness in the selected axis direction.
Its type is integer 32 bits.