[Tile-serving] [osm2pgsql-dev/osm2pgsql] Flex: Allow creating point geometry from way (PR #2429)
Jochen Topf
notifications at github.com
Sat Nov 1 10:39:51 UTC 2025
joto left a comment (osm2pgsql-dev/osm2pgsql#2429)
Force pushed new version: as_point() can now take an index argument when called for a way which specifies which member node to take the location from. Index is 1-based, negative indexes count from the back.
So :as_point(), :as_point(nil), :as_point(0), :as_point(1) will return the first node, :as_point(2) the second node and so on. :as_point(-1) will return the last node.
If the index is out of range a null geometry will be returned. If the parameter is not a number an error will be generated.
--
Reply to this email directly or view it on GitHub:
https://github.com/osm2pgsql-dev/osm2pgsql/pull/2429#issuecomment-3476178419
You are receiving this because you are subscribed to this thread.
Message ID: <osm2pgsql-dev/osm2pgsql/pull/2429/c3476178419 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/tile-serving/attachments/20251101/82cfca66/attachment.htm>
More information about the Tile-serving
mailing list