-
Notifications
You must be signed in to change notification settings - Fork 732
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Tearing/Vsync issues in Cinnamon/Clutter #3423
Comments
Is this something demonstrable with Intel graphics? |
nVidia hardware so far as I said. No clue about Intel. Do you have Intel hardware? Do you see any screen tearing in games or movies in Totem? This has always been a problem for me on Mint. If there is a setting that successfully can force vsync on in every app perhaps it should be made the default configuration setting for all nVidia hardware. |
Intel here (4500MHD) and there is tearing everywhere out of the box. Adding some Clutter environment variable hacks gets rid of it but then everything is jerky and slow to respond (dragged windows lag behind the cursor). |
What Clutter variable are you using out of curiosity? One or both of these?
|
Tried each of those as well as both, no dice. Note: GNOME and most other Xorg DEs also seem to do this. Weston doesn't. |
But is that what you used to eliminate tearing? As for things slowing down when you did apply whatever tearing fix you used, that might be due to some inefficiency in Clutter and/or the particular fix you used. If I were you I'd give Compton a try and see if you get no tearing + better performance than Clutter. Corvias has it posted here: http://www.reddit.com/r/linux_gaming/comments/28skqt/psa_do_you_have_screen_tearing_issues_only_in/ |
Sorry, yes the CLUTTER_PAINT line fixes tearing by itself but it causes the other problems I described. As for the other fix, it says to install Openbox. Is it possible to use Compton with Cinnamon? |
I was curious about that myself as well, I saw it mentioned that there is no "--replace", so you cannot swap in Compton and swap out Clutter once running Cinnamon, but maybe there is a way to load up Cinnamon with Compton instead, not sure how to though. It looks like trying out Compton is pretty easy though, just install the Openbox metapackage, Compton, make the config file and select Openbox in the login manager to log into. Curious to try it out myself now when I have some spare time to see if I get any performance differences in games. |
So, here: linuxmint/muffin#86, we made detection of these types of programs better, to improve their performance (by not compositing them). People were beating down the doors saying we needed to do this if Cinnamon was to be a gaming platform. (I'm not exaggerating!) So, now, we seem to have exposed this side effect of tearing (of course), which I can't reproduce yet, but I'm going to keep trying. Ideally, we have the performance and the no-tearing, but aren't the two mutually exclusive to a degree? Honestly I'm not very familiar anymore with the different drivers and manufacturers out there. I'd welcome more input (and of course I'll continue to look for more info too). |
Yeah it is indeed a strange issue. My understanding is X.org by default doesn't want to vsync, whereas Wayland by default does want to vsync, so Wayland apps don't have to implement code to force vsync on like they do with X apps. There are a lot of movies and games in which tearing is particularly visible and I can easily see a line(s) across my monitor. There are several other games where it isn't though. It may depend on what monitor you have, too. That's why perhaps having a setting in Cinnamon to force on or off vsync might be the best solution, and then based upon certain hardware perhaps you could change what the default setting should be, or just not bother with that last part. It's easiest to notice in situations where large blocks of graphics are moving, so movies are particularly noticeable. Some Steam games I've noticed it in extra easily (pan around the screen): I couldn't reproduce it on any open source games yet. Totem/Movie Player is very easy to reproduce though. Can play any movie, especially high-res movies, I get a very solid tearing line at 1/3rd of the way down my screen. However, VLC does not have this issue so that is what I use on my HTPC with Mint 17 and nVidia. Using some other type of output apparently. What I haven't done yet is compare framerate performance between Compton and Cinnamon and other WMs. If Compton fixes screen tearing and gives a better framerate, maybe Cinnamon should switch to it instead of Mutter/Muffin. XD I'm definitely willing to do tests and troubleshooting in my spare time if there are any helpful tests that I can do or things I can try. ^n.n^ |
The thing that gets me (unless I'm misreading about Compton) is an easy fix would just be to force redirection (compositing) on these windows, or simply provide a switch (like in an applet) to allow you to disable unredirect detection - nothing to do with vsync at all. Discussing with someone who knows a bit more about video cards, and reading a bit myself, it seems like they all have their own way to force vsync on or off, and as you mentioned, some of the programs themselves do as well. So would it be satisfactory to simply avoid the issue and force compositing in these cases? |
Right, unless there is a way to have Muffin adjust a program's settings to avoid screen tearing, it'd probably be best to have an option to force it on everywhere, just like you can do with Compton from what I understand from what Corvias has said here: ...since it looks like the "sync to vblank" option in the nVidia control panel is useless or helpless in fixing it. XD I need to play with some Muffin settings and see if I can fix tearing through it. Do you know of any settings that might do so? If I remember correctly in Mint 16 I used some settings that fixed tearing, but Corvias tried "everything" he said and couldn't get it fixed without using Compton, but I still need to try myself. Either way, once the right setting or solution is found, having an option in Effects or someplace better for that might be good. That'd be easy enough I could add it myself. XD |
Has any of you already tried Gnome Shell to see if the tearing (and other vsync issues) also happen there? |
I've heard complaints of Gnome Shell having vsync issues, but have not tried it yet myself. I'll install a few DEs this weekend and try things out. |
I also have a tearing issue on the desktop - about 10-15 pixels wide lane is tearing, everything else is good. This bug exists in all cinnamon versions, intel hd graphics here. |
#2804 (comment) - Maybe this would help? |
Hello! Do you have any idea for this? Thank you! |
After some searching, I found this: https://bbs.archlinux.org/viewtopic.php?id=177925&p=1 |
It seems like it's better with this xorg.conf content: /etc/environment has already this two lines by default: |
Are you using Linux Mint 17.1? It has vsync turned on by default in everything unless you turn it off in the options. |
Yes, it's 17.1 (upgraded from Linuxmint 17). |
On Linux Mint 17.1 and the integrated graphics of an Intel Core i5-3450 the tearing happens on desktop applications like Sublime or Firefox. On an i5 laptop, it also happens even in VLC, horribly so. |
When I watch videos or play games, the screen gets updated inside the windows I see a triangle in the lower-left and another in the upper-right inside of the rectangular part of the screen that gets updated. My card is an "Integrated Intel Graphics Media Accelerator 3100". It is another issue with synchronisation, else I wouldn't see two triangles in portions of the screen that get updated. My "xorg.conf" file in "/etc/X11/" is empty, so I don't know what to do about that and how I am going to fix this problem. |
Hopefully this issue is gone in Mint 17.3 for everyone, it's been gone for me for a long while but I'm still on NVIDIA. |
@Swiftpaw I do still get tearing on Cinnamon with Nvidia on my 4K monitor, but not my 1080p monitor. What settings are you using to remove tearing? |
I get tearing on both of my 60Hz monitors using a GTX 760 and Linux Mint 17.2 Rafaela. If I have understood it correctly; screen tearing is a guarranteed issue (at least for Linux) if your GPU is of the Kepler architecture and you're not using a global Vsync. edit: Is this fixed in 17.3? So here's a brief write-up of what I've learned about Linux screen tearing since I posted ITT a couple weeks ago. I'm still not exactly what you would call an expert so excuse me if my terminology is off. Written for anyone like me who stumbled into this thread from Google looking for ANY fix to "tearing in Linux" whatsoever. If you want to spend as little time and effort as possible your first go-to should be to check if you're currently using any sort of compositor, be it a compositing "Window Manager" or a standalone compositor. If your Desktop Environment is Cinnamon, chances are that you are using "Muffin" which is a compositing WM. However, if you are ok with changing your software and spending time learning about crap I'm pretty sure is not applicable to anything in life but graphics in GNU/Linux, the following paragraphs are for you. Check which WMs are compatible with your current DE (or if the DE even allows an alternative WM) and then switch to a compositing one, for example Compiz. Also, a standalone compositor is pretty much always an option as long as you can turn off compositing in your current WM. The root of the problem lies within X11 (aka X, aka X-Windows) which is what your DE or WM is using to display graphics. X11 has been piled upon with software additions and upgrades since the late 80's and is - from what I hear - a jumbled mess. |
I get diagonal screen tearing in Firefox in Linux Mint 18 Cinnamon beta on Intel Graphics.
` |
I'm continuing to have this issue with what seems like no solution in sight. I have a Dell XPS 15 laptop with NVIDIA Optimus running on a Skylake Intel HD 530 and a GTX 960M combo. The issue seems to occur when I have bumblebee installed for GPU switching, which should default to running off the Intel GPU. There is no tearing if I don't have bumblebee installed and default to using the NVIDIA GPU. If I choose to set the intel GPU to use the Is there some setting in the compositor that can be changed? I've installed KDE on the side and tested the same configuration with bumblebee and there is no tearing whatsoever. This issue only persists on Cinnamon. |
In nvidia-settings, do you have it configured to sync to your display? |
Not sure what distro you are running, but you could try reinstalling and reconfiguring Bumblebee with the procedure described here. http://lenovolinux.blogspot.com.au/2018/02/bumblebee-on-lenovo-t440p-nvidia-gt.html |
@mainmachine It's not possible to configure nvidia-settings to sync with display since you cannot access advanced settings when using an Optimus laptop and have bumblebee installed. I'm also not sure why that would change anything since the video output should be coming through the Intel integrated GPU? @echuber2 I'm running on the latest Arch Linux. |
Might want to check your xorg logs for errors and warnings, and still peruse the link I posted above to make sure your modules are being updated correctly (although I'm sure it's different for Arch) |
@echuber2 checking Xorg logs for errors and warnings specific to what problem? Because bumblebee is definitely working. Not sure how Xorg logs would help with V-sync or tearing issues. What I'm getting is a diagonal tearing that is system wide and is not limited to just firefox or chrome. This is especially evident if I move windows around really fast. Running |
@kvnxiao - Yes, the Intel GPU should be doing this, but check on the "X Server XVideo Settings" tab. I'm typing this from a Optimus laptop and I don't have tearing, so there's hope. :) I am using modesetting driver as well, looking through my Xorg.0.log... Can you post your Xorg.0.log somewhere? |
I've been trying for years and I've never been able to eliminate Vsync/tearing issues on my machine. It's not as bad as it used to, but I still occasionally notice it when I play some high-bitrate videos. I use Nvidia graphics only. If you guys go to https://www.vsynctester.com and run the test, can you see the red or cyan vsync in the right corner? I haven't been able to eliminate that no matter what "fix" or browser I tried. |
@mainmachine Here is my In the |
@echuber2 - that looks like a good resource for that specific hardware; here's another that I've found invaluable (it is specific to Ubuntu, though): http://danielteichman.blogspot.com/2017/03/how-to-install-bumblebee-on-ubuntu-1604.html @kvnxiao - it's probably worth looking over your config versus these two links. I'm also using the latest stable Mesa (17.3.2) - what are you using? |
Good news! It seems like after some tinkering I actually got it to work! No more diagonal screen tearing visible system wide. I'm not sure if this applies to other optimus users with older integrated intel GPUs, but for Skylake users with Intel HD 530, this is what I found that helped me fixed the problem.
Since I use GRUB, I then added these kernel parameters to
And regenerated my grub configuration file, then rebooted. All that, and bumblebee is still working:
|
@kvnxiao - the only difference I've seen that looks notable is that your Xorg is this: Do you have an xorg.conf in /etc/X11/ and if so, what's in it? If you have any lines specifying or loading the "intel" module, then I'd comment and restart... |
@kvnxiao - that's great! 👍 As far as this issue goes globally, it seems as if more and more vsync is getting solved at the driver level. This has certainly been my experience with Nvidia, AMD and Intel, on both Nvidia proprietary and Mesa... maybe this isn't an issue for Cinnamon (or any other DE) specifically anymore...? |
@mainmachine Well... the reason I asked for help originally was because while on the To me that seemed like a DE issue. If while keeping the system configuration constant, swapping to a different DE showed no screen tearing, but swapping back and screen tearing shows up again. |
@kvnxiao - sure, could be Kwin was doing something different at the compositor level, versus what muffin does. With regard to DE's, tearing is usually solved by compositing in the window manager. I think currently Cinnamon does this by default, but there is an option to disable compositing for full screen applications (like games, for example). This is in Settings > General > Disable compositing for full-screen windows, if you're curious. |
These doesn't help me out on my radeon r5 230 1Gb VRAM caicos GPU. I have no such things with couple of others DE's to be honest the only DE which has these issue is Cinnamon. |
This problem is still quite alive and well. Must be some complicated for it to have a 6+ year span. |
Can you be more specific about what symptoms you're seeing and what configuration you have, now? |
I see vsync-issues & tearing in cinnamon, the issue subsides if I start the session with xfce instead. I only consider it a problem inside firefox when watching videos. I even tried some firefox specific fixes, which I figured might work since VLC doesn't seem to suffer as badly from it. In fact any time I think I've seen tearing I'm not sure if it was or not, so it might as well be considered tear-free at that point (VLC that is). Nvidia GT 710 |
I have tearing in Linux Mint 19.3 (Cinnamon, 64-bit) with Nvidia GTX 1060 (3GB) (driver: 440.48.02), using desktop applications such as firefox, as well as in games (i recently tried CounterStrike:CZ, Torchlight 2, No Man's Sky and various different Unity3d Games, also self made Unity3d Games). To solve this, i tried what they said here: #3355 I've read that it should be less issue on MATE, but i would prefer to stay with Cinnamon. |
Why do you need the nvidia beta vulkan driver?, ubuntu vulkan packages aren't new enough to benefit from the new extensions.
I doubt adding that option will help with the newer nvidia drivers
|
@leigh123linux ForceFullCompositionPipeline helped a bit for desktop application, its way better for me with enabled, but didn't get rid of it completly |
Seeing the same problem with Nvidia RTX 2070 on Ubuntu 19.10 and Cinnamon 4.2.4 (though same was with previous versions for the past year+) and as others have tried ForceFullCompositionPipeline and other settings to no avail. Beyond it be annoying for me, apparently it's pretty bad on web meettngs - I need to be on zoom often and share my screen which makes the attendees see the desktop or window or I'm sharing disappear and show my background and then reappear periodically. After months of trying to resolve this, regrettably I'd had to switch to the default GNOME (3.34.2) and everything has been fine but I do miss my Cinnamon. Would love to see a fix for this. |
Have you tried the various Vsync modes in the control panel? https://www.reddit.com/r/CinnamonDE/comments/dx4lyk/vsync_method/ |
Honestly I am skeptical the vsync modes do anything, there is no discernible difference between any of them for me. After rebooting between changing the modes. |
Check the source if you're skeptical. They do something; I saw it make a difference on one of my machines instantly after changing the setting. (That did not have an nvidia GPU though.) If anything I bet this all comes down the drivers you have installed. Although, if there is something distinctively wrong with Cinnamon's vsync then I'd also like to know about it. |
I also tried different vsync modes but it did not make a noticeable difference. I also tried different driver versions, the recommended one, the newest, older stable drivers that were recommended by community users, nothing helped. |
@echuber2 I too have tried those various Vsync modes and followed the steps in the link. No change. I'm on an Nvidia. And I don't think it's the drivers as I don't have this issue anymore with GNOME :( Open to trying other things as would love to switch back. |
Running nVidia hardware on multiple machines, and along with other nVidia users I have bad screen tearing in Cinnamon/Clutter unless the game has a VSYNC option which forces it on, then things work fine. For some reason VLC doesn't have tearing that I can notice, but Totem always has horrible tearing.
The solution being done by several users right now is to switch to the Compton compositor instead and forcing on VSYNC for everything through that, but can't we get an option to force it on for Cinnamon instead? For some reason the usual Cluttter options do NOT force on VSYNC. See the following threads on the Linux Mint forums and Reddit:
http://forums.linuxmint.com/viewtopic.php?f=59&t=171020
http://www.reddit.com/r/linux_gaming/comments/28skqt/psa_do_you_have_screen_tearing_issues_only_in/
Also found this suggestion to add a VSYNC option to Cinnamon options, but if that option doesn't work anyway then that won't fix the problem.
#1773
Using nVidia closed driver.
The text was updated successfully, but these errors were encountered: