Fixed the array problem, mixed up y x coordinates for BufferedImage sub image.