ImageTransformRotate
Rotate without the jaggies — supersampled, with honest transparent corners
- images
- IMAGE
Rotating an image is where a lot of batch pipelines quietly get ugly. A naive rotate leaves stair-step edges, and if the canvas grows to fit the rotated rectangle you get hard black corners to cut out later. ImageTransformRotate is Allor's answer to both: it supersamples before rotating, resamples on the way down, and fills any exposed corners with transparent alpha instead of black.
How it works
Each frame tensor is converted to a PIL image, rotated, and converted back, then the batch is re-stacked. The interesting part is the SSAA path. With SSAA above 1, the frame is upscaled by that factor, rotated, then downscaled back - supersample anti-aliasing. At the default of 4, the rotation effectively happens at 4x resolution, so interpolated edges land where they belong instead of stair-stepping.
Set expand to "true" and the canvas grows so the whole rotated rectangle fits, with the exposed areas filled with fully transparent RGBA (0,0,0,0). The result composites cleanly over anything later in the graph - no black L-shapes to mask.
Two details worth knowing before you wire it in:
angleof exactly 0.0 or 360.0 short-circuits to a pass-through; your original batch comes back untouched.- Rotating through an angle that isn't a right angle is an interpolation, which means pixels are resampled - detail is reconstructed, not preserved. For exact 90° / 180° / 270° turns, use the sibling ImageTransformTranspose instead. It's lossless, and it's faster.
The inputs that matter
images- the IMAGE batch to rotate (required)angle- FLOAT, default 35.0, max 360.0, step 0.1expand-"true"keeps the full rotated canvas with transparent corners;"false"crops to the original boundsSSAA- INT, default 4, range 1–16; the supersampling factormethod- resampling:lanczos,bicubic,hamming,bilinear,box,nearest
The output is IMAGE, same number of frames. If you rotated with expand on, frames come out larger than they went in - plan your downstream resolution accordingly.
When you'd reach for it
Straightening a tilted scan or photo, rotating every frame of an animation identically, or pre-rotating before a composite. SSAA=4 is a fine default; drop it to 1 when you're churning through hundreds of frames and want speed. Keep expand=true whenever the rotated content overhangs the original frame and you'll composite the result, because the transparent corners let you just place it.
Installing Allor
ImageTransformRotate ships in the Allor Plugin, Nourepide's ~90-node image-processing pack. Install via ComfyUI Manager (search "Allor") or:
cd ComfyUI/custom_nodes
git clone https://github.com/Nourepide/ComfyUI-Allor
Restart ComfyUI. First run creates a config.json in the pack folder; the bundled install.sh / install.bat can install requirements into your venv or embedded Python. The pack pulls rembg and onnx (plus onnxruntime via rembg) for its segmentation nodes - heavier than a rotate needs, but a one-time cost.
Common issues
Updates are the known weak spot. The repo was rebased to strip image history, which the README says can break auto-updates, and users have reported Allor nodes disappearing after one. A fresh re-clone fixes it; "update_frequency": "never" in config.json prevents it.
Inputs (5)
| Name | Type | Default | Description |
|---|---|---|---|
| images | IMAGE | — | |
| angle | FLOAT | 35.0 | — |
| expand | COMBO | 2 options: true, false | |
| SSAA | INT | 41–16 | — |
| method | COMBO | 6 options: lanczos, bicubic, hamming, bilinear, box, nearest |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| IMAGE | IMAGE | — |