[Geoserver-users] Question on WPS Rendering processes

Hello all,

I’m wondering if it is possible to use a WPS JTS process (like JTS:interiorPoint) directly as WPS rendering process in a SLD file, or if it is necessary to build a process taking as input a feature collection (what i did until now).
If both are possible, would there be one more performant than the other?

Thanks
Emmanuel

On Mon, Mar 11, 2013 at 10:39 AM, Emmanuel Blondel <emmanuel.blondel1@anonymised.com> wrote:

Hello all,

I’m wondering if it is possible to use a WPS JTS process (like JTS:interiorPoint) directly as WPS rendering process in a SLD file, or if it is necessary to build a process taking as input a feature collection (what i did until now).
If both are possible, would there be one more performant than the other?

Rendering transformations need to get the layers they are transforming as inputs.
Layers can come in two shapes, vector, which are represented by the FeatureCollection interface,
and raster, which are represented by the GridCoverage class.

Using JTS processes manipulation geometries directly as rendering transformations is thus
not possible, at least directly.
I can imagine a generic process that can apply other processes on just the geometries, the
hard part seems to be to teach this process about how to call the other process for each geometry,
giving it a notion of which parameter of the inner process is the geometry, and a list of the
other parameters that we might need to pass down

Cheers
Andrea

==
Our support, Your Success! Visit http://opensdi.geo-solutions.it for more information.

Ing. Andrea Aime
@geowolf
Technical Lead

GeoSolutions S.A.S.
Via Poggio alle Viti 1187
55054 Massarosa (LU)
Italy
phone: +39 0584 962313
fax: +39 0584 1660272
mob: +39 339 8844549

http://www.geo-solutions.it
http://twitter.com/geosolutions_it


On Mon, Mar 11, 2013 at 10:49 AM, Andrea Aime <andrea.aime@anonymised.com> wrote:

On Mon, Mar 11, 2013 at 10:39 AM, Emmanuel Blondel <emmanuel.blondel1@anonymised.com> wrote:

Hello all,

I’m wondering if it is possible to use a WPS JTS process (like JTS:interiorPoint) directly as WPS rendering process in a SLD file, or if it is necessary to build a process taking as input a feature collection (what i did until now).
If both are possible, would there be one more performant than the other?

Btw, if all you want is to extract the interior point of a geometry, why don’t you just use
a geometry transformation instead?
http://docs.geoserver.org/stable/en/user/styling/sld-extensions/geometry-transformations.html

Cheers
Andrea

==
Our support, Your Success! Visit http://opensdi.geo-solutions.it for more information.

Ing. Andrea Aime
@geowolf
Technical Lead

GeoSolutions S.A.S.
Via Poggio alle Viti 1187
55054 Massarosa (LU)
Italy
phone: +39 0584 962313
fax: +39 0584 1660272
mob: +39 339 8844549

http://www.geo-solutions.it
http://twitter.com/geosolutions_it


Yes indeed, it's better, i missed the geometry transformations.
Thanks

Le 11/03/2013 10:50, Andrea Aime a écrit :

On Mon, Mar 11, 2013 at 10:49 AM, Andrea Aime <andrea.aime@anonymised.com <mailto:andrea.aime@anonymised.com>> wrote:

    On Mon, Mar 11, 2013 at 10:39 AM, Emmanuel Blondel
    <emmanuel.blondel1@anonymised.com <mailto:emmanuel.blondel1@anonymised.com>>
    wrote:

        Hello all,

        I'm wondering if it is possible to use a WPS JTS process (like
        JTS:interiorPoint) directly as WPS rendering process in a SLD
        file, or if it is necessary to build a process taking as input
        a feature collection (what i did until now).
        If both are possible, would there be one more performant than
        the other?

Btw, if all you want is to extract the interior point of a geometry, why don't you just use
a geometry transformation instead?
http://docs.geoserver.org/stable/en/user/styling/sld-extensions/geometry-transformations.html

Cheers
Andrea

--

Our support, Your Success! Visit http://opensdi.geo-solutions.it for more information.

Ing. Andrea Aime
@geowolf
Technical Lead

GeoSolutions S.A.S.
Via Poggio alle Viti 1187
55054 Massarosa (LU)
Italy
phone: +39 0584 962313
fax: +39 0584 1660272
mob: +39 339 8844549

http://www.geo-solutions.it
http://twitter.com/geosolutions_it

-------------------------------------------------------

--
*Emmanuel Blondel*
GIS Consultant
Engineer in Agronomy & Environment

Geographic Information Systems
in Agronomy - Environment - Fisheries
Email: emmanuel.blondel1@anonymised.com - Emmanuel.Blondel@anonymised.com
View my LinkedIn profileView my LinkedIn profile <http://fr.linkedin.com/in/emmanuelblondel1&gt;

btn_in_20x15.png

However, i've noted some strange rendering behavior with WMS 1.1.1.:
I've compared a geometry transformation and a WPS rendering transformation (that applies to a polygon feature collection), with the JTS:interiorPoint.

* if in the SLD in i specify both point (interiorPoint) and polygon symbolizer, the 'continuum' of world WMS images is maintained (for both geometry and rendering transformations)
see first attached image

* now if in the SLD i only specify a point symbolizer (interiorPoint):
   -- with the geometry transformation: it is applied to the main view but i don't have continuum of WMS image (e.g. if move on the right of the map towards Western Pacific area)
   -- with the rendering transformation (that computes interiorPoint), i have this continuum

How can you explain that? is it a bug?

Thanks in advance
Emmanuel

Le 11/03/2013 10:50, Andrea Aime a écrit :

On Mon, Mar 11, 2013 at 10:49 AM, Andrea Aime <andrea.aime@anonymised.com <mailto:andrea.aime@anonymised.com>> wrote:

    On Mon, Mar 11, 2013 at 10:39 AM, Emmanuel Blondel
    <emmanuel.blondel1@anonymised.com <mailto:emmanuel.blondel1@anonymised.com>>
    wrote:

        Hello all,

        I'm wondering if it is possible to use a WPS JTS process (like
        JTS:interiorPoint) directly as WPS rendering process in a SLD
        file, or if it is necessary to build a process taking as input
        a feature collection (what i did until now).
        If both are possible, would there be one more performant than
        the other?

Btw, if all you want is to extract the interior point of a geometry, why don't you just use
a geometry transformation instead?
http://docs.geoserver.org/stable/en/user/styling/sld-extensions/geometry-transformations.html

Cheers
Andrea

--

Our support, Your Success! Visit http://opensdi.geo-solutions.it for more information.

Ing. Andrea Aime
@geowolf
Technical Lead

GeoSolutions S.A.S.
Via Poggio alle Viti 1187
55054 Massarosa (LU)
Italy
phone: +39 0584 962313
fax: +39 0584 1660272
mob: +39 339 8844549

http://www.geo-solutions.it
http://twitter.com/geosolutions_it

-------------------------------------------------------

Polygon_and_Point_Symbolizers.JPG

Point_Symbolizer_withGeomTransformation.JPG

Point_Symbolizer_withRenderingTransformation.JPG