Pixel Art Sprite Sheet and JSON Atlas Generator for Phaser 3
Zero post-processing cleanup between generation and engine playback
Direct load.atlas and load.animation compatibility
Celgrid writes both atlas.json and phaser-animations.json using matching texture keys and zero-padded frame names (idle_000, idle_001...), eliminating hand-coded frame index errors.
Zero WebGL pixel bleeding with extrude and padding controls
Set padding and extrude (0 to 8 px) in Celgrid's sheet settings before export so WebGL texture sampling never picks up transparent seams or neighbor-frame edges during camera pan.
Tiny lossless PNG payloads for fast web game loading
Exact 16x16 and 24x24 indexed pixel atlases compress to a few kilobytes without WebP/JPEG artifacts, ideal for instant-play HTML5 and itch.io Phaser games.
Automated REST API asset pipeline for TypeScript projects
Pull sprites directly into public/assets/ during build or prototyping with GET /v1/pixel-assets/{id}/pack.zip or Celgrid's MCP server inside Cursor and Claude Code.
Exact Phaser 3 files generated from Emerald Moss Slime (16x16, 4 frames)
These snippets are produced directly by Celgrid's live exporter (sheet_export.py) — never hand-faked placeholder code.
import Phaser from "phaser";
class MeadowScene extends Phaser.Scene {
preload() {
this.load.atlas("sprite-c7e070843d90", "assets/slime/sprite.png", "assets/slime/atlas.json");
this.load.animation("sprite-c7e070843d90-clips", "assets/slime/phaser-animations.json");
}
create() {
const slime = this.add.sprite(160, 120, "sprite-c7e070843d90");
slime.setOrigin(0.5, 1.0); // Match Celgrid bottom-center pixel anchor
slime.setScale(4); // Crisp 4x integer scale
slime.play("sprite-c7e070843d90-idle");
}
}
new Phaser.Game({
type: Phaser.AUTO,
width: 640,
height: 360,
pixelArt: true,
roundPixels: true,
backgroundColor: "#11201a",
scene: [MeadowScene],
});
{
"anims": [
{
"key": "sprite-c7e070843d90-idle",
"type": "frame",
"frameRate": 8.0,
"repeat": -1,
"frames": [
{
"key": "sprite-c7e070843d90",
"frame": "idle_000"
},
{
"key": "sprite-c7e070843d90",
"frame": "idle_001"
},
{
"key": "sprite-c7e070843d90",
"frame": "idle_002"
},
{
"key": "sprite-c7e070843d90",
"frame": "idle_003"
}
]
}
]
}{
"frames": [
{
"filename": "idle_000",
"frame": {
"x": 0,
"y": 0,
"w": 16,
"h": 16
},
"rotated": false,
"trimmed": false,
"spriteSourceSize": {
"x": 0,
"y": 0,
"w": 16,
"h": 16
},
"sourceSize": {
"w": 16,
"h": 16
},
"duration": 125,
"pivot": {
"x": 0.5,
"y": 0.9375
}
},
{
"filename": "idle_001",
"frame": {
"x": 16,
"y": 0,
"w": 16,
"h": 16
},
"rotated": false,
"trimmed": false,
"spriteSourceSize": {
"x": 0,
"y": 0,
"w": 16,
"h": 16
},
"sourceSize": {
"w": 16,
"h": 16
},
"duration": 125,
"pivot": {
"x": 0.5,
"y": 0.9375
}
}
],
"meta": {
"image": "sprite.png",
"format": "RGBA8888",
"size": {
"w": 64,
"h": 16
},
"scale": "1",
"frameTags": [
{
"name": "idle",
"from": 0,
"to": 3,
"direction": "forward"
}
]
}
}How to import Celgrid pixel art into Phaser 3 in four steps
Enable pixelArt and roundPixels in Phaser.Game config
Set pixelArt: true and roundPixels: true in your Phaser 3 config so WebGL and Canvas renderers lock nearest-neighbor sampling and snap sprite transforms to whole screen pixels.
Extract sprite.png, atlas.json, and phaser-animations.json
Download pack.zip from Celgrid Studio or GET /v1/pixel-assets/{id}/pack.zip and place the three files inside your public/assets/sprites/ folder.
Load the atlas and animation manifest in Scene.preload()
Call this.load.atlas(...) and this.load.animation(...) using the texture key recorded in IMPORT.txt.
Spawn and play the animation at crisp integer scale
Instantiate the sprite with setScale(3) or setScale(4) and call sprite.play(clipKey) — every pixel stays square and razor sharp.
Preventing texture bleeding, shimmer, and blur in HTML5 browsers
| Phaser 3 / Sheet Setting | Effect on WebGL & Canvas Rendering |
|---|---|
render.pixelArt: true | Switches Phaser WebGL texture min/mag filters to GL_NEAREST and disables browser canvas imageSmoothingEnabled automatically. |
render.roundPixels: true | Snaps sprite and camera transforms to integer screen pixels so 16x16 tiles and characters never shimmer during smooth scrolling. |
padding: 1 and extrude: 1 | Duplicates outer border pixels around every atlas rectangle so WebGL UV interpolation never bleeds adjacent frames on non-integer zoom. |
Scale.FIT + integer zoom | Keeps browser viewport upscaling crisp across 1x, 2x, and 4x HiDPI monitors without introducing uneven mixel rows. |
Lossless RGBA PNG (< 4 KB) | Native 16x16 and 24x24 spritesheets stay tiny for itch.io, Poki, and instant-play HTML5 bundles without JPEG or lossy WebP color halos. |
Phaser 3 Pixel Art FAQ
Does Celgrid export Phaser 3 JSON atlas and animation files directly?
Yes. Every pack.zip contains sprite.png, atlas.json (standard TexturePacker/Aseprite JSON array format), and phaser-animations.json formatted directly for Phaser's this.load.animation loader.
Why do sprites shimmer when moving in Phaser 3?
Sub-pixel camera coordinates or linear filtering cause shimmering. Set pixelArt: true and roundPixels: true in your Phaser.Game config, and export sheets with padding: 1 and extrude: 1 when using trimmed frames.
How big are Celgrid spritesheets for HTML5 web games?
Because Celgrid outputs exact native-resolution RGBA PNGs (16x16 to 64x64 per frame) with tight 4 to 16 color palettes, an entire 6-frame animated spritesheet is typically only 1 to 4 KB.
Can Phaser 3 games load individual frames instead of a packed atlas?
Yes. Every pack.zip also includes individual frames/<tag>_000.png files and sprite.json metadata, or you can fetch single frames via GET /v1/pixel-assets/{id}/frame.png?index=0.
Compare all lossless engine export pipelines
Ship crisp Phaser 3 pixel art today
Start with 25 free starter credits (verified signup) plus 4 complete starter packs and zero-credit manual editing and exports.