|
POST
|
my application still crashed. but when i do not stringify it, it return qml point sum hex number const sr = { "wkid": 4326}; var boundaryJson = {"rings":ring,"spatialReference":sr}; var boundary= ArcGISRuntimeEnvironment.createObject("Polygon", {"json": boundaryJson}); var centroid = GeometryEngine.labelPoint(boundary); console.log("=========="); console.log((centroid)); return boundary;
... View more
08-17-2020
02:54 AM
|
0
|
2
|
3411
|
|
POST
|
hi Luke Smallwood I tried it your way, but when i try to console the qml point it crashed my application everytime. Actually i am trying to put a picture marker on centre of polygon. So i need to get centre x and y coordinates Suppose this is the JSON m passing in ring [[["172.4843305878348","-43.48191185124988"],["172.4877698503442","-43.48248171686965"],["172.48715361282302","-43.484065878559875"],["172.48428867831893","-43.48421950013839"],["172.4843305878348","-43.48191185124988"]]] function createPolygon(ring) { // create polygon using json const sr = { "wkid": 4326}; var boundaryJson = {"rings":ring,"spatialReference":sr}; var boundary= ArcGISRuntimeEnvironment.createObject("Polygon", {"json": boundaryJson,"id":"property"}); var centroid = GeometryEngine.labelPoint(boundary); console.log("=========="); console.log(JSON.stringify(centroid));//Crashed my application return boundary; }
... View more
08-17-2020
12:50 AM
|
0
|
4
|
3411
|
|
POST
|
thanks luke, well if simply created it does not use outline. where was the problem actually // *** create simple boundary symbol ***// SimpleFillSymbol { id: fillSymbol style: Enums.SimpleFillSymbolStyleSolid color: Qt.rgba(1, 1, 0, 0.0) SimpleLineSymbol { style: Enums.SimpleLineSymbolStyleSolid color:"#ff7919" width: 2.0 } }
... View more
08-14-2020
04:54 AM
|
0
|
0
|
1141
|
|
POST
|
how to use it , is their any example i could follow, because i could not found any example for it. Should i use it like this: var a = Point labelPoint(Polygon ring); it gives some syntax error
... View more
08-14-2020
04:31 AM
|
0
|
6
|
3411
|
|
POST
|
No it does not work, it just show filled symbol but it doesnot show outline. I tried this also, it shows only fillsymbol with no outline var houtline = ArcGISRuntimeEnvironment.createObject("SimpleLineSymbol",{"style":Enums.SimpleLineSymbolStyleSolid, "color":"#FF0000","width":2.0}); return ArcGISRuntimeEnvironment.createObject("SimpleFillSymbol",{style:Enums.SimpleFillSymbolStyleSolid, color:Qt.rgba(2, 2, 0, 0.4),simpleLineSymbol:houtline}); }
... View more
08-14-2020
04:16 AM
|
0
|
2
|
1141
|
|
POST
|
i want to calculate centroid (center point ) of a polygon.
... View more
08-14-2020
03:34 AM
|
0
|
8
|
3490
|
|
POST
|
This code have some error kindly help: it do not plot outline with the fill symbol function zmarkerSymbol(){ var houtline={"style":Enums.SimpleLineSymbolStyleSolid, "color":"red","width":1.0}; return ArcGISRuntimeEnvironment.createObject("SimpleFillSymbol",{"style":Enums.SimpleFillSymbolStyleSolid, "color":Qt.rgba(2, 2, 0, 0.4),"SimpleLineSymbol":{simpleLineSymbol:houtline}}); }
... View more
08-14-2020
02:58 AM
|
0
|
4
|
1218
|
|
POST
|
I am using 4.16 esri js version I didn't get your second question
... View more
08-13-2020
08:38 PM
|
0
|
1
|
1621
|
|
POST
|
HI i want to change selected marker outline color from blue to any other
... View more
08-12-2020
10:14 PM
|
0
|
3
|
1708
|
|
POST
|
Hi i want fade my map outside its geometry like i have done javascript api like in the link. Query : How to create the gray area over the extent expand to 10 so that i will perform difference between geometry and the extent Geometry difference(Geometry geometry1, Geometry geometry2) I want to do it same in qt sdkFade back map outside of polygon
... View more
08-11-2020
12:31 AM
|
0
|
8
|
5127
|
|
POST
|
Hi i am trying to add muliple picture marker symbol in my app where x and y coordinates of different type of markers come from db like low signal and high signal Now i am trying to add it in my map like below but it doesn't show up with markers import QtQuick 2.7 import QtQuick.Controls 2.1 import QtQuick.Controls.Material 2.1 import QtQuick.XmlListModel 2.0 import ArcGIS.AppFramework 1.0 import Esri.ArcGISRuntime 100.2 Item { //! [GOSymbols MapView] // Map view UI presentation at top MapView { id: mapView anchors.fill: parent rotationByPinchingEnabled: true zoomByPinchingEnabled: true Map { BasemapOceans {} initialViewpoint: viewPoint } GraphicsOverlay { id: graphicsOverlay } GraphicsOverlay{ id:markergraphicOverlay } } //! [GOSymbols MapView] // the center of the mapview ViewpointCenter { id: viewPoint center: Point { x: 172.49307355493 y: -43.4810759934974 spatialReference: SpatialReference { wkid: 4326 } } targetScale: 288895.277144
} PictureMarkerSymbol { id:markersymbol url: "http://sampleserver6.arcgisonline.com/arcgis/rest/services/Recreation/FeatureServer/0/images/e82f744ebb069bb35b234b3fea46deae" width: 38.0 height: 45.0 offsetX: 0 offsetY: 25 } SimpleFillSymbol { id: fillSymbol style: Enums.SimpleFillSymbolStyleSolid color: Qt.rgba(1, 1, 0, 0.4) SimpleLineSymbol { style: Enums.SimpleLineSymbolStyleSolid color: "blue" width: 2.0 antiAlias: true } } //! [GOSymbol line symbol] // add all the graphics to the graphics overlay // create each graphic type and then add them to the overlay at a time // alternatively you can create all of them and store in a list and add all of them // by calling appendAll and pass in the list. Component.onCompleted: { // add boat route graphicsOverlay.graphics.append(createGraphic(createBoundaryRoute(), fillSymbol)); markergraphicOverlay.graphics.append(createGraphic(addMarker(), markersymbol)); // add the nesting ground } //! [GOSymbol createGraphic] // create and return a graphic function createGraphic(geometry, symbol) { var graphic = ArcGISRuntimeEnvironment.createObject("Graphic"); graphic.geometry = geometry; graphic.symbol = symbol; console.log((graphic.geometry.json)); return graphic; } //! [GOSymbol createGraphic] //! [GOSymbol createBoatRoute] // create the boat route function createBoundaryRoute() { // create polyline using json return ArcGISRuntimeEnvironment.createObject("Polygon", {"json": boundaryJson}); } //! [GOSymbol createBoatRoute] function addMarker(){ return ArcGISRuntimeEnvironment.createObject("Point",{"x":172.49307355493,"y": -43.4810759934974, "spatialReference": { wkid: 4326 } }); } //! [GOSymbol boatRouteJson] property var boundaryJson : {"rings":[[[172.4864177167, -43.4807531333], [172.4947915167, -43.4814620167], [172.4942547333, -43.4809051667], [172.4937289833, -43.4799734], [172.4935005833, -43.4796536333], [172.4934417167, -43.4795711167], [172.486064, -43.4807159833], [172.4860340333, -43.4807206667], [172.4864177167, -43.4807531333]]], "spatialReference":{"wkid":4326}} //! [GOSymbol boatRouteJson] }
... View more
08-06-2020
04:51 AM
|
0
|
1
|
651
|
|
POST
|
Thanks i was using paths in attributes instead of rings
... View more
08-04-2020
01:24 AM
|
0
|
0
|
1318
|
|
POST
|
Hi i have resolved this problem, i just upgraded from version 4.13 to 4.16, they have some upgradation in reshape tool i think. my vertices were around 4000, they all plot instantly But still when i try to reshape it by dragging them, they still consume time for this much big boundaries
... View more
08-03-2020
11:53 PM
|
0
|
0
|
709
|
|
POST
|
Hi i m naive to arcgis appstudio and trying to create multiple polygons through JSON set of vertices, i have my vetices in json format in db like below, but my geometry symbol do not support it. Kindly guide in right direction. Or my question could be like.. how to create a polygon through JSON data import QtQuick 2.7 import QtQuick.Controls 2.1 import QtQuick.Controls.Material 2.1 import QtQuick.XmlListModel 2.0 import ArcGIS.AppFramework 1.0 import Esri.ArcGISRuntime 100.2 Item { //! [GOSymbols MapView] // Map view UI presentation at top MapView { id: mapView anchors.fill: parent rotationByPinchingEnabled: true zoomByPinchingEnabled: true Map { BasemapOceans {} initialViewpoint: viewPoint } GraphicsOverlay { id: graphicsOverlay } } //! [GOSymbols MapView] // the center of the mapview ViewpointCenter { id: viewPoint center: Point { x: 172.49307355493 y: -43.4810759934974 spatialReference: SpatialReference { wkid: 4326 } } targetScale: 288895.277144 } //! [GOSymbol line symbol] SimpleFillSymbol { id: fillSymbol style: Enums.SimpleFillSymbolStyleSolid color: Qt.rgba(1, 1, 0, 0.4) SimpleLineSymbol { style: Enums.SimpleLineSymbolStyleSolid color: "blue" width: 2.0 antiAlias: true } } //! [GOSymbol line symbol] // add all the graphics to the graphics overlay Component.onCompleted: { // add boat route graphicsOverlay.graphics.append(createGraphic(createBoundaryRoute(), fillSymbol)); // add the nesting ground } //! [GOSymbol createGraphic] // create and return a graphic function createGraphic(geometry, symbol) { var graphic = ArcGISRuntimeEnvironment.createObject("Graphic"); graphic.geometry = geometry; graphic.symbol = symbol; return graphic; } //! [GOSymbol createGraphic] //! [GOSymbol createBoatRoute] // create the boat route function createBoundaryRoute() { // create polygine using json return ArcGISRuntimeEnvironment.createObject("Polygon", {"json": boundaryJson}); } //! [GOSymbol createBoatRoute] //! [GOSymbol boatRouteJson] property var boundaryJson : {"paths":[[[172.49307355493, -43.4810759934974], [172.5030454523, -43.4334343434], [172.481307356908, -43.391075445974], [172.481307356908, -43.391075445974], [172.47307356908, -43.419075445974],[172.49307355493, -43.4810759934974]]], "spatialReference":{"wkid":4326}} //! [GOSymbol boatRouteJson] }
... View more
07-29-2020
11:42 PM
|
0
|
3
|
1424
|
|
POST
|
Finally i get the result But does this code replace my drawing polygons and
,markers also which i m going to put in future in this code??
I just want to change basemap with my secured map here..
Can anyone tell me that i am going right way
function chooseBasemap() { var credential = ArcGISRuntimeEnvironment.createObject("Credential", { token: Backend.getMapToken() }); var securityPortal = ArcGISRuntimeEnvironment.createObject("Portal", { credential: credential }); var item = ArcGISRuntimeEnvironment.createObject("PortalItem", { portal: securityPortal, itemId: tItemId }); mapView.map= ArcGISRuntimeEnvironment.createObject("Map", { item: item }); }
... View more
07-27-2020
11:13 PM
|
0
|
1
|
848
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 12-28-2020 10:30 PM | |
| 1 | 12-27-2020 09:03 PM | |
| 1 | 05-17-2020 10:15 PM | |
| 2 | 04-21-2020 10:39 PM | |
| 3 | 09-09-2020 08:44 PM |
| Online Status |
Offline
|
| Date Last Visited |
04-30-2024
05:15 AM
|