I haven't found a way to programmatically position the main view in visionOS apps, which seems intentional. While this aligns with user-controlled window placement, it creates a challenge: as users move, they must constantly reposition the main window manually.
A potential solution could be a feature that quickly brings the window to the user, perhaps via a custom gesture. This might improve user experience significantly.
Given my current understanding of visionOS, I may be missing something. I'd appreciate any insights or alternative perspectives on this issue. Thoughts?
The position of the window cannot be modified through programming in VisionOS. For your requirements, I suggest you consider using immersive space to achieve the desired effect. This approach allows the window to move in sync with the user’s movements. To track the user’s head, you can utilize the anchorEnity feature in RealityView.