04-22-2021, 02:17 PM
(04-22-2021, 09:11 AM)denzjos Wrote: Ofnuts, 'ofn-brush-strokes-on-path', a nice script. Two problems : if I animate a scene in gimp, then the moving object is perfect blending out. When I export the animation to a gif file, then the blending out disappeard. What am I doing wrong in the workflow ? Second problem : how can I use a background (picture or photo) in the animation? I just can choose between white, background(colour), foreground(colour), pattern and transparent. I tried some things but I can't figure out how to do it. Thanks in advance for the answer.
The exported gif file :
As seen in the animation in gimp:
Gif export settings I used :
In a GIF (and the color-indexed mode in Gimp) the opacity of pixels in layers/frames is binary so anything under 50% becomes transparent when you export to GIF.
In my own animations, I do the animation in RGB mode, and the object and its fading copies are put on a fully opaque background so all layers are fully opaque when I create the GIF. This isn't much of a problems because in my animation the layers are in a solid color almost everywhere so they compress well. Over a real picture, I would expect Filters ➤ Animation ➤ Optimize (for GIF) to be quite efficient.
Technically, for a 3-steps fade:
- Create the N frames of the animation, with fully opaque object on transparent background (stack image)
- Use ofn-interleave-layers to copy the frames of Stack at 100% opacity over a solid background, yielding Image1
- In Stack, move the top layer to the bottom
- Use ofn-interleave-layers to copy the frames of Stack at 75% opacity over the frames in Image1, yielding Image2. Image1 can be discarded.
- In Stack, move the top layer to the bottom
- Use ofn-interleave-layers to copy the frames of Stack at 50% opacity over the frames in Image2, yielding Image3. Image2 can be discarded.
- In Stack, move the top layer to the bottom
- Use ofn-interleave-layers to copy the frames of Stack at 25% opacity over the frames in Image3, yielding Image4. Image3 can be discarded.
- Export Image4 as your animation.