Questions tagged [webp]

WebP is an open standard for image encoding. It is intended to provide support for animation, metadata, lossless compression, and transparency without the patent or license restrictions of existing formats.

WebP is a new image format that provides lossless and lossy compression for images on the web. WebP lossless images are 26% smaller in size compared to PNGs. WebP lossy images are 25-34% smaller in size compared to JPEG images at equivalent SSIM index. WebP supports lossless transparency (also known as alpha channel) with just 22% additional bytes. Transparency is also supported with lossy compression and typically provides 3x smaller file sizes compared to PNG when lossy compression is acceptable for the red/green/blue color channels.

754 questions
2
votes
1 answer

How to download and save Bitmap of animated webp?

When I am using webp files for animated sticker packs it get rejected but if use same files for static stickers it get excepted. After looking all the codes I came to know that this is the last point where those files becomes problematic. But don…
CrackerKSR
  • 1,380
  • 1
  • 11
  • 29
2
votes
2 answers

How to compress animated webp without converting it to static in java?

It seems that Bitmap compressions is making animated WEBP files static or something else that when I use them as animated stickers files I get an error from WhatsApp that there is a problem with this sticker pack. That error does not occur if I use…
UHS
  • 584
  • 4
  • 8
2
votes
1 answer

Chrome Isn't Using my WebP Source (But Should?)

I have the following HTML: When I use the Chrome developer tools to inspect the img, I can see it's not using the WebP image…
machineghost
  • 33,529
  • 30
  • 159
  • 234
2
votes
1 answer

Responsive images: Picture element using width and height of fallback tag when using AVIF/WEBP

I have a website that I have made responsive and utilise the element to serve up webp, avif and have a png fallback for older browsers. It should look like this (Chrome/Safari): For some reason, certain browsers (Firefox 94 on desktop and…
Myles Gray
  • 8,711
  • 7
  • 48
  • 70
2
votes
1 answer

'Serve images in next-gen formats' warning from Google PSI even after implementing different image formats

I've implemented the picture element with different image formats and a fallback image, but on Google PSI i'm still getting the warning to 'Serve images in next-gen formats' This warning is not being reported by Lighthouse which makes it very…
2
votes
0 answers

How to get the frame number of a webp format picture in browser

I tried to use libwebp, but found that it cannot decode multi-frame webp format pictures. Do you have any ideas?
darkmood
  • 21
  • 2
2
votes
2 answers
2
votes
1 answer

Does not work image optimization on an external website for @nuxt/image

Can't optimize images on the fly from a remote website. Example: // nuxt.config.js export default { image: { domains:…
Makhnov
  • 71
  • 1
  • 8
2
votes
0 answers

Make a png converter for webp images in Java

I wanted to make a png converter for webp images in Java, I tried to use multiple libraries for webp images but without success. My base code is this: String path = "C:\\Users\\matti\\Desktop\\eru webp\\01_(1).webp"; File input = new File…
LAC
  • 47
  • 5
2
votes
2 answers

Saved webp images are 3x bigger than jpg in OpenCV

For some reason, on my Ubuntu 20.04 machine when I use OpenCV in Python like: cv2.imwrite("myfile.webp", cv2image) in my code, the file of 800x600 px has about 300 KiB while if I do: cv2.imwrite("myfile.jpg", cv2image) the output file of the same…
kipkipe
  • 121
  • 2
  • 4
2
votes
1 answer

Trying to convert an MP4 to WEBP with ffmpeg with different lossless/compression settings, but getting the same result

I am trying to convert an MP4 video to WEBP. I am trying different -lossless and -compression_level settings (as described here https://ffmpeg.org/ffmpeg-codecs.html#Options-30), but all the output videos have identical disk size. -lossless can…
corgrath
  • 11,673
  • 15
  • 68
  • 99
2
votes
1 answer

Convert image file to webp on upload

Trying to write script which will convert image type (gif, jpeg, jpg,png) to webP in addition to uploading original file for fallback in browsers not supporting webP (earlier versions of Safari, etc.) In attempting to get this to work I have: built…
Monkeework
  • 97
  • 2
  • 11
2
votes
1 answer

Convert png to webp does not preserve transparency

Using the Google cwebp utility (https://developers.google.com/speed/webp/docs/cwebp) and the ImageMagick convert utility, I am unable to preserve transparency in png images when converted to webp. Using convert I've tried using alpha-compression=0…
jeffmcneill
  • 2,052
  • 1
  • 30
  • 26
2
votes
1 answer

Can I use different file types in srcset?

I'm trying to combine .jpg and .webp, but it doesn't work for me..
Lokix
  • 21
  • 1
2
votes
0 answers

Why does the Squoosh CLI rotate vertical pictures?

I used the Squoosh CLI in order to compress my several pictures from JPEG to WebP. However, some of the vertical pictures are somehow automatically rotated and become horizontal without my intent. Some of the horizontal pictures are not…