Welcome to the OpenGlobus overview page! OpenGlobus is a javascript library designed to display interactive 3d maps and planets with map tiles, imagery and vector data, markers and 3d objects. It uses the WebGL technology, open source and completely free.
The OpenGlobus main goal is to make 3d map features fast, good lookin, user friendly and easy to implement in any related project.
Here we create a globe in the 'globus'
div with useful controls, tile layer of OpenStreetMap tiles, and then add a marker with some label:
var osm = new og.layer.XYZ("OpenStreetMap", {
isBaseLayer: true,
url: "//{s}.tile.openstreetmap.org/{z}/{x}/{y}.png",
visibility: true,
attribution: 'Data @ OpenStreetMap contributors, ODbL'
});
var globus = new og.Globe({
"target": "globus",
"name": "Earth",
"terrain": new og.terrain.GlobusTerrain(),
"layers": [osm],
"autoActivated": true,
"viewExtent": [5.56707, 45.15679, 5.88834, 45.22260]
});
new og.layer.Vector("Markers", {
clampToGround: true
})
.addTo(globus.planet)
.add(new og.Entity({
lonlat: [5.73, 45.183],
label: {
text: "Hi, Globus!",
outline: 0.77,
outlineColor: "rgba(255,255,255,.4)",
size: 27,
color: "black",
offset: [10, -2]
},
billboard: {
src: "./marker.png",
width: 64,
height: 64,
offset: [0, 32]
}
}));