Hi,
Sure, you can use the VertexCreator+Reprojector+CoordinateExtractor.
Alternatively, the AttributeReprojector can also be used if you don't need to create point geometry.
Regarding UTM zone choice, consider using the Conditional Value for the "Destination Coordinate System" setting.
Takashi
Hi,
if you've got a LatLong geometry, you can insert a PythonCaller with the following code:
---
import fmeobjects
import math
def get_utm_zone(feature):
first_coord = feature.getCoordinate(0)
lon, lat = first_coord :2]
utmzone = int((math.floor((lon + 180.0)/6) % 60) + 1)
# Special cases for Norway and Svalbard
if lat > 55.0 and utmzone == 31 and lat < 64.0 and lon > 2.0:
utmzone = 32
elif lat > 71.0 and utmzone == 32 and lon < 9.0:
utmzone = 31
elif lat > 71.0 and utmzone == 32 and lon > 8.0:
utmzone = 33
elif lat > 71.0 and utmzone == 34 and lon < 21.0:
utmzone = 33
elif lat > 71.0 and utmzone == 34 and lon > 20.0:
utmzone = 35
elif lat > 71.0 and utmzone == 36 and lon < 33.0:
utmzone = 35
elif lat > 71.0 and utmzone == 36 and lon > 32.0:
utmzone = 37
feature.setAttribute('UTM_ZONE', utmzone)
---
The output features will have a new attribute UTM_ZONE that contains the zone number. Special provisions are in place to handle the special cases around Norway and Svalbard (see the grid map at
http://en.wikipedia.org/wiki/Universal_Transverse_Mercator_coordinate_system).
David