func drawPoint(ctxt draw2d.GraphicContext, g *geos.Geometry, c color.Color, radius float64, scale func(x, y float64) (float64, float64)) { if c != nil { ctxt.SetFillColor(c) } x, err := g.X() if err != nil { log.Fatal(err) } y, err := g.Y() if err != nil { log.Fatal(err) } x, y = scale(x, y) ctxt.MoveTo(x, y) ctxt.ArcTo(x, y, radius, radius, 0, 2*math.Pi) ctxt.Fill() }