Lambert conformal projection in d3

I am trying to project a set of points ([long, lat] tuples) over an SVG map of my home country Austria:

https://commons.wikimedia.org/wiki/File:Austria-geographic_map-blank.svg

The description of the SVG file in Wikimedia gives the name of the projection and the border of the map:

Lambert Conic, WGS84 Date
Geographic map limits:

West: 17.2 ° W
East: 9.3 ° W
North: 49.2 ° N
South: 46.0 ° N

Naive, like me, I thought that this information would be enough to create the right kind of projection with D3.

This is what I tried first:

    let gcc = d3.geoConicConformal()
        .fitSize([width, height], bbox)

Where bboxis the GeoJSON polygon representing the borders of the map, as described above.

Unfortunately, the result does not match the correct projection:

enter image description here

, D3-, , , . . , , , . , , , , , ?

-, , , - , .fitSize .

- - ?

+3
1

Fitsize , , , , , , .

Parallels:

, . , , , , [46,49], .

. , , x y (. , ( )),

, , . , 13 , 20 (13.333 ), . x .

:

d3.geoConicConformal()
    .parallels([46,49])
    .rotate([-13.333,0])
    .fitSize([width,height],bbox)

downsampled goto world topojson:

enter image description here

, svg- , (, ) ; , .

+4

Source: https://habr.com/ru/post/1669882/


All Articles