-
Notifications
You must be signed in to change notification settings - Fork 11
RunningOnWindows
Running TopoMC under Windows is not supported. That being said, this is what I did and it worked for me.
I installed the 64-bit version of Python 2.7.3 from http://www.python.org/getit/ to match my 64-bit version of Windows 7. I then went to http://www.gisinternals.com/sdk/ where I clicked on "release-1600-x64-gdal-1-9-1-mapserver-6-0". This page contains links for GDAL itself (gdal-19-1600-x64-core.msi) and for the Python bindings (GDAL-1.9.2.win-amd64-py2.7.msi), both of which I installed.
At this point I modified the Path variable to contain the locations of GDAL, Python, and the Python scripts directory -- C:\Program Files\GDAL;C:\Python27;C:\Python27\Scripts got stuck at the end of the existing variable.
I went to http://www.lfd.uci.edu/~gohlke/pythonlibs/ for most of the remaining dependencies, including numpy-MKL, scipy, pywin32, and pyyaml.
I downloaded ez_setup.py from http://peak.telecommunity.com/dist/ez_setup.py and ran it in order to install easy_install. I then used easy_install to install suds, since it's not available from LFD. This is done by the command "easy_install suds" from within the Windows command shell.
Now that GDAL, Python, and all their dependencies are installed, I installed GitHub for Windows from http://windows.github.com/ which included a Powershell install. Once that install completed, I visited the web page https://github.com/mathuin/TopoMC and clicked the 'Clone in Windows' button. Once the clone finished, I opened the Powershell (right-click on the repository, select 'open a shell here') and ran the following commands:
- git checkout develop
- git submodule init
- git submodule update
These commands switch to the develop branch (the most recent code with all the fixes), initialize the submodules (currently just pymclevel), and update those same submodules (checking out the proper version of pymclevel).
At this point TopoMC is ready to roll. From this same shell, try the following commands:
- python ./GetRegion.py --name Provincetown --ymax 42.0901 --xmin -70.2611 --ymin 42.0091 --xmax -70.1100
- python ./PrepRegion.py --name Provincetown
- python ./BuildRegion.py --name Provincetown
The USGS is having trouble with their servers, so ./GetRegion.py isn't working. I have a trouble ticket with them and hope they get it fixed soon!
When the scripts are run, an error message is displayed:
ERROR: The system was unable to find the specified registry key or value.
This message appears to be innocuous. Additionally, ./PrepRegion.py may cause two error windows to appear with titles like this:
gdalwarp.exe: No Disk
and saying something about not seeing a CD or something. Click 'Continue' and all should be well.
Once the third script is complete, use Windows Explorer to cruise around the Regions directory. It should contain a subdirectory named Provincetown. This subdirectory should contain directories named Datasets and Tiles, and files named Map.tif and Region.yaml. The Worlds directory should contain a subdirectory named Provincetown which contains the generated world, which can be copied to your Minecraft saves directory if you want to play single-player, or to your server directory, or wherever you like.
Please note: if you have not updated your pymclevel checkout, the map will need to be opened from inside Minecraft in order to convert it to Anvil.
This is what I had to do.
I downloaded and installed Virtual Studio C++ Express 2008 and Platform SDK 7.0, including the 64 bit compilers.
I opened the CMD shell from within the Windows SDK 7.0 menu in the Start menu.
I set the DISTUTILS_USE_SDK variable to 1.
I ran python setup.py build_ext --inplace from the pymclevel directory.
My laptop does not support OpenCL so I was unable to take advantage of this feature. If you have a desktop with a modern video card, visit the OpenCL site at http://developer.nvidia.com/cuda/opencl to see if it will work for you. Once you have OpenCL working, you will need to install the pyopencl module from LFD. OpenCL support should be detected automatically by ./PrepRegion.py if it is installed. Again, if you get it to work, please let me know!