GetObliqueSliceFromVolume3d
Extracts a 2D section from a 3D volume.
Access to parameter description
GetObliqueSliceFromVolume3d extracts a section of a 3D image, given a point of this section and the theta and phi angles of its normal given in respect to the spherical coordinates generally used in mathematics.
The 2D image is created with dimensions deduced from the intersection between the input volume and the plane defined by the point and normal inputs.
See also
Access to parameter description
GetObliqueSliceFromVolume3d extracts a section of a 3D image, given a point of this section and the theta and phi angles of its normal given in respect to the spherical coordinates generally used in mathematics.
The 2D image is created with dimensions deduced from the intersection between the input volume and the plane defined by the point and normal inputs.
See also
Function Syntax
This function returns outputImage.
// Function prototype
std::shared_ptr< iolink::ImageView > getObliqueSliceFromVolume3d( std::shared_ptr< iolink::ImageView > inputImage, iolink::Vector3i32 pointCoordinates, double thetaAngle, double phiAngle, GetObliqueSliceFromVolume3d::InterpolationType interpolationType, std::shared_ptr< iolink::ImageView > outputImage = nullptr );
This function returns outputImage.
// Function prototype. get_oblique_slice_from_volume_3d(input_image: idt.ImageType, point_coordinates: Iterable[int] = [1, 1, 1], theta_angle: float = 0, phi_angle: float = 0, interpolation_type: GetObliqueSliceFromVolume3d.InterpolationType = GetObliqueSliceFromVolume3d.InterpolationType.NEAREST_NEIGHBOR, output_image: idt.ImageType = None) -> idt.ImageType
This function returns outputImage.
// Function prototype. public static IOLink.ImageView GetObliqueSliceFromVolume3d( IOLink.ImageView inputImage, int[] pointCoordinates = null, double thetaAngle = 0, double phiAngle = 0, GetObliqueSliceFromVolume3d.InterpolationType interpolationType = ImageDev.GetObliqueSliceFromVolume3d.InterpolationType.NEAREST_NEIGHBOR, IOLink.ImageView outputImage = null );
Class Syntax
Parameters
Parameter Name | Description | Type | Supported Values | Default Value | |||||
---|---|---|---|---|---|---|---|---|---|
inputImage |
The input 3D image (the volume from which the slice is extracted). | Image | Binary, Label, Grayscale or Multispectral | nullptr | |||||
pointCoordinates |
Coordinates of a point of the 3D section. | Vector3i32 | >=0 | {1, 1, 1} | |||||
thetaAngle |
The azimuthal angle in degrees (angle between the X axis and the projection of the normal on XY plane). | Float64 | Any value | 0 | |||||
phiAngle |
The polar angle in degrees (angle between the normal and the Z axis). | Float64 | Any value | 0 | |||||
interpolationType |
The interpolation mode. Method used to calculate the intensity of each result voxel.
|
Enumeration | NEAREST_NEIGHBOR | ||||||
outputImage |
The output 2D image (the extracted slice). | Image | nullptr |
Parameter Name | Description | Type | Supported Values | Default Value | |||||
---|---|---|---|---|---|---|---|---|---|
input_image |
The input 3D image (the volume from which the slice is extracted). | image | Binary, Label, Grayscale or Multispectral | None | |||||
point_coordinates |
Coordinates of a point of the 3D section. | vector3i32 | >=0 | [1, 1, 1] | |||||
theta_angle |
The azimuthal angle in degrees (angle between the X axis and the projection of the normal on XY plane). | float64 | Any value | 0 | |||||
phi_angle |
The polar angle in degrees (angle between the normal and the Z axis). | float64 | Any value | 0 | |||||
interpolation_type |
The interpolation mode. Method used to calculate the intensity of each result voxel.
|
enumeration | NEAREST_NEIGHBOR | ||||||
output_image |
The output 2D image (the extracted slice). | image | None |
Parameter Name | Description | Type | Supported Values | Default Value | |||||
---|---|---|---|---|---|---|---|---|---|
inputImage |
The input 3D image (the volume from which the slice is extracted). | Image | Binary, Label, Grayscale or Multispectral | null | |||||
pointCoordinates |
Coordinates of a point of the 3D section. | Vector3i32 | >=0 | {1, 1, 1} | |||||
thetaAngle |
The azimuthal angle in degrees (angle between the X axis and the projection of the normal on XY plane). | Float64 | Any value | 0 | |||||
phiAngle |
The polar angle in degrees (angle between the normal and the Z axis). | Float64 | Any value | 0 | |||||
interpolationType |
The interpolation mode. Method used to calculate the intensity of each result voxel.
|
Enumeration | NEAREST_NEIGHBOR | ||||||
outputImage |
The output 2D image (the extracted slice). | Image | null |
Object Examples
auto foam = readVipImage( std::string( IMAGEDEVDATA_IMAGES_FOLDER ) + "foam.vip" ); GetObliqueSliceFromVolume3d getObliqueSliceFromVolume3dAlgo; getObliqueSliceFromVolume3dAlgo.setInputImage( foam ); getObliqueSliceFromVolume3dAlgo.setPointCoordinates( {1, 1, 1} ); getObliqueSliceFromVolume3dAlgo.setThetaAngle( 0.0 ); getObliqueSliceFromVolume3dAlgo.setPhiAngle( 0.0 ); getObliqueSliceFromVolume3dAlgo.setInterpolationType( GetObliqueSliceFromVolume3d::InterpolationType::NEAREST_NEIGHBOR ); getObliqueSliceFromVolume3dAlgo.execute(); std::cout << "outputImage:" << getObliqueSliceFromVolume3dAlgo.outputImage()->toString();
foam = imagedev.read_vip_image(imagedev_data.get_image_path("foam.vip")) get_oblique_slice_from_volume_3d_algo = imagedev.GetObliqueSliceFromVolume3d() get_oblique_slice_from_volume_3d_algo.input_image = foam get_oblique_slice_from_volume_3d_algo.point_coordinates = [1, 1, 1] get_oblique_slice_from_volume_3d_algo.theta_angle = 0.0 get_oblique_slice_from_volume_3d_algo.phi_angle = 0.0 get_oblique_slice_from_volume_3d_algo.interpolation_type = imagedev.GetObliqueSliceFromVolume3d.NEAREST_NEIGHBOR get_oblique_slice_from_volume_3d_algo.execute() print("output_image:", str(get_oblique_slice_from_volume_3d_algo.output_image))
ImageView foam = Data.ReadVipImage( @"Data/images/foam.vip" ); GetObliqueSliceFromVolume3d getObliqueSliceFromVolume3dAlgo = new GetObliqueSliceFromVolume3d { inputImage = foam, pointCoordinates = new int[]{1, 1, 1}, thetaAngle = 0.0, phiAngle = 0.0, interpolationType = GetObliqueSliceFromVolume3d.InterpolationType.NEAREST_NEIGHBOR }; getObliqueSliceFromVolume3dAlgo.Execute(); Console.WriteLine( "outputImage:" + getObliqueSliceFromVolume3dAlgo.outputImage.ToString() );
Function Examples
auto foam = readVipImage( std::string( IMAGEDEVDATA_IMAGES_FOLDER ) + "foam.vip" ); auto result = getObliqueSliceFromVolume3d( foam, {1, 1, 1}, 0.0, 0.0, GetObliqueSliceFromVolume3d::InterpolationType::NEAREST_NEIGHBOR ); std::cout << "outputImage:" << result->toString();
foam = imagedev.read_vip_image(imagedev_data.get_image_path("foam.vip")) result = imagedev.get_oblique_slice_from_volume_3d(foam, [1, 1, 1], 0.0, 0.0, imagedev.GetObliqueSliceFromVolume3d.NEAREST_NEIGHBOR) print("output_image:", str(result))
ImageView foam = Data.ReadVipImage( @"Data/images/foam.vip" ); IOLink.ImageView result = Processing.GetObliqueSliceFromVolume3d( foam, new int[]{1, 1, 1}, 0.0, 0.0, GetObliqueSliceFromVolume3d.InterpolationType.NEAREST_NEIGHBOR ); Console.WriteLine( "outputImage:" + result.ToString() );