WK Video Resolution
Megapixels in, two resolution pairs out
- width
- height
- scale_width
- scale_height
- resolution
What it's for
Video models don't care about "1080p." They care about an aspect ratio, a pixel budget, and whether the numbers divide into whatever their VAE demands. LTX wants both dimensions divisible by 32. Wan workflows live around 832×480 and 1280×720. Most current models take any size in a one-to-two megapixel band and degrade softly above it rather than breaking outright.
So the useful input isn't a resolution - it's how many pixels, at what shape. WK Video Resolution is that node: you dial in aspect ratio, megapixels, an alignment multiple and a scale factor, and it returns both the base size and a scaled size, already computed. It's part of ComfyUI WorkspaceKit (ZiYao00, public beta) under 🧩 WorkspaceKit/Utilities, and it's the current, non-legacy replacement for WK Resolution Preset (Legacy).
How it works
The base size uses ComfyUI's own ResolutionSelector formula: target_pixels = megapixels × 1024 × 1024. From there it solves scale = sqrt(target_pixels / (ratio_w × ratio_h)), computes each side, and rounds to the nearest multiple of your multiple value - not up, so the result sits close to your pixel budget rather than always overshooting.
Concrete, verified outputs at 16:9:
| megapixels | multiple | result | |---|---|---| | 0.5 | 32 | 960 × 544 | | 1.0 | 8 | 1368 × 768 | | 2.0 | 64 | 1920 × 1088 |
Note 1368×768 rather than the 1366×768 you'd get from a naive 16:9 division - the alignment multiple is doing that. Set multiple to 32 and the 16:9 case lands on 960×544, which is a real draft size people run. Set it to 64 for Flux-family work; leave it at 8 for SDXL-era latents, where 8 is enough for the VAE.
Then the second stage: scale is one of nine presets - 0.5, 1.0, 1.5, 2.0, 2.5, 3.0, 4.0, 6.0, 8.0 - and scale_width / scale_height are the base dimensions multiplied by that factor and rounded. At 1.0 MP, 16:9, 1.5 gives you 2052×1152 alongside the 1368×768 base. That pairing is the whole reason the node exists: base size for the first sampling pass, scaled size for the hires or upscale pass, both computed from one place instead of you doing it twice and getting it inconsistent.
Five outputs: width, height, scale_width, scale_height (all INT) and resolution, a STRING that labels both stages - something like 1368 × 768 → 2052 × 1152 · scale 1.5. Wire that string into a filename prefix or a note node and every render tells you exactly what produced it.
Aspect ratios include 21:9, which the legacy node doesn't have. You ask for the shape, you get the shape.
Inputs worth changing
- aspect_ratio -
▭ 16:9is the default, and for video it's usually right. - megapixels -
0.5to1.0for drafts,1.0–2.0for finals. The range goes to 16, but a 16 MP video shot is a fantasy on consumer hardware; Wan's practical ground is 480p–720p. - multiple - 8 by default, step 4, range 8–128. This is the field to get right per model: 32 for LTX, 64 for Flux-style divisibility, 8 otherwise.
- scale - the second-stage multiplier. Leave it at
1.0if you don't need the second pair.
Install
Manager: search WorkspaceKit or comfyui-workspacekit, install, restart. Or:
cd ComfyUI/custom_nodes
git clone https://github.com/ZiYao00/ComfyUI-WorkspaceKit.git
cd ComfyUI-WorkspaceKit
python -m pip install -r requirements.txt
Windows portable, run from the ComfyUI root:
.\python_embeded\python.exe -m pip install -r .\ComfyUI\custom_nodes\ComfyUI-WorkspaceKit\requirements.txt
One dependency, send2trash, for the sidebar's trash - nothing needed for this node, no models, no torch. It's a plain backend node with no custom frontend code, so it renders and serializes the same in the legacy canvas and under Nodes 2.0. Restart after installing, since you're also loading WorkspaceKit's frontend.
Where it bites
Scale height must be between 1 and 16384.Dimensions cap at 16384 on a side. A big base times a big multiplier walks straight into it - 4096×2304 at8.0is 32768 wide.- Your model rejects the size. Check which multiple it wants. Off-grid values on LTX fail rather than round, and this node aligns to your multiple, not the model's.
- The numbers look off by a few pixels. That's the alignment multiple, working as intended. Round to nearest means the pixel count drifts a little from your megapixel target.
- You wanted exact dimensions. This node won't take them - use its sibling
WK Resolution Preset (Legacy)withuse_customon, or ComfyUI's own empty-latent width/height fields, if you need a literal number. - Beta context. WorkspaceKit is public beta (0.2.6, GPL-3.0-only), and its README tells you to back up workflows and settings before leaning on it in a production install. The arithmetic nodes are the safe part of it.
Inputs (4)
| Name | Type | Default | Description |
|---|---|---|---|
| aspect_ratio | COMBO | ▭ 16:9 | 11 options: ▯ 4:5, ▯ 3:4, ▯ 2:3, ▯ 9:16, ■ 1:1, ▭ 5:4, +5 |
| megapixels | FLOAT | 1.00.1–16 | — |
| multiple | INT | 88–128 | — |
| scale | COMBO | 1.0 | 9 options: 0.5, 1.0, 1.5, 2.0, 2.5, 3.0, +3 |
Outputs (5)
| Name | Type | Description |
|---|---|---|
| width | INT | — |
| height | INT | — |
| scale_width | INT | — |
| scale_height | INT | — |
| resolution | STRING | — |