Revision 13051 trunk/libraries/libProjection/src/org/cresques/cts/gt2/CSUTM.java
CSUTM.java | ||
---|---|---|
1 | 1 |
/* |
2 | 2 |
* Cresques Mapping Suite. Graphic Library for constructing mapping applications. |
3 | 3 |
* |
4 |
* Copyright (C) 2004-6.
|
|
4 |
* Copyright (C) 2004-7.
|
|
5 | 5 |
* |
6 | 6 |
* This program is free software; you can redistribute it and/or |
7 | 7 |
* modify it under the terms of the GNU General Public License |
... | ... | |
38 | 38 |
public class CSUTM extends CoordSys { |
39 | 39 |
public CSUTM(CSDatum datum, int zone) { |
40 | 40 |
super(datum); |
41 |
init(datum, zone, "N"); |
|
42 |
} |
|
43 |
|
|
44 |
public CSUTM(CSDatum datum, int zone, String ns) { |
|
45 |
super(datum); |
|
46 |
init(datum, zone, ns); |
|
47 |
} |
|
41 | 48 |
|
49 |
public void init(CSDatum datum, int zone, String ns) { |
|
42 | 50 |
Unit linearUnit = Unit.METRE; |
43 | 51 |
|
44 | 52 |
javax.media.jai.ParameterList params = csFactory.createProjectionParameterList("Transverse_Mercator"); |
... | ... | |
50 | 58 |
params.setParameter("latitude_of_origin", 0.0); |
51 | 59 |
params.setParameter("scale_factor", 0.9996); |
52 | 60 |
params.setParameter("false_easting", 500000.0); |
53 |
params.setParameter("false_northing", 0.0); |
|
61 |
if (ns.toUpperCase().compareTo("S") == 0) |
|
62 |
params.setParameter("false_northing", 10000000.0); |
|
63 |
else |
|
64 |
params.setParameter("false_northing", 0.0); |
|
54 | 65 |
|
55 | 66 |
try { |
56 | 67 |
Projection projection = csFactory.createProjection("UTM" + zone, |
Also available in: Unified diff