JLC Resize Multiple Images
One resize policy, five images, zero math on your part
- image_1
- image_2
- image_3
- image_4
- image_5
- image_1
- image_2
- image_3
- image_4
- image_5
- batch
JLC Resize Multiple Images takes one to five IMAGE tensors, applies one shared aspect-ratio-preserving resize policy to all of them, and hands you each resized image back separately - plus a convenience batch output for the nodes that insist on one.
You reach for it when a workflow needs several reference images prepped identically: multi-reference IP-Adapter, a stack of ControlNet hint images, a batch of condition images that all have to follow the same scaling rule. Doing that with stock nodes means dropping an ImageScale node per image and keeping every widget in sync by hand; this node shares the policy once, and each input resizes from its own source geometry instead of being forced to one canvas size.
How it works
For every active input it computes target dimensions (preserving that input's own aspect ratio), rounds them to your divisible_by multiple, and resizes with ComfyUI's common_upscale using your chosen interpolation. Nothing exotic - but the details are where it earns its keep:
slot_count(1–5) is the master switch. Set it, press Update Visible Slots, and the frontend shows exactly that many input/output sockets. Inactive slots returnNone.resize_bypicks the policy - six options:scale by multiplier,scale longer dimension(default, 1024),scale shorter dimension,scale width,scale height, orscale total pixels(megapixels, using 1024×1024 per megapixel).divisible_by(default 16) rounds width and height down to that multiple after the aspect calculation. Set to 1 to disable. This is the setting that keeps your output dims friendly to the model.scale_methodis your interpolation:areais generally strong for downscaling,lanczosoften better for upscaling - that's the author's own guidance in the tooltip, and it matches how people actually use these in upscaling pipelines.
Outputs are image_1 through image_5, each retaining its own calculated dimensions, plus a trailing batch output. The batch follows ComfyUI's legacy ImageBatch behavior: later images are normalized to the first active result's geometry (bilinear rescale) before concatenation, and channel-count mismatches get padded with opaque values. If an upstream node deliberately outputs None at runtime, the node passes that through positionally and leaves it out of the batch.
The trap
The batch output normalizes everything to the first active image's dimensions. Feed it two images with different aspect ratios and the second one gets squashed to match. That's expected ImageBatch behavior, but it's a genuine footgun - if each image should keep its own geometry, wire the individual outputs instead and only use batch when a downstream node genuinely needs one stack. Also note divisible_by rounds down: target 1000 with the default 16 becomes 992, which surprises people who expected a clean 1000.
And it's one policy for all slots. If you need different target sizes per image, this isn't the node - the pack's single-image JLC Resize Image (or stock ImageScale) is the per-image tool.
Install
Ships in jlc-comfyui-nodes by J. L. Córdova. ComfyUI Manager finds it as "jlc-comfyui-nodes" (also on the ComfyUI Registry), or:
cd ComfyUI/custom_nodes
git clone https://github.com/Damkohler/jlc-comfyui-nodes.git
Restart ComfyUI after. No requirements.txt, no model downloads - plain ComfyUI core plus a small frontend extension for the slot visibility.
If you resize the same kind of images every session - reference crops for a multi-LoRA Flux stack, say - one node doing all five keeps the graph readable and the settings honest. It's the rare utility node that's simpler than doing it with stock parts.
Inputs (15)
| Name | Type | Default | Description |
|---|---|---|---|
| image_1 | IMAGE | Incoming IMAGE tensor to resize. If the upstream connected node deliberately outputs None at runtime, this node passes None through. | |
| slot_count | INT | 11–5 | Number of active image inputs and individual outputs. Press Update Visible Slots to apply the frontend socket layout. |
| resize_by | COMBO | scale longer dimension | Aspect-ratio-preserving resize policy. |
| multiplier | FLOAT | 1.000.01–8 | Scale factor; 2.0 doubles both dimensions. |
| longer_size | INT | 10241–16384 | Target size of the source image's longer edge. |
| shorter_size | INT | 10241–16384 | Target size of the source image's shorter edge. |
| width | INT | 10241–16384 | Target width; height is calculated from aspect ratio. |
| height | INT | 10241–16384 | Target height; width is calculated from aspect ratio. |
| megapixels | FLOAT | 1.000.01–64 | Target total megapixels using 1024×1024 per megapixel. |
| scale_method | COMBO | area | Interpolation method. Area is generally strong for downscaling; Lanczos is often useful for upscaling. |
| divisible_by | INT | 161–512 | After aspect-ratio calculation, round width and height down to this multiple. Use 1 to disable. |
| image_2opt | IMAGE | Optional source image for active slot 2. | |
| image_3opt | IMAGE | Optional source image for active slot 3. | |
| image_4opt | IMAGE | Optional source image for active slot 4. | |
| image_5opt | IMAGE | Optional source image for active slot 5. |
Outputs (6)
| Name | Type | Description |
|---|---|---|
| image_1 | IMAGE | — |
| image_2 | IMAGE | — |
| image_3 | IMAGE | — |
| image_4 | IMAGE | — |
| image_5 | IMAGE | — |
| batch | IMAGE | — |