NL WanVideo ImageToVideo Encode v2 (multi-ref)
Multi-reference Wan image-to-video encoding, without the wire spaghetti
- vae
- clip_embeds
- reference_images
- control_embeds
- temporal_mask
- extra_latents
- add_cond_latents
- image_embeds
If you've built a Wan 2.1 image-to-video workflow, you know the encode step is the fiddly heart of it: VAE-encode your reference frame, inject it into the right latent positions, wire the CLIP vision embeds, juggle the noise schedule. It works, but it's a wall of wires and it gets worse the moment you want more than one reference. NL WanVideo ImageToVideo Encode v2 is the pack's attempt to collapse that whole mess into a single node that takes one or more reference frames and produces the image_embeds a Wan sampler wants. "Multi-ref" is the headline: instead of just a first frame, you can anchor the start, middle, and end of a clip with different images.
That's a genuinely useful trick. Wan 2.2's two-pass architecture and the community's favorite I2V workflows lean hard on first-frame anchoring, but a middle or end reference is what stops a video from drifting off into "close enough" territory halfway through. This node lets you place references anywhere and spreads them evenly when you set reference_frame_indices to auto.
What matters
reference_images- one or more frames. Wire up to three and they become start/middle/end references.reference_frame_indices- comma-separated frame indices for each reference;-1means the last frame.autospreads them evenly, which is the sane default until you have an opinion.noise_aug_strength- the README of Wan workflows will tell you this is the dial that adds motion and sharper results on I2V. Zero is the safe start; a little noise-aug buys motion at the cost of reference fidelity.start_latent_strength/end_latent_strength- multipliers for how strongly the first/last latent takes the reference. Lower these and the model gets more room to invent.vaeandclip_embeds- plug in the pack's Wan VAE and CLIP-vision embeds from your loader.dual_encode_last- the Wan 2.2 style two-pass VAE encoding that treats the last frame as an end frame. Turn it on for Wan 2.2; leave it off for 2.1-style.temporal_mask- optional per-frame mask, auto-resized and combined with the reference locations. This is how you localize what gets conditioned.tiled_vae- reduced-memory tiled encoding for when the 27B model is eating your VRAM for lunch.fun_or_fl2v_model- flip this on when you're using the official FLF2V or Fun variant.
Output: a single image_embeds tensor in the WANVIDIMAGE_EMBEDS format, which feeds straight into the Wan sampler node in your graph.
Install and the usual caveats
Pack install as always: ComfyUI Manager → "ComfyUI-NL_Nodes", or clone:
cd ComfyUI/custom_nodes
git clone https://github.com/NOLABEL-VFX/ComfyUI-NL_Nodes
Restart and it shows up under WanVideoWrapper. One thing to flag: this node works on top of Wan's own ComfyUI integration, so have the Wan model family and its wrapper nodes installed and working before you blame this node. Also remember the wider picture from the Wan ecosystem: as of mid-2026, open Wan means 2.1/2.2 - Alibaba's later versions are API-only. Multi-reference anchoring like this is exactly the workflow that keeps Wan 2.2 relevant.
Inputs (18)
| Name | Type | Default | Description |
|---|---|---|---|
| width | INT | 83264–8096 | Width of the image to encode |
| height | INT | 48064–8096 | Height of the image to encode |
| num_frames | INT | 811–10000 | Number of frames to encode |
| noise_aug_strength | FLOAT | 0.0000–10 | Strength of noise augmentation, helpful for I2V where some noise can add motion and give sharper results |
| start_latent_strength | FLOAT | 1.0000–10 | Multiplier for the first latent that receives a reference frame |
| end_latent_strength | FLOAT | 1.0000–10 | Multiplier for the last latent that receives a reference frame |
| force_offload | BOOLEAN | true | — |
| vaeopt | WANVAE | — | |
| clip_embedsopt | WANVIDIMAGE_CLIPEMBEDS | Clip vision encoded image | |
| reference_imagesopt | IMAGE | One or more reference frames (start / middle / end) | |
| reference_frame_indicesopt | STRING | auto | Comma separated frame indices for each reference. -1 targets the last frame. Use 'auto' to evenly spread references. |
| control_embedsopt | WANVIDIMAGE_EMBEDS | Control signal for the Fun -model | |
| fun_or_fl2v_modelopt | BOOLEAN | true | Enable when using official FLF2V or Fun model |
| dual_encode_lastopt | BOOLEAN | false | Use Wan 2.2 style two-pass VAE encoding that treats the last frame as an end frame |
| temporal_maskopt | MASK | Optional per-frame mask; combined with reference locations and resized automatically | |
| extra_latentsopt | LATENT | Extra latents to add to the input front, used for Skyreels A2 reference images | |
| tiled_vaeopt | BOOLEAN | false | Use tiled VAE encoding for reduced memory use |
| add_cond_latentsopt | ADD_COND_LATENTS | Additional cond latents WIP |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| image_embeds | WANVIDIMAGE_EMBEDS | — |