jumpinjackie / mapguide-rest

REST Extension for MapGuide Open Source
GNU Lesser General Public License v2.1
26 stars 14 forks source link

Vector Tiled JSON - Access MapGuide/AIMS layer styles directly #141

Open RenoSun opened 8 years ago

RenoSun commented 8 years ago

I noticed the comments under following link, and I hope there will be a way for mapguide-rest to access , and interpret the layer styles on AIMS/Mapguide into the Tiled JSON. Then, the Openlayers 3/or other Map APIs would be able to access display vector tiled layers with similar styles.

http://localhost/mapserver/rest/sampleapps/vector/index.html

function styleFunc(feature, resolution) {
            //These styles have been painfully hand written from what's specified in the Layer Definitions
            //
            //Wouldn't it be nice if there was a way to translate these styles automatically? ;-)
...........
}

For example: feature.get("ScaleFrom"); feature.get("ScaleTo"); feature.get("LegendLabel"); feature.get("FeatureLabel"); feature.get("SymbolStyle"); feature.get("SymbolColor"); feature.get("SymbolText"); feature.get("SymbolWidth"); //in mm only will be easier? feature.get("SymbolHeight"); //in mm only will be easier? feature.get("SymbolRotaion"); feature.get("Condition"); ...and so on...

I think it will be truly awesome enhancement for mapguide-rest, but the complexity is very high I assume.

jumpinjackie commented 8 years ago

I see you found that comment :)

But, I don't believe this is an actual concern that mapguide-rest should be trying solve. This is something for a client-side JS library to solve as the problem revolves specifically around a particular client (OpenLayers 3)