Skip to content

Latest commit

 

History

History
73 lines (46 loc) · 4.36 KB

SCREEN_SETUP.md

File metadata and controls

73 lines (46 loc) · 4.36 KB

Screen Setup

This is a small guide for setting up xorg screens. This document serves the purposes of providing references for configuring the X server screen layout through configurations and highlighting the important parts in them. X does not have functionality for setting up screens on the fly, but there are some extensions that may be of use.


DMX

The Distributed Multihead X extension is an X proxy server that allows adding screens dynamically.
DMX can connect to multiple backend X servers and treat each one as a separate screen. A new screen can be attached using DMXAddScreen though it is not clear from the wording of the docs whether the number of screens itself is fixed initially or not. In general, DMX can come in handy for serving the ultimate business goal of this project.


Configuring Xorg

for thorough docs on how to configure xorg check the Manual here.
As a side note, xorg doesn't require a config file and normally auto detects the devices and provides a default layout. a different config is required if a non trivial configuration is to be setup.

Overview

The xorg config is defined in terms of sections, subsections, entries and options. Most important sections for this are ServerLayout, Monitor, Screen, Device and maybe a little less relevant is the Modes Section.

Server Layout

This is the root section of a configuration. It combines multiple Screens, InputDevices and other config options to provide a complete layout.

Device

This section represents a video device. The most relevant config entries and options for this section are the following.

  • Identifier(mandatory): Specifies the config specific ID of this device.
  • Driver(mandatory): Specifies the driver for this device.
  • BusID: specifies the hardware specific bus ID, usually PCI, in which the physical device is connected. This is useful when multiple devices are present.
  • ScreenID(important): This is useful when having multiple CRTCs and if multiple screens on the same device is required. A separate Device Section is defined with each section having a different ScreenID entry.
    Note: This was tested on virtual displays and it was found out that it does NOT work. Maybe there are some undocumented limitations or a default option that prevents it. For verifying this, please use actual multiple physical displays and check the ZaphodHeads option(more on that in the notes).
  • Option "Monitor-outputname" "monitorsection": In line with the design of RandR, this ties a monitor to a specific output of the device.

Monitor

This section defines a physical monitor. The only relevant entry for this section is the config specific Identifier entry.

Screen

This section couples together a Device and a Monitor to be used in the layout. The relevant config entries are the following.

  • Identifier(mandatory): Specifies the config specfic ID of this screen.
  • Device(mandatory): Specifies the device to be used for this screen.
  • Monitor: Specifies the monitor to be used for this screen.

Modes

This is a not-so-important section which can provide some modes independent of the screens.


Notes

  • In the old times, video devices did not provide multi head support and the standard setup was a one screen, one card and one monitor setup. A multi-head based on one head per screen aka Zaphod Mode, or a multi-head based on multiple monitors on one screen as supported by randr can be setup.
  • There are some undocumented options in the xorg config like the ZaphodHeads option.
  • Generally, a possible approach could setting up the layout of screens initially, then manipulating the outputs dynamically through randr.
  • DMX is not part of the list of implemented extensions in python-xlib.
  • DMX remains a possible option but all of the proposed options would preferably require testing on an actual physical displays.
  • For setting up virtual devices the xf86-video-dummy driver can be used to setup a virtual screen.

Additional References