Animation frames and character turnarounds in Krita with AI

Updated 2026-11-28 · MCP Pro for Krita 1.0.0

Krita has a real animation timeline, and MCP Pro for Krita drives it: frame rate and range, keyframes, frames built from layers, and export to frames, sprite sheets and GIFs. This guide covers the common game-art jobs.

Timeline basics

Frames from a layer stack

Many artists draw frames as separate layers. frames_from_layers turns them into one animated layer, each layer one keyframe held for hold frames:

frames_from_layers(group="walk", name="Walk", hold=2)

Pass layers=[...] (first to last) or a group (its children, bottom first). The source layers are hidden and the clip range is set.

A character turnaround in one call

Draw the views on separate layers, anywhere on the canvas, then:

recipe_turnaround(layers=["front", "three_quarter", "side", "back"],
                  fps=4, align="bottom",
                  export_dir="D:/game/hero", gif_scale=6)
Four pose layers scattered on the canvaslayers
Turnaround animationGIF
Live test, Krita 6.0.5: four 8-px-wide pose layers drawn with set_pixel_rows and pixel_outline at different spots; the recipe aligned them on a common baseline and centre, made one keyframe per view, and wrote the GIF and a sprite sheet.
The four views side by side
The sprite sheet from the same call (JSON alongside). ping_pong=true plays the views back and forth; hold keeps each view longer.

The same recipe works for any set of poses: an idle cycle, a jump, expressions. Each run is one undo step.

Importing image sequences

import_frames(files=[...], first_frame=0, step=1) brings existing images in as an animated layer, one file per keyframe, for example frames rendered elsewhere or exported from another tool.

Onion skins

set_onion_skin(previous=2, next=1, opacity=50) sets how many neighbouring frames show and how strongly. Krita cannot report a layer's own onion-skin switch, so toggle_layer=true flips it rather than setting it; the counts and opacity are Krita-wide and the Onion Skins docker shows them after it is reopened.

Looking at frames

get_canvas_preview(frame=3) returns one frame as an image, so the AI can check spacing and alignment frame by frame. For a quick overall check, have it export a GIF and a sprite sheet and look at the sheet.

Export

Limits

Get MCP Pro for Krita
$15 once on itch.io, free updates.

itch.io · $15

More guides