Quick code to slice up an image into pieces based on coords