[postgis-tickets] [PostGIS] #3034: ST_AsTWKBagg does not check the input precision
PostGIS
trac at osgeo.org
Wed Feb 11 15:07:57 PST 2015
#3034: ST_AsTWKBagg does not check the input precision
-------------------------+--------------------------------------------------
Reporter: javisantana | Owner: nicklas
Type: defect | Status: new
Priority: medium | Milestone:
Component: postgis | Version: 2.1.x
Keywords: |
-------------------------+--------------------------------------------------
Comment(by nicklas):
Thanks javisantana!
I didn't read properly so I added the check a little later in the file. I
missed the patch. Your placing of the check is more logical, but I leave
it where it is. I will commit some major rework of the twkb-code anyway
soon. Then I think as Sandro proposed some time ago that the aggregation
code should go in a separate file.
THe reason of the limit of 7 decimals is because it is stored in 4 bts,
and as discussed
here:
https://github.com/TWKB/Specification/issues/5
and here
https://github.com/TWKB/Specification/issues/9
there should probably be possible to use negative values too, for meter
based projections on low zoom-levels.
So, since there is still no conclusion about that I have left space for
allowing negative numbers in one way or another (will need 1 bit no matter
how it is done I guess).
Is there a need for more than 7 decimals?
Well, it can be of course, maybe it should be. I don't know.
There is still the fourth bit available, but I would like to use that for
zoom-levels (Is there a bitmap included for zoom-levels). But I have to
prove that it is usable first :-)
Anyway this is not the place for this discussion. Github is better as an
issue for the twkb spec.
--
Ticket URL: <http://trac.osgeo.org/postgis/ticket/3034#comment:2>
PostGIS <http://trac.osgeo.org/postgis/>
The PostGIS Trac is used for bug, enhancement & task tracking, a user and developer wiki, and a view into the subversion code repository of PostGIS project.
More information about the postgis-tickets
mailing list