Re: [mapserver-users] Automatic simplification based on resolution

2014-01-02 Thread Eichner, Andreas - SID-NLKM
Wasn't RFC 86 (http://mapserver.org/development/rfc/ms-rfc-86.html) intended to 
solve such problems? Does something like the following work and do the job?

  SCALETOKEN
NAME %geometry%
VALUES
  0 the_geom
  1000 st_simplify(the_geom, 100)
  1 st_simplify(the_geom, 1000)
END
  END
  DATA the_geom from (select %geometry% as the_geom, prop1 from roads) as foo

Would be nice to know if that would work...

Regards,
Andreas Eichner

 -Ursprüngliche Nachricht-
 Von: mapserver-users-boun...@lists.osgeo.org [mailto:mapserver-users-
 boun...@lists.osgeo.org] Im Auftrag von thomas bonfort
 Gesendet: Dienstag, 31. Dezember 2013 18:46
 An: Rahkonen Jukka
 Cc: Mapserver-Users (mapserver-users@lists.osgeo.org)
 Betreff: Re: [mapserver-users] Automatic simplification based on
 resolution
 
 Jukka,
 IIRC this has already surfaced a few times on the mailing list or the
 bugtracker. MapServer already simplifies geometries at the pixel
 level
 before sending them to the renderers, and from my testing at the time
 was more efficient at doing so than using st_simplify(), with the
 added bonus that the cellsize (resolution, units per pixel) does not
 need to be factored in the actual SQL query, and that the
 simplification applies to all data backends.
 Doing the simplification inside postgis does however make sense if
 the
 data transfer from db to mapserver is a bottleneck, and/or
 potentially
 if reprojection is involved (as less points would need to be fed into
 proj). If you can come up with hard numbers to show there is a gain
 I'd be interested.
 
 regards,
 thomas
 
 
 
 On 31 December 2013 10:31, Rahkonen Jukka jukka.rahko...@mmmtike.fi
 wrote:
  Hi,
 
  Mapnik has such a feature
 http://blog.cartodb.com/post/20163722809/speeding-up-tiles-rendering
  Andrea Aime is experimenting with it with Geoserver and is reaching
 a 50% speedup.
  http://osgeo-org.1560.x6.nabble.com/Some-interesting-optmizations-
 from-Jonathan-s-load-test-td5095839.html
  Can Mapserver do the same?
 
  -Jukka Rahkonen-
  ___
  mapserver-users mailing list
  mapserver-users@lists.osgeo.org
  http://lists.osgeo.org/mailman/listinfo/mapserver-users
 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Automatic simplification based on resolution

2013-12-31 Thread Andrea Peri
Hi Jukka,

I often need to produce for our wms some light dataset using the
SimplifyPreserveTopology from postgis or spatialite.

The question is that this is usually need when the dataset is huge and many
complex.
But this is also the situation where using this algorithm often will be
produced some invalid geometry.

So after I produce a dataset light with the simplify I need to do an
correction using the makevalid when the isvalid is false.

So I guess is quite insicure to do an automatic simplify at the mapserver
level without a test and a correction of invalidity geometrics.

And the apply of the isvalid and makevalid is a too slow process to do it
realtime on a request.

Are you think to some other strategy that grant the production of a surely
valid geometry ?

Thx,

Andrea.



2013/12/31 Rahkonen Jukka jukka.rahko...@mmmtike.fi

 Hi,

 Mapnik has such a feature
 http://blog.cartodb.com/post/20163722809/speeding-up-tiles-rendering
 Andrea Aime is experimenting with it with Geoserver and is reaching a 50%
 speedup.

 http://osgeo-org.1560.x6.nabble.com/Some-interesting-optmizations-from-Jonathan-s-load-test-td5095839.html
 Can Mapserver do the same?

 -Jukka Rahkonen-
 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users




-- 
-
Andrea Peri
. . . . . . . . .
qwerty àèìòù
-
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users