Canvas
Pictures for menus, HUDs, icons and key art: generate, edit, cut out the background, upscale, and import as textures
Overview
Canvas makes the art in a game that is neither a model nor a sound: a title screen, a menu backdrop, a health bar frame, an inventory icon, a portrait, a loading screen, a sprite. Describe it, pick a size and a model, and the picture is generated, stored and saved as an Image in Saved Assets with a version history like a Forge model. Every later step — an edit in words, a background cutout, a 2x upscale — is a new version; the old one stays and can be pinned.
Behind it are fal.ai endpoints: the same operator-edited text-to-image list Forge uses for concept renders, plus lists for editing, background removal and upscaling. Credits are charged at the vendor's actual cost times the surcharge, the same rule as every other generator.
Generating a picture
- 1Open Canvas → New image and describe the picture as you would brief an artist: subject, style, palette, mood, and any words that must appear on it, in quotes.
- 2Pick a size. The named sizes cover the common game uses; the API also takes any width and height in multiples of 16 up to 2048.
- 3Pick a model, or leave the default. For text on the picture choose Ideogram 3 or Nano Banana: they can spell.
- 4Turn on Transparent background for a HUD element, an icon or a sprite: the picture is drawn on plain white and the background is then removed, so the PNG has alpha.
- 5Optionally choose a project and a character (a portrait, an emblem), and a name — it becomes the texture name in the engine.
- 6Generate. The picture opens on its own page when it is stored, usually within ten to thirty seconds.
Sizes
| Size | Pixels | Suits |
|---|---|---|
square | 1024 × 1024 | icons, portraits, tiles, item art (the default) |
square_small | 512 × 512 | small icons and buttons |
landscape_16_9 | 1536 × 864 | splash screens, backgrounds, key art |
landscape_4_3 | 1280 × 960 | panels, cards, dialogue frames |
portrait_16_9 | 864 × 1536 | mobile screens, loading screens |
portrait_4_3 | 960 × 1280 | character cards, posters |
banner | 2048 × 512 | title bars, HUD strips |
ultrawide | 2048 × 864 | menu backdrops |
Transparent means two steps
No picture model draws alpha. With transparent the prompt gets "isolated on a plain solid white background" appended, the picture is generated, and a background-removal model cuts the subject out. Name one object in the prompt; a scene has no background to remove.
The next version
On an image's page, Make the next version takes the active picture and does any of three things, in this order: an edit from instructions ("make the frame brass", "remove the text at the bottom", "add a subtle glow behind the icon"), a background cutout, and a 2x upscale. Each is a fal endpoint from the catalog; the editor can be chosen. The result is a new version, active by default; Set Active on any older version pins it, and each version downloads on its own.
- •Edits keep what you did not mention. Say what changes, not the whole picture again.
- •Cut out after the edit, not before: a transparent picture edited again comes back with a background.
- •Upscale last. It doubles the pixels of whatever it is given, including a cutout's alpha.
Talking to the Canvas agent
One call makes one picture. The work a picture is not — a sprite sheet with even cells, a button in three states, a 9-slice panel with its margins, a title set in a real font, a palette swap, a seamless tile — is a conversation with the Canvas agent: an agent with an image workspace of named layers, the same picture models as above when it needs a new element, and one step per message. Say what you want; it does that step, shows you the result, and asks where next. Every step you keep becomes a draft version of the image; Export writes the finished one.
- •Start from an image's page (Talk to the Canvas agent) to work on that picture, or from Canvas's New conversation with a brief to make one from nothing.
- •Sizes and positions are exact: "128 px cells, 4 px margin, 3 columns" comes back as those pixels, with the atlas in the export's
meta.json. - •A turn costs a small flat reservation settled to what the step actually cost; a step that calls a picture model adds that model's price.
Into the engine
The Unreal plugin's import_content(content_id) (and the Import button in its Library) brings an Image in as a UTexture2D under <Import Root>/Canvas/ named T_<Name>, set up for UI: the UI texture group, no mipmaps, sRGB, never streamed. Drop it into a UMG Image or Brush. See Unreal Engine.
API
Scopes: canvas:read to read the catalog and images, canvas:write to generate, edit and delete. Images are Saved Assets with contentType: "image": they come back from GET /api/v1/content?contentType=image, and the usual content routes rename, re-tag, link to a character, pin a version, and delete them.
/api/v1/canvas/catalogcanvas:readmodels (key, label, notes, estimatedCredits for one 1024 × 1024 picture, default), editModels, cutoutModels, upscaleModels, sizes, and limits. The lists are operator-editable: read them rather than assuming keys.
/api/v1/canvas/generatecanvas:write| Field | Type | Description |
|---|---|---|
prompt* | string | What to draw, up to 2000 characters |
model | string | Picture model key from the catalog (omit for the default) |
size | string | A named size (default square); or width and height |
width · height | integer | Multiples of 16 between 256 and 2048, together |
transparent | boolean | Remove the background afterwards: a PNG with alpha |
cutoutModel | string | Background-removal key (omit for the default) |
name | string | Asset name (letters, digits, underscores, hyphens; starts with a letter; ≤ 48). Omitted: from the prompt |
projectId | string | Save into this project |
characterId | string | The character the picture belongs to; it is saved into that character’s project |
tags | string[] | Up to 20 |
Synchronous. Answers 201 with { contentId, name, versionNumber, image: { url, width, height, mimeType, sizeBytes, transparent }, model, creditsCharged, content }. Credits are reserved when the call starts and settled to the vendor's cost; a failure refunds them.
curl
curl -X POST https://tonetta.io/api/v1/canvas/generate \
-H "Authorization: Bearer $TONETTA_API_KEY" -H "Content-Type: application/json" \
-d '{"prompt":"round brass compass icon, art deco, game UI, crisp edges","size":"square_small","transparent":true,"name":"Icon_Compass"}'/api/v1/canvas/editcanvas:write| Field | Type | Description |
|---|---|---|
contentId* | string | The image (alias id) |
instructions | string | What to change, in words. Optional when only cutting out or upscaling |
model | string | Editor key from editModels (omit for the default) |
cutout | boolean | Remove the background (after the edit) |
cutoutModel | string | Background-removal key |
upscale | boolean | Upscale 2x (after the edit and the cutout) |
upscaleModel | string | Upscaler key |
At least one of instructions, cutout, upscale. Answers 201 with the new version: { contentId, versionNumber, image, steps, creditsCharged, content }.
Conversations
The Canvas agent is four routes with the shape of the Forge conversation: POST /api/v1/canvas/sessions (a message with either a contentId to work on or a projectId for a new image), POST /api/v1/canvas/sessions/{contentId}/messages, GET /api/v1/canvas/sessions/{contentId} (the transcript, the current picture as sceneUrl, and whether the agent is still working), and POST /api/v1/canvas/sessions/{contentId}/export. Optional model (the agent's LLM), conceptModel and editModel pick the models it may call.
MCP
The same as tools: get_canvas_catalog, generate_image, edit_image, and for the conversation start_canvas_session, send_canvas_message, get_canvas_session, export_canvas_session, with the same arguments, filtered by the key's scopes. See MCP.