I'm trying to understand how data are stored into IDAT chunk. I'm writing a little PHP class and I can retrieve most of chunks information but what I get for IDAT doesn't match pixels of my image :
It is 2×2px truecolour with alpha (bitdepth 8).
But when I interpret IDAT data like this:
I don't understand how it can match pixels. Or is it my code which corrupts data?
Thanks for your help!
EDIT: I get
as hex compressed data, so it seems I loss several bytes after uncompressing.