Decode and Encode PNG chunks