I have been looking for some PNGDecoder for a project I am working on, all was looking weird / complexe / dirty coded and hard to hunderstand, so last night and as often … I’ve decided to reinvent the well and to built my own
- it support the 4 filter type for filter method 0
- for now only decoding of RGB24 & RGB32 are implemented, but adding GREY & PALETTE one should be a kid game (5/6 code line more for each)
- it is based on high efficiency & low memory usage (also did not allocate tones of buffer)
- only critical chunks are decoded but extended should be pretty easy to add
even if it is a first shot and it still need some improvment, I have tried to make the code as clear as possible, and it may be of interrest to better understand PNG
NB : some object are missing as RGBArrayImage and Log but can be easily replaced
EDIT : please follow the thread post to get the lastest version