Opened 14 years ago
Closed 14 years ago
#348 closed defect (fixed)
WKTWriter producing nan's for 3d geometries that aren't really 3D
Reported by: | warmerdam | Owned by: | strk |
---|---|---|---|
Priority: | major | Milestone: | |
Component: | Core | Version: | main |
Severity: | Unassigned | Keywords: | |
Cc: |
Description
I am getting results like this from Ingres, where the input boundary is 2D. The problem is that operators like Envelope produce 3D geometries, but put nan in the 3rd dimension. Also the WKTWriter does not try to do anything careful with nan's.
SELECT AsText(Envelope(boundary)) FROM named_places WHERE name = 'Goose Island' \g POLYGON Z ( ( 59 13 nan , 67 13 nan , 67 18 nan , 59 18 nan , 59 13 nan ) )
This problem only occurs as a result of other dimension related improvements in trunk by me for other tickets.
Note:
See TracTickets
for help on using tickets.
Attempt to make geometry dimension perform more smoothly. Modified CoordinateArraySequence? to default to unknown dimension (0), which is determined at the point getDimension() is called by examination of the first coordinate Z (ISNAN test). The WKTWriter has also been altered to write 0.0 instead of nan, and to avoid writing "Z" for EMPTY geometries.
Changes are in trunk (r2998).