Outpaint tutorial - ten algorithms and multi-format export

Open Tool Image Outpaint

Outpaint tutorial - ten algorithms and multi-format export

This walkthrough follows the real order of work: what the tool is for, what each control does, a five step pass, and a self-check before you ship the export.

When to use

Putting a portrait image into a landscape banner, or a square cover into a wide slot, usually means adding space rather than cropping content. This tool widens the canvas on four sides, fills the new area with mirrored, blurred or stretched edge pixels, and hides the seam with a blend band.

It generates nothing new and calls no model: the extended area is purely copied or blurred edge pixels, which suits solid backgrounds, gradients and regular textures. Faces and busy scenes will show repetition.

A 1,200 by 800 image with 200 pixels per side previews about 110 ms after a parameter change.

One source canvas and one output canvas are kept; mirror tiles are drawn block by block and no copy survives afterwards, so swapping images replaces the source instead of stacking memory.

Steps

  1. Click the dashed box or drop a file; the image scales down to fit within 2,400 pixels.
  2. Tick the sides to extend and enter pixels per side, starting conservative.
  3. Choose the fill: mirror for photos, blur for flat backgrounds, stretch for quick previews.
  4. Raise the blend radius until the seam line disappears.
  5. Use the 16:9 button for a fixed ratio, then download the PNG.

Screenshots

These three shots come from the final build of this plugin.

The empty state: the upload area and extension options on the left, canvas preview and size stats on the right.

After loading an image with 160 pixels per side, mirrored edges appear and a dashed box marks the original.

Right column: a 900x900 1:1 output, the dashed original boundary and mirrored fill.

Features in detail

Any side:top, bottom, left and right toggle independently, from 8 to 1600 pixels each.

Three fills:mirror looks most natural, blur suits solid or defocused backgrounds, stretch is fastest.

Seam blend:a 0 to 20 radius softens the join so no hard line remains.

One-click 16:9: the tool decides whether to add width or height and ticks the right sides.

Boundary hint: a dashed rectangle marks the original image inside the preview.

Local export:a PNG named after the source, with no pixels uploaded.

What you get

Inputs

  • An image is required, PNG, JPG or WebP, scaled down when a side exceeds 2,400 pixels.
  • Sides, pixels per side, fill mode, blend radius and background colour are adjustable.

Outputs

  • A preview of the extended canvas with the original boundary dashed.
  • The output size, scale factor and a PNG file.

Parameters

The workspace exposes 19 controls, from Top to Output sharpening (contrast + saturate), and every one of them only affects the local rendering: nothing is sent back to a server.

Ranges and defaults: Fill algorithm (Mirror (most natural) / Faded mirror / Tile / Directional smear / Seamless block tile / Four-way kaleidoscope / Patch match (closest colour) / Gradient-domain (Poisson-like) / Blur (solid backgrounds) / Edge stretch (fastest)), Edge blend (0–20), 6 (0–20 (default 6)), Aspect preset (16:9 / 4:3 / 1:1 / 3:4 / 9:16 portrait / 4:5 social / 5 : 4 / 21:9 ultrawide / 2:1 banner), Watermark position (Bottom right / Bottom left / Top right / Top left / Center), Watermark opacity (%) 72 (20–90 (default 72)), Export format (PNG / JPEG / WebP). Values outside the slider range are rejected rather than silently clamped.

ControlTypeRange or options
Topswitch-
Bottomswitch-
Leftswitch-
Rightswitch-
Expand each side (px)number-
Fill algorithmselectMirror (most natural) / Faded mirror / Tile / Directional smear / Seamless block tile / Four-way kaleidoscope / Patch match (closest colour) / Gradient-domain (Poisson-like) / Blur (solid backgrounds) / Edge stretch (fastest)
Edge blend (0–20), 6range0–20 (default 6)
Aspect presetselect16:9 / 4:3 / 1:1 / 3:4 / 9:16 portrait / 4:5 social / 5 : 4 / 21:9 ultrawide / 2:1 banner
Corner radius (px)number-
Watermark texttext-
Watermark positionselectBottom right / Bottom left / Top right / Top left / Center
Watermark opacity (%) 72range20–90 (default 72)
Export formatselectPNG / JPEG / WebP
Quality (JPEG / WebP) 92range60–98 (default 92)
Seam blend strength (%) 55range0–100 (default 55)
Max output edge (px, 0 = unlimited)number-
Grain (0–60), 0range0–60 (default 0)
Vignette (0–60), 0range0–60 (default 0)
Output sharpening (contrast + saturate)switch-

