Nodes/ComfyUI-RvTools_v2/Size + XY Offset
ComfyUI Node

Size + XY Offset

Width, height and an offset, for clean sizing and cropping

By r-vage·Created about a year ago·Updated 5 months ago· 23
Size + XY Offset
    • width
    • height
    • offset_y
    • offset_x
    Width150
    Height20
    Offset_Y0
    Offset_X0

    This is the definition of a utility node: Size + XY Offset takes a width and height, adds an X/Y offset, and hands all four back as integers on separate sockets. No computation, no cleverness - it's a tidy way to keep your sizing values in one place and feed them to the nodes that need them. If you've ever had an empty-latent width here, a crop width over there and an inpaint offset somewhere else, this is the node that un-fragments your numbers.

    How it works

    The execute method just returns its inputs: (Width, Height, Offset_Y, Offset_X) out the width, height, offset_y, offset_x INT sockets. That's it. But that simplicity is the point - it turns scattered widget values into named, wireable values. Width defaults to 150, Height to 20 (an odd default, honestly - fine if you're sizing crops or tiles, less useful if you expected 512+; just set them). Offset_X and Offset_Y default to 0.

    Where it fits

    The classic use is a "sizing block" at the top of a workflow: one node defines the canvas, and its outputs drive an Empty Latent Image, a sampler resolution, or an upscale target. The offsets are the detailer-friendly part - in inpaint/outpaint and region workflows, an offset lets you shift a crop window or recenter a region without editing a mask. Wire width/height into an Empty Latent Image, and offset_x/offset_y into whatever crop or paste node your workflow uses.

    The inputs that matter

    • Width (INT, default 150) and Height (INT, default 20) - required.
    • Offset_Y (INT, default 0) and Offset_X (INT, default 0) - optional.

    Four INT outputs, all named. Since the outputs are plain integers, they'll feed anything that takes an INT - latents, upscalers, crop nodes, even a Size string builder if you convert them.

    Installing it

    ComfyUI Manager → search ComfyUI-RvTools_v2, install, restart; or:

    cd ComfyUI/custom_nodes
    git clone https://github.com/r-vage/ComfyUI-RvTools_v2
    

    No model downloads, no extra dependencies.

    Gotchas

    The pack is unmaintained (superseded by ComfyUI_Eclipse) but a four-value pass-through can't really rot. The v2 rename is the one real trap: legacy ComfyUI-RvTools v1 workflows will report this node missing. And worth knowing: this node doesn't round or clamp anything - it's a pure pass-through - so if you feed it values that don't divide cleanly for your model's latent size, that's on you to normalize. Most workflows just set width/height to multiples of 8 anyway.

    Category🫦 RvTools II/ Settings

    Inputs (4)

    NameTypeDefaultDescription
    WidthINT150
    HeightINT20
    Offset_YoptINT0
    Offset_XoptINT0

    Outputs (4)

    NameTypeDescription
    widthINT
    heightINT
    offset_yINT
    offset_xINT