Universal Seamless Tiles
Model-agnostic seamless / tileable image generation for ComfyUI — works on transformer/DiT models (Flux, Wan/Anima) as well as convolutional models (SD1.5, SDXL).
Universal Seamless Tiles
Model-agnostic seamless / tileable image generation for ComfyUI.
The classic seamless-tiling trick (switching every Conv2d to circular padding) only works on
convolutional U-Nets like SD1.5 and SDXL. Modern transformer / DiT models — Flux, Wan / Anima,
and similar — patchify with a Linear or a non-overlapping Conv, so that trick has nothing to grab
and produces no tiling at all.
This pack takes a different, architecture-independent approach that works across SD1.5, SDXL, Flux, and Wan/Anima:
- Latent rolling during sampling makes the denoiser treat the canvas as periodic, so no fixed seam can form.
- Circular VAE decode removes the pixel-level seam at the true edges, for both 2D (SD/Flux) and 3D (Wan) autoencoders.
Neither node mutates ComfyUI's shared/cached model — they clone/copy first, so tiling can never "leak" into your other generations.
Nodes
Seamless Tile Model (DiT) — MODEL → MODEL
Installs a UNet function wrapper that rolls the latent by a per-step offset (and un-rolls the result), so the model can never lock onto a fixed edge. The roll magnitude is tapered with the noise level: large structural rolls early, near-zero rolls on the final detail steps — this keeps the tiling artifact on the true edge (where the circular VAE handles it) instead of leaving a faint line inside the image.
| Input | Meaning |
|-------|---------|
| model | Any diffusion model (SD/SDXL/Flux/Wan/…). |
| tiling | enable (both axes), x_only, y_only, disable. |
| seed | Makes the per-step offsets reproducible. |
Make Circular VAE (DiT) — VAE → VAE
Applies circular padding to the VAE decoder so the decoded edges wrap. Handles both Conv2d
(SD/Flux AutoencoderKL) and Conv3d / CausalConv3d (Wan VAE), preserving Wan's causal temporal
padding and single-frame fast path. Feed the result into a normal VAE Decode.
| Input | Meaning |
|-------|---------|
| vae | The VAE to make tileable. |
| tiling | enable, x_only, y_only, disable. |
| copy_vae | Make a copy (recommended) or Modify in place. |
Usage
Load Checkpoint ─▶ Seamless Tile Model (DiT) ─▶ KSampler ─▶ VAE Decode ─▶ (image)
▲
VAE ─▶ Make Circular VAE (DiT) ───────┘
Set both nodes to the same tiling mode. To verify the result tiles, offset the output by 50% in x/y
(e.g. an image-offset node) and check that no seam appears.
Notes & limitations
- Latent rolling is very good but not conv-perfect. Quality scales with step count because the method averages across steps. On turbo / few-step models, use more steps (e.g. 15–20) for tighter seams, or expect a slightly softer result.
- Rolling does not roll ControlNet hints or other spatial
transformer_optionsdata, so ControlNet/inpaint spatial alignment with tiling is out of scope for now. - For single-image use of video models (Wan/Anima), only the spatial (H/W) axes are rolled.
Compatibility
- ComfyUI (recent builds with
set_model_unet_function_wrapper). - Tested against SDXL, Flux, and Wan/Anima model + VAE code paths.
License
MIT — see LICENSE.