|Hi all, help, after i installed ArcGIS Runtime Qt 10.2.3 ....There are no Debug Errors. Same sample code as give in ArcGIS Runtime SDK... An application window pops up however there is no basemap shown.||FYI: Graphic card used is GeForce 9200.|
Solved! Go to Solution.
First of all.. Thanks for your interest....
Kindly chk the following code snippet
Note: There are 3 Scenarios which I tried.
* Scenario 1 and 2 failed during running due Invalid NULL Pointer in Visual Studio file. (I have attached the snapshot of both cases). I believe it is to do something with the type of slash.
* Scenario 3 I tried using QDir and No exception was thrown however no map was loaded into the application.
For easy understanding I have placed Topograpgraphic.tpk in C:/ Drive also.
// set to openGL rendering
m_mapGraphicsView = EsriRuntimeQt::MapGraphicsView::create(m_map, this);
// show Esri logo by default
QString path = EsriRuntimeQt::ArcGISRuntime::installDirectory();
QDir dataDir(path); // using QDir to convert to correct file separator
QString pathSampleData = dataDir.path() + QDir::separator();
//// Local Tiled Basemap Layer using: sdk/samples/data/tpks/Topographic.tpk
// senario 1
QString tiledBaseMapLayer = pathSampleData + "tpks" + QDir::separator() + "Topographic.tpk";
// senario 2
QString temp = ("C:/RasterHillshade.tpk");
// scenario 3
QDir temp_1 = ("C:/RasterHillshade.tpk");
m_tiledLayer = EsriRuntimeQt::ArcGISLocalTiledLayer(temp_1.dirName());//
//// connect to signal that is emitted when the map is ready
//// the mapReady signal is emitted when the Map has obtained a
//// spatial reference from an added layer
connect(&m_map, SIGNAL(mapReady()), this, SLOT(onMapReady()));
Scenario 3 output:
Scenario 1 and 2 should work. However Scenario 3 will not work since it is a directory not a file path that will be returned.
If you do: qWarning() << temp_1.dirName() you will see that in the application output you will get just the tpk name:
My question is: What is the version of Visual Studio are you running? VS 2012?
What is the version of Qt are you using? You will need to run a version of Qt that is above 5.1.1 and it has to be using OpenGL with VS2012.
Jen Trieu | Product Eng.
Thanks Jeanne for your reply... and yes... you are right about Scenario 3. Since I had placed the file in Build directory also... I was expecting it to pick the .tpk file from the file. Anyways... I have checked during Runtime... OPEN GL version : 2.0 .... Qt installed is 5.1.1 with VS 2012 (Downloaded from http://download.qt-project.org/archive/qt/5.1/5.1.1/qt-windows-opensource-5.1.1-msvc2012-x86-offline... )