Typical cases

  • A portrait poster has to become a landscape banner without cropping the subject.
  • A square cover must fill a wide slot, so the edges need extending instead of leaving blank space.
  • Batch normalising product shots to 16:9 before layout.

In each of these cases the pass is the same: load the file, make one change, check the preview, export and reopen. Skipping the reopen step is why people later discover a transparent halo or a truncated table that looked fine on screen.

A worked pass

Step 1: Click the dashed box or drop a file; the image scales down to fit within 2,400 pixels. Read the hint line before touching anything: it tells you which prerequisite is missing.

Step 2: Tick the sides to extend and enter pixels per side, starting conservative. Do not start with the most extreme setting; one small change is enough to see whether the result moves in the right direction.

Step 3: Choose the fill: mirror for photos, blur for flat backgrounds, stretch for quick previews. Check the preview at 100% rather than the fitted view, because artefacts often hide in the downsampled version.

Step 4: Raise the blend radius until the seam line disappears. Export once, open the file in a local viewer, and only then decide the settings are final.

Step 5: Use the 16:9 button for a fixed ratio, then download the PNG. Keep the source file untouched so you can repeat the pass with a different setting without re-importing.

Walking through the controls

The Top switch is a binary choice. Turn it off first to record what the default output looks like, then turn it back on and export once so you can confirm the difference survives outside the preview. On a slow machine the redraw is scheduled rather than immediate, so wait for the status line to settle before judging the result.

The Bottom switch is a binary choice. Turn it off first to record what the default output looks like, then turn it back on and export once so you can confirm the difference survives outside the preview. On a slow machine the redraw is scheduled rather than immediate, so wait for the status line to settle before judging the result.

The Left switch is a binary choice. Turn it off first to record what the default output looks like, then turn it back on and export once so you can confirm the difference survives outside the preview. On a slow machine the redraw is scheduled rather than immediate, so wait for the status line to settle before judging the result.

The Right switch is a binary choice. Turn it off first to record what the default output looks like, then turn it back on and export once so you can confirm the difference survives outside the preview. On a slow machine the redraw is scheduled rather than immediate, so wait for the status line to settle before judging the result.

The Expand each side (px) field accepts free text. Paste a realistic value rather than a placeholder, because both the preview and the exported file depend on what you type here; an empty value usually means the tool falls back to a default derived from the file itself.

The Fill algorithm dropdown offers Mirror (most natural) / Faded mirror / Tile / Directional smear / Seamless block tile / Four-way kaleidoscope / Patch match (closest colour) / Gradient-domain (Poisson-like) / Blur (solid backgrounds) / Edge stretch (fastest). Switching it re-renders the preview immediately, so compare two neighbouring options rather than jumping across the whole list; the exported file follows the option that is selected at the moment you press export, not the one you looked at earlier.

The Edge blend (0–20), 6 slider is bounded by 0–20 (default 6). Keep it near the default for a first pass, then move one step at a time: each step is visible in the preview, and moving it in large jumps makes it impossible to tell which setting produced the artefact you are trying to remove. Values outside the range are rejected instead of being silently clamped, so the number in the readout always matches what the export will use.

The Aspect preset dropdown offers 16:9 / 4:3 / 1:1 / 3:4 / 9:16 portrait / 4:5 social / 5 : 4 / 21:9 ultrawide / 2:1 banner. Switching it re-renders the preview immediately, so compare two neighbouring options rather than jumping across the whole list; the exported file follows the option that is selected at the moment you press export, not the one you looked at earlier.

The Corner radius (px) field accepts free text. Paste a realistic value rather than a placeholder, because both the preview and the exported file depend on what you type here; an empty value usually means the tool falls back to a default derived from the file itself.

