Nodes/MKRShift_Nodes/Texture Cell Pattern
ComfyUI Node

Texture Cell Pattern

Texture Cell Pattern is the voronoi you don't have to build

By criskb·Created 7 months ago·Updated 5 months ago· 0
Texture Cell Pattern
    • image
    • mask
    • cell_pattern_info
    settings_json{"width":1024,"height":1024,"pattern_mode":"fill","cell_scale_px":96.0,"jitter":0.85,"edge_width":0.18,"softness":0.0,"contrast":1.2,"balance":0.0,"invert":false,"seed":31}

    Scales, cracked mud, reptile skin, shingled roofs, armor plates - a huge slice of nature and tech is just "cells." Making convincing cells used to mean building a voronoi in a texture tool or downloading a tileable pack and hoping it didn't repeat visibly. x1TextureCellPattern generates a cell pattern procedurally in any resolution, tileable by construction, with enough control to go from clean hexagons to wobbly lizard scales. It takes no image input - one settings blob in, a texture out.

    How it works

    It's a procedural cell field: seeds are scattered across the canvas, and each pixel belongs to its nearest seed, forming the classic voronoi cell walls. cell_scale_px (96px) sets the cell size, and jitter (0.85) is the whole personality of the node - it's how much the seeds are scattered from a perfect grid. Low jitter gives you regular, honeycomb-ish cells (good for sci-fi paneling or tiles); high jitter gives the irregular, organic cell boundaries you want for scales and cracked mud.

    pattern_mode extends it beyond plain cells. The valid modes are fill (solid cells), edge (just the cell walls as lines), cracks (wall-based crack lines), distance (distance-to-seed as a gradient, which reads as a soft bumpy field), and bevel (cells with a beveled edge - the armor-plate look). edge_width (0.18) sets how thick the walls are, softness (0.0) blurs them, and contrast/balance shape the response. seed rerolls the whole arrangement for variation.

    The inputs that matter

    Everything lives in a settings_json string, prefilled:

    • width / height (1024) - output resolution.
    • pattern_mode - fill, edge, cracks, distance, or bevel.
    • cell_scale_px (96) - how big the cells are.
    • jitter (0.85) - grid-vs-organic. The character knob.
    • edge_width (0.18) - wall thickness.
    • seed (31) - reroll the cell layout.
    • invert - flip the pattern.

    Outputs are image, mask, and cell_pattern_info (mode, scale, seed).

    Installing it

    Part of the MKRShift Nodes pack. ComfyUI Manager: search "MKRShift", install, restart. Or:

    cd ComfyUI/custom_nodes
    git clone https://github.com/criskb/MKRShift_Nodes
    

    Restart after. No models - instant procedural math.

    Gotchas

    For organic materials, resist the urge to drop jitter all the way down - perfect cells are the fastest way to a "generated texture" read. And the mask output matters more than you'd think: it's the same pattern as a MASK, which means you can wire it into a bump or roughness map and get the cell relief without ever generating a separate height field. The node's edge mode is genuinely good as a tileable line-art overlay too. Just remember the same settings_json rule as every MKRShift node: broken JSON silently resets to defaults, so reroll a boring result with seed, not by breaking the string.

    CategoryMKRShift Nodes/Surface/Texture

    Inputs (1)

    NameTypeDefaultDescription
    settings_jsonSTRING{"width":1024,"height":1024,"pattern_mode":"fill","cell_scale_px":96.0,"jitter":0.85,"edge_width":0.18,"softness":0.0,"contrast":1.2,"balance":0.0,"invert":false,"seed":31}

    Outputs (3)

    NameTypeDescription
    imageIMAGE
    maskMASK
    cell_pattern_infoSTRING