Gimp-Forum.net
assistance needed creating gif - Printable Version

+- Gimp-Forum.net (https://www.gimp-forum.net)
+-- Forum: GIMP (https://www.gimp-forum.net/Forum-GIMP)
+--- Forum: General questions (https://www.gimp-forum.net/Forum-General-questions)
+--- Thread: assistance needed creating gif (/Thread-assistance-needed-creating-gif)



assistance needed creating gif - echoMOTN - 06-25-2018

Greetings, all. I'm familiarizing myself with this software but experiencing a problem creating a gif, or rather, exporting it. I've captured a part of game and created a gif with another program. I opened the gif with GIMP and I went through each frame to erase the background and leave transparency in its absence. Now, when I export, all the layers are shown when the gif is viewed, one after the next. I want the previous frames to become hidden when the next one is displayed. I've toyed with all the options in the export settings and cant seem to find a solution. any advice? xcf project file is available here:
https://nofile.io/f/wVgVCsOMR2e/Next+Level+HD+Taunt.xcf
thanks in advance!


RE: assistance needed creating gif - Ofnuts - 06-25-2018

When you export as a GIF, and once you have clicked "As animation" you have a bunch of options. One of them is "Frame disposal where unspecified", make sure it is set to "On frame per layer (replace)".

Alternatively you can rename each frame with a name that ends with (replace) (including the parentheses).

Another option is to use Filters>Animation>Optimize (for GIF). This restricts layers to the minimum neceesary to carry chnages between frames, using either replace or combine. The resulting GIF is usually smaller.

Also, don't be surprised if you discover that your animation has jagged edges, this is due to the lack of partial transparency in the GIF format (and may explain why your initial GIF has a background).


RE: assistance needed creating gif - rich2005 - 06-25-2018

Not going to be as easy as you hope. The xcf file has been heavily optimised.
example: frame 72 original https://i.imgur.com/UGqesYK.jpg
and does not un-optimise Filters -> Animation -> Unoptimise to what was probably the original frames.
example: frame 72 un-optimised: https://i.imgur.com/tIXvZcH.jpg

Looks like sometime, the frames under, were merged. No point using replace frames with this one. The damage has been done.
You could go round frame by frame (start at the top of the stack and work down) and erase unwanted bits. A rough-and-ready top 15 frames - not doing 74 fames. https://i.imgur.com/NSrAhjk.gif but will be a labour-of-love Wink

Quote:I've captured a part of game and created a gif with another program

What was the original capture - a video? Not knowing what 'other program' is but maybe avoid it in the future. Might be easier to start again.


RE: assistance needed creating gif - echoMOTN - 06-25-2018

(06-25-2018, 09:25 AM)rich2005 Wrote: Not going to be as easy as you hope. The xcf file has been heavily optimised.
example: frame 72 original https://i.imgur.com/UGqesYK.jpg
and does not un-optimise Filters -> Animation -> Unoptimise to what was probably the original frames.
example: frame 72 un-optimised: https://i.imgur.com/tIXvZcH.jpg

Looks like sometime, the frames under, were merged. No point using replace frames with this one. The damage has been done.
You could go round frame by frame (start at the top of the stack and work down) and erase unwanted bits. A rough-and-ready top 15 frames - not doing 74 fames. https://i.imgur.com/NSrAhjk.gif but will be a labour-of-love Wink

Quote:I've captured a part of game and created a gif with another program

What was the original capture - a video? Not knowing what 'other program' is but maybe avoid it in the future. Might be easier to start again.

original capture created a gif directly from an area selected on my screen. the utility i used for this was LICEcap.
and for reference, the original gif is available here > https://nofile.io/f/EmKySo1x9DR/Next+Level+original.gif
you are correct about being unable to use the replace frames option; it ends up looking terrible.
what i find most confusing about this is that if i take the original file ^ and open with gimp, export it straight away without editing, using the "i dont care" option for how the frames are handled, the result turns out just fine. perhaps something i did during my editing process caused it to become broken?


RE: assistance needed creating gif - rich2005 - 06-26-2018

(06-25-2018, 09:12 PM)echoMOTN Wrote: original capture created a gif directly from an area selected on my screen. the utility i used for this was LICEcap.
and for reference, the original gif is available here > https://nofile.io/f/EmKySo1x9DR/Next+Level+original.gif
you are correct about being unable to use the replace frames option; it ends up looking terrible.
what i find most confusing about this is that if i take the original file ^ and open with gimp, export it straight away without editing, using the "i dont care" option for how the frames are handled, the result turns out just fine. perhaps something i did during my editing process caused it to become broken?

Looks like you did a good job of removing the background from the original gif but you did not un-optimise it first. You do need the original background for that.

Once it is un-optimised, and mode set to RGB you can bulk remove the background with a script. c2a-all-layers.scm (applies color-to-alpha to visible layers)

The background is not black. It has a touch of blue in it. Makes the edited layers very transparent. You can add that back in, reasonably successfully, with another script sg-combine-bg.scm

My attempt, as a video. 7 minutes - a long one for me. There will be other ways / other scripts and plugins.





direct link. https://youtu.be/EjX5CN1aLSo

Where to get the scripts
c2a-all-layers.scm is in the zip here: https://www.gimp-forum.net/Thread-How-to-extend-an-Image-from-side-to-side-softening-the-hard-edge-of-image?pid=2609#pid2609

Get sg-combine-bg.scm from http://chiselapp.com/user/saulgoode/repository/script-fu/wiki?name=sg-combine-bg

if you want to inspect the gif I got it is here: https://my.pcloud.com/publink/show?code=XZqI6f7Z6Jmi0oyjQGjjvSQk39rjBhObnQAV about 5 MB