Resizes images to a maximum dimension of 1024px