在不同的监视器上设置不同的子像素渲染

我正在使用双显示器,其中一个旋转了90度。 在旋转的监视器中,字体抗锯齿看起来并不正确(即字符周围有彩虹边框)。

我相信这是因为X在两台显示器上使用相同的子像素渲染顺序。 有没有办法为每个监视器配置不同的子像素渲染顺序? (即,监视器1 = RGB,监视器2 = vRGB)。

您必须将显示器配置为单独的X屏幕,而不是共享桌面。 然后,Ubuntu应该允许您调整单个X屏幕的子像素顺序。

否则,跨越两个具有不同子像素顺序的显示设备的窗口会发生什么? 甚至更棘手,两个显示器在克隆模式下具有不同的物理顺序(RGB与BGR)。

这是目前所有操作系统的已知限制,需要进行重大的重新设计才能解决问题。 动态调整是不可行的,因为执行渲染的库必须知道您所在的屏幕并动态调整。 另外,假设您在一个屏幕上有一半窗口而在另一个屏幕上有一半 – 它不知道选择哪个。

设置多个X屏幕:

  1. 启动并重新配置X. sudo dpkg-reconfigure -phigh xserver-xorg按照步骤设置主显示屏。 (我不知道从CLI执行此特定步骤的方法)
  2. 打开一个终端和
    lspci
    这应该会为您提供设备及其总线ID的列表。 找到显卡并记下他们的公交车ID。
  3. xorg.conf复制为xorg.conf.orig ,然后打开它: sudo vi /etc/X11/xorg.conf
  4. 请继续阅读此 内容 ,以确保您可以根据需要自定义它。
  5. 现在制作两个Device部分并列出要共享的卡的BusID ,并列出驱动程序,如下所示:

     Section "Device" Identifier "nvidia0" # Your preferred driver Driver "nvidia" # Edit the BusID with the location of your graphics card BusID "PCI:2:0:0" Screen 0 EndSection Section "Device" Identifier "nvidia1" # Your preferred driver Driver "nvidia" # Edit the BusID with the location of your graphics card BusId "PCI:2:0:0" Screen 1 EndSection 
  6. 现在创建两个Screen部分(当然,您选择的参数,唯一需要匹配的是本节中的Device与前一个中的Identifier ):

     Section "Screen" Identifier "Screen0" Device "nvidia0" Monitor "Monitor0" DefaultDepth 24 Subsection "Display" Depth 24 Modes "1600x1200" "1024x768" "800x600" "640x480" EndSubsection EndSection Section "Screen" Identifier "Screen1" Device "nvidia1" Monitor "Monitor1" DefaultDepth 24 Subsection "Display" Depth 24 Modes "1600x1200" "1024x768" "800x600" "640x480" EndSubsection EndSection 
  7. 现在为每个监视器创建一个Monitor部分:

     Section "Monitor" Identifier "monitor name here" EndSection Section "Monitor" Identifier "monitor name here" # Rotate as you want (your question says one is rotated) Rotate "left" EndSection 
  8. 最后,更新ServerLayout部分以使用和定位两个Screen部分:

     Section "ServerLayout" ... Screen 0 "Screen0" Screen 1 "Screen1" leftOf "Screen0" ... EndSection 
  9. 重启X并交叉手指! 如果它确实有效,那么可以根据需要对其进行微调。

现在为SUBPIXEL RENDERING ORDER~/font.conf或/ etc / X11 / font.conf`中对font.conf进行此更改。 BGR

Interesting Posts