Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support building for iOS 18 #9

Open
wants to merge 3 commits into
base: visionos-2
Choose a base branch
from
Open

Conversation

carson-katri
Copy link
Contributor

@carson-katri carson-katri commented Jul 25, 2024

Use the camera attribute on RealityView to switch between AR and virtual modes.

<RealityView camera="worldTracking" />
<RealityView camera="virtual" />

The realityViewCameraControls(_:) modifier can be used with the virtual camera mode.

<RealityView camera="virtual" style="realityViewCameraControls(.orbit)" />

Now you can drag to orbit the 3D scene around.

Use the cameraTarget attribute to mark an entity as the target for orbit controls.

<Entity cameraTarget />

Now the camera will automatically reframe to fit this entity as it moves and resizes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant