'libpng', converting a PNG file from grayscale to RGB (to just one of the channels)
I have a piece of source code that reads and writes images to PNG files. However, it only writes the images as grayscale, precisely just black and white.
Now, how do I modify it such that it would write to one of the channels in RGB (R or G or B is fine)?
Is there a short tutorial about that pixel开发者_如何学Go manipulation with libpng?
It isn't small or nice written tutorial, but always something:
http://www.libpng.org/pub/png/libpng-1.2.5-manual.html
精彩评论