Factored out function to convert heightmap to greyscale.
Interface change to make-heightmap.