Visit ComfyUI Online for ready-to-use ComfyUI environment
Upscale images by adjusting dimensions based on specified side length, maintaining aspect ratio and offering various upscale methods.
The DF_Image_scale_to_side
node is designed to upscale images by adjusting their dimensions based on a specified side length. This node allows you to scale an image proportionally by either its width, height, longest side, or shortest side, ensuring that the aspect ratio is maintained. It provides flexibility in choosing the scaling method and whether to crop the image, making it a powerful tool for AI artists who need to resize images while preserving their quality and proportions. The node supports various upscale methods, offering a range of options to achieve the desired visual effect.
This parameter accepts the image you want to upscale. The image should be in a format that the node can process, typically an image tensor.
This integer parameter specifies the target length for the chosen side (width, height, longest, or shortest). The image will be scaled proportionally based on this length. The minimum value is 0, and there is no explicit maximum value, but it should be within reasonable limits to avoid excessive scaling.
This parameter determines which side of the image will be scaled to the specified length. Options include "Longest", "Shortest", "Width", and "Height". Choosing "Longest" or "Shortest" will scale the image based on its longest or shortest side, respectively, while "Width" or "Height" will scale based on the specified dimension.
This parameter allows you to select the method used for upscaling the image. Available options are "nearest-exact", "bilinear", "bicubic", "bislerp", "area", and "lanczos". Each method offers different trade-offs between speed and quality, with "lanczos" generally providing the highest quality at the cost of processing time.
This parameter specifies whether the image should be cropped after scaling. Options are "disabled" and "center". "Disabled" means no cropping will occur, while "center" will crop the image to maintain the specified aspect ratio, focusing on the center of the image.
The output is the upscaled image, returned as an image tensor. This image will have the dimensions adjusted according to the specified side length and scaling method, maintaining the aspect ratio and applying any cropping if specified.
© Copyright 2024 RunComfy. All Rights Reserved.