ComfyUI Node

Wan Multi Ref Stack

The boring ref-stacker that's still useful

By Tessiiiz·Created 6 months ago·Updated 6 months ago· 2
Wan Multi Ref Stack
  • image_1
  • image_2
  • image_3
  • image_4
  • image_5
  • image_6
  • image_7
  • image_8
  • image_9
  • image_10
  • image_11
  • image_12
  • images
resize_modematch_first

WanMultiRefStack ("Wan Multi Ref Stack") is the pack's oldest and most boring node, and it's fine. It exists because the "Multi Ref" name on this pack's main nodes implies you need a way to combine many still images into one batch - and if you're not using the fancy positioned gallery, this is the plain manual way to do it.

What it does

Twelve optional image slots, one stacked output. Wire any number of image_1 through image_12 inputs, and it concatenates them into a single IMAGE batch in slot order. That's the whole mechanism: no timeline, no masks, no positions - a straight torch.cat of whatever's connected, resized to a common shape first.

The one setting that matters is resize_mode:

  • match_first (default) - every image is stretched to the dimensions of the first connected image.
  • crop_to_first - images are center-cropped to the first image's dimensions instead.

Given how the resize is implemented, match_first is effectively a stretch; if your refs are mixed aspect ratios, crop_to_first avoids the distortion.

Why you'd use it

The README's recommended wiring is specific: use it for extra_reference_images on the main VACE nodes when you have refs you don't want to pin to specific frames. So the pattern is:

  1. Wan Positioned Ref Gallery handles the frames you want placed on the timeline.
  2. Wan Multi Ref Stack rounds up everything else.
  3. The stack's images output goes into Wan VACE Multi-Ref To Video.extra_reference_images.

Just keep the earlier article's warning in mind: on the 2.1 node, only the first reference makes it into the primary reference_image slot. Feeding extra refs through this stack is a "some influence, not full multi-ref anchoring" situation - the positioned gallery is the real multi-ref path.

Gotchas

  • Empty slots are skipped, so you don't need to fill all twelve. If nothing is connected you get an empty batch rather than an error.
  • It's a manual tool, and the author has flagged it as the older approach - the gallery supersedes it for anything position-aware.
  • No dependencies beyond ComfyUI itself. Install via Manager ("ComfyUI-Tessiiiz-WanVideoToolkit") or:
cd ComfyUI/custom_nodes
git clone https://github.com/Tessiiiz/ComfyUI-Tessiiiz-WanVideoToolkit

...and restart ComfyUI.

If you only ever need to pile five images into one tensor, this does it in one node instead of five Image Batch core nodes. That's the whole value, and it's a real one.

CategoryWan 2.1 Toolkit

Inputs (13)

NameTypeDefaultDescription
resize_modeCOMBOmatch_first2 options: match_first, crop_to_first
image_1optIMAGE
image_2optIMAGE
image_3optIMAGE
image_4optIMAGE
image_5optIMAGE
image_6optIMAGE
image_7optIMAGE
image_8optIMAGE
image_9optIMAGE
image_10optIMAGE
image_11optIMAGE
image_12optIMAGE

Outputs (1)

NameTypeDescription
imagesIMAGE