I have a problem with getting a map in EPSG 3031 to work.
From my research I have already learned that the parameters for the projection have to be defined in the javasc
Please have a look at the following snippet:
proj4.defs("EPSG:3031", "+proj=stere +lat_0=-90 +lat_ts=-71 +lon_0=0 +k=1 +x_0=0 +y_0=0 +datum=WGS84 +units=m +no_defs");
ol.proj.proj4.register(proj4);
var proj3031 = ol.proj.get('EPSG:3031');
var esriArctic = new ol.layer.Tile({
title: 'ESRI Imagery',
type: 'base',
zIndex: 0,
source: new ol.source.XYZ({
url: 'https://services.arcgisonline.com/arcgis/rest/services/Polar/Antarctic_Imagery/MapServer/tile/{z}/{y}/{x}'
})
});
var map = new ol.Map({
target: 'map',
layers: [esriArctic],
view: new ol.View({
center: ol.proj.fromLonLat([0, -80], proj3031),
zoom: 3
})
})
html,
body,
#map {
width: 100%;
height: 100%;
overflow: hidden;
}