Home (All Topics) → Technology → Software → AI-Created Software
By Marios Alexandrou on September 9, 2026.
The following AI-generated aka vibe-coded software. The software is specific to my needs and my system and may not work for you or your system. Support is limited, but if you report a bug I'll certainly look into it. All code is provided in a zip file for you to review should you choose.
A desktop GUI tool for blending two images together — a “before” and an “after” — using a grayscale mask to control where the blend happens, and a slider to control how much. White areas of the mask reveal the after image, black areas keep the before image, and gray areas blend proportionally.
Typical uses: before/after photo edits, retouching comparisons, texture or terrain blending, compositing two renders, or any situation where you want to dial in a spatially-varying crossfade between two images and inspect the result at full resolution.
sudo apt install python3-tk)Optionally, to enable dragging files onto the window:
Without it the app works normally — it just won’t accept dropped files.
You can also drag and drop files onto the window (with tkinterdnd2 installed). Dropped images fill the Before, After, and Mask slots in that order; if all three are already loaded, you’ll be asked which slot to replace. Dropping a .ibwmproj file opens that project.
None of the three images need to be the same pixel size — each is resized as needed depending on which one you’re currently viewing at full resolution (see Zoom and viewing modes below).
B key at any time to momentarily see the pure before image, and release to return to the current blend. This never affects what gets saved or exported.
A readout directly below the image shows, for whatever pixel is under the cursor: its coordinate in the working image, the before and after RGB values, the mask value (as both 0–255 and a percentage), and the resulting blended RGB value. This is the quickest way to answer “what is the mask actually doing here?” without guessing from the overlay.
Mask Tools… (also under the Mask menu) opens a panel of non-destructive adjustments. Everything updates the preview live, and none of it modifies your mask file on disk:
All mask adjustments are saved into (and restored from) project files.
Save Project… creates a self-contained project folder:
result.png, at the before image’s native resolution.<name>.ibwmproj, JSON), recording the source paths, slider position, zoom mode/level, and all mask adjustments.A before image must be loaded to save a project, since its filename drives the folder name.
By default source files are symlinked (with a hardlink fallback on systems where symlinks aren’t permitted), which keeps project folders tiny. But links break the moment the folder moves to another machine or drive.
Enable File → Portable export (copy files instead of links) to write real copies instead. A portable project folder can be moved, archived, or handed to someone else and still opens correctly — the loader falls back to files sitting beside the project file when the originally recorded paths no longer exist. The setting persists between sessions.
If your mask was generated from difference rather than loaded from disk, it’s written into the project folder as generated_mask.png so the project stays reproducible.
Load Project… reopens a .ibwmproj file: it reloads the before, after, and mask images and restores the slider, zoom, and every mask adjustment. File → Recent Projects lists the last 10 projects you saved or opened.
Reload Images and Mask re-reads all three images from their current paths — useful when another application has just re-saved one of them. The slider, zoom, pan position, mask adjustments and overrides are all left untouched; only the pixel content refreshes.
File → Auto-reload when files change on disk turns this into a live link with your image editor: the app polls the source files once a second and reloads automatically when any of them changes.
Combined with an editor on a second monitor, you can tweak a mask and watch the blend update without touching the app.
File → Export Image… writes the current blend with a choice of:
File → Export Slider Sweep… renders a series of frames stepping the slider across a range, for demonstrating an edit:
The app remembers its window size, position, and maximized state between sessions, saved to image-blender-with-mask.ini next to the script itself. If that file is missing or unreadable, it just falls back to a default window size.
A .ibwmproj file is plain JSON:
{
"format": "image-blender-with-mask-project",
"version": 3,
"before_image": "/absolute/path/to/before.png",
"after_image": "/absolute/path/to/after.png",
"mask_image": "/absolute/path/to/mask.png",
"generated_mask": null,
"slider_value": 42.5,
"zoom_mode": "fit",
"zoom_percent": 76.0,
"portable": true,
"mask_settings": {
"channel": "Luminance",
"invert": false,
"black_point": 0.0,
"white_point": 255.0,
"threshold_enabled": false,
"threshold": 128.0,
"feather": 0.0
},
"overlay": { "color": "Red", "opacity": 50.0 }
}
Any of the three image fields may be null if that image wasn’t loaded when the project was saved. generated_mask names a mask file written into the project folder when the mask came from Generate from Difference rather than from disk.
tkinterdnd2 package. Everything else works without it.

Leave a Reply