3 ms·
> [I want] screen tearing to not happen on X11... If you have AMD hardware that uses the 'amdgpu' driver, then -IME- enabling the TearFree option seems to comp
by simoncion 4y ago
> [I want] screen tearing to not happen on X11...
If you have AMD hardware that uses the 'amdgpu' driver, then -IME- enabling the TearFree option seems to completely eliminate tearing. (Though, I am using KDE, which _also_ has a "Make the compositor use vsync" option... which didn't actually eliminate tearing, when used by itself. But, there _may_ be confounders.)
Anyway. Drop this into a file named "$WHATEVER.conf" in '/etc/X11/xorg.conf.d' (or into your xorg.conf), and you should be good to go:
Section "Device"
Identifier "AMD"
Driver "amdgpu"
Option "TearFree" "on"
EndSection
Alternatively, you could enable the setting with the 'xrandr' tool:
xrandr --output $OUTPUT_NAME --set TearFree on
but that only sticks for as long as the affected X server stays up.
- wmf 4y agoWhat a great example. This stuff should be fixed by default.
- simoncion 4y agoFWIW, I assume it adds a (maybe one frame) delay. It _is_ on by default when you've rotated or transformed the output (and for "secondary outputs".... whatever a "secondary" output is). From 'amdgpu(4)`: Option "TearFree" "boolean" Set the default value of the per-output 'TearFree' property, which controls tearing prevention using the hardware page flip‐ ping mechanism. TearFree is on for any CRTC associated with one or more outputs with TearFree on. Two separate scanout buffers need to be allocated for each CRTC with TearFree on. If this op‐ tion is set, the default value of the property is 'on' or 'off' accordingly. If this option isn't set, the default value of the property is auto, which means that TearFree is on for rotated outputs, outputs with RandR transforms applied and for RandR 1.4 secondary outputs, otherwise off. Edit: Also, distro packagers are quite able to set this on-by-default. It is configurable, after all. If you don't like the default that your distro has chosen, go chat at em. :)
- ajvs 4y agoThe default is supposed to be Wayland, since Xorg is no longer being actively developed. Though it's taking some distros a while to move to it as default.