|
3 | 3 | GeoScript Groovy Releases
|
4 | 4 | =========================
|
5 | 5 |
|
| 6 | +1.15.0 (In progress) |
| 7 | +-------------------- |
| 8 | +The 1.15 release of GeoScript is build on Groovy 3.0.3, GeoTools 23.0, and the Java Topology Suite 1.16.1 and requires Java 8. |
| 9 | + |
| 10 | +Add geoscript.carto package for building maps with cartographic elements like north arrows, text, and neatlines:: |
| 11 | + |
| 12 | + File file = new File("map.png") |
| 13 | + file.withOutputStream { OutputStream outputStream -> |
| 14 | + PageSize pageSize = PageSize.LETTER_LANDSCAPE |
| 15 | + |
| 16 | + CartoFactories.findByName("png") |
| 17 | + .create(pageSize) |
| 18 | + .rectangle(new RectangleItem(0, 0, pageSize.width - 1, pageSize.height - 1) |
| 19 | + .fillColor(Color.WHITE) |
| 20 | + ) |
| 21 | + .map(new MapItem(20, 20, pageSize.width - 40, pageSize.height - 40).map(map)) |
| 22 | + .northArrow(new NorthArrowItem(pageSize.width - 60, pageSize.height - 100, 40, 80) |
| 23 | + .font(new Font("Arial", Font.BOLD, 24)) |
| 24 | + .drawText(true)) |
| 25 | + .build(outputStream) |
| 26 | + |
| 27 | + } |
| 28 | + |
| 29 | +.. image:: images/carto.png |
| 30 | + |
| 31 | +Raster.getBufferedImage():: |
| 32 | + |
| 33 | + File file = new File("alki.tif") |
| 34 | + GeoTIFF geoTIFF = new GeoTIFF(file) |
| 35 | + Raster raster = geoTIFF.read() |
| 36 | + BufferedImage image = raster.bufferedImage |
| 37 | + |
| 38 | +Add Schema alias for GeometryCollection. |
| 39 | + |
| 40 | +Add static Layer methods to create Layer from a Geometry or a List of Geometries:: |
| 41 | + |
| 42 | + Layer layer = Layer.fromGeometry("world", new Bounds(-180,-90,180,90).geometry) |
| 43 | + |
| 44 | + Layer layer = Layer.fromGeometries("testPits", Geometry.createRandomPoints(new Bounds(-180,-90,180,90).geometry, 10).geometries) |
| 45 | + |
| 46 | +Update GeoDB dependency to for Java 8 compatability. |
| 47 | + |
| 48 | +Add Viewer.drawBase64String method:: |
| 49 | + |
| 50 | + def geom = Geometry.fromWKT("POINT (-111 45.7)").buffer(10) |
| 51 | + String str = Viewer.drawToBase64EncodedString(geom) |
| 52 | + |
| 53 | +Add Flatgeobuf Workspace:: |
| 54 | + |
| 55 | + Workspace workspace = new FlatGeobuf(new File("flatgeobuf/files")) |
| 56 | + |
| 57 | +Create oval Vector grids:: |
| 58 | + |
| 59 | + Bounds bounds = new Bounds(-180,-90,180,90,"EPSG:4326") |
| 60 | + double length = 20 |
| 61 | + Layer layer = Graticule.createOvals(bounds, length) |
| 62 | + |
| 63 | +.. image:: images/layer_graticule_oval.png |
| 64 | + |
6 | 65 | 1.14.0
|
7 | 66 | ------
|
8 | 67 | The 1.14 release of GeoScript is build on Groovy 2.5.8, GeoTools 22.0, and the Java Topology Suite 1.16.1 and requires Java 8.
|
|
0 commit comments