|
POST
|
Hi, the filename does have an upper case "E" so I think that the line should actually be including like so: #include "Error.h" Thanks, Luke
... View more
08-11-2017
06:13 AM
|
0
|
0
|
1192
|
|
POST
|
Hi Norbert, Here's a screenshot of what I see when I run my example code above. The Brest data you mention is a SceneLayer I believe - here is the Url: http://tiles.arcgis.com/tiles/P3ePLMYs2RVChkJx/arcgis/rest/services/Buildings_Brest/SceneServer/layers/0
... View more
08-09-2017
07:17 AM
|
0
|
4
|
2264
|
|
POST
|
Hi Norbert, I have some simple code which adds a ModelSceneSymbol graphic following the above approach - let me know if this is not what you are trying to do. Make sure you have the anchor position for the symbol set to "Bottom" otherwise the centre-point of the model will be on the ground. I do not have a .flt format model to test with unfortunately so I have used an .lwo from one of our samples. // Create a scene using the topographic BaseMap Scene* scene = new Scene(Basemap::topographic(this), this); // create a new elevation source from Terrain3D rest service ArcGISTiledElevationSource* elevationSource = new ArcGISTiledElevationSource( QUrl("http://elevation3d.arcgis.com/arcgis/rest/services/WorldElevation3D/Terrain3D/ImageServer"), this); // add the elevation source to the scene to display elevation scene->baseSurface()->elevationSources()->append(elevationSource); // Create a scene view, and pass in the scene m_sceneView = new SceneGraphicsView(scene, this); // set the sceneView as the central widget setCentralWidget(m_sceneView); GraphicsOverlay* overlay = new GraphicsOverlay(this); // Edinburgh
Point p(-3.1774341277692018, 55.946948955260694, 0., SpatialReference::wgs84()); ModelSceneSymbol* mss = new ModelSceneSymbol(QUrl("~/ArcGIS/Runtime/Data/3D/SkyCrane/SkyCrane.lwo")); mss->setAnchorPosition(SceneSymbolAnchorPosition::Bottom); mss->setHeight(2000); mss->setWidth(2000); mss->setDepth(2000); Graphic* g = new Graphic(p, mss, this); overlay->graphics()->append(g); overlay->setSceneProperties(LayerSceneProperties(SurfacePlacement::Draped)); m_sceneView->graphicsOverlays()->append(overlay);
... View more
08-09-2017
01:44 AM
|
1
|
1
|
2264
|
|
POST
|
Hi Norbert - apologies for the delay in responding to your question. I will see if I can replicate your problem with a simple application - just to confirm the workflow: - Create a scene with a basemap (e.g. topographic) - add an elevation source - add a graphic which uses a ModelSceneSymbol taking a model in .flt format - set the SurfacePlacement mode to be "Draped" Let me know if this is not the approach you are using. Thanks, Luke
... View more
08-09-2017
01:24 AM
|
0
|
2
|
2264
|
|
POST
|
Hi Takahiro KAMIYA, thanks for reporting this problem. I am able to reproduce the memory issue that you are seeing and have a logged an issue to investigate further. However, there are a few ways to deal with this in your example code: - the first is that you do not need to create a new Symbol for every Graphic which you create in the loop. If you create one Symbol it can be passed to the constructor of each Graphic (this should reduce the amount of memory you are allocating) - secondly, you are providing the "this" object as the parent QObject for both the Symbols and the Graphics which means that they will be preserved until the parent object is deleted (in this case when the app exits). Appending the graphic to the GraphicsListModel does not transfer ownership so it will not be freed when the model is cleared. One way to tackle this is to provide a "local parent" which you can delete whenever you clear the model - e.g. QObject* localParent = new QObject(this); // new local parent object ... Graphic *g = new Graphic(polyBUilder.toGeometry(), nestingSymbol, localParent); // pass as parent instead of this ... model->clear(); // when you clear the model also delete the parent to delete all of the child objects delete localParent; I hope that helps, Luke
... View more
08-07-2017
07:10 AM
|
2
|
1
|
913
|
|
POST
|
Hi taner koka, Have you added the ssl libs to your Qt kit? That can be the cause of ssl issues on android. There are some instructions at System requirements—ArcGIS Runtime SDK for Qt | ArcGIS for Developers . I hope that helps, Luke
... View more
07-20-2017
04:19 AM
|
0
|
2
|
1226
|
|
POST
|
Hi Norbert - thanks for the feedback, I will pass that on. I'm based in Scotland so it's morning here for me. Thanks, Luke
... View more
07-20-2017
03:45 AM
|
1
|
0
|
2033
|
|
POST
|
Hi Norbert - sorry, I wasn't very clear. The data used by the samples is downloaded on demand and goes to a separate location (based on the Qt home location) - depending on your platform it will be something like: - Windows: c:\Users\[user_name]\ArcGIS\Runtime\Data - Mac: ~/ArcGIS/Runtime/Data - Linux: ~/ArcGIS/Runtime/Data
... View more
07-20-2017
02:26 AM
|
2
|
1
|
2033
|
|
POST
|
Hi Norbert, I believe there have been some updates made to the stylx file for 100.1 The sample, when run from the viewer, will download the file if it is missing - possibly both samples viewers are using the same (older?) version of the file. If you delete the file from ...ArcGIS/Runtime/Data/styles/mil2525d.stylx and run again it should download the latest version. Please let me know if you are still getting inconsistent results. Thanks, Luke
... View more
07-20-2017
01:46 AM
|
0
|
0
|
2033
|
|
POST
|
Hi, support for ImageServiceRaster was added to the Qt API at version 100.1 - if you want to load this type of data I think you will need to upgrade your Runtime version. Hope that helps, Luke
... View more
07-17-2017
03:48 AM
|
0
|
0
|
665
|
|
POST
|
Hi Paulraj J, If you add the following code to your createAndAddRasterLayer function you should see the WKID of the spatial reference from your raster layer logged to the QtCreator console: connect(rasterLayer, &RasterLayer::doneLoading, this, [this, rasterLayer](Error loadError) { if (!loadError.isEmpty()) { qDebug() << loadError.message() << loadError.additionalMessage(); return; } m_mapView->setViewpointCenter(rasterLayer->fullExtent().center(), 80000); qDebug() << "MapView wkid" << m_mapView->spatialReference().wkid(); qDebug() << "rasterLayer wkid" << rasterLayer->spatialReference().wkid(); }); For example, with a local file I am using I see: rasterLayer wkid 26910 If the reported wkid is 0 then your raster is not getting loaded with a valid Spatial Reference and so the position that you create the graphics at will not match. It also looks like your dataPath is missing a directory separator at the end - I think at the moment the url you are passing would be "C:\Users\TAS\ArcGIS\Runtime\Data\rasterMap.tif" - but I could be wrong. I hope that helps, Luke
... View more
06-29-2017
01:34 AM
|
1
|
1
|
1187
|
|
POST
|
Hi Paulraj J, could I just confirm that your are using version 10.2.X of the SDK and not the 100.0 release? For version 100.0, this GitHub repository (arcgis-runtime-samples-qt/ArcGISRuntimeSDKQt_CppSamples at master · Esri/arcgis-runtime-samples-qt · GitHub ) has some examples of the kinds of things you are doing. The code in the link you posted would not be valid If you are using 10.2.6, perhaps you could provide some more details of how your project is set up? E.g. are you using QtCreator as your IDE? Luke
... View more
06-28-2017
06:19 AM
|
0
|
3
|
1187
|
|
POST
|
Excellent - I'm glad that's working for you now. It might be worth making the SimpleLineSymbol a ptr type - I'm not sure what will happen when the local simpleLineSymbol goes out of scope and is destructed since the Graphic will continue to exist and need to be rendered... You may also want to consider giving your other ptr objects (e.g. the Graphic) a parent QObject so that they are cleaned up. For example you could pass "this" as the parent to these types if you want them to be cleaned up when the current object is destroyed.
... View more
06-22-2017
02:35 AM
|
1
|
0
|
1593
|
|
POST
|
Hi there, Can you try providing the Graphic* that you create with a Symbol (for example a SimpleLineSymbol). The Graphic class should have c'tor that accepts a Symbol* or you can call Graphic::setSymbol. Let me know if that helps. Thanks, Luke
... View more
06-22-2017
01:56 AM
|
0
|
2
|
1593
|
|
POST
|
Hi Norbert, If you are trying to draw a cuboid which has irregular z values and don't think that extrusion will work, another option could just be to draw a series of vertical polygons for the faces of the shape. Here's some example code that draws the sides of a 3d shape with some variation in the z values. Note you could probably do this in a more elegant fashion using a multi part polygon. SimpleLineSymbol* outlineSym = new SimpleLineSymbol(SimpleLineSymbolStyle::Solid, Qt::black, 4, this); SimpleFillSymbol* fillSym = new SimpleFillSymbol(SimpleFillSymbolStyle::Solid, Qt::red, outlineSym, this); PolygonBuilder* bldr = new PolygonBuilder(m_sceneView->spatialReference(), this); bldr->addPoint(Point(0., 0., 40000)); bldr->addPoint(Point(0., 1., 50000)); bldr->addPoint(Point(0., 1., 100000)); bldr->addPoint(Point(0., 0., 100000)); Graphic* g1 = new Graphic(bldr->toPolygon(), fillSym, this); PolygonBuilder* bldr2 = new PolygonBuilder(m_sceneView->spatialReference(), this); bldr2->addPoint(Point(0., 1., 50000)); bldr2->addPoint(Point(1., 1., 50000)); bldr2->addPoint(Point(1., 1., 100000)); bldr2->addPoint(Point(0., 1., 100000)); Graphic* g2 = new Graphic(bldr2->toPolygon(), fillSym, this); PolygonBuilder* bldr3 = new PolygonBuilder(m_sceneView->spatialReference(), this); bldr3->addPoint(Point(1., 1., 50000)); bldr3->addPoint(Point(1., 0., 50000)); bldr3->addPoint(Point(1., 0., 100000)); bldr3->addPoint(Point(1., 1., 100000)); Graphic* g3 = new Graphic(bldr3->toPolygon(), fillSym, this); PolygonBuilder* bldr4 = new PolygonBuilder(m_sceneView->spatialReference(), this); bldr4->addPoint(Point(1., 0., 50000)); bldr4->addPoint(Point(0., 0., 40000)); bldr4->addPoint(Point(0., 0., 100000)); bldr4->addPoint(Point(1., 0., 100000)); Graphic* g4 = new Graphic(bldr4->toPolygon(), fillSym, this); m_overlay->graphics()->append(g1); m_overlay->graphics()->append(g2); m_overlay->graphics()->append(g3); m_overlay->graphics()->append(g4); Does that help with your problem? Luke
... View more
06-06-2017
07:19 AM
|
0
|
1
|
906
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 05-04-2018 04:22 AM | |
| 1 | 11-02-2022 06:25 AM | |
| 1 | 07-12-2022 05:35 AM | |
| 4 | 10-21-2021 01:58 AM | |
| 1 | 07-12-2021 01:09 AM |
| Online Status |
Offline
|
| Date Last Visited |
10-23-2024
09:16 AM
|