PC Definitive Stutter Fix Via Engine.ini Settings

Discussion in 'TSW General Discussion' started by dbrunner#4864, Jun 1, 2023.

  1. dbrunner#4864

    dbrunner#4864 Well-Known Member

    Joined:
    Mar 25, 2021
    Messages:
    489
    Likes Received:
    691
    Jetwash included similar or same streaming optimization tweaks as the ones here but with modified VRAM allocation values for ultra high end specs . I don't know if the TOD or graphic tweaks still work properly with TSW4 but you can try and paste your current settings to TSW4 engine ini and see how it goes, at least in the stutter department I would hope that you will still see an improvement.
     
    Last edited: Sep 22, 2023
    • Like Like x 1
  2. squerble

    squerble Well-Known Member

    Joined:
    Mar 8, 2020
    Messages:
    254
    Likes Received:
    387
    Sadly yes, it's as though it's the first run every time. I'd really appreciate a DTG employee chiming in here to tell us if these settings are overridden or if some are baked into the game.
     
    • Like Like x 3
  3. JetWash

    JetWash Well-Known Member

    Joined:
    Mar 6, 2021
    Messages:
    3,120
    Likes Received:
    11,661
    Just FYI, those settings you’ve got there are massively over the top. I found them on an old forum for another game and posted it verbatim here. Since then I’ve hugely cut down and optimised what’s there, adding the ToD4 changes as well. I’d strongly suggest you bin all of that and simply use one of my presets from the TSC website.
     
    • Like Like x 2
  4. speediek#8515

    speediek#8515 Member

    Joined:
    Aug 27, 2022
    Messages:
    40
    Likes Received:
    47
    I’ll be giving them a try on both my regular pc and steam deck and will report back at some point if they work.
     
  5. speediek#8515

    speediek#8515 Member

    Joined:
    Aug 27, 2022
    Messages:
    40
    Likes Received:
    47
    I haven’t tried the engine.ini tweaks yet myself but TSW4 seems to have worse stuttering than default TSW3 does for me. Technically of course the game isn’t officially released so I expected issues like this. I also get massive frame drops for some reason despite still having lots of cpu, gpu ram available. I’ll probably wait till the official release to give the engine.ini tweaks a fair tryout.
     
    Last edited: Sep 22, 2023
    • Like Like x 1
  6. JetWash

    JetWash Well-Known Member

    Joined:
    Mar 6, 2021
    Messages:
    3,120
    Likes Received:
    11,661
    This is the official release. ‘Early Access’ doesn’t mean it’s an early access game, it just means you’re getting earlier access to play it than other people. What you have now will almost certainly be what is released on the 26th.
     
    • Like Like x 5
  7. speediek#8515

    speediek#8515 Member

    Joined:
    Aug 27, 2022
    Messages:
    40
    Likes Received:
    47
    Oh I agree that it’s not an early access game. Lots of games have day 1 patches to address issues picked up from the Pre order "early access". I’m assuming here TSW4 just like what TSW3 did will be no different.

    I’m just trying to give it a fair try before concluding anything as clearly the game has a few issues right now.
     
    Last edited: Sep 22, 2023
  8. dbrunner#4864

    dbrunner#4864 Well-Known Member

    Joined:
    Mar 25, 2021
    Messages:
    489
    Likes Received:
    691
    JetWash How is your experience with your current TOD4 config in TSW4? Everything still works as it was in TSW3 without major hitching or stuttering ? If not I suspect something changes either in the engine or variables themselves

    That is bad news , thanks for letting me know. I will do some tests tomorrow when I get home and see if I can figure it out. I hope we can still tweak the streaming engine and shader cache part or else we are back to the stuttering experience .
     
  9. JetWash

    JetWash Well-Known Member

    Joined:
    Mar 6, 2021
    Messages:
    3,120
    Likes Received:
    11,661
    I’m gonna hold my hands up here, I just bought it because the thought of people trying to use my mods and them not working was bugging me, and I simply can’t fix them without owning the game. QED. That very likely makes me a massive hypocrite but so be it. It is what it is.

    Initial impressions are the ToD4 ini works just fine. There is definitely one adjustment I need to make as they appear (on the 800 at least) to have significantly improved the brightness of the screens to be more in line with the changes I made. My ini changes on top of that cause the cab screens and PiS to be difficult to see. I’m not seeing the stuttering some are talking about, it’s no different to TSW3 in that regard.

    I’m going to have a play around with the volumetric fog too as there’s a lot can be done there.
     
    Last edited: Sep 22, 2023
    • Like Like x 6
  10. squerble

    squerble Well-Known Member

    Joined:
    Mar 8, 2020
    Messages:
    254
    Likes Received:
    387
    As it turns out, I missed the crucial step of forcing TSW4 to use -dx12 launch option in Steam. Since then, a quick test at the beginning of AVL suggests your ini tweaks very well still work. I'll play around a little on ECML now.
     
    • Helpful Helpful x 2
  11. squerble

    squerble Well-Known Member

    Joined:
    Mar 8, 2020
    Messages:
    254
    Likes Received:
    387
    In addition to the above, yep, even on this first run through the whole of Doncaster to Peterborough, things are improving massively as I go along. Phew!
     
  12. wcwood92

    wcwood92 Well-Known Member

    Joined:
    Jul 23, 2021
    Messages:
    394
    Likes Received:
    502
    JetWash I can definitely understand why you might have been frustrated. TSW4 was announced pretty much right after you released your ini tweaks. They were presumably a lot of work so I get it.

    But I'm glad you're still at it because those tweaks are the best thing to ever happen to my TSW experience. So thank you.
     
    • Like Like x 1
  13. JetWash

    JetWash Well-Known Member

    Joined:
    Mar 6, 2021
    Messages:
    3,120
    Likes Received:
    11,661
    Thanks, appreciate it. I’m going to have a play around with them over the next day or so and make some tweaks. I also want to see what can be done with the volumetric fog, although it looks pretty good as it is. Once that’s done I’ll put them up as a separate TSW4 download.
     
    • Like Like x 2
  14. wcwood92

    wcwood92 Well-Known Member

    Joined:
    Jul 23, 2021
    Messages:
    394
    Likes Received:
    502
    Sounds great! I'm looking forward to it
     
    • Like Like x 2
  15. solicitr

    solicitr Well-Known Member

    Joined:
    Jun 20, 2020
    Messages:
    12,812
    Likes Received:
    19,585
    Well, I copied my TSW3 engine.ini file system settings verbatim to TSW4, and everything seems to be working just as before; haven't noticed a problem.

    Unfortunately, the God Mode mod, in its old version, does not seem to work.
     
    • Like Like x 1
  16. Tigert1966

    Tigert1966 Well-Known Member

    Joined:
    Aug 18, 2020
    Messages:
    2,174
    Likes Received:
    3,667
    I'm glad you got it JetWash, I ended up getting it earlier than planned as seeing a lot of streams from streamers I trust tipped me over the edge of wanting it now instead of waiting a couple of weeks until I'm at home.

    I only discovered your mods / ini files just before TSW4 was announced (mainly to improve MML to a playable state). Pleased to say that despite a washed out screen on the 801, your engine.ini (High) is working ok on my laptop, so I'm pretty sure the Ultra settings will be fine on my desktop when I get back from holidays. Really appreciate your ongoing efforts.
     
    • Like Like x 1
  17. JetWash

    JetWash Well-Known Member

    Joined:
    Mar 6, 2021
    Messages:
    3,120
    Likes Received:
    11,661
    When you say washed out, is it very dim or overly bright? Have a look at the external PIS as well, how does that look?

    Assuming you’re seeing what I’m seeing I’ll get that fixed very soon.
     
  18. JetWash

    JetWash Well-Known Member

    Joined:
    Mar 6, 2021
    Messages:
    3,120
    Likes Received:
    11,661
    GodMode needs applying on a route by route basis so hopefully Foob is on that as we speak. Assuming it doesn’t crash the game (and you were able to download them) it ought to work with the TSW3 content within TSW4. Hope that makes sense.
     
  19. dbrunner#4864

    dbrunner#4864 Well-Known Member

    Joined:
    Mar 25, 2021
    Messages:
    489
    Likes Received:
    691
    I'm quite glad you decided to give TSW4 a try. I am also a big fan of you in regards of your TOD mod and the multiple fantastic route mods you have made.
    I'm thinking that the editor will be a game changer for you and other fellow modders who managed to bring huge changes to routes and stock with the minimum tools you had. With the editor life should be much better for you in regards to modding right?
    I am glad you are thinking if new ways of improving volumetric fog but be careful as I think this can really lower fps on lower systems :)

    Many thanks for the feedback , that is good news. I forgot to mention again that dx12 needs to be forced on for best results since I am quite sure that the shader compilation is only run for DX 12, and that is a critical stage of the ini tweaks.
    I was thinking the best way could be to force the shader compilation at start of a route as many games will force this operation at the start of the game but that is not possible via ini commands from what I know.
     
    Last edited: Sep 22, 2023
    • Like Like x 4
  20. SGTDRE

    SGTDRE Well-Known Member

    Joined:
    Sep 6, 2022
    Messages:
    1,509
    Likes Received:
    793
    Excuse me if I miss a few words here and there, was up most of the n, night from 1700 hrs to about 0500 messing around and while you are correct those ini tweaks are as you stated, BUT, I can honestly say that the game ran well, in a few places my FPS dropped to 45 - 50, see the attached images will ask my daughter to slap tpgether a video, I did record some, my PC did crask but dought it was from the game, it's a week or since a reboot. I will edit and correct this post later.

    For the most part, things ran fairly well, I even deliberately did what I could to break the game meaning what if I do this or that, anyway, I will try to get some things done to show what I see, but for the most part, I did not see stutters then again as I said I was pushing hard to see what happens.

    TSW4 DLC List.png

    Yes, this all is working no crashing of the game. I will be doing more later in the day.
    God Mode is only working & here and there but in the training center, it is working well.

    Shots taken
    upload_2023-9-22_12-9-59.png

    [​IMG]
    [​IMG] [​IMG]
    screenshot with ctrl+f12 reduced to 1080 so I can add it here
    TSW3_OleDre_1695347587_00-v2.png
    20230922122229_1.jpg
    20230922122057_1.jpg
     
    Last edited: Sep 22, 2023
    • Like Like x 1
  21. SGTDRE

    SGTDRE Well-Known Member

    Joined:
    Sep 6, 2022
    Messages:
    1,509
    Likes Received:
    793
    20230922122130_1.jpg
    20230922122407_1.jpg
    20230922122433_1.jpg
     
  22. solicitr

    solicitr Well-Known Member

    Joined:
    Jun 20, 2020
    Messages:
    12,812
    Likes Received:
    19,585
    Hold it- are those TSW3 routes running in TSW4?
     
  23. JetWash

    JetWash Well-Known Member

    Joined:
    Mar 6, 2021
    Messages:
    3,120
    Likes Received:
    11,661
    DX12 is without question a considerably smoother experience than DX11. I’m seeing little to no stutters for what it’s worth. I have had a crash though which I think was related to DX12, it certainly looks that way from the crash report.
     
    • Like Like x 2
  24. JetWash

    JetWash Well-Known Member

    Joined:
    Mar 6, 2021
    Messages:
    3,120
    Likes Received:
    11,661
    They can’t be, not yet.
     
    • Like Like x 1
  25. dbrunner#4864

    dbrunner#4864 Well-Known Member

    Joined:
    Mar 25, 2021
    Messages:
    489
    Likes Received:
    691
    Hmm I wonder if the crash is a random one time events or is it caused by one of the ini settings. You should redo the same run and let the AI drive the train if you are bored just to get a better picture. I had multiple crashes on KSW and SEHS in TSW3 whit the initial TSW2 ini tweak and the only way to find the problem was to re run the same scenario over and over while removing or modifing the ini values. In my case it was from some of the streaming ini settings being to aggressive for TSW3. Maybe your CTD might not be from DX12 itself but one of the ini tweaks to.

    I think the pictures are from TSW4 native routes ECML and Vorarlberg
     
  26. IsambardKingdomBrunel

    IsambardKingdomBrunel Well-Known Member

    Joined:
    Oct 6, 2017
    Messages:
    515
    Likes Received:
    941
    JetWash, you are a life saver. Applied the beyond ultra ini settings to TSW4. Now the Antelope route, is no longer the over bright, bland and washed out mess it was before.
    Proper job, thanks buddy.

    Mike.
     
    • Like Like x 2
  27. JetWash

    JetWash Well-Known Member

    Joined:
    Mar 6, 2021
    Messages:
    3,120
    Likes Received:
    11,661
    Awesome! Pleased to hear it.
     
    • Like Like x 1
  28. JetWash

    JetWash Well-Known Member

    Joined:
    Mar 6, 2021
    Messages:
    3,120
    Likes Received:
    11,661
    ps I will update this as soon as I can (got the mother-in-law visiting this weekend) but if you find the in-cab displays and screens or PIS too dim you can either delete the last line of the config file relating to legacy emissives altogether or change the value. I think I set it to 500 (because the screens in TSW3 were just an over-exposed mess), the default is 2000. I would suggest a number around the 1700/1800 mark for TSW4. From what I’ve seen this aspect of the visuals is much improved.
     
    Last edited: Sep 22, 2023
    • Like Like x 3
    • Helpful Helpful x 2
  29. IsambardKingdomBrunel

    IsambardKingdomBrunel Well-Known Member

    Joined:
    Oct 6, 2017
    Messages:
    515
    Likes Received:
    941
    Thanks again JetWash, people like yourself who make these upgrades and mods in general.
    Are worth your weight in gold. Particularly for players like myself, who can't create, fiddle with or fix stuff for themselves.
    Cheers,
    Mike.
     
    • Like Like x 2
  30. Hi Jetwash, whereabouts can I find your engine.ini settings for TSW3? Im using Laika's atm but Im keen to give yours a go!
     
  31. Thorgred

    Thorgred Well-Known Member

    Joined:
    Jun 8, 2018
    Messages:
    658
    Likes Received:
    320
    • Helpful Helpful x 2
    • Like Like x 1
  32. JetWash

    JetWash Well-Known Member

    Joined:
    Mar 6, 2021
    Messages:
    3,120
    Likes Received:
    11,661
    Please note that Foobian has added God mode to the TSW4 routes meaning the skylight intensity slider is back in the game.

    Happy days!
     
    • Like Like x 3
  33. SGTDRE

    SGTDRE Well-Known Member

    Joined:
    Sep 6, 2022
    Messages:
    1,509
    Likes Received:
    793
    I did change the ini setting below to what it is now from 500 the displays look much better
    "TimeofDaySystem.LegacyEmissiveAdjustments.EmissiveMultNonLamp=1700"
    With your ini settings and god mode from Foobian, I am very thankful for the hard work time, and effort that you, Foobian, and all of the modders for making this game so much better. Thank you. :)
     

    Attached Files:

    Last edited: Sep 23, 2023
    • Like Like x 3
  34. SGTDRE

    SGTDRE Well-Known Member

    Joined:
    Sep 6, 2022
    Messages:
    1,509
    Likes Received:
    793
    20230922153838_1.jpg 20230922153901_1.jpg 20230922185951_1.jpg 20230922190202_1.jpg 20230922191757_1.jpg
     
    • Like Like x 2
  35. hello i have been using your engine.ini for TSW4 and finding even after 1st runs on each new route still got many micro shutters and its so bad i livestream and upload and finding it way worse then TSW3 is there some new settings i could use that u using please
     
  36. JetWash

    JetWash Well-Known Member

    Joined:
    Mar 6, 2021
    Messages:
    3,120
    Likes Received:
    11,661
    In a word, no.
     
  37. sad to say micro shutters are still heaps after 1st run with the classic settings u done for TSW3 so a new set of lines need to be done when u get the chance please do reply to us all and myself as a you tuber i need to get the game micro shutters out of this game bad
     
    • Like Like x 1
  38. speediek#8515

    speediek#8515 Member

    Joined:
    Aug 27, 2022
    Messages:
    40
    Likes Received:
    47
    I had a play with both the stutter fix mentioned in this thread and your TOD4.ini tweaks, which I have to say are amazing. On both my desktop and steam deck .

    After a few runs on the three various routes I’ve concluded at least on the steam deck the stutter tweaks still make a massive difference to TSW4 in both the general frame pacing and stuttering of the game and I even managed to get most of your tod4 settings to play nicely with the steamdecks hardware.

    EDiT : It definitely took more than 3 runs of each route to get a smooth experience and some of my own changes especially on the steamdeck but I rarely see stuttering anymore. I also found forcing -dx12 still works and keeps the frame rate consistent at station especially on ECML. On dx11 I was getting massive frame drops with the same graphic settings and engine.ini tweaks.
     
    Last edited: Sep 25, 2023
    • Like Like x 2
  39. JetWash

    JetWash Well-Known Member

    Joined:
    Mar 6, 2021
    Messages:
    3,120
    Likes Received:
    11,661
    Matt has said that, assuming people are finding it works ok that DX12 may well become default before long.

    I think in a sim, which is a genre that requires a lot of CPU power, anything that can alleviate the load has to be used. If people are struggling I would very strongly suggest you use the DX12 launch parameter and Nvidia Image Scaling (as described on the TSC page for the ini tweaks) to buy some more GPU headroom. Until such time as the game gets DLSS it’s the best we have, it is daft not to use it.
     
    • Like Like x 5
  40. dbrunner#4864

    dbrunner#4864 Well-Known Member

    Joined:
    Mar 25, 2021
    Messages:
    489
    Likes Received:
    691
    Hello. I just did a couple of runs on my side on ECML and Vorarlberg and after the initial stutter especially on ECML where it was horrendous i did not encounter any issues whatsoever. Everything is smooth as butter on the consecutive runs on any of the routes with the exception of ECML where there is still some micro stutter when another Azuma passes by.
    Are you sure you have DX12 forced on ? squerble was having similar issues like you and it turned out he did not force DX12 on in the command line and that resulted in still having stutters on each run.
     
    • Like Like x 2
    • Helpful Helpful x 1
  41. The stutters on ECML was bad. I will think the shaders are written now so I will it a go.

    I wonder if the new Radeon drivers are better, apparently there is a bit of commotion about how good they are?

    Can you recommend???
     
    • Like Like x 1
  42. i have the same settings as TSW3 clear not working on the USA route is very bad check out my stream i did of All Aboard that just ended on my yt channel and u will clear see the issues i went to steam right click on TSW4 go to launch options and -dx12 thats 100% right yeah if so then i say your settings are not working like they were with TSW3
     
    • Like Like x 1
    • Like Like x 2
  43. I have been using these tweaks by drunner#4864 for months in TSW3.

    I just ran TSW4 without these tweaks and DX12 setting and it is terrible.

    I did install the latest video card drivers now. And changed the Engine.ini file and it works great again. Smooth!! It is very good!!
     
    • Like Like x 1
  44. dbrunner#4864

    dbrunner#4864 Well-Known Member

    Joined:
    Mar 25, 2021
    Messages:
    489
    Likes Received:
    691
    That is strange. I only did a 10 minute run on Antelope but even during the initial run the stuttering was quite mild.
    Did you do a full run first in order to for the game to compile and store the shaders, and then play a second time in order to observe the benefit of pre compiled shaders?

    Glad to hear that. It seems that there isn't any new stuff in the engine pipeline that could conflict with the ini tweaks. I suspect DTG is is still not trying to address performance issues in any way :D
     
  45. Do you think it might take a meeting with AMD and Nvidia to get some drivers made up for Train Sim World?

    I think Matt Peddleston is eager at DX12 and the engine.ini tweaks.

    It will happen surely.
     
    • Like Like x 1
  46. OldVern

    OldVern Well-Known Member

    Joined:
    Nov 2, 2020
    Messages:
    17,936
    Likes Received:
    36,499
    Got a bit of tl:dr block on the thread.

    Just wondering what I need to change in the ini or download to tame the over bright mid-day lighting as we did with TSW3?

    Advice appreciated, thanks.
     
  47. JetWash

    JetWash Well-Known Member

    Joined:
    Mar 6, 2021
    Messages:
    3,120
    Likes Received:
    11,661
    Here you go;

    https://www.trainsimcommunity.com/m...ini-tweaks/i3889-tsw4-to-d4-lighting-overhaul

    As mentioned in the description, you need God Mode as well (linked through mod) to change the skylight intensity setting using the slider.
     
    • Helpful Helpful x 2
  48. geloxo

    geloxo Well-Known Member

    Joined:
    Nov 21, 2018
    Messages:
    957
    Likes Received:
    1,725
    Ironically, using higher detail LODs and texture Mips results in the lowest hitching (microfreezes). The engine seems to struggle when handling many objects LOD/Mip changes in short time, for instance when a new tile is loaded. However if the same amount of objects is loaded at higher details the workload appears to be lower. That has an impact on performance but results in almost no noticeable hitching.

    The only reason I can imagine for that is that LOD and texture Mips transitions happen within very few frames time interval, meaning that system is requested to increase several objects level of details in one go when it didn´t have time to even load the lowest detail ones requested just few frames before. Player train moves faster than the distance designed for the objects details transitions, so to speak. By increasing quality less transitions are needed. Ideally some closer objects could be even loaded at max details directly when new tile is loaded. That results in virtually no tile loading hitching.

    Indeed it´s a matter of viewdistance. Very distant objects at the border of the tile will be still loaded at low detail, helping performance. The problem happens on medium and short range distances, in the transitions between LOD1 and LOD0 I would say. That happens in a range typically lower than 300m in some cases, and that´s much lower than the size of the map tiles (typically 1km), so it can happen that some routes find a tile loading event together with a LOD or texture Mip change event in the same frame and that´s too much, even for a high-end system.

    I think the LOD transitions in game are simply too short. They need to happen at bigger distances and with a proper spacing, keeping the objects between 0 and 500m from player position (meaning with those example values the mid range distances) still with LOD0 and still allowing enough time for a smooth transition between LOD1 and LOD0 if a new tile is loaded containing objects with those two different LODs. That won´t hurt performance much more than it hurts being at a big station platform with high details but will be more fluent in general for the game thread as the fps figures are not fluctuating so much, so game thread is going to be more efficient as well as it can maintain similar amount of calculations per second (operations per frame) during longer periods of time.

    I´m testing some things but apparently increasing texture streaming boost and LOD distances helps a lot to get rid of this limitation. Performance impact can be still levered by using viewdistance scale.

    Cheers
     
    Last edited: Sep 24, 2023
    • Like Like x 4
    • Helpful Helpful x 2
  49. OldVern

    OldVern Well-Known Member

    Joined:
    Nov 2, 2020
    Messages:
    17,936
    Likes Received:
    36,499
    • Like Like x 1

Share This Page