新内拉玛

新内拉玛

我想设置双屏配置,即两个完全独立的 :0.0 和 :0.1 屏幕,它们彼此之间没有任何关系。以下配置有效,只是屏幕 :0.0 显示在 VGA 输出上(奇怪的是它被称为 DP-1),但我希望它显示在 :0.1 上,而 :0.0 应该是 HDMI-1 输出:

Section "ServerLayout"
    Identifier     "Layout0"
    Screen      0  "Screen0" 0 0
    Screen      1  "Screen1" RightOf "Screen0"
    Option         "Xinerama" "0"
EndSection

Section "Monitor"
    Identifier     "DP-1"
    Option         "DPMS" "true"
EndSection

Section "Monitor"
    Identifier     "HDMI-1"
    Option         "DPMS" "true"
EndSection

Section "Device"
    Identifier     "Device0"
    BusID          "PCI:0:2:0"
    Screen          0
    Driver         "modesetting"
    Option         "Monitor-HDMI-1" "HDMI-1"
EndSection

Section "Device"
    Identifier     "Device1"
    BusID          "PCI:0:2:0"
    Screen          1
    Driver         "modesetting"
    Option         "Monitor-DP-1" "DP-1"
EndSection

Section "Screen"
    Identifier     "Screen0"
    Device         "Device0"
    Monitor        "HDMI-1"
    DefaultDepth    24
    SubSection     "Display"
        Depth       24
    EndSubSection
EndSection

Section "Screen"
    Identifier     "Screen1"
    Device         "Device1"
    Monitor        "DP-1"
    DefaultDepth    24
    SubSection     "Display"
        Depth       24
    EndSubSection
EndSection

无论我如何命名,xorg 始终将 VGA 输出分配给屏幕:0.0,并且我可以在 Xorg.0.log 中看到以下几行:

[     5.314] (WW) modeset(0): Option "Monitor-HDMI-1" is not used
[     5.412] (WW) modeset(1): Option "Monitor-DP-1" is not used

我没有发布整个日志,因为它有 902 行长,但如果您需要更多信息,我可以从中剪切并粘贴任何内容。

答案1

您可以通过 nvidia 驱动程序的 metamodes 选项执行此操作

Section "Screen"
    Identifier     "Screen0"
    Device         "Device0"
    Monitor        "HDMI-1"
    DefaultDepth    24
    Option         "metamodes" "HDMI-1: nvidia-auto-select +0+0"
    SubSection     "Display"
        Depth       24
    EndSubSection
EndSection

Section "Screen"
    Identifier     "Screen1"
    Device         "Device1"
    Monitor        "DP-1"
    DefaultDepth    24
    Option         "metamodes" "DP-1: nvidia-auto-select +0+0"
    SubSection     "Display"
        Depth       24
    EndSubSection
EndSection

您正在使用的模式设置驱动程序可能存在类似情况。

看起来有一个ZaphodHeads选项你可以尝试一下。来自:https://manpages.debian.org/stretch/xserver-xorg-core/modesetting.4.en.html

Section "Screen"
    Identifier     "Screen0"
    Device         "Device0"
    Monitor        "HDMI-1"
    DefaultDepth    24
    Option         "ZaphodHeads" "HDMI-1"
    SubSection     "Display"
        Depth       24
    EndSubSection
EndSection

Section "Screen"
    Identifier     "Screen1"
    Device         "Device1"
    Monitor        "DP-1"
    DefaultDepth    24
    Option         "ZaphodHeads" "DP-1"
    SubSection     "Display"
        Depth       24
    EndSubSection
EndSection

答案2

新内拉玛

(如果我没记错的话)是桌面跨越。

这就是如何将“2 个显示器变成 1 个显示器”
先删除该选项然后尝试。

除此之外:我相信格式是 XServer # 和 Screen # 所以服务器 0 屏幕 0 或 1:0.0:0.1 或者它是一个逗号......“:0,0”

相关内容