geoscript-groovy icon indicating copy to clipboard operation
geoscript-groovy copied to clipboard

Viewer.plot issues

Open moovida opened this issue 5 years ago • 1 comments

Given the following testcode:

import geoscript.geom.*
import geoscript.viewer.*

def multiLineCoordinates = [
    [[10,10],[20,20],[10,40]],
    [[40,40],[30,30],[40,20],[30,10]]
]
def geom = new MultiLineString(multiLineCoordinates)

Viewer.plot([size: [800,800]],[geom])

I get the following:

image

You can see the points being shifted against the lines they are part of.

The same result can be obtained by avoiding to set the size:

Viewer.plot([geom])

and then enlarging the plot window.

moovida avatar Apr 06 '19 09:04 moovida

Confirmed. After looking at the code, this is probably an issue with org.geotools.renderer.chart.GeometryRenderer or org.geotools.renderer.chart.GeometryDataset.

jericks avatar Apr 10 '19 17:04 jericks