From 9f42da23f61a116f0687d30db702b3b433fd322f Mon Sep 17 00:00:00 2001 From: Alexander Grothe Date: Wed, 3 Jan 2018 13:19:59 +0100 Subject: [PATCH] ForceFullCompositionPipeline for nvidia cards to prevent screen tearing when playing video with xineliboutput-sxfe or other video players which use opengl components --- Manual.org | 11 +++++++++-- roles/yavdr-xorg/templates/xorg.conf.j2 | 8 ++++++-- 2 files changed, 15 insertions(+), 4 deletions(-) diff --git a/Manual.org b/Manual.org index 739d0a8..874c22b 100644 --- a/Manual.org +++ b/Manual.org @@ -135,6 +135,9 @@ cd yavdr-ansible sudo ./install-yavdr.sh #+END_SRC +We use a callback to generate tags for all roles autmatically: +#+INCLUDE: "ansible.cfg" src conf + ** Install script for local usage #+BEGIN_SRC shell :tangle install-yavdr.sh :shebang "#!/bin/bash" if (( $EUID != 0 )); then @@ -2101,7 +2104,9 @@ Section "Screen" Option "ConnectedMonitor" "{{ xorg.primary.connector }}{% if xorg.secondary is defined %}, {{ xorg.secondary.connector }}{% endif %}" Option "UseDisplayDevice" "{{ xorg.primary.connector }}" Option "CustomEDID" "{{ xorg.primary.connector }}:/etc/X11/edid.{{ xorg.primary.connector }}.bin" - Option "metamodes" "{{ xorg.primary.connector }}: {{ xorg.primary.mode }} +0+0" + Option "metamodes" "{{ xorg.primary.connector }}: {{ xorg.primary.mode }} +0+0 {ForceCompositionPipeline=On, ForceFullCompositionPipeline=On}" + Option "AllowIndirectGLXProtocol" "off" + Option "TripleBuffer" "on" Option "SLI" "Off" Option "MultiGPU" "Off" Option "BaseMosaic" "off" @@ -2140,7 +2145,9 @@ Section "Screen" Option "ConnectedMonitor" "{{ xorg.secondary.connector }}" Option "UseDisplayDevice" "{{ xorg.secondary.connector }}" Option "CustomEDID" "{{ xorg.secondary.connector }}:/etc/X11/edid.{{ xorg.secondary.connector }}.bin" - Option "metamodes" "{{ xorg.secondary.connector }}: {{ xorg.secondary.mode }} +0+0" + Option "metamodes" "{{ xorg.secondary.connector }}: {{ xorg.secondary.mode }} +0+0 {ForceCompositionPipeline=On, ForceFullCompositionPipeline=On}" + Option "AllowIndirectGLXProtocol" "off" + Option "TripleBuffer" "on" Option "SLI" "Off" Option "MultiGPU" "Off" Option "BaseMosaic" "off" diff --git a/roles/yavdr-xorg/templates/xorg.conf.j2 b/roles/yavdr-xorg/templates/xorg.conf.j2 index 2658f1c..1bcd268 100644 --- a/roles/yavdr-xorg/templates/xorg.conf.j2 +++ b/roles/yavdr-xorg/templates/xorg.conf.j2 @@ -48,7 +48,9 @@ Section "Screen" Option "ConnectedMonitor" "{{ xorg.primary.connector }}{% if xorg.secondary is defined %}, {{ xorg.secondary.connector }}{% endif %}" Option "UseDisplayDevice" "{{ xorg.primary.connector }}" Option "CustomEDID" "{{ xorg.primary.connector }}:/etc/X11/edid.{{ xorg.primary.connector }}.bin" - Option "metamodes" "{{ xorg.primary.connector }}: {{ xorg.primary.mode }} +0+0" + Option "metamodes" "{{ xorg.primary.connector }}: {{ xorg.primary.mode }} +0+0 {ForceCompositionPipeline=On, ForceFullCompositionPipeline=On}" + Option "AllowIndirectGLXProtocol" "off" + Option "TripleBuffer" "on" Option "SLI" "Off" Option "MultiGPU" "Off" Option "BaseMosaic" "off" @@ -87,7 +89,9 @@ Section "Screen" Option "ConnectedMonitor" "{{ xorg.secondary.connector }}" Option "UseDisplayDevice" "{{ xorg.secondary.connector }}" Option "CustomEDID" "{{ xorg.secondary.connector }}:/etc/X11/edid.{{ xorg.secondary.connector }}.bin" - Option "metamodes" "{{ xorg.secondary.connector }}: {{ xorg.secondary.mode }} +0+0" + Option "metamodes" "{{ xorg.secondary.connector }}: {{ xorg.secondary.mode }} +0+0 {ForceCompositionPipeline=On, ForceFullCompositionPipeline=On}" + Option "AllowIndirectGLXProtocol" "off" + Option "TripleBuffer" "on" Option "SLI" "Off" Option "MultiGPU" "Off" Option "BaseMosaic" "off"