Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

why are files so big? #3

Closed
nunodonato opened this issue Mar 14, 2016 · 6 comments
Closed

why are files so big? #3

nunodonato opened this issue Mar 14, 2016 · 6 comments
Labels

Comments

@nunodonato
Copy link

So I'm recording some tiny GIFs (around 400px wide) at 15fps, and still get big file sizes.
Twitter sets a limit at 5mb per gif, so I can never use a gif captured with Peek. Yet, I see constantly long gifs with good quality... whats the catch?

thanks for the awesome tool :)

@phw
Copy link
Owner

phw commented Apr 7, 2016

Sorry for the way too late reply :(

I can't really tell you why your file is so big without more information. What exactly is "big" and "long"?

In general ImageMagick is used to convert the animation to GIF and it does a very decent job in minifying the frames: Each frame will only contain the data that differs from the one before.

In general for animated GIFs there are a few rules to follow for good results:

  • Use a low framerate. 15fps seems to work quite well for me
  • Avoid too much change. If there is heavy animation the frames will differ a lot
  • Avoid too many colors, since GIF is limited to a 256 color pallette. This one is not so much about file size but more about visual quality.

Otherwise I'd need some real world comparison to tell you more, e.g. an animation you think is large and not so big and a comparable animation you recorded with peek which you consider too big.

@quentin-st
Copy link

I used to use ScreenToGif on Windows to record gifs: please know that I'm delighted there's a Linux alternative!

I used ScreenToGif to record the following gif (used in one of my projects' README):
screenshot

In order to compare file sizes, I recorded quite the same animation with Peek:
peek 2016-08-31 21-19

Even if these are not quite comparable, they are still based on the same filesize scale (framerate, colors amount, duration, "change rate"/animation speed).

Here's the conclusion: ScreenToGif produced a 58,2 kB file while Peek saved a 16,6 kB file. Peek wins!
Should this issue be closed? We could mention it somewhere in the documentation though, or lead some more tests

@phw
Copy link
Owner

phw commented Sep 1, 2016

Thanks @chteuchteu for doing this investigation. It is also my suspicion that Peek is already doing a nice job (thanks to imagemagick in this case) of reducing the file size. In the end Gif is just not well suited for doing large animations with a lot of changes, as the optimization completely depends on just having the differences in each frame. I lean toward closing this, but maybe we should have some kind of FAQ first :)

@quentin-st
Copy link

+1 for the FAQ!

phw added a commit that referenced this issue Feb 20, 2017
@phw
Copy link
Owner

phw commented Feb 20, 2017

I have added a FAQ to the README

@phw phw closed this as completed Feb 20, 2017
phw pushed a commit that referenced this issue Nov 14, 2017
@davidricardo1026
Copy link

ScreenToGif now is really small and peek is really large.
maybe There is a new optimization in ScreenToGif

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants