Skip to content

UltraVNC monitor switch support #2031

@berik-99

Description

@berik-99

I’m using this great VNC client as a library inside my website and it works very well, but I’ve encountered an issue when connecting to an UltraVNC server running on a machine with multiple monitors.

When the connection is established, only one monitor is actually displayed, but the canvas size matches the combined resolution of all monitors.
Example: with two Full HD monitors, the canvas becomes 3840×1080, but only the left half contains the actual screen image, while the rest remains filled with the default background color.

This problem does not occur with TightVNC, which correctly shows all monitors together.

After investigating, I found that UltraVNC streams only one monitor at a time, and its native viewer has a dedicated button to switch between monitors.
If I connect both noVNC and the UltraVNC viewer simultaneously, and I press the “switch monitor” button in UltraVNC Viewer, noVNC immediately updates as well, showing the newly selected monitor with the correct dimensions.

It would be extremely helpful if the client could support UltraVNC’s single-monitor switching behavior, ideally by exposing a method or command that mimics the UltraVNC viewer’s “switch monitor” button. This would allow choosing which monitor to display when connected to an UltraVNC server.

Switching to TightVNC would fix the issue, but company policies require the use of UltraVNC, so replacing the server is not an option.

Additional context: the problem seems tied specifically to how UltraVNC handles multi-monitor setups, streaming only one monitor at a time. A way to control or request the active monitor would solve the issue completely.


Steps to Reproduce

  1. Set up an UltraVNC server on a Windows machine with multiple monitors.
  2. Connect to the server using noVNC (or this VNC client library).
  3. Observe that the canvas resolution equals the combined resolution of all monitors.
  4. Notice that only one monitor is displayed, while the rest of the canvas remains empty / background-colored.
  5. (Optional) Connect simultaneously using the official UltraVNC Viewer.
  6. Press the “Switch Monitor” button in UltraVNC Viewer and observe that noVNC updates accordingly, confirming that UltraVNC streams only one monitor at a time.

Expected Behavior

The client should either:

  • display all monitors correctly (like TightVNC), or
  • provide a way to select which monitor to display, replicating UltraVNC’s monitor-switch button.

Actual Behavior

Only one monitor is rendered, but the canvas spans across the total resolution of all monitors, leaving unused areas blank.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions