←back to thread

A new PNG spec

(www.programmax.net)
614 points bluedel | 2 comments | | HN request time: 0s | source
Show context
joshmarinacci ◴[] No.44378719[source]
A fun trick I do with my web based drawing tools is to save a JSON representation of your document as a comment field inside of a PNG. This way the doc you save is immediately usable as an image but can also be loaded back into the editor. Also means your downloads folder isn’t littered with unintelligible JSON files.
replies(12): >>44379250 #>>44379645 #>>44379652 #>>44379867 #>>44379992 #>>44380435 #>>44380543 #>>44380616 #>>44380678 #>>44380701 #>>44380930 #>>44384671 #
1. shiryel ◴[] No.44380435[source]
That is also how Krita stores brushes. Unfortunately, that can cause some unexpected issues when there's too much data [1][2].

[1] - https://github.com/Draneria/Metallics-by-Draneria_Krita-Brus...

[2] - https://krita-artists.org/t/memileo-impasto-brushes/92952/11...

replies(1): >>44380667 #
2. oakwhiz ◴[] No.44380667[source]
If a patch is needed for libpng to get around the issue, maybe Krita should vendor libpng for usability. It's not unreasonable for people to want to create gigantic files like this.