WebP Rewind
2010-2020
Happening now!
How did we get there?
Happening now!
Story time!
Let’s get back to around 2009
See the problem?
Image credit: VersionMuseum
And it got worse...
Image credit: Imgur (in WebP format!)
The idea
2010 : On2 acquisition, VP8 released
VP8 is here for video, let’s use it for image.
The idea
2010 : On2 acquisition, VP8 released
VP8 is here for video, let’s use it for image.
It’s there anyway. It’s free. Users’ interest first .
Support - History [ caniuse ]
|
2010 |
2011 |
2012 |
2013 |
2014 |
2015 |
2016 |
2017 |
2018 |
2019 |
2020 |
libwebp |
v0.1.2 |
v0.1.3 |
v0.2.1 |
|
|
|
|
|
|
|
|
Chrome Android |
|
9 4.0 |
23 4.3 |
|
|
|
|
|
|
|
|
Off we go!
Support - History [ caniuse ]
|
2010 |
2011 |
2012 |
2013 |
2014 |
2015 |
2016 |
2017 |
2018 |
2019 |
2020 |
libwebp |
v0.1.2 |
v0.1.3 |
v0.2.1 |
|
|
|
|
|
|
|
|
Chrome Android |
|
9 4.0 |
23 4.3 |
|
|
|
|
|
|
|
|
Opera* |
|
11.10 |
12.10 |
|
|
|
|
|
|
|
|
Fast forward to 2020...
Support - History [ caniuse ]
|
2010 |
2011 |
2012 |
2013 |
2014 |
2015 |
2016 |
2017 |
2018 |
2019 |
2020 |
libwebp |
v0.1.2 |
v0.1.3 |
v0.2.1 |
v0.3.1 |
v0.4.0 |
v0.4.4 |
v0.5.2 |
v0.6.1 |
v1.0.0 |
|
v1.1.0 |
Chrome Android |
|
9 4.0 |
23 4.3 |
32 |
|
|
|
|
|
|
|
Opera* |
|
11.10 |
12.10 |
|
19 |
|
|
|
|
|
|
UC browser |
|
|
|
|
|
|
12.12 |
|
|
|
|
MS-Edge |
|
|
|
|
|
|
|
|
18 |
|
|
Firefox |
|
|
|
|
|
|
|
|
|
65 |
|
Safari |
|
|
|
|
|
|
|
|
|
|
14 |
The blog-post
Trouble times
consolidation
maintenance
Support - History [ caniuse ]
|
2010 |
2011 |
2012 |
2013 |
2014 |
2015 |
2016 |
2017 |
2018 |
2019 |
2020 |
libwebp |
v0.1.2 |
v0.1.3 |
v0.2.1 |
v0.3.1 |
v0.4.0 |
v0.4.4 |
v0.5.2 |
v0.6.1 |
v1.0.0 |
|
v1.1.0 |
Chrome Android |
|
9 4.0 |
23 4.3 |
32 |
|
|
|
|
|
|
|
Opera* |
|
11.10 |
12.10 |
|
19 |
|
|
|
|
|
|
UC browser |
|
|
|
|
|
|
12.12 |
|
|
|
|
MS-Edge |
|
|
|
|
|
|
|
|
18 |
|
|
Firefox |
|
|
|
|
|
|
|
|
|
65 |
|
Safari |
|
|
|
|
|
|
|
|
|
|
14 |
The blog-post
Trouble times
consolidation
maintenance
Shout-out to lesser visible allies
CDNs (Akamai, Cloudflare, Cloudinary, …)
Mobile Apps (+Android Studio)
Mobile Game devs
Other formats? Busy decade(s)!
animated
still
images
Was it worth it?
The lossy case
Was it worth it?
Transfer
decode
JPEG
Not at scale!
Was it worth it?
Transfer
decode
JPEG
Transfer
decode
WebP
😎
Was it worth it?
Transfer
decode
JPEG
Transfer
decode
WebP
😎
Transfer
decode
WebP
incr.
user engagement be like...
😎
Athens, 2015
1 GB = 10 €
And most importantly
It was useful for transitioning into
optimized and responsive Web
cnn.com:
Lesson learnt
Early Errors
2010-2014
Lesson learnt
Early Errors
image/webp = ???
Lesson learnt
Early Errors
Hardware = meh
Lesson learnt
Nice surprises
Hindsight look-back
Image Codec
Vs
Video Codec
Digitalization of the World, circa 2000
2000
2020
“Capture”
“Web”
2020
Capture
“Web”
Video-image codec
“Web”
Alpha
Lossless
Thumbnail preview
Interruptibility
animation
Deploying at scale.
Deploying at scale.
The hardest is the first B users.
Deploying at scale.
Keep it simple and useful
FLEXIBILITY = LIABILITY
Deploying at scale.
open-sourced bulletproof implementation
offered royalty-free
speaking of which...
Contributors. Thanks!
- Aidan O'Loan
- Alan Browning
- Charles Munger
- Cheng Yi
- Christian Duvivier
- Djordje Pesut
- Hui Su
- James Zern
- Jan Engelhardt
- Jehan
- Johann Koenig
- Jovan Zelincevic
- Noel Gordon
- Oliver Wolff
- Owen Rodley
- Parag Salasakar
- Pascal Massimino
- Paweł Hajdan, Jr
- Pierre Joye
- Sam Clegg
- Scott Hancher
- Scott LaVarnway
- Scott Talbot
- Slobodan Prijic
- Jyrki Alakuijala
- Konstantin Ivlev
- Lode Vandevenne
- Lou Quillio
- Mans Rullgard
- Marcin Kowalczyk
- Martin Olsson
- Maryla Ustarroz
- Mikołaj Zalewski
- Mislav Bradac
- Nico Weber
- Somnath Banerjee
- Sriraman Tallam
- Tamar Levy
- Timothy Gu
- Urvang Joshi
- Vikas Arora
- Vincent Rabaud
- Vlad Tsyrklevich
- Yang Zhang
- Yannis Guyon
Or, is it?
WebP v2?
More of the same
why?
The world has changed.
Good connectivity and resource mindfulness are more critical than ever
why?
Service workers and WASM make it much easier to introduce codecs at scale
…. especially if you don’t rely on hardware.
WebP v2 - features and ideas
(still) keep it simple and useful
10b ought to be enough for everyone
Custom color space, not necessarily YCbCr
tight-fit the color transform matrix.
RGB Cube
Custom color space
Not that infrequent
Entropy coding: ANS everywhere
Software-friendly
Multi-symbol decoding
Adaptive probabilities
Full incremental / suspendable
GetNextByte() can exit the codec and return later
Full incremental / suspendable
Available bytes
Not-yet-received bytes
Stopping at rows:
Stopping anywhere:
Decoded bitstream
Left to do
Decoded bitstream
Left to do
No redo, no state
Next row of pixels
Redo Area
webp-v1
webp-v2
Floating partitioning
Arbitrary blocks
positions?
Multi-pass FTW
Floating partitioning
Big flat blocks first
(easy!)
Floating partitioning
“Directional” blocks
Floating partitioning
Same-variance blocks
Floating partitioning
Parsing order != decoding order
Strategy: try to maximize the left-sample availability
|
|
|
|
|
|
|
|
---|---|---|---|---|---|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1
4
2
8
5
3
6
7
Borrow building bricks from AV1/AV2
Transforms
Residuals coding
Filters (simplified, for still images)
Tiles
...
Lossless
More predictors
Improved color-caches
16bit-signed
Intra Block-copy
Lossy alpha mask
Lossy alpha mask
lossy/lossless mix
Lossy-coded
Lossless-coded
Previews
Cheap thumbnail using few vertices + triangulation + colormap
Previews
Squint! 3...2...1...
294 bytes
base64:AAGUcRsz9PysYqADOlisiFRXUn1aXEkX+if3GOxbD5+s/30apmYm1Ggr83TsVHpTeKRVFYY8YcHm8WO1PQL6R2t4wPBjO9MHs3YuQ7gX5Xj4xedOQp8PyBpCTC+r5NALt3M0kjLXAGIJTRQ1hHXy9SXwRfFvO0sjecQcigeOxUuxRWA9DV1bm7iRVlVZmEkMTt7vaqlICYX1kqg+3UVAVqiYGE79l8BrUxbdp27cyIuadtBWC6GQ20vkOvQvw8x10XS0ck1/1mltjIarkOifuXwohOKpfBmS5mxkSzPhGM+UzsgPVH/IYhcpLvG3+Z9MLFSxUVUv8V8ltbh9/COggOIoODp5YOURn4gbU7deUjg/YAZWGcJD/YFIE7S85yuWs8FWMp5C
Previews
ta-dah!
Decoder: ~300 lines of WebGL
Squoosh demo time!
https://squoosh.app/ (WASM power)
0.37bpp
q ~= 30
WebP
JPEG
WebP2
AVIF
Timeline
In 10 years?
Next week?
Thanks!
Questions?
mailto:skal@google.com
Extra stuff
~200-250 bytes
126 bytes
Extra stuff