1 | // assumes that projection is UTM
|
2 | function getHemisphere(projection) {
|
3 | const projstr = projection.toString();
|
4 | if (projstr.startsWith("326") || projstr.startsWith("269")) {
|
5 | return "N";
|
6 | } else if (projstr.startsWith("327")) {
|
7 | return "S";
|
8 | }
|
9 | }
|
10 |
|
11 | if (typeof define === "function" && define.amd) {
|
12 | define(function () {
|
13 | return getHemisphere;
|
14 | });
|
15 | }
|
16 |
|
17 | if (typeof module === "object") {
|
18 | module.exports = getHemisphere;
|
19 | module.exports.default = getHemisphere;
|
20 | }
|