Using (geoserver) wms service in Qt/QML

5066
3
05-08-2015 01:05 AM
KK2014
by
New Contributor III

I using geoserver wms service in my qt/qml app like http://giswebservices.massgis.state.ma.us/geoserver/wms? but I can't see any layer in map and spatial refrerence is invalid ,but there are not any exception .How can I see this service layer in map?

I can use this service from ArcMap when I add as WMS Server from GIS Server.And then I drag and drop one layer(Counties) in map .Here is below pictures:

arcMap.JPGArcMap1.JPGArcMap2.JPG

Here is below picture using with WmsDynamicMapServiceLayer in qt/qml app.

wms.JPG

Here is below console output:

output.JPG

Thanks

Tags (3)
0 Kudos
3 Replies
LucasDanzinger
Esri Frequent Contributor

I don't think the URL you provided is enough for the layer to know what to display. It appears to be the endpoint to several services/layers hosted by that org. The below code works for me

ApplicationWindow {
    id: appWindow
    width: 800
    height: 600
    title: "wms"


    Map {
        anchors.fill: parent


        focus: true


        WmsDynamicMapServiceLayer {
            url: "http://mesonet.agron.iastate.edu/cgi-bin/wms/iowa/rainfall.cgi?"
        }
    }
}






0 Kudos
KK2014
by
New Contributor III

Lucas,

So QT/QML side don't supported to display one of layer (Counties) or don't know what to display from http://giswebservices.massgis.state.ma.us/geoserver/wms? service.Can we display in QT/C++ side same layer(Counties) in http://giswebservices.massgis.state.ma.us/geoserver/wms? service?

Thanks

0 Kudos
LucasDanzinger
Esri Frequent Contributor

KK- We are currently looking into this, as I'm not sure how this works with this structure.

0 Kudos