Add and use new proj4.register function

This commit is contained in:
Andreas Hocevar
2017-12-15 18:47:51 +01:00
parent 345ce340e4
commit 9f1ebbb852
20 changed files with 195 additions and 138 deletions

View File

@@ -6,6 +6,7 @@ import _ol_layer_Image_ from '../src/ol/layer/Image.js';
import {fromLonLat} from '../src/ol/proj.js';
import _ol_proj_Projection_ from '../src/ol/proj/Projection.js';
import _ol_source_ImageWMS_ from '../src/ol/source/ImageWMS.js';
import {register} from '../src/ol/proj/proj4.js';
// Transparent Proj4js support:
@@ -23,6 +24,8 @@ import _ol_source_ImageWMS_ from '../src/ol/source/ImageWMS.js';
// create an ol.proj.Projection instance. ol.proj.get() will take care of it
// internally.
register(proj4);
var projection = new _ol_proj_Projection_({
code: 'EPSG:21781',
extent: [485869.5728, 76443.1884, 837076.5648, 299941.7864]