vichan-devel / vichan

Vichan is the most popular and widely used imageboard software in the world. It is a free, light-weight, fast, highly configurable and user-friendly imageboard software package.
https://vichan.info
Other
619 stars 194 forks source link

animated .webp images error when uploaded #672

Open RealAngeleno opened 6 months ago

RealAngeleno commented 6 months ago

Failed to resize image! Details: gm convert: No data returned (/tmp/phpotgB36).

There are a lot of ways to fix this all in /inc/image.php but unsure of the best way to do so.

crazy4cars69 commented 6 months ago

why even implement it? .gif is used for animated images and so can .png too. Also didn't webp recently have CVE exploit to track users who viewed .webp image?

Zankaria commented 6 months ago

.gif has a limited color palet and .webp supports better lossless compression than png. As for CVEs, have there ever been an image which has never suffered an exploit?

perdedora commented 4 weeks ago

I was able to generate animated webp using ffmpeg, it's not ideal but works. Apparently convert support resize, tested on my machine and it works. Going to give a try later in image.php https://github.com/ImageMagick/ImageMagick/issues/6351#issuecomment-1574154628

convert source.webp -coalesce -resize WxH destination.webp

crazy4cars69 commented 3 weeks ago

.webpshit is worthless, return to tradition(aka .gif).

Zankaria commented 3 weeks ago

.webpshit is worthless, return to tradition(aka .gif).

.gif has a limited color palet and .webp supports better lossless compression than png.

perdedora commented 3 weeks ago

.webpshit is worthless, return to tradition(aka .gif).

Since all major browsers supports it, I've changed our thumbnails and static files to webp. Webp + lazy loading made a huge difference in speed. And on the plus size: file size are smaller and no loses in quality.

perdedora commented 3 weeks ago

I was able to generate animated webp using ffmpeg, it's not ideal but works. Apparently convert support resize, tested on my machine and it works. Going to give a try later in image.php ImageMagick/ImageMagick#6351 (comment)

convert source.webp -coalesce -resize WxH destination.webp

Yeah, it worked but with a few tweaks tho