Open sjain882 opened 8 months ago
I was under the impression that the "Maximum Texture Memory for high-res Texture load" option only controlled the threshold at which point it should switch to using "#low.xxx" textures, similarly to what the "Use Only Low-Res Textures" option does. When I'm able to I'll have to check the exe myself to confirm this though.
Either way, I have already tried setting this value to my GPU's VRAM (2GB) and it didn't seem to make a difference. It might be too low for the game, but I'm much rather willing to bet DXVK handles mipmap generation much better. It's interesting to note that OMSI 2 is not the only game with the fading black texture bug once the 4GB patch is applied (I don't remember which other games are affected in specific, but I do recall them having this same issue).
Slightly off-topic but, one of the methods of fixing this that I had in mind was dynamically saving game-generated textures as DDS files as a "cache" of some sort, though given that texture loading can be pretty sluggish already (and that I have no clue how I'd even implement a working cache that won't fetch potentially outdated textures lol) I feel this kind of job in particular is best left for a static method (I completely forgot texconv exists, thank you for reminding me).
I'll check out the video, and I'll also check out your tutorial for setting up DXVK for OMSI 2 when I have time. Thank you for your contribution, I will add the appropriate info to the MD soon!
It should be noted that the incorrect texture format problem extends further than described in your Twitter/X thread. It is possible for .dds textures to have the wrong alpha format.
They should have a separate alpha channel & should be in texconv's "dx9" format. After export from editing softare, they can be converted as follows:
texconv *.dds -alpha -sepalpha -dx9 -y -ft dds
The wrongly formatted textures show up as black as OMSI mis-interprets the non-existent alpha channel as a mipmap channel.
All of the above was explained by Anonim17PL a while back in this video.
Additionally, some users had luck by ticking (or unticking?) the "Generate Mip Maps" in Paint.NET, but this is likely a worse solution as it removes mipmaps entirely from textures, rather than formatting them correctly.
Personally, despite never converting any textures, since I started using DXVK I have not experienced this problem once. It has been around 2 years since I've seen black textures, whereas before installing DXVK, I would see the problem quite often.
In addition, I play a large selection of mostly medium-heavy content. Even in some of the most intense situations (e.g, Westcountry 3 + SP Renown DLC) it has not happened to me.
I believe this can be attributed to a combination of DXVK and setting a reasonable memory limit. Here are my configuration details:
6144.0
(I found that using something reasonable like3072.0
or above works great, but0.0
/ no limit consistently made black textures re-appear)dxvk.conf
:d3d9.maxAvailableMemory = 6144
D3D9ERR_INVALIDCALL
crashes when the graphics device was lost (e.g, when running Task Manager, CTRL ALT DELETE, UAC), and helped with black textures, however I'm unsure of its effect with DXVK).Here's a quick guide I created a while back, that allows less tehcnically advanced users to replicate this setup. Feel free to use it as you wish.
Spoiler
# **Solving white/black texture issues & out of memory errors** *Please note: this still requires a decently capable system and is not guaranteed to solve every error* ### __First, apply the 4GB Patch:__ 1. Download the .zip archive from https://ntcore.com/files/4gb_patch.zip 2. Extract the archive somewhere on your computer and open executable / Application file inside. 3. In the file picker dialog that appears, locate your OMSI 2 executable file (guidance below) and open it. 4. You should see a window detailing "Executable successfully patched". 5. Right click on your OMSI 2 executable file in File Explorer (guidance below). 6. Click ***Properties***. 7. Ensure the ***Read-only*** box is checked. 8. Click OK. ### __Next, set the video memory limits correctly:__ *If you are unsure of how to follow these steps, please refer to the image guide below.* 1. Launch OMSI 2. 2. In the main menu, click on ***Options***. 3. Click on the ***Graphics (advanced)*** tab. 4. In the the ***Max. Tex. Mem...*** box, enter either of the below values: For graphics card with >=3GB VRAM: `3072.0` For graphics cards with <3GB VRAM: the maximum amount of VRAM available to your graphics card, in MiB (e.g, `1024.0` for a 1GB VRAM card) 5. Click OK. ### __**Locating your OMSI 2 executable file**__ 1. Open Steam. 2. Hover your cursor over the ***Library*** tab in the top left, then click on Home. 3. Right click on the ***OMSI 2*** entry in the games list on the left. 4. Click on ***Properties....*** 5. Click on the ***Local Files*** option on the left. 6. Click on ***Browse...***. A File Explorer / Windows Explorer window will appear. 7. Look for the file named ***Omsi*** with type ***Application*** or file extension `.exe`. ### __**Why 3072.0 MiB?**__ In my experience, using a reasonable VRAM limit makes OMSI much more stable vs `0.0` / no limit. I no longer get `D3DERR_INVALIDCALL` errors, no longer see any white/black textures (its been around a year), and have never seen OMSI use >3GB VRAM anyway, without this limit. My graphics card: RTX 3060M Max-Q, with 6144MiB of VRAM. ![image](https://github.com/brokenphilip/OMSI_Errors/assets/43217178/1c7b1889-7d48-4560-81e5-fea62cbcaac6)