Nodes/ComfyUI-MaxedOut/WAN 2.2 Video Prep I2V MXD
ComfyUI Node

WAN 2.2 Video Prep I2V MXD

Feed WAN 2.2 the bucket size it actually wants

By Maxed-Out-99·Created about a year ago·Updated 21 days ago· 9
WAN 2.2 Video Prep I2V MXD
  • video
  • scaled_video
  • images
  • fps
tierAuto
crop_to_fittrue
force_fpsfalse
target_fps16
aspect_modeAuto

WAN 2.2 is the last great open video base - Alibaba froze the open line at 2.2 in July 2025 and most of the open video models since have been built on it. It's also picky: it wants its frames inside specific resolution "buckets" (480p and 720p classes), and if you throw a 1920x1080 clip or a weird 786x412 file at it, you get slow, sloppy, or flat-out failed results. WAN 2.2 Video Prep I2V MXD is the "make my random source video fit WAN's buckets" node from the MaxedOut pack, built for iterative image-to-video extension workflows.

What it does

You feed it a VIDEO (from the pack's Load Video MXD, or anything that outputs the new ComfyUI VIDEO type), and it hands you back three things: a scaled_video at a valid WAN bucket, the same frames as an images batch, and the fps as a float. The idea is you drop it between your video loader and the WAN I2V pipeline, and it quietly does the size math so you don't have to.

Under the hood it does two jobs:

  1. Optional FPS resampling. With force_fps on, it actually drops or duplicates frames (nearest-frame selection, preserving duration) and sets the output to exactly target_fps - default 16, which is the frame count WAN 2.2 was trained around. Off, it keeps the source FPS.
  2. WAN bucket scaling. It picks a bucket based on your tier (Auto / 480p / 720p), then either resizes-to-cover and center-crops (crop_to_fit on, "perfect fit") or resizes to fit inside with no crop (crop_to_fit off, "closest fit").

The inputs that matter

  • tier - Auto, 480p (832x480 class), or 720p (1280x720 class). Auto is the sensible default; pick 720p if your VRAM allows and quality is the goal.
  • crop_to_fit - on it crops edges to hit the exact bucket, off it letterboxes/pillarboxes inside the bucket. On for WAN's preferred input, off if you can't afford to lose content.
  • force_fps / target_fps - force a clean 16fps (or whatever you want). WAN likes clean frame counts; this avoids the janky cadence you get from a 24→16 remux.
  • aspect_mode - Auto, or force Tall/Wide/Square bucket shapes.

A real gotcha: this node needs the new ComfyUI

The WAN I2V nodes in this pack only register when ComfyUI's newer comfy_api (the Nodes 2.0 API layer) is available. If you're on an older ComfyUI release, WAN22_I2V_Video_Prep_MXD simply won't appear in your node list - no error, just missing. Update ComfyUI before you go hunting for it.

Install

cd ComfyUI/custom_nodes
git clone https://github.com/Maxed-Out-99/ComfyUI-MaxedOut.git

Restart after cloning, or install via ComfyUI Manager (search "Maxed Out"). No extra pip dependencies and no model files for this node itself - though you'll obviously need a WAN 2.2 checkpoint (the 14B A14B image-to-video model is the usual pairing) and the pack's other WAN helpers.

Troubleshooting

  • "Input video has zero frames" - the VIDEO you fed it is empty. Check your loader.
  • "Unexpected frame tensor shape" - some loaders hand over audio-only or pre-decoded weirdness; run the source through the pack's Load Video MXD first.
  • Previews look cropped - that's crop_to_fit doing its thing. Flip it off if the subject is getting sliced, or fix your source aspect ratio upstream.
  • Output comes back the same size - if your source is already WAN-safe, the "Safe Auto" path passes it through untouched. That's a feature, not a bug.

If your video fits, WAN 2.2 I2V is one of the best local motion generators you can run - this node just makes sure you're feeding it on its own terms.

CategoryMXD/video

Inputs (6)

NameTypeDefaultDescription
videoVIDEO
tierCOMBOAuto3 options: Auto, 480p, 720p
crop_to_fitBOOLEANtrue
force_fpsBOOLEANfalseWhen enabled, resample frames (drop/duplicate) and set exact target fps.
target_fpsINT161–1000Used when Force FPS is enabled. Output video fps will be set exactly to this value.
aspect_modeCOMBOAutoAuto picks wide/tall/square from the source. Use Square/Tall/Wide to force the target bucket shape.

Outputs (3)

NameTypeDescription
scaled_videoVIDEO
imagesIMAGE
fpsFLOAT