Nodes/ComfyUI-AusBoss/Load Image + Pad πŸ†Ž
ComfyUI Node

Load Image + Pad πŸ†Ž

Loads an image and pads it into an outpaint canvas in one node. Drag any edge of the canvas drawn on the node to set the per-side padding visually; the mask covers exactly the new padding, optionally feathered inward across the seam. The canvas rounds up to a clean multiple, and a megapixel target rescales the source first so the mask seam stays crisp.

By ausbossΒ·Created about a month agoΒ·Updated 7 days agoΒ· 2
Load Image + Pad πŸ†Ž
    • image
    • mask
    • width
    • height
    • stitcher
    • reference
    β—„imageβ–Ύβ–Ί
    β—„pad_left0β–Ί
    β—„pad_top0β–Ί
    β—„pad_right0β–Ί
    β—„pad_bottom0β–Ί
    β—„modecolorβ–Ί
    β—„fill_color#808080β–Ί
    β—„backdrop_blur0.50β–Ί
    β—„feather0β–Ί
    β—„canvas_multiple8β–Ί
    β—„target_megapixels0.00β–Ί
    CategoryπŸ†Ž AusBoss/Image

    Inputs (11)

    NameTypeDefaultDescription
    imageCOMBOChoose or upload an image from ComfyUI's input folder.
    pad_leftINT00–16384Pixels added to the left edge (drag the canvas edge on the node).
    pad_topINT00–16384Pixels added to the top edge (drag the canvas edge on the node).
    pad_rightINT00–16384Pixels added to the right edge (drag the canvas edge on the node).
    pad_bottomINT00–16384Pixels added to the bottom edge (drag the canvas edge on the node).
    modeCOMBOcolorcolor = solid fill_color; edge = each side takes the average color of the nearest image edge; edge pixel = the outermost rows and columns smear outward; pillarbox blur = the image itself, stretched to cover the canvas, blurred and dimmed behind the sharp original.
    fill_colorSTRING#808080Padding color for the color mode; accepts #RGB/#RRGGBB hex, R, G, B (0-255 or 0..1 floats), one grayscale number, or a CSS color name. Other modes ignore it.
    backdrop_blurFLOAT0.500–1Pillarbox blur only: one knob for how strongly the backdrop is blurred and dimmed; 0 keeps it sharp and full brightness.
    featherINT00–2048Ramps the mask inward across the image edge on each padded side so the sampler blends the seam; 0 keeps the seam hard.
    canvas_multipleINT81–4096Rounds the final canvas up to this multiple; the remainder joins the right and bottom padding.
    target_megapixelsFLOAT0.000–640 = off. Rescales the SOURCE so the padded canvas lands on this many megapixels (then re-rounds to canvas_multiple) β€” resizing before padding keeps the mask seam crisp.

    Outputs (6)

    NameTypeDescription
    imageIMAGEThe padded image; the original pixels are untouched (resized only when a megapixel target is set).
    maskMASKWhite over the new padding, feathered inward per the feather widget β€” feed it straight to an inpainter as the outpaint mask.
    widthINTFinal canvas width after multiple/megapixel rounding.
    heightINTFinal canvas height after multiple/megapixel rounding.
    stitcherAUSBOSS_STITCHERHand to Stitch Inpaint πŸ†Ž with the sampled result to keep only the new padding and restore the original pixels bit-identically. Also carries where the source sits on the canvas, which Krea 2 Outpaint Model Patch πŸ†Ž reads to place the reference.
    referenceIMAGEThe source alone, no padding, fitted to a small multiple of 16 β€” the reference image for Krea 2 Encode πŸ†Ž and other reference conditioning. Wire it nowhere and nothing is computed.