Open shinebay opened 6 years ago
Yes this repo is what you found in the steemit post. But I'm not actively studying WebAssembly anymore, I can't give you the answer for the first question, sorry. The answer for the second question is that you need to wait few milliseconds before using Gifsicle class. Because Gifsicle class downloads(fetch) wasm file in async manner internally. Thank you
@appetizermonster thank you for your instant reply, I just wonder how can I pass the parameters to gifsicile.js?
var gifsicle = new Gifsicle(reader.result,{arguments:['-O3','--lossy=80']});
but it doesn't compress the gif, only output the original gif without any compression
I remembered that I modified c source file and inserted hard-coded arguments in the source file. and it worked.
FYI, the WebAssembly version of Gifsicle was very slow when I built, because Gifsicle is using recursive call very intensively but recursive call is very slow in WebAssembly for now.
Hello, I find this article in steemit: https://steemit.com/kr-dev/@heejin/c-c-webassembly, I guess this "tinygif" maybe refer to the article, but it doesn't has any compiled javascript in "tinygif", so I follow your article step by step(I am just a newbie in emscripten), but there are 2 problems:
what is code in setTimeout function? can you give us some demo code? thank you very much:)