AI Image Generation and DesignEditing, upscaling and finishing · Lesson 7 of 18
Inpainting, outpainting and generative fill
Video lecture
Inpainting, outpainting and generative fill
The narrated lecture is in production
Every chapter is scripted and ready. Browse the chapters and read the full transcript now — the video will appear here when it’s published.
Chapters
Transcript of the narration, chapter by chapter.
0:00 Inpainting, outpainting and generative fill
Here's a scenario you'll recognize. You finally get an AI image that's almost perfect. Great composition, great light. But the hand has six fingers, there's a weird object in the background, and it's square when you need a vertical story. Most people throw it away and start again, and lose everything that was working. Professionals don't. They edit. In this lecture, you'll learn inpainting, outpainting and generative fill, how to write edit prompts that actually work, how to expand one image into several formats, and how to keep editing honest. By the end, you'll be able to rescue an eighty percent image and turn it into a finished, multi-format asset.
0:48 Why edit instead of regenerate
Why does editing matter so much? Because regenerating is a lottery. Every new generation gives you new problems along with the fixes. Editing lets you keep what's right and change only what's wrong. Think of it like a tailor adjusting a suit that almost fits. You don't buy a new suit because one sleeve is long. You take in the sleeve. Editing is also where AI output becomes production work. Clients need specific formats, clean backgrounds, space for text, and accurate products. And most of that happens in editing, not in the first prompt. It's where your design skill shows.
1:31 Core editing techniques
Here are the core techniques. Inpainting regenerates a selected area, guided by a short prompt, which is ideal for hands, clothing or small objects. Outpainting, also called generative expand, extends the canvas, so you can turn a square into a vertical story or add space for a headline. Generative fill, inside design tools like Photoshop, fills any selection, for removing distractions or adding elements. Then there's object removal, background replacement, and instruction edits, where you just describe the change in plain words. In current Photoshop, you can even choose which model does the fill, Adobe's own Firefly models or partner models, depending on your plan. Check terms for each, because they can differ.
2:20 Inpainting in five steps
Let's get specific about inpainting. Step one, select slightly larger than the problem, so the model sees some context and the fill blends. Step two, write a local prompt that describes only what belongs in that area. Not the whole scene. Relaxed open hand resting on the table, natural skin texture, warm light from the left. Step three, generate several options and pick the one that matches lighting, perspective and texture. Step four, check the edges for seams and color shifts. Step five, fix multiple problems one at a time with small masks. Here's the key idea. Small masks and local prompts preserve identity and style. Huge masks invite the model to reinvent everything.
3:10 Worked example 1: a restaurant promo
Worked example one, simple. A restaurant promo image. The food looks great, but there's a fork floating in midair and a menu with gibberish text in the corner. First, I mask the floating fork generously and prompt, empty wooden tabletop continuing the existing grain. Three options, and one blends perfectly. Next, I mask the menu and ask for a plain folded napkin. Now the image is clean, but it's square, and I need a vertical story. So I expand upward in one step, prompting for a plain warm wall with soft shadow and no new objects. That calm wall becomes my headline space. Two small inpaints and one expand, about ten minutes, and the image is usable.
4:01 Worked example 2: one scene, three formats
Worked example two, a business scenario with illustrative details. Layla runs content for a cosmetics shop in Jeddah. She has one square AI product scene and needs a four by five feed post, a nine by sixteen story and a sixteen by nine web banner. The golden rule: the product is a real photo layer on top, and it never gets regenerated. For the feed, she expands the top in one pass. For the story, she expands in two steps, top then bottom, because huge expansions tend to repeat patterns. She keeps the areas where the platform shows buttons and captions clear. For the banner, she expands left and right, checking that the horizon line stays straight. Finally, she inpaints any seams and adds matching grain. One scene, three native formats.
4:58 Watch me do it: Photoshop edit pass
Watch me do it. I'm in Photoshop with the café image open. I use the lasso to select around the distorted hand, with some table included. In the Generative Fill bar, I type my local prompt and press generate. I get three variations in the properties panel. I cycle through them. Variation two matches the light. Now I zoom to one hundred percent and check the knuckles and the edge of the sleeve. Clean. Next, I choose the crop tool, drag the top edge up for the story format, and use Generative Expand, leaving the prompt focused on a plain wall. Then I check the model menu, so I know which model made the edit, and I note it in my log.
5:51 Editing real photos honestly
Now, editing real photographs, and honesty. You can use these tools on real photos, and that's where ethics matter most. Removing a stray cable or a passerby is ordinary cleanup. Changing a product's results, a person's body, or what happened at an event is not cleanup. It can mislead, and in advertising it can break the rules. Get consent before you meaningfully alter a real person. And keep provenance. Many tools, including Photoshop and the AI image tools from OpenAI and Google, attach Content Credentials, which record that AI was used. Don't strip that metadata. Some platforms read it to apply AI labels, and it protects you if anyone asks how an image was made.
6:41 Common mistakes
Common mistakes. Masking huge areas and losing the subject's identity. Writing a full scene prompt inside a small mask, which confuses the model. Expanding a canvas by two hundred percent in one step, which creates repeated patterns and warped perspective. Forgetting to match grain and blur, so edited patches look plasticky. Regenerating the product instead of keeping the real photo layer. Trusting instruction edits without comparing before and after, because they sometimes change the face or the label quietly. And stripping metadata on export. Keep a simple editing checklist next to your screen, and run it on every asset.
7:24 Recap and try this now
Let's recap. Don't throw away an eighty percent image. Edit it. Use inpainting with small masks and local prompts, expand in stages for new formats, keep real products as untouched photo layers, and compare before and after at one hundred percent. Know which model did the work and which terms apply, and keep provenance data intact. Here's your try this now. Take an AI image with at least two flaws. Fix each one with a separate small inpaint. Then expand it into a second aspect ratio in two stages, and run the editing checklist from the lesson. Save the before and after side by side. It's a great portfolio piece.
Editing is where AI images become usable
Many AI images are 80% right: a great composition with a distorted hand, an odd object in the background, or the wrong aspect ratio. Rather than regenerating from scratch and losing what works, use targeted editing.
Key editing techniques
| Technique | What it does | Typical use |
|---|---|---|
| Inpainting | Regenerates a selected (masked) area guided by a prompt | Fix hands, change clothing, remove objects, add details |
| Outpainting / generative expand | Extends the canvas beyond the original edges | Convert 1:1 to 9:16, create space for text |
| Generative fill | Fills a selection with generated content (in design suites) | Remove distractions, add elements, extend backgrounds |
| Object removal | Removes selected items and fills naturally | Clean up photos and AI outputs |
| Background replacement | Separates subject and generates a new background | Product scenes, portraits |
| Conversational edits | Text instructions to modify an image | Quick changes like color or lighting |
Inpainting step by step
- Select the area slightly larger than the problem, including a little surrounding context so the fill blends.
- Write a local prompt describing only what should appear in the masked area ("relaxed open hand resting on the table"), not the whole scene.
- Generate several options and choose the one that matches lighting, perspective and texture.
- Check edges for seams, color shifts or texture mismatches.
- Repeat in small steps for multiple fixes rather than masking huge areas at once.
Tips:
- For faces and hands, smaller masks usually preserve identity and style better.
- If the fill keeps failing, simplify: change the pose description, or crop the problem out of frame.
- Match grain and sharpness; generated patches can look smoother than surrounding areas.
Outpainting for new formats
Outpainting is especially useful for social formats. A strong 1:1 image can be extended to 9:16 for stories, or to 16:9 for thumbnails, by generating additional content above/below or to the sides.
Best practice:
- Extend in stages (for example, add a portion at a time) rather than a huge expansion at once.
- Describe what should appear in the new area ("continuation of the sky with soft clouds", "more of the wooden table surface").
- Keep the subject within safe zones after expansion.
- Check for repeated patterns, warped perspective or duplicated objects at the edges.
Editing real photographs
Generative editing is also used on real photos. This is powerful and needs care:
- Acceptable edits usually include removing distractions, cleaning backgrounds, extending canvas for layout, and color correction.
- Risky edits include changing a person's body, face or skin in ways that misrepresent them; altering product appearance or results; adding people or events that did not happen in a documentary context.
- Consent: editing images of real people — especially changing their appearance — should be done with their knowledge and consent.
- Disclosure: some platforms require labels for realistic content that has been materially altered or synthetically generated; some advertising regulators have specific rules on filters and retouching in beauty advertising.
Content provenance
Some tools attach Content Credentials (based on the C2PA standard) or invisible watermarks to generated or edited images, recording that AI was used. Platforms may read this metadata and apply labels automatically. Do not deliberately strip provenance data to hide AI use; this can breach platform policies and undermines trust.
Worked example: a restaurant promo
A generated 1:1 image shows a beautiful table of dishes, but there is a fork with four prongs merging into a plate, a garbled menu card, and the client needs a 9:16 story version.
- Inpaint the fork area: "a simple silver fork resting beside the plate".
- Inpaint the menu card: "a plain blank card" (real menu text will be added in the design tool).
- Outpaint upward in two stages: "warm restaurant ceiling with soft pendant lights, out of focus".
- Check that dishes still represent real menu items accurately — if the image is used to advertise specific dishes, it should reflect what customers actually receive; for real menu items, real food photography is often more appropriate.
Editing checklist
[ ] Mask slightly larger than the problem, include context
[ ] Local prompt describes only the masked area
[ ] Multiple options generated; best match chosen
[ ] Seams, lighting, perspective, grain checked at 100% zoom
[ ] Outpainted areas free of duplicates and warping
[ ] No misrepresentation of people, products or results
[ ] Provenance metadata preserved; disclosure needs assessedCommon mistakes
- Masking huge areas and losing the original image's quality.
- Writing the whole-scene prompt for a small inpaint.
- Not zooming in to check seams.
- Using generative edits to alter people's bodies or product results misleadingly.
What's new: model choice and instruction edits inside the editor
In current versions of Photoshop, Generative Fill and Generative Expand let you choose which model does the work — Adobe's own models (such as Firefly Fill & Expand and Firefly Image 5) and, on eligible plans, partner models from other labs. Adobe notes that partner models come and go (for example, support for an older Gemini model is being removed in 2026), so check the model menu and Adobe's help pages before building a workflow around one model. Assistant-built models (GPT Image, Gemini image models) also edit by instruction: you upload an image and describe the change.
Two practical rules:
- Adobe's commercial-use and training terms apply to Adobe's own models; partner models may have different terms. Check before client work.
- Instruction edits can change more than you asked. Compare before and after at 100%, especially faces, labels and hands.
Hands-on: edit prompt templates
LOCAL INPAINT (describe only the masked area)
"relaxed open hand resting on the table, natural skin texture,
same warm light from the left"
REMOVE
"empty wooden tabletop continuing the existing grain" (or leave blank
in tools where an empty prompt means 'remove')
EXPAND FOR A NEW FORMAT (in stages, ~20-30% per step)
"continue the café interior upward: plain warm-white wall, soft shadow,
no new objects" — leave this area calm for the headline
INSTRUCTION EDIT (assistant-built models)
"Keep everything exactly the same, including the product label and the
person's face. Only change the tablecloth from white to deep green linen."Worked example: one image, three formats
A cosmetics shop in Jeddah has a 1:1 AI product scene and needs 4:5 feed, 9:16 story and 16:9 web banner versions (illustrative brief).
| Step | Action | Check |
|---|---|---|
| 1 | Place the real product photo layer above the AI background (never regenerate the product) | Label and cap unchanged |
| 2 | Expand canvas to 4:5, generate the top area in one pass | No repeated patterns |
| 3 | Expand to 9:16 in two steps (top, then bottom) | Safe zones clear for UI |
| 4 | Expand to 16:9 left and right in two steps | Horizon line straight |
| 5 | Inpaint any seams; add grain to match | Edges invisible at 100% |
| 6 | Export with Content Credentials enabled where supported | Provenance kept |
Before: cropping the 1:1 to 9:16 would have cut the product in half. After: one scene, three native formats, product untouched.
Summary
Use inpainting for targeted fixes, outpainting for new formats, and generative fill for clean-ups; work in small steps, check at full zoom, preserve provenance, and never use edits to mislead.
Key takeaways
- Edit near-miss images with targeted inpainting instead of regenerating and losing what works.
- Use small masks with local prompts, and expand canvases in stages to avoid repetition and warped perspective.
- Keep real products as untouched photo layers; never regenerate the product itself.
- Know which model performed an edit — partner models in design tools may have different terms.
- Cleanup is fine; altering facts is not. Keep Content Credentials and get consent to alter real people.
Check your understanding
Quick questions to lock in the lesson. They don’t count towards your certificate.
Put it into practice
Take an AI image with at least two flaws. Fix each with a separate small inpaint, then outpaint it to a second aspect ratio in stages, completing the editing checklist.
Enrol for free to save your progress
Reading is always free. Enrol to keep your place, take the final assessment and earn a verifiable certificate.