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

Second screen android support #617

Open
wants to merge 13 commits into
base: master
Choose a base branch
from

Conversation

DavidRGriswold
Copy link
Collaborator

@DavidRGriswold DavidRGriswold commented Mar 3, 2025

Enable support for a second screen on android, either through a physical connection or using screen mirroring through Chromecast or Miracast.

What Currently Works

  • A "Secondary Screen Layout" option has been added to the Settings menu on Android where user can choose between (1) System Default (mirroring) (2) Top Screen Only (3) Bottom Screen Only (4) Side by Side.
  • A secondary window is always enabled at emulation start - either on an invisible virtual display or a physical display if it exists. If the setting is "System Default (mirroring)" the virtual display is used instead
  • It is possible to switch back and forth between the virtual display and physical display using the settings above

Issues and changes yet to be done

  • Test test test

Addresses #351

@rtiangha
Copy link
Collaborator

rtiangha commented Mar 3, 2025

I'd be interested in seeing what the lag might be while casting. Might not matter much if the second screen is mostly static or not used often.

@DavidRGriswold
Copy link
Collaborator Author

I'd be interested in seeing what the lag might be while casting. Might not matter much if the second screen is mostly static or not used often.

The issue is that the most clear use-case involves casting the top screen while keeping the bottom touchscreen on the phone so touch input works as normal. So it would usually be the more active screen getting cast. It works pretty okay in my wifi environment - I wouldn't want to play, like, shovel knight on it, but it's okay for link between worlds type stuff where a little lag is unlikely to result in death.

that said, I think the most likely long-term use for this will be a two-screen android handheld, if such a thing ever comes to be. The DNA Duo on an Ayn Odin 2 basically makes one, but I expect a retroid pocket flip 3 with a smaller bottom screen between the controller parts in a few years.

@OpenSauce04 OpenSauce04 added the squash This pull request should be squashed if approved label Mar 18, 2025
@DavidRGriswold DavidRGriswold marked this pull request as ready for review March 19, 2025 16:32
@DavidRGriswold
Copy link
Collaborator Author

I am pretty sure this is ready for review or at least significant additional testing.

I have tested with vulkan pretty extensively - i have had a couple of crashes here and there but they are not consistently reproducible and I'm not even certain they can be linked to this code. That said there are almost certainly things that can be improved in the programming flow.

@OpenSauce04 OpenSauce04 added this to the 2123 milestone Mar 19, 2025
@DroidlyMobile
Copy link

I'd be interested in seeing what the lag might be while casting. Might not matter much if the second screen is mostly static or not used often.

Citra MMJ has the Media Projection library already integrated into it, and it's amazing to play on a secondary USB C display!!!! Even DNA Mobile Gaming has been developing/designing a detachable portable OLED display to use this!!!

@OpenSauce04 OpenSauce04 modified the milestones: 2123, 2122 Mar 19, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request size/XL squash This pull request should be squashed if approved
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants