Reducing input lag in bordeless mode?

Discussion in 'Videocards - NVIDIA GeForce Drivers Section' started by Rapyer, Aug 21, 2018.

  1. Rapyer

    Rapyer Guest

    Messages:
    218
    Likes Received:
    2
    GPU:
    1080ti
    What are some of your favorite tips on reducing input lag in borderless windowed mode?

    maximum frames to render ahead 1

    frame limiter flip queueing 2

    not limiting fps /no vsync


    i heard there was ways to force old DWI to work on windows 10 to remove the lag, but i tried it and it looked like i went back to windows 95.


    So looking for any hacks on how to remove input lag and make it as close to fullscreen mode as possible

    Thanks in advance
     
  2. RealNC

    RealNC Ancient Guru

    Messages:
    5,092
    Likes Received:
    3,376
    GPU:
    4070 Ti Super
    If you indeed found a way to disable DWM compositing in W10, that is the only way you're gonna get input lag as low as fullscreen mode.

    The only exception are games that support "new style" borderless windowed mode. In that mode, DWM is disabled automatically. The way to test this is to disable vsync and check if you get tearing or not. If you get tearing, that means DWM is disabled.
     
  3. Blackfyre

    Blackfyre Maha Guru

    Messages:
    1,388
    Likes Received:
    391
    GPU:
    RTX 3090
    Backup your registry & try the changes below (under spoiler). I use these changes to decrease input lag and improve network performance in games.

    Open Notepad, paste the entire code below, save it and name it, change the extension from .txt to .reg and then double click on it to merge the changes to registry, then restart.

    Windows Registry Editor Version 5.00
    [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Multimedia\SystemProfile]
    "NetworkThrottlingIndex"=dword:ffffffff
    "SystemResponsiveness"=dword:00000000
    [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Multimedia\SystemProfile\Tasks\Games]
    "Affinity"=dword:00000000
    "Background Only"="False"
    "Clock Rate"=dword:00002710
    "GPU Priority"=dword:00000008
    "Priority"=dword:00000006
    "Scheduling Category"="High"
    "SFIO Priority"="High"
    [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Multimedia\SystemProfile\Tasks\DisplayPostProcessing]
    "Affinity"=dword:00000000
    "Background Only"="True"
    "BackgroundPriority"=dword:00000008
    "Clock Rate"=dword:00002710
    "GPU Priority"=dword:00000008
    "Priority"=dword:00000008
    "Scheduling Category"="High"
    "SFIO Priority"="High"
    [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\PriorityControl]
    "IRQ8Priority"=dword:00000001
    "Win32PrioritySeparation"=dword:00000026
    [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Executive]
    "AdditionalCriticalWorkerThreads"=dword:00000008
    "AdditionalDelayedWorkerThreads"=dword:00000006
    [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Memory Management]
    "SecondLevelDataCache"=dword:00000000
    "IoPageLockLimit"=dword:08000000
    "DisablePagingExecutive"=dword:00000001
    "LargeSystemCache"=dword:00000000
    [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Memory Management\PrefetchParameters]
    "EnablePrefetcher"=dword:00000000
    "EnableSuperFetch"=dword:00000000
    [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\FileSystem]
    "DisableDeleteNotification"=dword:00000000
    "LongPathsEnabled"=dword:00000000
    "NtfsAllowExtendedCharacter8dot3Rename"=dword:00000000
    "NtfsBugcheckOnCorrupt"=dword:00000000
    "NtfsDisableCompression"=dword:00000000
    "NtfsDisableEncryption"=dword:00000001
    "NtfsEncryptPagingFile"=dword:00000000
    "NtfsMemoryUsage"=dword:00000000
    "NtfsMftZoneReservation"=dword:00000004
    "RefsDisableLastAccessUpdate"=dword:00000001
    "UdfsSoftwareDefectManagement"=dword:00000000
    "Win31FileSystem"=dword:00000000
    "FileNameCache"=dword:00000400
    "PathCache"=dword:00000200
    "NtfsDisable8dot3NameCreation"=dword:00000001
    "NTFSDisableLastAccessUpdate"=dword:00000001
    "ContigFileAllocSize"=dword:00000600
    [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MSMQ\Parameters]
    "TCPNoDelay"=dword:00000001
    [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System]
    "EnableFirstLogonAnimation"=dword:00000000
    "SynchronousUserGroupPolicy"=dword:00000000
    "VerboseStatus"=dword:00000001
    "SynchronousMachineGroupPolicy"=dword:00000000
    [HKEY_CURRENT_USER\Control Panel\Desktop]
    "HungAppTimeout"="1000"
    "MenuShowDelay"="0"
    "ActiveWndTrkTimeout"=dword:00000000
    "AutoEndTasks"="1"
    "FontSmoothing"="2"
    "PaintDesktopVersion"=dword:00000000
    "WaitToKillAppTimeout"="1000"
    "LowLevelHooksTimeout"="1000"
    [HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer]
    "NoLowDiskSpaceChecks"=dword:00000001
    "LinkResolveIgnoreLinkInfo"=dword:00000001
    "NoResolveTrack"=dword:00000001
    [HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\System]
    "DisableLogonBackgroundImage"=dword:00000001
    [HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\Psched]
    "TimerResolution"=dword:00000001
    "NonBestEffortLimit"=dword:00000000
    [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control]
    "SystemStartOptions"=" NOEXECUTE=OPTIN NOGUIBOOT BOOTLOGO"
    "DirtyShutdownCount"=dword:00000078
    "WaitToKillServiceTimeout"="2000"
    "WaitToKillAppTimeout"="2000"
    [HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Serialize]
    "StartupDelayInMSec"=dword:00000000
    [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Power\PowerSettings\54533251-82be-4824-96c1-47b60b740d00\0cc5b647-c1df-4637-891a-dec35c318583]
    "Attributes"=dword:00000000
    [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Power\PowerSettings\0012ee47-9041-4b5d-9b77-535fba8b1442\0b2d69d7-a2a1-449c-9680-f91c70521c60]
    "Attributes"=dword:00000002
    [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Power\PowerSettings\0012ee47-9041-4b5d-9b77-535fba8b1442\dab60367-53fe-4fbc-825e-521d069d2456]
    "Attributes"=dword:00000002
    [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer]
    "Max Cached Icons"="2000"
    [HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced]
    "ExtendedUIHoverTime"=dword:00000000
    "TaskbarAnimations"=dword:00000000
    "ListviewAlphaSelect"=dword:00000000
    [HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Services\Tcpip\Parameters]
    "Tcp1323Opts"=dword:00000001
    "SackOpts"=dword:00000000
    "TcpMaxDupAcks"=dword:00000002
    [HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Services\LanmanWorkstation\Parameters]
    "MaxCollectionCount"=dword:00000020
    "MaxThreads"=dword:0000001e
    "MaxCmds"=dword:0000001e
    [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\PCHealth\ErrorReporting]
    "ShowUI"=dword:00000001
    "DoReport"=dword:00000000
    [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\AeDebug]
    "Auto"="0"
    [HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Control\Session Manager]
    "AutoChkTimeOut"=dword:00000005
    [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon]
    "AutoRestartShell"=dword:00000001
     
  4. mbk1969

    mbk1969 Ancient Guru

    Messages:
    15,605
    Likes Received:
    13,614
    GPU:
    GF RTX 4070

    Way too many parameters.

    1.
    [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Power\PowerSettings\54533251-82be-4824-96c1-47b60b740d00\0cc5b647-c1df-4637-891a-dec35c318583]
    "Attributes"=dword:00000000
    [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Power\PowerSettings\0012ee47-9041-4b5d-9b77-535fba8b1442\0b2d69d7-a2a1-449c-9680-f91c70521c60]
    "Attributes"=dword:00000002
    [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Power\PowerSettings\0012ee47-9041-4b5d-9b77-535fba8b1442\dab60367-53fe-4fbc-825e-521d069d2456]
    "Attributes"=dword:00000002

    Registry values "Attributes" of these power plan settings have nothing to do with the values themselves. For example "Attributes"=dword:00000001 just means "hide this power plan setting from dialog with advanced power plan settings".

    PS Here are corresponding constants in Win API:

    //
    // Power setting attribute flags
    //

    #define POWER_ATTRIBUTE_HIDE 0x00000001
    #define POWER_ATTRIBUTE_SHOW_AOAC 0x00000002

    And I guess POWER_ATTRIBUTE_SHOW_AOAC (i.e. "Attributes"=dword:00000002) is related to AlwaysOnAlwaysConnected

    2.
    HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Multimedia\SystemProfile\Tasks

    These tasks profiles only relevant for applications which directly utilize certain Win API functions to state their task profile.

    3.
    HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet
    This registry key is actually a shortcut to this registry key
    HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001
    So they can be used both.
     
    Last edited: Aug 21, 2018

  5. Minotaur

    Minotaur Member Guru

    Messages:
    106
    Likes Received:
    9
    GPU:
    Gainward 1080 GLH
    [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Multimedia

    Doesn't even exist here... Win 1803 build 17134.228
     
  6. Rapyer

    Rapyer Guest

    Messages:
    218
    Likes Received:
    2
    GPU:
    1080ti
    I tried using DWM.ForceSwitch-master on LTSB, doesnt seem to have issues i had on creators update, just annoying black logon window :)

    tried fortnite windowed, get screen tearing, no noticable input delay that i normally would feel right away

    that program has a few registry fixes that disabling DWM breaks, it's quite nifty


    https://github.com/Phorofor/DWM.ForceSwitch
     
    Last edited: Aug 23, 2018
    RealNC likes this.
  7. cookieboyeli

    cookieboyeli Master Guru

    Messages:
    304
    Likes Received:
    47
    GPU:
    Gigabyte 1070 @2126
    If you switch to fullscreen that completely gets rid of the input lag on borderless.

    lol

    For real though second screen isn't worth it. If everything is set up right alt tabbing is nearly instant.
     
  8. tsunami231

    tsunami231 Ancient Guru

    Messages:
    14,750
    Likes Received:
    1,868
    GPU:
    EVGA 1070Ti Black
    I did not know there is new style to bordless windows that has it versions of vsync disable, I probably dont have one those games, I honestly dont see any input lag vsync and windowed boardless, proably cause I just compensated for it over the 20+ years of using vsync I see more input lag that is annoying in turn off gamemode on UHDTV then the difference from vsync on and off
     
  9. tsunami231

    tsunami231 Ancient Guru

    Messages:
    14,750
    Likes Received:
    1,868
    GPU:
    EVGA 1070Ti Black
    I wish CRT were still a thing, I still think they are better then 99% LCD/LED on the market, 1 day oLED will replace LDC/LED and it wont mater much anymore
     
    janos666 likes this.
  10. RealNC

    RealNC Ancient Guru

    Messages:
    5,092
    Likes Received:
    3,376
    GPU:
    4070 Ti Super
    Some old games are automatically redirected from exclusive fullscreen to new-style borderless fullscreen. Even very old games (like from 2004.)

    If you have a keyboard shortcut (or media keys) for changing the audio volume so that the Windows audio volume bar appear in the upper-left when you press it, that means the game is running in the new-style borderless mode. This happens even for very old games, unless you check the "disable fullscreen optimizations" checkbox in the game's exe file compatibility properties.

    The Windows Game Bar needs DWM to be active, which is why games are automatically redirected from exclusive fullscreen to the new mode. When there's no overlay to be drawn (like the Game Bar or the sound volume bar), DWM is off. As soon as an overlay needs to be displayed, DWM is enabled for the duration the overlay is visible.

    There are some games that don't get this treatment though. I don't know if this feature operates on a whitelist or a blacklist.
     

  11. Caesar

    Caesar Ancient Guru

    Messages:
    1,561
    Likes Received:
    686
    GPU:
    RTX 4070 Gaming X
    do please give FPS comparison [ with and without borderless mode with an ingame specific test] as all depends within games requirements' settings
     
  12. tsunami231

    tsunami231 Ancient Guru

    Messages:
    14,750
    Likes Received:
    1,868
    GPU:
    EVGA 1070Ti Black
    I didnt not know that, might explain why I seen volume control pop up in games I know dont have borderless windows mode

    Always wonder what the full screen optimise was all about
     
  13. Rapyer

    Rapyer Guest

    Messages:
    218
    Likes Received:
    2
    GPU:
    1080ti
    there are other uses to this. screen overlay like statitistics, crosshairs, etc

    battleye, eac are very aggressive to what they ban for example. if you have eyesight problems and stuck with a faint white crosshair as your only option, it becomes very frustrating

    in win 10, even on beast PC, you can tell input lag in borderless due to win10 forced DWM, and as soon as fps drops in gunfights you can tell fullscreen vs borderless easily if you are a gamer

    you can do a simple test, dual boot windows 7, disable aero and play same game borderless.

    you will know what im talking about


    its like tinnitus in your ear, you can learn to live with it, but its always there and an annoyance
     
    Last edited: Aug 25, 2018
  14. tyguy

    tyguy Guest

    Messages:
    24
    Likes Received:
    0
    GPU:
    Geforce 1070
    Sorry for the grave dig here but im assuming if you have freesync or gsync and the game uses the "old style" borderless window you don't get additional lag?

    I have some games that I have to use borderless window or I cant play in 1440p 120 hz. What ends up happening is my tv will upscale to 4k 60 hz but the game is internally rendered at 1440p. Games that allow me to select the refresh rate allow me to use exclusive full screen at 120 hz 1440p. My tv also has freesync, so in most games borderless works with freesync.

    The only game I cant get to work in borderless with freesync is hell divers. I also cant select the refresh rate in that game so I get upscaled. Since the game isn't demanding I just use native 4k and cap at 58 fps and use native 4k and never push over 90 % gpu usage.

    Id still prefer to play at 118 fps capped 1440 p, but i've wondered if im getting additional lag playing some games in borderless like apex legends for example. I have to play in borderless to get 1440p 120 hz, but freesync is working with it in borderless so am I getting additional lag over exclusive full screen?

    Borderlands 3 is another example sort of... Fullscreen works with 1440p 120 hz but HDR is screwed up and unusable. The brightness is completely blown out. Borderless mode actually fixes that which is weird since most games hdr doesn't work with borderless.
     
    Last edited: Sep 20, 2019
  15. RealNC

    RealNC Ancient Guru

    Messages:
    5,092
    Likes Received:
    3,376
    GPU:
    4070 Ti Super
    I should have used better naming. It's not "new-style borderless", it's new-style fullscreen. This new fullscreen mode is closer to borderless mode when it comes to usability, but it still provides the performance and latency benefits of fullscreen.

    You'll never get that new mode if you set the game to borderless. You'll only get it if you set the game to fullscreen, and fullscreen optimizations have not been disabled in Windows 10.
     

  16. EdKiefer

    EdKiefer Ancient Guru

    Messages:
    3,140
    Likes Received:
    395
    GPU:
    ASUS TUF 3060ti
    I know this is old post but happen to come across this vid a day ago.
     
    Singleton99 likes this.
  17. tyguy

    tyguy Guest

    Messages:
    24
    Likes Received:
    0
    GPU:
    Geforce 1070
    Oh okay I got it. What about if you do use borderless with gsync/freesync? Would the input lag be on par with exclusive full screen?
     
  18. tsunami231

    tsunami231 Ancient Guru

    Messages:
    14,750
    Likes Received:
    1,868
    GPU:
    EVGA 1070Ti Black
    Yes i know I seen it, its nothing I didnt know already most people that grew up with only Flatpanel/fix resolution lcd are have no clue how much CRT is better when it working "properly" no lcd panel can compete. The technology was simply abandoned cause it size and weight which would not be much of issue at this point if it wasnt abandoned..


    I hooked up my old Sony Crt monitor found lay around few days ago. and my eye cried tries of joy. none of this bs with responsive time making motion look like crap when text is moving in or mouse is moving there zero blur and it readable compared all LCD I seen not even the 240 lcd can compete in my eyes. and lets not forget runnuing 640x480 on fix panel look like utter crap compared to crt much like nes games look like trash on lcd panels vs crt

    If I had room for CRT of 24" size I would still be using them, but like most people they dont have space
     
  19. RealNC

    RealNC Ancient Guru

    Messages:
    5,092
    Likes Received:
    3,376
    GPU:
    4070 Ti Super
    Last time we measured this, it was in 2017. Windowed mode g-sync had no added input lag. I don't know if anything changed since then with Windows 10's later updates.

    This was a weird result, since windowed mode goes through DWM, but with g-sync, it seems this doesn't matter. However, there can be stutter if the GPU is maxed out.
     
  20. tyguy

    tyguy Guest

    Messages:
    24
    Likes Received:
    0
    GPU:
    Geforce 1070
    Awesome, that sounds about right to me. This video tests borderless input lag, but neither freesync or gsync was tested with it so perhaps the added input lag is due to the forced vsync for windowed/borderless mode?

     

Share This Page