W
W
wawa2015-01-06 17:25:31
C++ / C#
wawa, 2015-01-06 17:25:31

How to unload an image from memory to a PNG file BYBYTE?

Due to the large size of the image, I can't fully load it into memory. Therefore, it is divided into tiles, which I load into memory, change them and unload them one by one . But at the end of processing, they need to be put together. But I can't find the code that saves to PNG line by line, and figuring out PNG specs is hell for me.
Please help with code or link. I'm just SURE that such code has been written more than once and is floating around the net somewhere.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
Don Kaban, 2015-01-07
@donkaban

1. If "understanding specs is hell for me" - change your profession
2. libpng operates with strings, obviously - www.libpng.org/pub/png/libpng.html, the examples there are exhaustive.
3. As you understand, packaging in png is a deterministic process, no one bothers you to first complete all your transformations, and then pack, buffer-> file, loading new lines into the buffer as necessary.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question