Skip to content

Commit 68c742f

Browse files
authored
Merge pull request #626 from Esri/destiny/default-tracking-mode
AR: default tracking mode
2 parents d551de5 + 96878b7 commit 68c742f

File tree

8 files changed

+8
-14
lines changed

8 files changed

+8
-14
lines changed

Examples/Examples/WorldScaleExampleView.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ struct WorldScaleExampleView: View {
4949
@State private var locationDataSource = SystemLocationDataSource()
5050

5151
var body: some View {
52-
WorldScaleSceneView(trackingMode: .worldTracking) { proxy in
52+
WorldScaleSceneView { proxy in
5353
SceneView(scene: scene, graphicsOverlays: [graphicsOverlay])
5454
.onSingleTapGesture { screen, _ in
5555
print("Identifying...")

Sources/ArcGISToolkit/Components/Augmented Reality/WorldScaleSceneView.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ public struct WorldScaleSceneView: View {
6363
/// and view drawing mode.
6464
public init(
6565
clippingDistance: Double? = nil,
66-
trackingMode: TrackingMode,
66+
trackingMode: TrackingMode = .worldTracking,
6767
sceneViewBuilder: @escaping (SceneViewProxy) -> SceneView
6868
) {
6969
self.clippingDistance = clippingDistance

Sources/ArcGISToolkit/Documentation.docc/Resources/WorldScaleSceneView/WorldScaleSceneViewStep1.swift

+1-2
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,7 @@ import ArcGISToolkit
55
struct WorldScaleExampleView: View {
66
var body: some View {
77
WorldScaleSceneView(
8-
clippingDistance: 400,
9-
trackingMode: .worldScale
8+
clippingDistance: 400
109
)
1110
}
1211
}

Sources/ArcGISToolkit/Documentation.docc/Resources/WorldScaleSceneView/WorldScaleSceneViewStep2.swift

+1-2
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,7 @@ struct WorldScaleExampleView: View {
2020

2121
var body: some View {
2222
WorldScaleSceneView(
23-
clippingDistance: 400,
24-
trackingMode: .worldScale
23+
clippingDistance: 400
2524
) { _ in
2625
SceneView(scene: scene)
2726
}

Sources/ArcGISToolkit/Documentation.docc/Resources/WorldScaleSceneView/WorldScaleSceneViewStep3.swift

+1-2
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,7 @@ struct WorldScaleExampleView: View {
2121

2222
var body: some View {
2323
WorldScaleSceneView(
24-
clippingDistance: 400,
25-
trackingMode: .worldScale
24+
clippingDistance: 400
2625
) { _ in
2726
SceneView(scene: scene)
2827
}

Sources/ArcGISToolkit/Documentation.docc/Resources/WorldScaleSceneView/WorldScaleSceneViewStep4.swift

+1-2
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,7 @@ struct WorldScaleExampleView: View {
2121

2222
var body: some View {
2323
WorldScaleSceneView(
24-
clippingDistance: 400,
25-
trackingMode: .worldScale
24+
clippingDistance: 400
2625
) { _ in
2726
SceneView(scene: scene)
2827
}

Sources/ArcGISToolkit/Documentation.docc/Tutorials/WorldScaleSceneViewTutorial.tutorial

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111

1212
@Steps {
1313
@Step {
14-
Initialize a `WorldScaleSceneView`. Specify the clipping distance and tracking mode.
14+
Initialize a `WorldScaleSceneView`. Specify the clipping distance. The tracking mode is set to `worldTracking` by default.
1515

1616
The clipping distance is the distance in meters that the ArcGIS Scene data will be clipped to.
1717
The tracking mode determines the type of tracking configuration that will be used by the AR view.

Tests/ArcGISToolkitTests/ARTests.swift

+1-3
Original file line numberDiff line numberDiff line change
@@ -151,9 +151,7 @@ import XCTest
151151
}
152152

153153
func testWorldScaleWorldTrackingInitWithDefaults() throws {
154-
let view = WorldScaleSceneView(
155-
trackingMode: .worldTracking
156-
) { _ in
154+
let view = WorldScaleSceneView { _ in
157155
SceneView(scene: Scene())
158156
}
159157

0 commit comments

Comments
 (0)