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

multiple outputs? #112

Closed
rpodgorny opened this issue Oct 21, 2021 · 7 comments
Closed

multiple outputs? #112

rpodgorny opened this issue Oct 21, 2021 · 7 comments

Comments

@rpodgorny
Copy link

hi, is there a way to provide multiple outputs? if not, what should be done to add such feature? thanks!

@any1
Copy link
Owner

any1 commented Oct 21, 2021

There is a neatvnc issue for this: any1/neatvnc#19

Neatvnc already has the public interface for it (see nvnc_display), but it's not implemented yet behind the scenes. What's required to implement the feature is to move the encoders from struct nvnc into struct nvnc_display, some more refactoring and then reading the display layout from the compositor in wayvnc and have it create an nvnc_display per output.

@lack
Copy link
Collaborator

lack commented Sep 28, 2022

If/when you do this, can you make it optional please? I actually like the fact that wayvnc only shows one of my displays (fits better in my client!)

@lack
Copy link
Collaborator

lack commented Sep 30, 2022

As discussed elsewhere, we have so far identified 5 different use-cases around what to do when VNC connects to a remote system with multiple displays:

  • Show all the displays as one giant screen (this is what x11vnc does)
  • Show only one display in the VNC client, but have a mechanism (keybind maybe?) to switch to other displays
    • Update: implemented via wayvncctl output-cycle and wayvnctl output-set
  • Show only one display in the VNC client, and temporarily disable all other displays (so all windows & desktops move to this display), and undo on disconnect (I like this for sway)
  • Create a new display as a side-car and extend the existing displays with it (effectively use a vnc client as an additional monitor!)
  • Create a side-car output and move ALL content to it, and undo on disconnect (I like this better than the 2nd option above)

@lack
Copy link
Collaborator

lack commented Nov 13, 2022

I have completed a series of PRs that implement part of this.

#171 introduces the wayvncctl command line tool, which can send IPC messages to a running wayvnc instance. And one of the commands I implemented is set-output which allows runtime switching of the Wayland output device.

So now you can set up a keybinding in your environment to run:

wayvncctl set-output --cycle=next

which will cycle through all your multiple outputs on-the-fly.

And #178 introduces wayvncctl events that can be used to run a script on every client connect/disconnect, so some clever scripting could maybe accomplish more of these scenarios!

@lack
Copy link
Collaborator

lack commented Dec 15, 2022

Just finishing up #200 which adds an example script to disable all outputs but one when a client connects, and re-enable them on disconnect.

@lack
Copy link
Collaborator

lack commented Jan 18, 2023

In light of the current state of support, I'm closing this issue and opening a new one for each of the outstanding use cases.

@lack
Copy link
Collaborator

lack commented Jan 18, 2023

Closing this because multiple outputs are now pretty nicely supported.

@rpodgorny : If the work done so far doesn't meet your needs, please comment on the new related issues (#225 or #226), or open a new issue with more info about what behaviors you'd like to see with wayvnc and multiple outputs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants