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

webm as gif format #36

Open
chapmanjacobd opened this issue May 1, 2020 · 4 comments
Open

webm as gif format #36

chapmanjacobd opened this issue May 1, 2020 · 4 comments

Comments

@chapmanjacobd
Copy link
Contributor

chapmanjacobd commented May 1, 2020

It might be more useful to generate webp for the gif format. Higher quality and lower size: https://gist.github.com/dreampiggy/52c658253de3ba22fd3dec4d3f3182ab

https://insanelab.com/blog/web-development/webp-web-design-vs-jpeg-gif-png/

I think it is still safe to use the .gif file extension and modern browsers will open it just fine

https://developers.google.com/web/fundamentals/performance/optimizing-content-efficiency/replace-animated-gifs-with-video

@mifi
Copy link
Owner

mifi commented May 6, 2020

Maybe we could do this if the output file has the extension .webp

@chapmanjacobd
Copy link
Contributor Author

chapmanjacobd commented May 6, 2020

maybe there is something that we can do to make the gif format more high quality, less dithering etc.
https://stackoverflow.com/questions/42980663/ffmpeg-high-quality-animated-gif

the commonFeatures.gif is only 7.7MB but I feel for 60sec of video we could do better if it were not "gif" gif format. I think the quality right now is a good compromise between size and quality but maybe we could have another not-gif but gif-like output format.

ahh I was mistaken. WebP is only for images. What I meant was WebM.

I tried to use webm as the file extension in commonFeatures (after replacing the assets with my own) but I get this error:

~/a/editly (master|✚1…) 🌭 node cli.js examples/commonFeatures.json5
720x1280 30fps
createFrameSource linear-gradient clip 0 layer 0
createFrameSource title clip 0 layer 1
createFrameSource radial-gradient clip 1 layer 0
createFrameSource title clip 1 layer 1
  0% [webm @ 0x55b2b8d052c0] Only VP8 or VP9 or AV1 video and Vorbis or Opus audio and WebVTT subtitles are supported for WebM.
Could not write header for output file #0 (incorrect codec parameters ?): Invalid argument
Error initializing output stream 0:0 -- 

I don't think it's my assets because when I use .mp4 it works fine

@chapmanjacobd chapmanjacobd changed the title webp as gif format webm as gif format May 6, 2020
@mifi
Copy link
Owner

mifi commented May 17, 2020

Yea, I think there are so many output formats people could want, that if editly is to support more formats, then I think the user should be able to set output arguments themselves: #27

mifi added a commit that referenced this issue Dec 8, 2020
@mifi
Copy link
Owner

mifi commented Dec 8, 2020

Have now implemented a way to set custom output args which can be used for webp. see example: https://github.com/mifi/editly/blob/master/examples/customOutputArgs.json5

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

No branches or pull requests

2 participants