Skip to main content
AIDiveForge AIDiveForge
🪄

Product-Shot Background Swap

Image & Video · by AIDiveForge · Apr 20, 2026 · Intermediate

Replace a product photo's background using a reference palette while preserving the product's reflections and shadows.

🧠 Why it works

Pure background removal leaves a floating product that looks obviously composited. Preserving shadow and reflection from the original image keeps the grounded look, so the final shot reads as 'shot in this environment' rather than 'cut out and pasted.' That difference is most of what separates studio from DIY product photos.

⚙️ How it works

  1. Segment the product with SAM or a foreground matting model — get an alpha mask. 2. Separately extract the ground-shadow layer using a soft threshold below the product's bounding box. 3. Reflect detection: if the product sits on a reflective surface, isolate the reflection via vertical mirroring + opacity estimation. 4. Composite: new background at the bottom, reflection layer with multiplied alpha, shadow layer with multiply blend, product at the top. 5. Color-grade the product subtly to match the new background's ambient palette.

Description

Input: a product photo + a target background (palette, color, or reference image). Output: the product composited onto the new background with shadow and reflection preserved from the original, so the shot still looks like it was taken in that environment rather than pasted onto it.

Install this skill

A Claude skill is a skill.md file with YAML frontmatter and a markdown body. Drop the file into your tool of choice — or pick a different format if you use Cursor, Windsurf, Copilot, or something else.

Download skill.md
mkdir -p ~/.claude/skills/product-shot-background-swap \
  && curl -L https://aidiveforge.com/skill/product-shot-background-swap.skill-md \
       -o ~/.claude/skills/product-shot-background-swap/skill.md

Save to ~/.claude/skills/product-shot-background-swap/skill.md

Recommended Use

Tools and workflow packs this skill pairs well with. Forge picks are auto-generated from category + capability signals; Community picks are added by people who've used the pairing.