Studio Yotsuba
Back to Node List

Pixel Scale

pixel_scale

Scale image by integer factor (enlarge or reduce). Enlarging can use Scale2x or Eagle edge smoothing

Reviewed
Guide available

Input Ports

NameTypeDescription
Image
input
Image
Required
Input image

Output Ports

NameTypeDescription
Image
output
Image
Scaled image

Parameters

NameTypeDefaultRangeDescription / Options
Mode
mode
Enum
Enlarge—

Enlarge (×N) or Reduce (÷N)

  • EnlargeEnlarge
    Scale up by integer factor (×N)
  • ReduceReduce
    Scale down by integer factor (÷N)
Scale
scale
Int
21–16

Integer scale factor (1x, 2x, 3x...)

Algorithm
sampling
Enum
Nearest—

Enlarging algorithm. Factors not covered by the smoothing steps fall back to Nearest

  • NearestNearest
    Duplicate each pixel — keeps the art exactly as drawn
  • Scale2xScale2x
    Smooths staircase edges while enlarging (AdvMAME2x/3x). Best for 2x, 3x, 4x, 6x...
  • EagleEagle
    Stronger corner rounding than Scale2x. Best for 2x, 4x, 8x...

Overview

Scales pixel art up or down by an integer factor without blurring. Its main uses are 2×/3× game-engine export and enlarged previews. Scale2x and Eagle can also create retro-game-style outline smoothing during enlargement.

Usage tips

  • For normal enlargement, keep the default Nearest, which preserves pixel shapes exactly.
  • Scale2x / Eagle come from retro emulators and smooth low-resolution pixel outlines. Use them as a stylistic change; factors around 2, 3, or 4 behave naturally.
  • If only export dimensions should increase, place this node at the end of the graph, immediately before export. Placing it earlier multiplies downstream processing cost by the square of the factor.
  • For non-integer or freely chosen dimensions, use content_resize / canvas_resize instead. Non-integer pixel-art scaling tends to blur and is best avoided.

Common pitfalls

  • Pixels disappear when reducing: Reduce simply samples every Nth pixel, so 1px lines and dots can vanish. Preserving every detail while shrinking is impossible; redraw at the target size or simplify elements.
  • Smoothing has no effect: solid areas remain the same in every method; only stair-step outlines change. For factors not divisible by 2 or 3, such as 5 or 7, the remaining factor uses Nearest.
  • Enlargement looks blurry: this node cannot blur because it uses integer scaling and nearest-neighbor sampling. Check filtering in the browser or game engine.

Enlargement methods

Method Description
Nearest Duplicate each pixel unchanged, preserving pixel shapes exactly
Scale2x AdvMAME2x/3x fills corners on stair-step outlines; supports factors such as 2, 3, 4, and 6
Eagle Rounds corners more strongly than Scale2x; supports factors such as 2, 4, and 8
  • Smoothing methods decompose the factor into 2× and 3× stages, for example 6× = Scale3x + Scale2x.
  • Any factor not divisible by 2 or 3, such as 5× or 7×, is completed with Nearest enlargement.
  • Solid-color areas do not change with any method. Only stair-step outlines are affected.

Technical details

  • Interpolation: nearest-neighbor, or Scale2x / Eagle
  • Enlarge: output dimensions = input_width × scale × input_height × scale
  • Reduce: output dimensions = input_width ÷ scale × input_height ÷ scale, sampling every Nth pixel
  • scale=1: pass the source through unchanged, with no copy and high performance
  • Reduction is clamped to a minimum of 1px when a dimension would fall below 1

Examples

2× enlargement for a game engine

Scale 32×32 pixel art with mode: Enlarge, scale: 2 → a pixel-perfect 64×64 image.

Thumbnail reduction

Scale a 64×64 image with mode: Reduce, scale: 2 → a 32×32 downsample.

3× enlargement for preview

Scale a 16×16 icon with mode: Enlarge, scale: 3 → a crisp 48×48 preview.

Difference from Transform

Item PixelScale Transform
Purpose Scaling only (enlarge/reduce) General translation, scaling, rotation, and flipping
Parameters mode + scale only offset_x/y, scale, rotation, flip_h/v
Use Export, preview, and thumbnails Image transformation within the graph

Related nodes

  • content_resize / canvas_resize — non-integer resizing or canvas expansion
  • transform — general translation, rotation, and flipping
  • pixel_rotate — rotation for pixel art
  • surface_export — also provides integer scaling during export
Back to Node List