GPT Image 2.5 pixel art sprite sheet: prompt a grid, slice it

Ask GPT Image 2.5 for a 4x2 sprite sheet at 2048x1024 on Sume, then slice frames and snap to a true pixel grid with Pillow. Prompt and code included.

5 min readSume
All posts

To make a pixel art sprite sheet with GPT Image 2.5, request one wide image laid out as a grid (for example 4 columns by 2 rows at 2048x1024), describe the same character in a repeated pose sequence, then slice the sheet into frames in your own code. Do not expect the model to output a true pixel grid: it paints pixel-art looking shapes, and snapping them to real pixels is a step you do afterwards with nearest-neighbour resizing.

This post gives a prompt, the request that fits Sume's size rules, and a short Pillow script. Size and parameter facts are from the Image API docs, read 2026-10-03.

What size should I request?

Sume's custom image_size for GPT Image 2.5 needs both edges to be multiples of 16, a maximum edge of 3840, an aspect ratio of at most 3:1, and between 655,360 and 8,294,400 pixels. A 2048x1024 sheet is 2:1 and 2,097,152 pixels, so it passes; it splits into eight 512x512 cells. The same layout at 1080 tall would fail, because 1080 is not a multiple of 16.

Higher sizes and quality push a request toward the 30-second sync limit. If you get a 202 instead of images, poll the job as described in the jobs docs.

Sheet layouts that satisfy Sume's custom-size rules, read 2026-10-03.
Gridimage_sizeCell sizeWhy it fits
4x22048x1024512x5122:1, 2,097,152 px, multiples of 16
4x42048x2048512x5121:1, 4,194,304 px
3x21536x1024512x5123:2, 1,572,864 px
8x1Not allowed-8:1 is above the 3:1 limit

What prompt gives a usable sheet?

Say the layout first, then the subject, then the constraints. Name the cell count, the background colour, and that every cell holds the same character at the same scale. Ask for a flat single-colour background so slicing and later background removal are easy.

Example: "A pixel art sprite sheet, 4 columns by 2 rows, 8 equal cells. A small knight with a blue cape walking right, one walk-cycle frame per cell, same size and position in each cell, flat light green background, hard pixel edges, limited 16-colour palette, no text, no grid lines." Test it at quality: "low" first; Sume's default for an omitted quality is high.

How do I slice and snap to real pixels?

Download the PNG from data[].url, cut it into the grid, then shrink each frame with nearest-neighbour to your game's pixel size (here 64x64) and enlarge it back for review. The result has real hard-edged pixels even if the model's were slightly soft. Needs pip install pillow.

from PIL import Image

COLS, ROWS, PIXEL = 4, 2, 64
sheet = Image.open("sheet.png").convert("RGBA")
cw, ch = sheet.width // COLS, sheet.height // ROWS

frames = []
for r in range(ROWS):
    for c in range(COLS):
        cell = sheet.crop((c * cw, r * ch, (c + 1) * cw, (r + 1) * ch))
        frames.append(cell.resize((PIXEL, PIXEL), Image.NEAREST))

strip = Image.new("RGBA", (PIXEL * len(frames), PIXEL))
for i, f in enumerate(frames):
    strip.paste(f, (i * PIXEL, 0))
strip.save("walk-strip.png")
strip.resize((strip.width * 4, strip.height * 4), Image.NEAREST).save("preview.png")

What can go wrong?

Expect to fix some of these by hand or by a masked edit.

  • Cells that do not sit on exact boundaries. Crop with a few pixels of margin, or ask for a gutter of background colour between cells.
  • The character drifting between frames. Generate the first frame, then use it as input_references for the others instead of asking for all eight at once.
  • A transparent background. Sume lists background: transparent for GPT Image 2.5, but for a sheet a flat key colour is easier to slice and to check.
  • Too many colours. Quantise in your own code, for example with Pillow's quantize, after slicing.

Does Sume animate the result?

Sume's docs describe no sprite-animation tool; the sheet is an image you assemble yourself. The frame-by-frame consistency trick is the same as in any multi-image job: keep one approved frame as the anchor, and keep the preserve list identical across calls.

How do I turn this into a game asset?

Export the strip at your game's native frame size, drop it into your engine as a sprite sheet and set the frame width to 64. Keep a nearest-neighbour filter on in the engine, or the hard pixels will blur when scaled. If the background must be transparent, remove the flat key colour in your own code with a tolerance and check the edges for a halo.

Keep the prompt, the sheet and the slicing script together. To add an attack animation later, reuse the approved walk frame as an input_references anchor so the knight stays the same character.

Sources

Related posts

More in Use cases

All Use cases posts

Written by Sume