Hacker News new | past | comments | ask | show | jobs | submit login
BPG Image Format Specification (bellard.org)
86 points by fezz on Nov 20, 2015 | hide | past | favorite | 32 comments




Very nice image comparison! I'm pretty impressed with the very low-end settings of this codec compared to JPEG. I put JPEG on "Large" and BPG on "Tiny" and honestly, the results were pretty close. Nowhere near as bad as JPEG set to tiny. And surprisingly, no banding in large smooth gradients like with JPEG.


I wonder if that's simply a debanding filter on decode.


debanding filter is required by h264. probably the same for h265.


I love the way BPG is able to retain textures while eliminating JPEG block artifacts. For the first picture, check the guy on the left, his ropes and eyebrows.


Vs. JPEG, you need 3/5 the size for the same image quality (personnal, subjective assesment).

That's impressive.


This made me look up https://en.wikipedia.org/wiki/Fabrice_Bellard. Creator of FFmpeg and QEMU. And quite a few other accomplishments. Impressive.


Fabrice is a wizard no doubt!


He is the kind of really smart guy who makes code that looks obvious when you read it. BPG compiles smoothly, the code base is easy to understand. And that's also the brilliant part of it.


I knew I'd seen that name before.

http://bellard.org/jslinux/


Related: http://flif.info/ (a different new image format)


I love that the flif format is totally free, which seems to be the main painpoint here with BPG. However:

1) It doesn't seem very compelling without lossy compression. Moreover, the recommended way to get a lossy version is to use `dd` on a flif file...

2) Even in the FLIF examples, BPG always looks the best: http://flif.info/example.html strikingly so.

This makes me think that, even if using HEVC is a bad idea, reusing video codecs might be a rich source of innovation for image compression.


Now that all the browser makers (except Apple) are on board for a royalty free video codec based on VP10/Daala/Thor tech, I would be surprised if they didn't re-use the same tech and patents to create a next-gen web image format.


It's not totally free. It's bound to the GPLv3 and thus has no chance of being included into any standard browser.


Thats the code's licence, not the file format's, so they'd only need to write a decoder (or ask that the decoder be re-licensed).


There's no specification, so you would have to do a clean room reimplementation.


> reusing video codecs might be a rich source of innovation for image compression

As in WebP?


While the results are interesting, being able to reuse a hardware HEVC decoder on a phone is a compelling reason to adopt BPG (if one adopts a new image format at all).


Using the hardware decoder requires creating a new decoder for each size of image you're decoding, and round-trip latency to get the frame back and do compositing on the web page. In addition, most hardware decoders have a limited number of decode contexts available, forcing the decodes to be serialized. Not a great prospect for an average website with tens to hundreds of images.


Re-using HEVC has very real legal implications. Which will hinder any mainstream adoption.


Was it ever sorted out if using this format was likely to get you sued by HEVC patent owners?


You will need at least two licenses, one from MPEG-LA and one from HEVC Advance. MPEG-LA publishes a list of patents so you can see if there are any covering your country. In addition, HEVC Advance also licenses based on the total revenue your content generates for your website.

tl;dr yes, if you don't pay for licenses for all of the required patents.


TL;DR, maybe! From the main BPG website:

Licensing

...

Some of the HEVC algorithms may be protected by patents in some countries (read the FFmpeg Patent Mini-FAQ for more information). Most devices already include or will include hardware HEVC support, so we suggest to use it if patents are an issue.

http://bellard.org/bpg/


>hardware HEVC support, so we suggest to use it if patents are an issue.

This will not save you from the HEVC Advance content fees, which are a percentage of your website's total revenue related to the images.


So, for websites that do not charge -- it is zero ? (ex. wikipedia)

If so, almost sounds like the reason to use it on free websites, so paid for ones do not steal your images


Is it a free format? Or patent encumbered? It mentions H.265...


It's based on HEVC which means that many of the patents that cover HEVC will cover BPG.


This guy is a freakin genius. I think last time I was on his site he had published a full working LTE stack.


I'm about 99% sure that Fabrice handwrote the html on his main page for BPG: http://bellard.org/bpg/

The bold choice of 0 CSS just gives this idea even more credibility than it already had.


Is writing HTML by hand weird? I've been doing so for all my personal sites since 1995 and I haven't needed to do anything differently yet.


Your comment has to be a joke.


Am the only one who was expecting something network related, just for a second?




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: