Symbiotica Reconstruct Cells
Edited sprites back onto the packed sheet
- cells
- masks
- sheet
Slice Cells cuts a generated sheet into one image per asset. Reconstruct Cells is the inverse: edited cells go back onto the grid they were cut from, on the same cell_boxes, so a sheet survives a per-asset edit intact. If your style LoRA was trained on packed sheets, and your pipeline edits each asset on its own, you need the sheet rebuilt at the same size and the same padding the split came from - that's this node.
How it works
You feed it the finished cells (in the order Slice Cells returned them) and the same cell_boxes that cut them - the JSON from Dataset Reference. The node lays each cell back at its box on a canvas and fills the gutters and any empty cell with a background color. The canvas size can be given explicitly or recovered from the boxes themselves, since the grid is centred: the margin after the last cell equals the one before the first.
The subtle part is transparency. A loader like ComfyUI's Load Image flattens alpha before a node sees it, so without a masks input a transparent sprite lands on a black rectangle instead of the background. Wire the masks in and mask_is_transparency decides the convention: ON for ComfyUI's Load Image (mask is 1 where the picture is see-through), OFF for a straight alpha channel (1 is the art).
The inputs that matter
cells(required) - the finished sprites, in Slice Cells' order.cell_boxes(required) - the samecell_boxesthat cut them. The sheet is rebuilt on exactly those boxes.background- the gutters and empty cells, default#808080. Match the packed sheets and the result is indistinguishable from one.canvas_size- sheet size, or 0 to recover it from the boxes.padding_color- what sits outside the cells: the gutters and border. The packer floods the sheet with this then punches each cell back to the background, which is what draws the black outline around every cell. Set it to the background colour for no outline.masks(optional) - transparency for the cells, for the reason above.
The output
sheet- one image, laid out like the packed one the cells came from. Wire it where the packed sheet would have gone - a compare node, a save, a final delivery step.
Install
Standard pack install:
cd ComfyUI/custom_nodes
git clone https://github.com/symbiotica-ai/comfyui-nodes.git symbiotica
pip install -r symbiotica/requirements.txt
Restart, or search Symbiotica in ComfyUI Manager. No keys, no models - this is pure image plumbing.
Gotchas
The most common mistake is skipping the masks wire and wondering why everything transparent is black. Loaders flatten alpha; the mask input is not optional polish, it's the mechanism. Second: don't invent your own boxes. The whole contract is that Reconstruct uses the same cell_boxes that cut the cells - wire it from the same Dataset Reference node, don't re-type it. And if a cell is missing (a slot with no sprite), it fills with the background rather than erroring, which is usually what you want for a WIP sheet but is easy to miss on a final delivery. Check the gutters before you ship.
Inputs (7)
| Name | Type | Default | Description |
|---|---|---|---|
| cells | IMAGE | The finished sprites, in the order Slice Cells returned them. | |
| cell_boxes | STRING | The same `cell_boxes` that cut them — from Dataset Reference. The sheet is rebuilt on exactly those boxes. | |
| background | STRING | #808080 | What the gutters and any cell with no sprite are filled with. Match the packed sheets and the result is indistinguishable from one. |
| canvas_size | INT | 00–8192 | Sheet size, or 0 to recover it from the boxes — the grid is centred, so the margin after the last cell equals the one before the first. |
| mask_is_transparency | BOOLEAN | true | ON for ComfyUI's Load Image, whose mask is 1 where the picture is see-through. OFF for a straight alpha channel, where 1 is the art. |
| padding_color | STRING | #000000 | What sits OUTSIDE the cells — the gutters and the border. The packer floods the sheet with this and then punches each cell back to the background above, which is what draws the black outline around every cell. Set it to the same colour as the background for no outline at all. |
| masksopt | MASK | Transparency for the cells. A loader flattens alpha before this node sees it, so without the mask a transparent sprite lands on a black rectangle instead of the background. |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| sheet | IMAGE | One sheet, laid out like the packed one the cells came from. |