Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I would like to use the Oblique Mercator projection in GeoTools.

I'm currently using a WGS84 Mercator projection like this:

        final CoordinateReferenceSystem wgs84CoordSystem = CRS
        final CoordinateReferenceSystem worldMercatorCoordSystem = CRS
        final MathTransform latLonToMercator = CRS.findMathTransform(wgs84CoordSystem,
        final MathTransform mercatorToLatLon = CRS.findMathTransform(worldMercatorCoordSystem,

The Oblique Mercator EPSG code doesn't appear to be supported (and I want to be able to specify the latitude of centre and azimuth anyway).

Could anyone give me an example of how to create a WGS84 Oblique Mercator projection and MathTransform to allow me to convert to/from Lat/Lon please?

share|improve this question

Here is the solution I used:

    // Define WGS84 Oblique Mercator WKT
private static final String MERCATOR_WKT = "PROJCS[\"OBLIQUE MERCATOR\","
        + "GEOGCS[\"WGS 84\","
        + "DATUM[\"WGS_1984\","
        + "SPHEROID[\"WGS 84\",6378137,298.257223563]],"
        + "PRIMEM[\"Greenwich\",0],"
        + "UNIT[\"degree\",0.01745329251994328]],"
        + "PROJECTION[\"Hotine_Oblique_Mercator\"],"
        // Centre location tags added to be replaced
        + "PARAMETER[\"latitude_of_center\",LATITUDE_OF_CENTRE],"
        + "PARAMETER[\"longitude_of_center\",LONGITUDE_OF_CENTRE],"
        // Azimuth and rectified grid angle set slightly below 90 to avoid
        // precision errors
        + "PARAMETER[\"azimuth\",89.999999],"
        + "PARAMETER[\"rectified_grid_angle\",89.999999],"
        + "PARAMETER[\"scale_factor\",1],"
        + "PARAMETER[\"false_easting\",0],"
        + "PARAMETER[\"false_northing\",0]," + "UNIT[\"metre\",1]]";

final CoordinateReferenceSystem obliqueMercatorCoordSystem = CRS

This allows me to set the longitude and latitude of centre.

share|improve this answer

Have you tried to define the Mercator projection using a WKT string?

and a org.gdal.osr.SpatialReference object calling the method SetWellKnownGeogCS:

String wkt = "PROJCS["WGS 84 / World Mercator",GEOGCS["WGS ...";

CoordinateReferenceSystem worldMercatorCoordSystem = CRS.parseWKT(wkt);
share|improve this answer
Yes - sorry I forgot to post my solution. See below... – user8204 Sep 12 '12 at 8:09

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.