[iOS] Enable AirPlay audio routing when mirroring
Shafa95 opened this issue · 0 comments
Game or games this happens in
All
What area of the game / PPSSPP
When using PPSSPP on iOS with AirPlay screen mirroring, video is displayed correctly on the TV but audio is not routed. Other apps (e.g. YouTube) present an AirPlay audio option, but PPSSPP does not.
It seems PPSSPP’s iOS audio session is preventing AirPlay routing. Currently it may be using an AVAudioSessionCategoryPlayAndRecord (or similar) which blocks AirPlay by default. The fix could be to configure the audio session to allow AirPlay:
[[AVAudioSession sharedInstance] setCategory:AVAudioSessionCategoryPlayback withOptions:AVAudioSessionCategoryOptionAllowAirPlay error:nil];
This would let iOS expose the AirPlay audio route and allow both video + audio to stream when mirroring.
I don't know Objective-C and I wrote this issue with the help of IA, so some technical consideration could be incorrect.
I would try to solve this on my own, but I don't have a Mac available with Xcode and it would need too much time to setup everything on a Windows PC.
Steps to reproduce:
- Start AirPlay screen mirroring from iPhone to Apple TV or compatible device.
- Launch PPSSPP and start a game (or just move into the menu buttons or selecting games. Sound effects should be played).
- Video shows on the TV, but no audio plays.
What should happen
Both audio and video should route over AirPlay, like in other iOS media apps.
Logs
No response
Platform
iOS
Mobile device model or graphics card (GPU)
iPhone 15 Pro with iOS 18.6.2 (Apple A17 Pro GPU)
PPSSPP version affected
v1.19.3
Last working version
No response
Graphics backend (3D API)
Vulkan
Checklist
- Test in the latest git build in case it's already fixed.
- Search for other reports of the same issue.
- Try resetting settings or older versions and include if the issue is related.
- Try without any cheats and without loading any save states.
- Include logs or screenshots of issue.