Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Javascript 3D statistical map library.
JavaScript Shell
branch: master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
build Adds a build version.
res Adds two resource file.
screenshots Add a screenshot.
src Make loading bar prettier.
README.md Modify README.

README.md

megamap

A javascript library for displaying statistical map using WebGL in 3d.
three.js is used in the project.
All browsers that support WebGL are able to display the page.


Usage :

mm3d-latest.js, mm3d.css and all meshes file(i.e. mapXxx.js) is required for the program.
The library is currently not completed.
The following code shows the basic usage, and the full API reference is also not avaliable until the completion of code work.

Include both js and css files in your html header.

<!-- Three.js (r47) is required in megamap library -->
<script type='text/javascript' src='Three.js'></script>
<!-- This is our megamap library -->
<script type='text/javascript' src='mm3d.min.js'></script>
<!-- Do not forget to include corresponding map file, 
     take China map for example -->
<script type='text/javascript' src='mm3d.chn.js'></script>

<link rel='stylesheet' type='text/css' href='mm3d.css'>

And initialize the map as following.

var map = mm3d.ChinaMap(document.getElementById('viewport'),
                          mapData, {'animation':false})
map.init();

Current examples :

China's population map Shanghai's housing price map

Something went wrong with that request. Please try again.