Post

Replies

Boosts

Views

Activity

VISIONOS: how to detect if the user closes a window vs a window going into the background
For context, we have a fully immersive application running on visions. The application starts with a standard View/menu, and when the user clicks an option, it takes you to fully immersive mode with a small floating toolbar window that you can move and interact with as you move around the virtual space. When the user clicks the small x button below the window, we intercept the scenePhase .background event and handle exiting immersive mode and displaying the main menu. This all works fine. The problem happens if the user turns around and doesn't look at the floating window for a couple of minutes. The system decides that the window should go into the background, and the same scenePhase background event is called - causing the system to exit immersive mode without warning. There seems to be no way of preventing this, and no distinction between this and the user clicking the close button. Is there a reliable way to detect if the user intentionally clicks the close button vs the window from going into the background through lack of use? onDisappear doesn't trigger. thanks in advance
1
1
648
Jun ’24
VisionOS: translucent view show blurred passthrough background instead of immersive background
Hi We have an issue where the blurred background shown behind the Views is incorrect. We are using the compositor layer to render a fully immersive scene using Metal, so there is no real world passthrough. We have a couple of SwiftUI Views in the scene that have translucency and the glassBackground effect enabled. We expected that the background would show the blurred immersive scene, in the same way it shows the blurred real world in passthrough mode. Instead, it seems to still show the blurred real world, which feels strange from the user perspective. This is only visible on-device, in the simulator the background is always black. Thanks Mark
0
0
507
Feb ’24