[Geoserver-devel] GeoServer, GeoTools 2.5 and UOM

Hey there,

We were starting to play around with GeoServer, and were noticing that, since GeoServer is still on GeoTools 2.5.x, it does not have the UOM attribute on the Symbolizers.

We were wondering then about the next moves of the GeoServer project and/or GeoTools:
- Will GeoServer move to GeoTools 2.6 soon?
- Will UOM support ever be backported to GeoTools 2.5?

Other than that, we would probably have to spend a little more effort on changing the GeoTools renderer so that the symbolizers rescale according to the UOM attribute. Right now, we are applying a "UomRescaleStyleVisitor" before calling the GeoTools renderer, but I guess that's not so nice for GeoServer right?

What do you think? Now that I am taking a closer look at the rendering process, it seems that we could manage this rescaling withing SLDStyleFactory, which could check the UOM attribute and generate a Style2D with the appropriate rescaled size.

Let me know your opinion on this then.

Cheers
Milton

Milton Jonathan ha scritto:

Hey there,

We were starting to play around with GeoServer, and were noticing that, since GeoServer is still on GeoTools 2.5.x, it does not have the UOM attribute on the Symbolizers.

We were wondering then about the next moves of the GeoServer project and/or GeoTools:
- Will GeoServer move to GeoTools 2.6 soon?
- Will UOM support ever be backported to GeoTools 2.5?

GeoServer trunk is already on 2.6. Look for the releases labeled "2.0-betaX", those are using gt2 2.6 (or checkout GeoServer trunk
instead of 1.7.x)

Other than that, we would probably have to spend a little more effort on changing the GeoTools renderer so that the symbolizers rescale according to the UOM attribute. Right now, we are applying a "UomRescaleStyleVisitor" before calling the GeoTools renderer, but I guess that's not so nice for GeoServer right?

Yeah, sounds like a workaround instead of an integrated solution.
I guess a quick way to solve it and hide the problem "under the carpet"
would be the renderer to deep clone the style, then pass the visitor
over the the cloned style.

What do you think? Now that I am taking a closer look at the rendering process, it seems that we could manage this rescaling withing SLDStyleFactory, which could check the UOM attribute and generate a Style2D with the appropriate rescaled size.

Yes, that would be preferable indeed. I guess we'd have to inform
SLDStyleFactory about the current scale, so a little API change
is needed.

Cheers
Andrea

--
Andrea Aime
OpenGeo - http://opengeo.org
Expert service straight from the developers.

Thanks a lot for the info Andrea

We'll checkout the GeoServer trunk code then, and then see which way to go with the rescaling part.

Right now I'm taking a look at rendering SVGs and fills as vectors. Once we know how to handle that, I guess we'll have a better idea as to how to do the rescaling.

Cheers
Milton

Andrea Aime wrote:

Milton Jonathan ha scritto:

Hey there,

We were starting to play around with GeoServer, and were noticing that, since GeoServer is still on GeoTools 2.5.x, it does not have the UOM attribute on the Symbolizers.

We were wondering then about the next moves of the GeoServer project and/or GeoTools:
- Will GeoServer move to GeoTools 2.6 soon?
- Will UOM support ever be backported to GeoTools 2.5?

GeoServer trunk is already on 2.6. Look for the releases labeled "2.0-betaX", those are using gt2 2.6 (or checkout GeoServer trunk
instead of 1.7.x)

Other than that, we would probably have to spend a little more effort on changing the GeoTools renderer so that the symbolizers rescale according to the UOM attribute. Right now, we are applying a "UomRescaleStyleVisitor" before calling the GeoTools renderer, but I guess that's not so nice for GeoServer right?

Yeah, sounds like a workaround instead of an integrated solution.
I guess a quick way to solve it and hide the problem "under the carpet"
would be the renderer to deep clone the style, then pass the visitor
over the the cloned style.

What do you think? Now that I am taking a closer look at the rendering process, it seems that we could manage this rescaling withing SLDStyleFactory, which could check the UOM attribute and generate a Style2D with the appropriate rescaled size.

Yes, that would be preferable indeed. I guess we'd have to inform
SLDStyleFactory about the current scale, so a little API change
is needed.

Cheers
Andrea

--

Milton Jonathan
Grupo GIS e Meio Ambiente
Tecgraf/PUC-Rio
Tel: +55-21-3527-2502