Nodes/ComfyUI_KimNodes/🍒Seamless_Tiling_Generator / 无缝四方连续拼图
ComfyUI Node

🍒Seamless_Tiling_Generator / 无缝四方连续拼图

Not 'make my texture seamless' — this arranges a list of images into a repeating pattern

By wjl0313·Created 2 years ago·Updated 12 months ago· 54
🍒Seamless_Tiling_Generator / 无缝四方连续拼图
  • image_list
  • image
  • mask
  • output_json
tiling_template经典四方连续
output_width1024
output_height1024
base_image_size84
edge_image_size168
fill_center_areatrue
random_seed0
enable_randomtrue
background_color#FFFFFF

First, kill the expectation: despite the name, this is not the node that takes one texture and makes it tile seamlessly (there's a recurring reddit thread of people installing "seamless tiling" nodes expecting exactly that and getting confused). Seamless_Tiling_Generator is the opposite direction - it takes a list of images and assembles them into a seamless, four-direction repeat layout, the kind of patterned collage you'd use for icons, textures, or 四方连续 (four-direction continuous) decorative design.

Think of it as the "compose the pattern" step. You feed it a pile of cut-out elements (the pack's Split_Mask and Transparent_Area_Cropper are its natural upstreams) and it lays them out so that when you tile the result, the pattern repeats without visible seams - because the corners and edges are built from images split into quarters and halves that wrap around.

The mechanism. The layout is template-driven, and the classic one is worth understanding because all the others are variations on it: the four corners are the four quarters of a single image (so the corners match when tiled), the top and bottom edges are halves of another image, the left and right edges are halves of a third, and the center is filled with images pulled from your list. Which template you pick changes how those edges and corners are arranged. The other five options are: enhanced classic, quadrant-edge, random-offset (as the name says, tiles get shifted randomly), multi-edge, and quad-edge.

Inputs that matter. Ten inputs sounds like a lot; you'll touch maybe four.

  • image_list - your source images, as a list.
  • tiling_template - the six-choice enum above. Default is classic.
  • output_width / output_height - canvas size, default 1024×1024, step 32.
  • base_image_size - controls the corner size (the center images render at 4× this, so keep it small). Default 84.
  • edge_image_size - controls the four edge images, default 168.
  • fill_center_area - whether the middle gets filled from your list at all (turn off if you just want a frame).
  • random_seed + enable_random - whether placement shuffles.
  • background_color - hex string, default #FFFFFF.

Outputs. Three, and they're meant to be used together: image (the assembled canvas), mask (the placement mask), and output_json - a JSON string that records each placed tile's bounding box and base64 crop, which is how the pack's own Crop_Paste/JSON compositors can reconstruct or repaste elements later. If you're not doing programmatic compositing, the JSON is ignorable.

Why you'd bother. Icon sheets and game-asset patterns are the headline use - KimNodes is very much an icon/asset-processing pack. But the same template system handles decorative wallpaper-style repeats, and being able to drop random-seed variation on placement (enable_random + seed) means you can batch out a dozen pattern variations and pick one.

Install. Part of KimNodes (wjl0313's 🍒 toolbox on the Comfy registry). ComfyUI Manager → search "ComfyUI_KimNodes", or:

cd ComfyUI/custom_nodes
git clone https://github.com/wjl0313/ComfyUI_KimNodes

then restart. The node uses only PIL/numpy/torch - no downloads, no models.

Gotchas. You need at least one input image, and the center fill will happily reuse images from your list multiple times, so a two-image list still works - you just get repetition. base_image_size and edge_image_size are independent; if your edges render blurry, they're probably being upscaled from a small source. And remember the masking caveat: the mask output describes where tiles were placed, not an alpha cutout of the art.

Category🍒 Kim-Nodes/🧩Icon Processing | 图标处理

Inputs (10)

NameTypeDefaultDescription
image_listIMAGE
tiling_templateCOMBO经典四方连续6 options: 经典四方连续, 增强经典拼图, 象限边缘拼图, 随机偏移拼图, 多边界拼图, 四边界拼图
output_widthINT1024256–4096
output_heightINT1024256–4096
base_image_sizeINT8432–512
edge_image_sizeINT16832–512
fill_center_areaBOOLEANtrue
random_seedINT00–4294967295
enable_randomBOOLEANtrue
background_colorSTRING#FFFFFF

Outputs (3)

NameTypeDescription
imageIMAGE
maskMASK
output_jsonSTRING