All done, but with bugs. Size recovers fine, but for some reason the image is weird
Some fixes. Not segmentation fault anymore. And color order fixed