-
🦎 @milohaxAuthor OwnerThis was "vibe-coded" using GitLab Duo Chat. Here's the prompt that I gave it:
help me write a GIMP script to put a white border around the outline of a picture that has a transparent background, so that it's outline is visible when placed on a dark background.
The basic approach that I see is
- add a layer for the image, with a transparent background
- move the image into that layer, from the default layer
- Select all the image that is not the transparent background
- scale the sellection some specified number of pixels larger
- Add a new layer for the outline, with a transparent background
- in the new layer fill the selection with white
- Reverse the layers so that the white border is behind the original image
Edited by MikeL -
🦎 @milohaxAuthor OwnerYou can see an example result:
-
java_duke_waves.xcf
Is a GIMP image with the layers that were created by the script -
java_duke_waves.png
is the final image exported to PNG, so that GitLab can render it in this snippet
-
Please register or sign in to comment