ComfyUI Node

Scaler | Area

Scale by area, not by side — the multiplier that keeps its shape

By wmpmiles·Created 2 years ago·Updated about a year ago· 5
Scaler | Area
    • scaler
    area_multiplier1.000

    Scaler | Area is the sizing node that thinks in total pixels instead of per-side lengths. You give it an area_multiplier, and it scales the image so the area is multiplied by that factor while keeping the aspect ratio intact. Set 2 and the image has twice the pixels; set 0.5 and it has half. No distortion, no thinking about dimensions.

    Why is that useful when the pack also has Scaler | Side for per-side multipliers and Scaler | Fixed for exact resolutions? Because "how much bigger" is usually an area question. Upscaling 1.5× per side is really a 2.25× pixel-count question, and people routinely underestimate how much VRAM that costs. Thinking in area keeps the cost in your head - which matters in ComfyUI, because pixel count is what fills your VRAM on the decode side.

    How it works

    The node takes one input, area_multiplier (FLOAT, default 1, min 0.001). Internally it takes the square root of the multiplier and scales each side by that - that's the math that keeps the aspect ratio: double the area means each side grows by √2. So a 1024×1024 image at area_multiplier = 2 becomes roughly 1448×1448. The output is a scaler wire, which you plug into Resample Image, Resample Mask, Resample Latent, or the inpaint pair's Pre node.

    A few useful numbers to have in your head: 1.5 ≈ 50% more pixels, 2 ≈ double, 0.25 ≈ quarter (halving each side), 0.01 ≈ one percent of the original pixel count. The last one is a genuinely handy "make this tiny" preset.

    Pairing it with a resampler

    Remember the scaler only decides size; the method is decided by the resampler you wire alongside it. If your area_multiplier is below 1 (shrinking), pair it with Resampler | Area to avoid moiré. If it's above 1 (growing), Resampler | Lanczos or Resampler | Mitchell-Netravali for quality. The two decisions are separate by design, and this node's whole job is the first half.

    Installing

    It ships with the rest of comfyui-some-image-processing-stuff:

    cd ComfyUI/custom_nodes
    git clone https://github.com/wmpmiles/comfyui-some-image-processing-stuff
    

    Restart, or use ComfyUI Manager → search "Some Image Processing Stuff". No model files, no dependencies beyond PyTorch. And the usual pack note: a scaler wire left unconnected is a required-input error on the Resample node, not a silent default.

    Categoryresampling/scaler

    Inputs (1)

    NameTypeDefaultDescription
    area_multiplierFLOAT1.000

    Outputs (1)

    NameTypeDescription
    scalerSCALER