[postgis-devel] KML from PostGIS patch

Eduin Carrillo yecarrillo at yahoo.com
Wed Dec 20 06:18:33 PST 2006

--- strk at refractions.net escribió:

> On Mon, Dec 18, 2006 at 10:21:10AM -0600, Eduin Carrillo wrote:
> > > 2) A test case would help making sure it works now and it will keep
> working
> > > in the future.
> > > 
> > I'm working on that but I haven't found useful information. A "how to
> document"
> > will be appreciated.
> How to write a testcase you mean ?
> Well, yes, regress/README seems to contain info about a really different
> (and not-more-needed) thing. Any volunteer willing to spend some words on
> adding testcases (should be really simple actually).

Yes, I guess this steps for regress tests:
1. Write a /regress/kml.sql file with data and sql queries for testing
2. Write a /regress/kml_expected file with expected results per query

How run the tests? I need to create a special db? Which user I need to use?

> > > 3) Documentation only contains AsKML(geometry, [precision]), but I read
> in
> > > the sql file
> > >    about a "version" parameter and an asUKML variant. What are them ?
> > 
> > I just follow the AsGML way of a third parameter for future changes on next
> > versions of KML specs. However, geometry in kml involves three aditional
> values
> > related to how GE displays 3D data: extrude,tessellate and altitudeMode.
> That
> > third (and eventually a fourth parameter) can be used to define the
> behaviour
> > when 3dz or 3dm geometry is passed. All suggestions are welcomed.
> I'm not a KML user so dunno, just wondered why the third parameter was there.
> Maybe, if you want to support complex configuration, a varchar would be
> better
> then an integer ?

I will wait for more comments of people using kml feature. KML produced by
PostGIS is enough for basic/medium complexity KML documents. Other parameters
would be implemented in next versions of PostGIS.

> > AsUKML is the primary function that returns the KML "untransformed". As
> Google
> > Earth only understand WGS84 data (srid=4326), I don't know if somebody will
> > find it useful. What do you think?
> Did you profile asUKML vs. asKML when input is already in 4326 ?

What do you mean with "profile". transform_equal_srid.patch modifies
lwgeom_transform.c to return the geometry as is if input srid is equal to
output srid in Tranform() function.

> --strk;


Correo Yahoo!
Espacio para todos tus mensajes, antivirus y antispam ¡gratis! 
Regístrate ya - http://correo.espanol.yahoo.com/ 

More information about the postgis-devel mailing list