The Watermark text field accepts free text. Paste a realistic value rather than a placeholder, because both the preview and the exported file depend on what you type here; an empty value usually means the tool falls back to a default derived from the file itself.

The Watermark position dropdown offers Bottom right / Bottom left / Top right / Top left / Center. Switching it re-renders the preview immediately, so compare two neighbouring options rather than jumping across the whole list; the exported file follows the option that is selected at the moment you press export, not the one you looked at earlier.

The Watermark opacity (%) 72 slider is bounded by 20–90 (default 72). Keep it near the default for a first pass, then move one step at a time: each step is visible in the preview, and moving it in large jumps makes it impossible to tell which setting produced the artefact you are trying to remove. Values outside the range are rejected instead of being silently clamped, so the number in the readout always matches what the export will use.

The Export format dropdown offers PNG / JPEG / WebP. Switching it re-renders the preview immediately, so compare two neighbouring options rather than jumping across the whole list; the exported file follows the option that is selected at the moment you press export, not the one you looked at earlier.

The Quality (JPEG / WebP) 92 slider is bounded by 60–98 (default 92). Keep it near the default for a first pass, then move one step at a time: each step is visible in the preview, and moving it in large jumps makes it impossible to tell which setting produced the artefact you are trying to remove. Values outside the range are rejected instead of being silently clamped, so the number in the readout always matches what the export will use.

The Seam blend strength (%) 55 slider is bounded by 0–100 (default 55). Keep it near the default for a first pass, then move one step at a time: each step is visible in the preview, and moving it in large jumps makes it impossible to tell which setting produced the artefact you are trying to remove. Values outside the range are rejected instead of being silently clamped, so the number in the readout always matches what the export will use.

The Max output edge (px, 0 = unlimited) field accepts free text. Paste a realistic value rather than a placeholder, because both the preview and the exported file depend on what you type here; an empty value usually means the tool falls back to a default derived from the file itself.

The Grain (0–60), 0 slider is bounded by 0–60 (default 0). Keep it near the default for a first pass, then move one step at a time: each step is visible in the preview, and moving it in large jumps makes it impossible to tell which setting produced the artefact you are trying to remove. Values outside the range are rejected instead of being silently clamped, so the number in the readout always matches what the export will use.

The Vignette (0–60), 0 slider is bounded by 0–60 (default 0). Keep it near the default for a first pass, then move one step at a time: each step is visible in the preview, and moving it in large jumps makes it impossible to tell which setting produced the artefact you are trying to remove. Values outside the range are rejected instead of being silently clamped, so the number in the readout always matches what the export will use.

The Output sharpening (contrast + saturate) switch is a binary choice. Turn it off first to record what the default output looks like, then turn it back on and export once so you can confirm the difference survives outside the preview. On a slow machine the redraw is scheduled rather than immediate, so wait for the status line to settle before judging the result.

Practical notes

Keep the browser window above 1200 pixels wide while working: below that the right column collapses under the left one and you lose the side-by-side view.

Use the reset control between experiments; carrying state from a previous pass is the most common reason a setting appears to have no effect.

If a control looks unresponsive, check the hint line first: most no-op states are caused by a missing file rather than a broken button.

Export after every meaningful change rather than at the very end, so you still have a known-good file if the next experiment goes wrong.

On a laptop with a scaled display the preview is drawn at device pixel ratio, so text that looks crisp on screen stays crisp in the exported image at the same size.

Compare your result against the limits section: if you are working outside the documented range, the tool may still run but the output quality is not guaranteed.

Long sessions are fine because nothing is uploaded, but reload before switching to a different kind of file so cached state cannot leak into the new pass.

The controls you will touch most often here are Top, Bottom, Left, Right.

Self-check list

Run the workflow once with a real file and confirm the result pane shows content, not the empty state.

Push every slider to its minimum and maximum and confirm the readout follows without an error.

Switch each dropdown and confirm the preview and the export change together.

Export once and reopen the file with a local viewer to confirm it is not truncated.

Reset the workspace and confirm all panels return to the empty state.

Reload the page and confirm no previous result is restored by accident.

FAQ

Q: Why does the filled area look repeated?

A: Mirroring folds edge pixels back, which reads naturally on regular textures. For people or busy scenes, extend less or switch to blur.

