-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Add iOS External Screen support #484
Conversation
Yeah, I kinda regret this code but the way vmDisplay and vmInput are set is:
So when you copy If I have time, I might go through and re-arch this who procedure to be more understandable. This bad design was a result of incrementally adding code as new features were introduced. |
You are right, the values are still nil when the view loads. I changed the implementation to grab the I read through some of the CoreSpice code and have a gist of what happens to create the virtual display. However I don't see anywhere where I could call a function to create another display. When a new display channel is needed that seems to be signaled by Spice on |
Not 100% sure on this but look at |
Thanks for that hint. I was able to extend the CSDisplayMetal implementation to allow me to request a resolution for a different display. However when that call happens, I get the following error printed in the console:
The Worth noting is that I tried this with a Win98 VM without the spice tools installed. |
That happens normally. libspice-gtk should automatically send the monitor config once the agent does connect (SPICE guest tools needs to be installed). Calling |
Oh alright. I'll try it again with the prebuilt VM that includes the spice tools. |
Just tried it with the "Debian 10.4 (LDXE) ARM" vm from the website, which includes SPICE tools. The output after the
However |
Do you get the log message |
No, I don't get that message. I tried to run |
|
Just to be clear, auto-resolution changes do work? (i.e. rotating the screen) |
No, that isn‘t working. In VM Display settings, Fit to screen is enabled, Retina mode is disabled. I‘m on iPad Pro 12.9 2nd gen, jailbroken on iOS 13.3. The VM is the "Debian 10.4 (LDXE) ARM" from the website (on the website it says that auto resolution change is not supported due to a bug, is that up to date?) Maybe you could try this branch on one of your devices & VMs? |
Still trying to figure out why the second display won't show up but I've ran into a couple of other issues: I've gotten rare crashes in Also, it seems like when I rotate the iPad (simulator) or use split view, it no longer sends the right resolution to SPICE. |
Oh. Duh. We only have one VGA device. https://people.freedesktop.org/~teuf/spice-doc/html/ch02s07.html |
I tried the suggestion from the website you linked to, which was to add the GEMU argument “-vga qxl -device qxl”. That results in the following error message when the VM starts: Edit: #303 seems related: “Add vga option (cirrus / std / vmware / qxl)” |
9a0c5c2
to
ca93319
Compare
fb397bc
to
bd66c2e
Compare
b4469a3
to
683df96
Compare
9b9bdec
to
54153f7
Compare
Hi I am just curious. What's the current status on this? Is it working? If yes, how does it work, what are the current caveats, issues, supported VM OSes, requirements... ? A Samsung Dex like experience running a VM on my iPhone would be amazing IMO. |
It's not working and needs further development to get to a working state. |
The rework in CocoaSpice on the dev branch should solve some of the issues but also require a lot of refactoring to be done. |
9c70901
to
cde596e
Compare
External displays have been implemented in 4.0.0 |
This is currently very WIP! This is eventually intended to implement #220.
Current status: if an external screen is connected, the VM display will be moved there. This breaks touch and cursor input to the VM, which will require separating the touch handling from the
MTKView to fix
. As a 'band aid' fix, I have redirected touch handling to the VM container view (VMDisplayMetalViewController+Touch.m
), which enables a small portion of the screen to be used to control the VM pointer.Help needed with mirroring mode: I have attempted to implement a display mirroring mode by introducing a second
MTKView
on a newVMExternalDisplayMetalViewController.swift
and setting itsUTMRenderer
,sourceDisplay
andsourceInput
the same as the internal ones. The relevant code is inExternalScreenController.swift
line 126. Unfortunately with regards to theUTMRenderer
andMTKView
, I have no idea what I'm doing. So if you use this mode by uncommenting it, that currently results in a blank screen.