←back to thread

A new PNG spec

(www.programmax.net)
616 points bluedel | 2 comments | | HN request time: 0.401s | source
Show context
albert_e ◴[] No.44373786[source]
So animated GIFs can be replaced by Animated PNGs with alpha blending with transparent backgrounds and lossless compression! Some nostalgia from 2000s websites can be revived and relived :)

Curious if Animated SVGs are also a thing. I remember seeing some Javascript based SVG animations (it was a animated chatbot avatar) - but not sure if there is any standard framework.

replies(10): >>44373806 #>>44373868 #>>44374146 #>>44374225 #>>44374312 #>>44374556 #>>44374786 #>>44376132 #>>44379316 #>>44385628 #
riffraff ◴[] No.44373868[source]
I was under the impression many gifs these days are actually served as soundless videos, as those basically compress better.

Can animated PNG beat av1 or whatever?

replies(6): >>44374218 #>>44374256 #>>44374550 #>>44374739 #>>44375571 #>>44385655 #
armada651 ◴[] No.44374550[source]
> Can animated PNG beat av1 or whatever?

Animated PNGs can't beat GIF nevermind video compression algorithms.

replies(2): >>44374811 #>>44374952 #
1. jeroenhd ◴[] No.44374811[source]
Once you add more than 256 different colours in total, GIF explodes in terms of file size. It's great for small, compact images with limited colour information, but it can't compete with APNG when the image becomes more detailed than what you'd find on Geocities.
replies(1): >>44378383 #
2. pornel ◴[] No.44378383[source]
No, APNG explodes in size in that case.

In APNG it's either the same 256 colors for the whole animation, or you have to use 24-bit color. That makes the pixel data 3 times larger, which makes zlib's compression window effectively 3 times smaller, hurting compression.

OTOH GIF can add 256 new colors with each frame, so it can exceed 256 colors without the cost of switching all the way to 16.7 million colors.