Q: Can it invent content that was not there?

A: No. This is pixel extension only; generative fill needs a different tool.

Q: Why did my large image shrink?

A: Sides above 2,400 pixels scale down first to bound memory. Crop before processing if you need full resolution.

Q: Does the original image shift when I expand?

A: No. The source is always pasted back into the centre and each margin is independent, so changing one side does not move another.

Q: Why is the exported PNG so large?

A: Size grows with canvas area, and expanding all four sides multiplies it; expand only the side you need or downscale the source first.

Q: Do huge images stall?

A: Sides above 2,400 pixels scale down first. For very large art, crop close to the target ratio and extend a small margin here.

Q: Does the file leave my device?

A: No. Everything runs inside the browser; requireNetwork is false and no upload happens.

Q: Which browsers does it run in?

A: Current Chrome, Edge, Firefox and Safari builds; no extension or plugin is needed.

Q: Why does the exported file differ in size from the source?

A: The export re-encodes the result, so size follows the chosen format and quality settings.

Limits

  • Canvas extension and edge filling only, no generated content.
  • PNG output only, without JPG quality control or a batch queue.
  • No perspective correction, corner rotation or irregular shapes.

Design trade-offs

Outpainting runs in two steps: build a larger canvas from the four margins, fill the new area, then paste the source back into the centre. Mirror folds blocks of pixels, blur stretches an edge strip and blurs it, stretch copies edge rows and is cheapest but shows banding.

Edge feathering only works inside the original border, softening the seam with semi-transparent source pixels; wider bands look more natural but cost edge detail, so keep it low for icons and documents.

Troubleshooting

Mirror fill on a flat background produces symmetric patterns that read as a reflection; use blur or stretch for that kind of image instead.

PNG size grows with canvas area, so expanding all four sides by 1600 pixels on a small image can produce a very large file.

Outpainting extends existing pixels and does not invent new content; use a generative tool when the goal is a new subject.

Workflow and acceptance

For marketplace images, compute the margin from the target ratio first, then pick a fill: stretch for flat studio shots, mirror for textured scenes, blur with low feather for people.

Fix the settings on one image before applying them to a group; mixing lighting conditions with one feather value makes seams obvious.

Accept when the original area has not shifted, the seam is invisible at 100%, the exported PNG matches the requested size, and a second pass does not repeat mirror patterns.

Performance and resource budget

Outpainting is pixel work: fill the background, then paint strips on the chosen edges. Mirror mode tiles several drawImage calls, blur sets a context filter, stretch is the simplest. A 900 by 900 redraw takes about 20 ms, which keeps the blend slider smooth.

Rendering is signature-guarded: unchanged pixels, directions, mode, blend and background return immediately, avoiding duplicate paints in one frame. In batch mode each image is decoded, painted and converted to a blob independently, then released, so bitmaps do not pile up.

Batch cost is dominated by PNG encoding rather than painting, and browsers have soft limits on live canvases, so keep queues under about twenty images.

Worked case: one square hero image into four placements

Scenario: a 1200x1200 marketplace hero needs 1:1 detail, 4:5 social and 16:9 banner versions. Approach: load the source, produce 1:1 first as the faithful base; then 4:5 extending top and bottom with blend at 8-12 so seams vanish; finally 16:9 extending left and right with the background sampled from the source edge rather than pure white, avoiding a sticker look. The batch queue runs all three ratios and packages them with consistent names.

Choosing a mode: solid or gradient backgrounds favour stretch or solid fill for the cleanest result. Textured backgrounds (fabric, wood) suit mirror because the texture continues naturally, but text near the edge mirrors into reversed glyphs - move badges into the safe area first. Blur suits portraits and soft backgrounds at the cost of edge detail.

Acceptance: check three things - the subject still reads as centred, no thin brightness line at the seam, no corner stretching. A 900x900 redraw is about 20 ms, so tune the blend in the preview until the seam disappears before exporting.

Version and compliance

This build is v1.6.1 on ToolCMS plugin spec 3.19, schemaVersion 2.1 and coreVersion 3.7.4. All processing happens inside the browser, requireNetwork is false and no file leaves the device.

⏫︎