Arcgis Runtime Sdks: Using QML to Build Native Cross-Platform Apps
Total Page:16
File Type:pdf, Size:1020Kb
ArcGIS Runtime SDKs: Using Qt to Build Native Cross-platform Apps Eric Bader @ECBader @ArcGISRuntime Agenda • The case for native apps • What we mean by Cross-platform • QML, C++, Apps, and the ArcGIS Runtime SDK for Qt • Build once, compile it for many • What’s ahead • Questions Why build native apps? • Work online & offline • Access hardware and sensors - GPS, camera, Bluetooth, NFC, etc • Great performance • Publish apps to stores The challenge Swift Objective C MacBook • Lots of platforms iOS iPhone • Lots of devices Windows XCode Mac OS X • Unique development patterns Desktop iPad Java Cocoa - Languages - Frameworks Windows Android Galaxy S 5 - IDEs .NET - Workflows Visual Nexus 10 Surface Android Studio Studio C# Eclipse Linux Windows Embedded Universal Gradle Qt and QML • Cross platform framework • Build native apps • Same source code compiled for each platform • Powered by C++ on the backend (very fast) • Exposed through QML (based on JavaScript) • ArcGIS Runtime SDK for Qt - Mapping API provided by Esri - Brings the power of ArcGIS to your devices ArcGIS Runtime Functionality • Build apps for any platform, any device (almost) • Visualize geographic data – maps, layers, graphics - feature, dynamic, tiled, raster, … • Identify features, query data, and display info pop-ups • Share maps and content across ArcGIS platform • Offline maps, data, routing, geocoding • Powerful analysis and local geometric operations • Loadable resources • Async APIs QML Highly readable JSON/CSS- ArcGIS like syntax Runtime Declarative UI elements Dynamic property binding Imperative JavaScript Code to handle events QML front-end, C++ back-end Cross platform Desktop only UI QtQuick QtQuick QtWidget Runtime Api Qml Qt – C++ Highly-recommended reading “Qt Quick - How to write a cross platform mapping application with a QML front-end and C++ back-end” - Lucas Danzinger https://geonet.esri.com/community/developers/native-app-developers/arcgis-runtime- sdk-for-qt/blog/2016/12/19/qt-quick-how-to-write-a-cross-platform-mapping- application-with-a-qml-frontend-and-c-backend To get there: 1. On http://developers.arcgis.com/qt , click the “Forum” tab 2. On the GeoNet page, click the “Content” tab, then the green icon (Blogs) About the QML and C++ APIs in ArcGIS Runtime SDK for Qt • 1 SDK – 2 APIs • Functionally equivalent • Don’t use components of the C++ and QML APIs together in the same app • JavaScript skills come in handy in the QML tier • Use C++ backend for compute-intensive app logic What You Need for Development • Windows + Visual Studio (2015), Linux, or macOS • Qt SDK and Qt Creator from The Qt Company – http://qt.io • OpenSSL for connected/secured services– need to get these binaries separately Building for Android devices? - OS: Windows, macOS, Linux - The Android SDK & NDK bits - Ant Do NOT WORRY – you don’t need to know how to - Java Developer Kit (JDK) program Android or iOS! • Building for iOS devices? - OS: macOS - Xcode - Apple Developer Subscription • ArcGIS Runtime SDK for Qt - http://developers.arcgis.com/qt Installing the Qt SDK on Windows Installing the Qt SDK on Mac Let’s see it in action! The Esri GeoServices Plugin • Connects Qt-based apps to Esri’s ArcGIS Online services https://doc-snapshots.qt.io/qt5-5.8/location-plugin-esri.html • Add Esri basemaps to your applications - 12 different styles • Locate addresses and coordinates - Uses ArcGIS Online Geosearch Service • Solve Point-to-point routing * - Uses ArcGIS Online Routing Service * A token is only needed for routing Esri GeoServices Plugin demo What’s ahead… ArcGIS Runtime 2017 Release Schedule Q2 Q4 Today 2017 2017 100.1 100.2 100.0 10.2.x equivalency The ‘Engine’ release Update 1 – Equivalency with 10.2.x SUBJECT TO CHANGE! • Complete the 3D viewing support for mobile devices • WMTS layer • Related tables • Toolkits* • Coordinate conversion operations Update 2 – the ‘Engine’ release SUBJECT TO CHANGE! • Geopackage layers – vector and raster • WMS layers • KML layers • Custom transformations • Time-aware layers • Toolkits* • Lots more 3D capabilities…. Resources • Developer Resources – - http://developers.arcgis.com/qt • Connect with us on GeoNet – - https://geonet.esri.com/community/developers/native-app-developers/arcgis-runtime-sdk- for-qt • All samples are shared on GitHub – - https://github.com/Esri/arcgis-runtime-samples-qt • QML Toolkit source code also on GitHub – - https://github.com/Esri/arcgis-runtime-toolkit-qt Questions? .