Search Unity

Ubuntu, Dual monitors, NVIDIA and RADEON

Discussion in 'Linux' started by MrMelSE, Dec 11, 2020.

  1. MrMelSE

    MrMelSE

    Joined:
    Dec 10, 2017
    Posts:
    25
    Hi,

    Not really a question, but rather some information for anyone in the future with same problem as me, unless of course someone here has a fix for this that I have spent countless hours trying to fix.

    Environment: Ubuntu 20.04, RTX1650, RTX2070, RTX2080, Radeon 5700XT
    Clean install + graphics drivers, tried per date the latest and earlier ones.

    Some background: I need to run 120+ FPS, I have to run vSync on my system, or rather, I cannot tolerate one single stuttering or one frame order wrong, ever, it's a custom shooting simulator that requires absolute perfect flow of graphics.

    I do run the system on a single projector without trouble on even quite modest hardware, never a hickup.

    Now to the "interesting" part..

    NVIDIA OpenGL Graphics engine
    Multiple monitors + NVIDIA Graphics card is capped to max 60FPS.
    As soon as you activate second monitor even if you do not render it, the FPS drops on all screens to 60fps, even if both monitors are higher.

    This is confirmed in 2019.4 and 2020 releases.

    I have submitted a bug report for this issue that it caps the FPS.


    Workarounds for some perhaps is following;

    - Disable vSync in NVIDIA control panel.
    - Run -force-vulkan to utilize the vulkan engine instead.


    NVIDIA Vulkan Graphics engine

    Now with Vulkan as stated above it works at full FPS with multiple monitors, and with vSync enabled.

    Unfortunatly it causing some stuttering/tearing issues that is not acceptable in my custom system
    With vulkan it might be possible if I go hardware price x 3 or x4, in other words, the stuttering/tearing can be purchased away with insane hardware.

    I've tried pretty much all settings possible with above hardwares to make it work, nothing helps, running profiler on vulkan just ends up showing it waiting for graphics, for some reason it priorites wrong sometimes and get stuck for a frame or two or even more sometimes.

    SOLUTION

    AMD Radeon to the rescue, never ran them before, been a NVIDIA guy, but since nothing worked I had to try and it works, using AMD Radeon 20.40 drivers I can run pretty much whatever setting I want, the graphics is smooth, hardware requirements are WAY down from NVIDIA+Vulkan.
    Now I just have to sort out other issues that arised with ubuntu + AMD... doh!. (Teamviewer does not work, crashing once each day)


    General information,
    there is some bug in Ubuntu + NVIDIA in combination with my projectors that I use, sometimes you can change refresh-rate in ubuntu but the projectors never see that change.
    Might be that this issue is releated to why unity cannot handle it, perhaps not, unsure.
    Switching to Radeon fixed that issue too.

    When I have time and if the willpower is there, I will try different projectors/monitors too.

    Added info 2020-12-14
    Tested different monitors, did not change anything.
    Tested different distro's of Linux without any change.
    Tested to turn off Linux Compositor and run Full force pipline or what's the option is called (recommended by some), not good enough.
    Bought best processor + motherboard + memory + hdd there is today, and performance really does not follow the speed of the computer, so I guess it's rooted in the Unity + Linux + Nvidia combo regardless.

    Added info 2020-12-16
    Final resolution for Nvidia cards, this is working;
    Ubuntu 20.04
    Enough hardware (on the high side)
    NVIDIA card, latest drivers 455
    QualitySettings.vSyncCount = 0,
    Application.FrameRate = -1;
    NVIDIA Blank to VSync: Checked
    Allow Flipping: Checked
    No other settings;

    This config works OK, I needed to get creative in terms of optimizing performance in my code, but in the end I reached the goal.


    Updated info 2020-12-21
    Final solution for me; Since setup below runs perfect.
    Changed to Xubunutu so you get away from Gnome3 since that is part of the problem.
    Xubuntu Compositor (Settings - > Windows Tweaks): DISABLED
    NVIDIA card, latest drivers 455
    QualitySettings.vSyncCount = 0,
    Application.FrameRate = -1;
    NVIDIA Blank to VSync: Checked
    Allow Flipping: Checked
    No other settings;
     
    Last edited: Dec 21, 2020