Nodes/ComfyUI-ResizeToCanvasSize/Resize To Canvas Size (COI)
ComfyUI Node

Resize To Canvas Size (COI)

A ComfyUI node in image/transform with 12 inputs and 2 outputs.

By Carasibana·Created 5 months ago·Updated 4 months ago· 3
Resize To Canvas Size (COI)
  • image
  • mask
  • IMAGE
  • padding_mask
width512
height512
anchor_grid3,3
anchor_modemanual
scale_methodFit to Canvas short edge
fill_methodcrop
padding_fillblack
custom_color_hex#000000
noise_seed0
custom_color_hex_input
Categoryimage/transform

Inputs (12)

NameTypeDefaultDescription
imageIMAGE
widthINT5121–8192
heightINT5121–8192
anchor_gridSTRING3,3
anchor_modeCOMBOmanual3 options: manual, mask_bbox_centre, mask_weighted_centre
scale_methodCOMBOFit to Canvas short edge5 options: None – use original size, Fit to Canvas short edge, Fit to Canvas long edge, Fit to Canvas height, Fit to Canvas width
fill_methodCOMBOcrop2 options: crop, stretch
padding_fillCOMBOblack6 options: black, white, gray_50, transparent, custom, noise
custom_color_hexSTRING#000000
noise_seedINT00–18446744073709550000
maskoptMASK
custom_color_hex_inputoptSTRING

Outputs (2)

NameTypeDescription
IMAGEIMAGE
padding_maskMASK