Nodes/Banana Gemini Image Generator/心宝❤图片拆分
ComfyUI Node

心宝❤图片拆分

One image, four or nine tiles, zero thought required

By 98624017·Created 9 months ago·Updated 4 months ago· 2
心宝❤图片拆分
  • image
  • IMAGE
split_mode四方格 (2x2)

Some nodes exist to do the boring thing so you don't have to think about it. This is one of them: it takes an image and cuts it into a 2×2 or 3×3 grid of tiles. That's the entire feature list, and honestly it's the right feature list.

Why does this ship in an e-commerce pack? Because a common trick in product-listing image work is to generate one large composed image and then split it into the individual screens a marketplace expects - or the reverse, to break a reference design into tiles for closer inspection. The pack's detail-page workflows generate multi-screen canvases, and something has to turn "one big canvas" into "four or nine individual images." This node is that something.

The inputs and output

  • image (IMAGE) - the canvas to split.
  • split_mode - a dropdown with exactly two choices: 四方格 (2x2) (four tiles) and 九宫格 (3x3) (nine tiles). No other controls, no overlap settings, no arbitrary grid dimensions. It's deliberately rigid.

The single output is IMAGE. Since the node's is_list is false, you get the tiles back as a batch tensor - ComfyUI treats them as one image batch, which is exactly what you want if the next node processes the batch (saving each tile, feeding them to a save node that names per-index, or iterating). If you need them as separate wires, put a batch-split node after it.

When it's the right tool

If you need a grid of nine different aspect-ratio crops, or tiles with overlap for upscaling workflows, this isn't the node - that's a crop/overlap problem and there are dedicated tools. But if you have a canvas and you just need it quartered or ninths-divided, this is a one-click version of what would otherwise be a small pile of crop nodes with hand-typed coordinates. It's the kind of plumbing the KB's node-plumbing doc describes - a value node that fights repetition and illegibility - and it wins by being small.

A subtle thing worth knowing: 2×2 tiles of a non-square image are all the same shape but different content; 3×3 of a 9:16 canvas gives nine narrow portrait tiles. If the marketplace you're feeding expects specific per-tile ratios, check the source canvas's ratio before you split, not after.

Installing

It's part of comfyui-banana-li-linux:

cd ComfyUI/custom_nodes
git clone https://github.com/98624017/comfyui-banana-li-linux

Restart ComfyUI. The split uses Pillow/opencv-contrib-python from the pack's requirements - nothing extra to install, nothing to download. Run it, and the tiles come out the other side.

CategoryXinbao/Image

Inputs (2)

NameTypeDefaultDescription
imageIMAGE
split_modeCOMBO四方格 (2x2)2 options: 四方格 (2x2), 九宫格 (3x3)

Outputs (1)

NameTypeDescription
IMAGEIMAGE