L.Proj.CRS(srsCode, options)
Name | Type | Description | ||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
srsCode |
string |
proj srsCode。 |
||||||||||||||||||||||||||||||||
options |
Object |
options.
|
Example
var crs =L.Proj.CRS("EPSG:4326",{
origin: [-180,90],
scaleDenominators: [2000,1000,500,200,100,50,20,10],
});
var map=L.map('map', {
crs: crs
...
})
Extends
Methods
-
scale(zoom)
Proj4Leaflet.js, line 192 -
Get the scale value according to the zoom level.
Name Type Description zoom
number The zoom level.
Returns:
The scale. -
zoom(scale){number}
Proj4Leaflet.js, line 216 -
Get the zoom level according to the scale value.
Name Type Description scale
number The scale value.
Returns:
Type Description number The zoom level.