Tutorial 9 of 9
Composite graphs in recipes
Intermediate 6 min
Run a Lumina compositor graph or preset on every image of a batch or on every frame of a short clip with the Composite graph step.
The Composite graph (Lumina) step runs a compositing graph from Lumina's Compositor on each file of a recipe. It works on images and on video clips of up to 10 seconds, and the result keeps the kind of the input: an image recipe produces images, a video recipe produces MP4 clips.
1. Add the step
Open a recipe in Recipes and choose Add step. Composite graph (Lumina) is offered for image and video recipes. Its settings are:
- Graph — one of the presets Green-screen composite, Product shot on a gradient, Colour grade with a LUT and Sky replacement with a luma key, or Custom graph JSON.
- Graph JSON (from Lumina → Compositor → Copy graph JSON) — shown for a custom graph. Build the graph in Lumina, choose Copy graph JSON there and paste it here.
- Background image (optional) — a library image for the green-screen and sky presets and for custom graphs that use the background slot. With None (use a generated background) the presets fall back to a gradient.
- Image format and JPEG/WebP quality for image outputs, and Video format (clips) for video recipes: MP4 H.264 (opaque, transparent parts on black), WebM VP9 with transparency or ProRes 4444 MOV with transparency (large files).
2. Images
For a batch of product photos with transparent backgrounds, choose Product shot on a gradient: every photo is placed on the same studio gradient with a soft contact shadow and a light vignette. Keep Image format at PNG if you want to process the results further, or pick JPEG for delivery.
3. Short clips
On a video recipe, the step decodes the clip with ffmpeg, runs the graph on every frame and encodes an MP4 with the original sound. Frames are scaled to about 0.4 megapixels (for example 854 × 480) and at most 30 frames per second; clips longer than 10 seconds are refused with a message, so put a Video Cutter & Merger step first to cut the part you need. Nodes that do not depend on the clip — a generated gradient, a background image — are computed once and reused for every frame. MP4 has no transparency: with the default video format, end the graph with a merge over a background, otherwise transparent areas turn black. To keep a keyed subject transparent, choose WebM VP9 with transparency (the step then produces .webm files) or ProRes 4444 MOV with transparency (.mov, for editing software). In our test a 5-second 640 × 360 clip keyed without a background gave a 105 KB WebM and a 1.5 MB ProRes file, and both kept 91.5 % of each frame fully transparent.
4. Check the result
The queue shows the step summary from the tool, for example how many frames went through how many nodes. Open the output in the library to compare it with the original. The tool behind the step is lumina-compositor; scripts and AI agents can call it with the same graph through the API or MCP.
Ready to try it?