I am building an iOS app using ArcGIS Runtime SDK (UIKit) that shows property parcel boundaries in AR using WorldScaleSceneView.
Problem: When basemap is visible, the graphic EXACTLY covers the property boundary on the basemap. But when I reduce the basemap opacity to 0, the graphic appears SMALLER than the actual real world property.
Property Details example sample data:
Sample Coordinates:
My Current Setup:
// Scene setup
let scene = AGSScene(basemapStyle: .arcGISImageryStandard)
scene.addElevationSource()
scene.baseSurface?.opacity = 0
arView.locationDataSource = AGSCLLocationDataSource()
arView.translationFactor = 1
// Graphics overlay setup
boundariesGraphicsOverlay.sceneProperties =
AGSLayerSceneProperties(surfacePlacement: .drapedFlat)
// Symbol
AGSSimpleLineSymbol(
style: .solid,
color: UIColor(red: 1.0, green: 1.0, blue: 0.0, alpha: 1.0),
width: 5
)
What I Have Already Tried:
Questions:
Hi @nvsraju0979,
It seems you are using the ArcGIS Runtime Toolkit for iOS which provides an `ArcGISARView` to support a world-scale AR experience rather than the ArcGIS Maps SDK for Swift Toolkit which provides the `WorldScaleSceneView` Toolkit component to support a world-scale AR experience.
In regards to the issue you are encountering, the scene view configuration looks correct. One suggestion to try would be to use the `.absolute` surfacePlacement instead `.drapedFlat` like the ARExample Toolkit sets here.
The issue could be how the graphics are configured before they are added to the graphics overlay. Changing the opacity of the basemap should not change how the graphics are rendered. Do the graphics change in size when rendering over the AR camera feed or are they the wrong size upon initialization? If the graphic is the wrong size upon initialization, this could be because the graphic has the correct location value but is missing the elevation value so it defaults to zero. See this ios sample here and this swift sample here which show how to show hidden pipe infrastructure in AR and use elevation when creating the graphics. Consider using a polyline graphic instead of a simple line symbol graphic if the elevation cannot be set for the simple line symbol.