0

I have created a custom hover effect per this WWDC video and many other examples on the net:

https://developer.apple.com/videos/play/wwdc2024/10152/

I can get the button to expand when looked at within a visionOS device and it will invoke a tap event when tapped but there is no click sound like a normal SwiftUI button does in visionOS!

I can't for the life of me figure out why. Any help would be appreciated!

4
  • Can we see code for a minimal reproduction? Commented Feb 28 at 23:07
  • Yes! Here is a VisonOS project demonstrating the problem: GitHub Project Commented Mar 4 at 22:14
  • @bdelliott In order for the 3D content to produce sound, you need to use developer.apple.com/documentation/realitykit/… Commented Mar 6 at 9:21
  • @PogosAnesyan That is for a user defined sound and not a system sound. If I want to manually play a system sound, I can use: AudioServicesPlaySystemSound(SystemSoundID("1306")) but the 1306 is close but not the exact system sound as the system default. I think the user will be able to hear the difference. Commented Mar 7 at 17:52

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.