Studio Yotsuba
Back to Node List

Region Pattern Assign

region_pattern_assign

Gives every region its own palette color or texture - per-stone tinting and per-face texturing in one step

Reviewed
Guide available

Input Ports

NameTypeDescription
Regions
regions
RegionMap
Required
RegionMap used for assignment
Palette
palette
Palette
Optional palette for palette modes
Pattern
pattern
Image
Optional pattern image for texture modes

Output Ports

NameTypeDescription
Image
output
Image
Pattern assigned image
Labels
labels
Map
UI overlay label positions for the inspector

Parameters

NameTypeDefaultRangeDescription / Options
Mode
mode
Enum
PaletteById—

How patterns are assigned

  • PaletteByIdPaletteById
    Assign palette colors by region id
  • PaletteRandomPaletteRandom
    Assign stable random palette colors per region
  • PatternTiledPatternTiled
    Tile the pattern image through all regions
  • PatternPerRegionPatternPerRegion
    Tile the pattern with a stable offset per region
  • AreaShadeAreaShade
    Shade between two colors by region area
Color A
color_a
Color
[0.18000000715255737,0.2199999988079071,0.2800000011920929,1]—

Low area color used by AreaShade

Color B
color_b
Color
[0.7200000286102295,0.7799999713897705,0.6399999856948853,1]—

High area color used by AreaShade

Tile Scale
tile_scale
Int
11–64

Pattern image pixel scale

Seed
seed
Int
10–99999

Random seed

Show IDs
show_ids
Bool
false—

Show region id labels on the inspector preview

Overview

An advanced counterpart to region_fill that assigns palette colors or pattern images to each RegionMap region and renders an image. It automatically creates texture variation such as a slightly different stone pattern in every region.

It assigns palette colors or pattern images to individual regions, supporting region-based coloring for ground, rock, ore, and grime.

Usage tips

  • Per-region pattern mode is the definitive cobblestone treatment: with a stone texture, each stone shows a different part of the same pattern, removing the copied look.
  • Random palette assignment works well with palette workflows. Connect a four-color earth palette to create color variation by region.
  • A practical workflow is to inspect the composition first with region_fill, then replace it with this node for finishing.

Related nodes

  • region_fill — simple color version for initial review
  • palette_create / common_palette_ref — color sources
  • noise_generate — pattern-image source
  • region_border — combines with mortar lines

Key parameters

ID Contents
mode Palette by ID, random palette, pattern tile, per-region pattern, or area-based lightness
color_a / color_b Two colors used for area-based lightness
tile_scale Pixel scale at which the pattern image is sampled
seed Seed for random assignment or per-region pattern offsets
show_ids Display ID labels in the Inspector preview

Pattern Tile repeats the input image unchanged across the full canvas. Per-region Pattern offsets the sampling position for each region, giving every region a slightly different appearance from the same image.

How to use

Region Fill provides simple color separation; this node renders regions while varying how palette colors or patterns are assigned. Use it for terrain surfaces, individual rock faces, ore, and grime.

The output is a regular Image. If downstream processing still needs region IDs, branch the upstream RegionMap along a separate route.

Without a connected palette, the preview uses temporary colors by region ID. To lock production colors, connect palette and select Palette by ID or Random Palette.

Back to Node List