PlateCarreeProjection defines the "plate carree" (square plate) projection, which converts points on the sphere to (longitude, latitude) pairs. Coordinates can be scaled so that they represent radians, degrees, etc, but the projection is always centered around (latitude=0, longitude=0). Note that (
| 80 | // longitude) ordering, in order to match the usual convention for graphs in |
| 81 | // which "x" is horizontal and "y" is vertical. |
| 82 | type PlateCarreeProjection struct { |
| 83 | xWrap float64 |
| 84 | toRadians float64 // Multiplier to convert coordinates to radians. |
| 85 | fromRadians float64 // Multiplier to convert coordinates from radians. |
| 86 | } |
| 87 | |
| 88 | // NewPlateCarreeProjection constructs a plate carree projection where the |
| 89 | // x-coordinates (lng) span [-xScale, xScale] and the y coordinates (lat) |
nothing calls this directly
no outgoing calls
no test coverage detected