Nodes/BRIA AI API nodes/Bria Image Expansion
ComfyUI Node

Bria Image Expansion

Outpaint to any canvas size without the crop-and-stitch dance — Bria Image Expansion

By Bria-AI·Created 2 years ago·Updated 3 months ago· 95
Bria Image Expansion
  • images
  • output_images
api_keyBRIA_API_TOKEN
original_image_size
original_image_location
canvas_size1000, 1000
aspect_ratioNone
prompt
seed681794
negative_promptUgly, mutated
prompt_content_moderationfalse
preserve_alphatrue
visual_input_content_moderationfalse
visual_output_content_moderationfalse

Ever needed a 16:9 crop out of a square image that doesn't cut off your subject? That's outpainting, and the local version means padding a canvas, masking the empty band, and inpainting it with the subject nudged out of the way - fiddly, seam-prone, and slow. Bria Image Expansion does it in one API call: you tell it the canvas size you want, it grows the image in every direction and invents plausible content for the new areas, and hands back the expanded result as an IMAGE tensor.

It's part of the BRIA AI API nodes pack, so the generation happens on BRIA's servers (/v2/image/edit/expand) and the only real prerequisite is an API token from platform.bria.ai. This is the node you reach for when you need a billboard, a story-format crop, or a print ratio out of an image that was shot for a completely different aspect.

The inputs that matter

  • images and api_key - required.
  • canvas_size - a string like "1000, 1000" (default), the target dimensions of the expanded canvas. This is the core control: bigger canvas = more invented content.
  • aspect_ratio - defaults to None, meaning the canvas_size string rules. Pick a ratio (1:1 through 16:9) instead if you want the canvas to derive from it.
  • prompt - describe what the extended areas should contain ("continue the beach to the right"). Empty means the model just extrapolates on its own, which is often fine.
  • original_image_size / original_image_location - optional overrides if the API needs help locating the source within the canvas (usually you can leave them empty).
  • negative_prompt - defaults to "Ugly, mutated", a sensible guard for expansion artifacts.
  • seed - string, default 681794; lock it for repeatable expansions.

Output: output_images - the expanded tensors.

Install

No requirements file, no models to fetch:

cd path_to_comfyui/custom_nodes
git clone https://github.com/Bria-AI/ComfyUI-BRIA-API.git

or ComfyUI Manager → search "BRIA API" → restart, and paste your token in.

The honest part

Outpainting is where generative models most often produce content that looks generated - the invented area usually blends convincingly at the seams but can add details the photographer would never have shot. That's the nature of the job, and the prompt field plus a locked seed are your two levers to steer it. Note this node pairs naturally with Bria Image Enhance (the README even wires them in the example workflows - the expand output feeds straight into enhance). And the standard pack caveat applies harder here than most: expansion of a big canvas is a big generation job, so each run costs real credits. Nail your prompt and canvas once, then batch.

CategoryAPI Nodes

Inputs (13)

NameTypeDefaultDescription
imagesIMAGE
api_keySTRINGBRIA_API_TOKEN
original_image_sizeoptSTRING
original_image_locationoptSTRING
canvas_sizeoptSTRING1000, 1000
aspect_ratiooptCOMBONone10 options: 1:1, 2:3, 3:2, 3:4, 4:3, 4:5, +4
promptoptSTRING
seedoptSTRING681794
negative_promptoptSTRINGUgly, mutated
prompt_content_moderationoptBOOLEANfalse
preserve_alphaoptBOOLEANtrue
visual_input_content_moderationoptBOOLEANfalse
visual_output_content_moderationoptBOOLEANfalse

Outputs (1)

NameTypeDescription
output_imagesIMAGE