On this page |
This node performs image scaling by changing the width, height, and pixel sizes of an image. Use this node to resize images into new output canvases that can be of different aspect ratios or resolutions. This node allows for different sampling algorithms such as point sampling, bilinear sampling, and box sampling.
Parameters ¶
Signature
The layer type that the source accepts.
See Signatures for more information.
Canvas ¶
Size Control
The method used to control how resampling is done.
Resolution
Control the number of pixels in the width or height.
Aspect Ratio
Control the ratio between the width and height.
Pixel Size
Control the size of the pixels.
Base Size
The base size to use as the final output’s dimensions.
Parameter
Set the base parameters directly using Base Resolution, Base Aspect Ratio, or Pixel Size.
Size Input
Inherit the base parameters from the size_ref
input or, if not wired in, the source
input.
Base Resolution
When Size Control is Resolution
and Base Size is Parameter
, this is the base number of pixels for the final image’s width and height.
Base Aspect Ratio
When Size Control is Aspect Ratio
and Base Size is Parameter
, this is the base aspect ratio for the final image.
Pixel Size
When Size Control is Pixel Size
and Base Size is Parameter
, this is the base pixel size for the final image. The base pixel size is square pixels, so this size
is for both the width and height of a pixel.
Uniform Scale
The scale to apply to the Base Size.
For Resolution
, this scales the number of pixels in both dimensions. For Aspect Ratio
, this scales the aspect ratio. For Pixel Size
, this scales the pixel’s dimensions.
Resolution Scale
When Size Control is Resolution
, this scales the number of pixels in width and height respectively.
Fixed Dimension
When Size Control is Aspect Ratio
, this determines which dimension stays constant from the input image. The other dimension changes to match the aspect ratio.
Width
The width matches the input image’s width.
Height
The height matches the input image’s height.
Smaller Dimension
The smaller resolution matches the input image’s smaller resolution.
Larger Dimension
The larger resolution matches the input image’s larger resolution.
Size Scale
When Size Control is Pixel Size
, this scales the pixel’s width and height respectively.
Reframe to Destination
Stretches the input image through resampling to conform to the entire boundary of the output and maintains the given pixel size. Specifically, this makes the display window match the data window.
See Data and display windows for more information.
Sampling ¶
Filter
The filter used to sample.
See Filters for more information.
Point
Sets the pixel value to the pixel value of the nearest neighbor.
Bilinear
Sets the pixel value through bilinear interpolation .
Box
Sets the pixel value through a box filter, done by sampling all pixels within a box on the original image’s matching pixel.
Bartlett
Sets the pixel value through interpolating according to a triangular window or a Bartlett window , taking each pixel as a sample of this signal.
Catmull-Rom
Sets the pixel value through a bicubic spline known as the Catmull-Rom spline . This is a special case of the Mitchell-Netravali filter .
Mitchell
Sets the pixel value through a bicubic spline known as the Mitchell-Netravali filter.
B-spline
Sets the pixel value through a bicubic spline known as the B-spline . This is a special case of the Mitchell-Netravali filter.
Stretch Behavior
Determine how the image stretches after the resample operation. Specifically, this determines how to stretch the display window.
Note
If Reframe to Destination is on, this parameter has no effect since the display window doesn’t stretch differently.
Stretch to Fit
Stretches the pixels to fit within the new display window. The display window is scaled naively according to the same scale that the data window is scaled at.
Fit Horizontally
Maintains the original pixel aspect ratio and aspect ratio by scaling the display window’s x dimension in relation to the data window’s x dimension.
Fit Vertically
Maintains the original pixel aspect ratio and aspect ratio by scaling the display window’s y dimension in relation to the data window’s y dimension.
Fit Maximally
Maintains the original pixel aspect ratio and aspect ratio by scaling the display window according to the original image’s data window’s maximal dimension.
Fit Minimally
Maintains the original pixel aspect ratio and aspect ratio by scaling the display window according to the original image’s data window’s minimal dimension.
Inputs ¶
source
The source image to resample.
size_ref
A representative layer that determines the size of the output image and controls the metadata.
Outputs ¶
resample
The output image with the new resolution or pixel size.