Downsample3D¶
-
MacroModule
¶ genre Resample
author MeVis Medical Solutions AG
package MeVisLab/Standard
definition Geometry.def see also Resample3D
keywords resample
,interpolate
,preview
Purpose¶
The Downsample3D macro module performs a downsampling operation on the input image according to a given size or resolution restriction.
The restriction can be specified with respect to a maximum image size for each dimension, a minimum voxel size or a maximum total image size in megabytes. Dependent on the size and resolution of the current input image, the module determines the scaling factor for each spatial dimension and computes the downsampled image at its output. If no scaling is necessary, i.e. if the input image is small enough to fulfill the size restriction, the input image is passed directly to the output.
Details¶
For restriction modes MaxVoxelsPerDim and MinVoxelDist, the scaling factors are computed independently for each dimension. For the MaxMBytes… restriction modes, a global size restriction for the image is specified and the scaling factors can not be computed independently. There are three different modes that differ in the way the global scaling requirement is distributed over the three dimensions. If MaxMBytesIsotropic is selected, the factors are chosen such that the resulting image is as isotropic as possible, i.e. dimensions with high spatial resolution are downsampled at a higher rate than dimensions with low resolution. With MaxMBytesCubic, the scaling factors are chosen such that the image extents (in voxels) in the three dimensions are as close as possible, whereas in the MaxMBytesUniform mode the scaling factors are preferably equal to each other. Scaling factors are always larger or equal to 1, i.e. the image is never upsampled in any dimension.
Parameter Fields¶
Field Index¶
Allow interpolation : Bool |
Voxel Size : Vector3 |
Image forwarded directly without resampling : Bool |
zoom : Vector3 |
Image Size : Vector3 |
|
Limit : Float |
|
Method : Enum |
|
noInputImgBytes : Integer |
|
Restriction : Enum |
|
Scaling : Vector3 |
Visible Fields¶
Restriction¶
-
name:
restriction
, type:
Enum
, default:
MaxMBytesIsotropic
¶ Defines the restriction mode.
Values:
Title | Name | Deprecated Name | Description |
---|---|---|---|
Max Voxels Per Dim | MaxVoxelsPerDim | MAX_VOXELS_PER_DIM | Select the scaling factors such that the image extent in voxels for each spatial dimension is equal or below the limit. |
Max MBytes Isotropic | MaxMBytesIsotropic | MAX_MBYTES_ISOTROPIC | Select the scaling factors such that the total image size in megabytes is equal or below the limit, preferring an isotropic output image. |
Max MBytes Cubic | MaxMBytesCubic | MAX_MBYTES_CUBIC | Select the scaling factors such that the total image size in megabytes is equal or below the limit, preferring a cubic output image. |
Max MBytes Uniform | MaxMBytesUniform | MAX_MBYTES_UNIFORM | Select the scaling factors such that the total image size in megabytes is equal or below the limit, preferring uniform scaling. |
Min Voxel Dist | MinVoxelDist | MIN_VOXEL_DIST | Select the scaling factors such that the voxel distance in millimeters for each spatial dimension is equal or above the limit. |
Limit¶
-
name:
limit
, type:
Float
, default:
0
¶ Sets the size limit in voxels, megabytes or millimeters, depending on the
Restriction
setting.
Allow interpolation¶
-
name:
interpolate
, type:
Bool
, default:
FALSE
¶ If checked, scaling factors are allowed to be fractional, otherwise only integer scaling factors are applied.
Method¶
-
name:
method
, type:
Enum
, default:
Nearest_Neighbor
¶ Defines the method to interpolate an image for compression.
See
Resample3D
for details.
Values:
Title | Name |
---|---|
Nearest Neighbor | Nearest_Neighbor |
Triangle/Linear | Triangle/Linear |
Hermite | Hermite |
Blackman | Blackman |
Hamming | Hamming |
Hanning | Hanning |
Gaussian | Gaussian |
Bell/Quadratic | Bell/Quadratic |
Cubic B-Spline | Cubic_B-Spline |
Catrom | Catrom |
Mitchell et al | Mitchell_et_al |
Trunc Sinc 4 | Trunc_Sinc_4 |
Lanczos 2 | Lanczos_2 |
Lanczos 3 | Lanczos_3 |
Lanczos 4 | Lanczos_4 |
Box NNB | Box_NNB |