logoalt Hacker News

A new PNG spec

389 pointsby tbillingtontoday at 3:54 AM138 commentsview on HN

Comments

poisonborztoday at 10:11 AM

Not backwards compatible. We just add it to that nice cupboard "great advanced image formats we will forget about".

Society doesn't need a new image format. I'd wager to say not any new multimedia format. Big corporate entites do, and have churning them out at a steady place.

Look at poor webp - a format pushed by the largest industry players - and the abysmal everyday use it gets, and the hate it generates.

show 2 replies
qwertoxtoday at 5:19 AM

> Officially supports Exif data

Probably the best news here. While you already can write custom data into a header, having Exif is good.

BTW: Does Exif have a magnetometer (rotation) and acceleration (gravity) field? I often wonder about why Google isn't saving this information in the images which the camera app saves. It could help so much with post-processing, like with leveling the horizon or creating panoramas.

show 3 replies
albert_etoday at 5:09 AM

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.

show 6 replies
ggmtoday at 5:26 AM

Somebody needs to manage human time/date approximates in a way other people in s/w will align to.

"photo scanned in 2025, is about something in easter, before 1940 and after 1920"

show 2 replies
LeoPantheratoday at 5:06 AM

> I know you all immediately wondered, better compression?. We're already working on that.

This worries me. Because presumably, changing the compression algorithm will break backwards compatibility, which means we'll start to see "png" files that aren't actually png files.

It'll be like USB-C but for images.

show 6 replies
LegionMammal978today at 5:06 AM

Reading the linked blog post on the new cICP chunk type [0], it looks like the "proper HDR support" isn't something that you couldn't already do with an embedded ICC profile, but instead a much-abbreviated form of the colorspace information suitable for small image files.

[0] https://svgees.us/blog/cICP.html

Dwedittoday at 7:42 AM

If you wanted better compression, it's called Lossless WEBP. Lossless WEBP is such a nice codec. Compared with Lossless JXL, it decompresses many times more quickly, and while JXL usually produces a smaller file, it doesn't always.

Lossless AVIF is not competitive.

However, lossless WEBP does not support indexed color images. If you need palettes, you're stuck with PNG for now.

show 2 replies
adgjlsfhk1today at 5:17 AM

I'm very curious to see how this will end up stacking up vs lossless jpegxl

show 1 reply
iliketrainstoday at 7:01 AM

Official support for animations, yes! This feels so nostalgic to me, I have written an L-system generator with support for exporting animated PNGs 11 years ago! They were working only in Firefox, and Chrome used to have an extension for them. Too bad I had to take the website down.

Back then, there were no libraries in C# for it, but it's actually quite easy to make APNG from PNGs directly by writing chunks with correct headers, no encoders needed (assuming PNGs are already encoded as input).

https://github.com/NightElfik/Malsys/blob/master/src/Malsys....

https://marekfiser.com/projects/malsys-mareks-lsystems/

show 1 reply
snickerbockerstoday at 8:01 AM

It was gone??? Was I the only one using it this entire time?

hrydgardtoday at 7:07 AM

What about implementations? libpng seems pretty dead, 1.7 has been in development forever but 1.6 is still considered the stable version. Is there a current "canonical" png C/C++ library?

b0a04gltoday at 7:25 AM

it's more to do with the obvious economic layer underneath. you give a format new life only if there's tooling and distribution muscle behind it. adobe, apple, chrome, ffmpeg etc may not get aligned at the same time. someone somewhere wants apng/hdr/png to be a standard pipe again for creative chains; maybe because video formats are too bulky for microinteraction or maybe because svg is too unsafe in sandboxed renderers. and think onboarding of animations, embedded previews, rich avatars, system wide thumbs ; all without shipping a separate codec or runtime. every time a 'dead' format comes back, it's usually because someone needed a way around a gate

tonyedgecombetoday at 6:36 AM

>After 20 years of stagnation, PNG is back with renewed vigor!

After 20 years of success, we can't resist the temptation to mess with what works.

show 1 reply
jbverschoortoday at 6:53 AM

What if we kind of fit JXL in PNG? That way it's more likely to be supported

meindnochtoday at 8:35 AM

Parallel compression/decompression is already possible via Z_SYNC_FLUSH.

nektrotoday at 6:31 AM

cautiously optimistic. the thing that makes png so sought after is its status as frozen

guilbeptoday at 7:16 AM

Let's call it PPNG: Pas Portable NetWork Graphic

defraudbahtoday at 7:13 AM

this is good news, any packages who support new png standard or planning to? rust/go/python/js?

kumarvvrtoday at 5:55 AM

Never heard about Animated PNGs, and I am a nerd to the core.

Pleasantly surprised.

sylwaretoday at 9:09 AM

Until everything new is "optional". Hopefully PNG won't be the target of "enshitification". We all know that for file formats, there is a very strong pressure from developers and vendors for that to happen since it favors, hard, vendor and developer lock-in. If not careful, even with a team of PHD devs won't be able to write alternatives encoders/decoders that "reasonbly" and the world will end-up with very few alternatives implementations, if not only one.

I did skim through the specs, it seems most of it is related to cleanup and optional blocks, so it seems PNG is still safe, am I wrong? (asking those who did dive into the new specs deeply).

neepitoday at 7:25 AM

Oh no another HEIC!

Joel_Mckaytoday at 6:05 AM

DaVinci Resolve also supports OpenEXR format with the added magic of LUT.

PNG is popular with some Commercial Application developers, but the exposure and color problems still look 1980's awful in some use-cases.

Even after spending a few grand on seats for a project, one still gets arrogant 3D clown-ware vendors telling people how they should run their pipeline with PNG hot garbage as input.

People should choose EXR more often, and pick a consistent color standard. PNG does not need yet another awful encoding option. =3

show 1 reply
antireztoday at 9:21 AM

PNG: doing very little with as much complexity as possible.

show 1 reply