mc: Make sure to convert PNG images

Signed-off-by: Jakob Bornecrantz <wallbraker@gmail.com>
math: Make sure that PNG images has the right amount of channels

Signed-off-by: Jakob Bornecrantz <wallbraker@gmail.com>
math: Verify PNG image store size

Signed-off-by: Jakob Bornecrantz <wallbraker@gmail.com>
util: Clean up PNG code a bit

Signed-off-by: Jakob Bornecrantz <wallbraker@gmail.com>