- Home /
How to prevent mipmaps from blurring textures
Hello, I am looking for a way to stop my textures from looking blurry in the distance, by that I mean that the textures look perfect when they are right next to me and get gradually blurrier in the distance, that's not why I want at all, I want my floor to be clear and visible even if I am looking from far away. I have been doing a lot of research for the past 8 hours and I can't find anything that helps my case.
I tried disabling mip maps but my textures end up looking like crap I tried entering dev mode and changing the mip bias but it doesn't fix it entirely I tried switching the filer mode I tried setting the anisotropic filtering to all the options available (disabled, per texture, forced on) I tried switching the aniso level to 16 I even tried downloading another version of unity All that didn't help at all, I have linked some images as examples for you to see
Let me know if you have an idea of what could be causing this Thanks in advance.
Answer by elzbeb · Jul 29, 2021 at 02:17 PM
The issue is that my nvidia drivers werent up to date so if anyone encounters this problem make sure you do that
Answer by Eno-Khaon · Jul 29, 2021 at 02:53 AM
To put it simply, there's no easy solution to this problem. Mipmapping is often handled primarily as a factor of distance, without taking the *current* screen resolution into account often enough, nor to a significant-enough degree.
Mipmapping basically exists to reduce visual noise, and is much more important to detailed, grainy textures than to more-solid-colored ones. Likewise, Anisotropic Filtering is there to apply the effects of Mipmapping on individual axes as the surface displaying the texture is slanted at greater and greater angles.
*cough* DXT texture compression is a different matter altogether, and easily leads to other nightmarish visual artifacts. *cough*
So, let's look at what happens as Mipmapping occurs, then.
Base image: Mipmaps:
Each iteration keeps key details intact (namely, the *existence* of the cross through the middle), but clarity is lost with each step of Mipmapping because the image is blurred as its resolution is reduced over and over again. At the same time, however, the noise is also blended together into mushy, vague colors.
This is meant to mimic reality.
As visual acuity drops off with distance, so too do the apparent details in the image. To save computational power of trying to do this in real time, as well as because the pixel size on your screen doesn't actively change just because it's drawing the 3D model smaller at a simulated distance, this is made up for by creating additional sets of that texture instead. They're scaled down since they'll take up less of the screen at a time the further away you are, and they're blurred to simulate the loss in detail that becomes challenging to accurately portray.
Texture filtering (e.g. Bilinear Interpolation) only blends between neighboring pixels to account for sub-pixel accuracy; it doesn't cover a wide area. Mipmapping expands on this by reducing the number of pixels in order to support that filtering. With this in mind, it's apparent that the textures are being reduced in quality at a point where it is not visually helpful to do so.
And that brings us back to the beginning of this answer. There's no easy solution to this problem. How apparent the problem is is dependent on the type of texture being displayed; yours relies on discrete lines, and there's no sanity checking to ensure those lines remain fully intact when automatically downscaling the image.
That doesn't mean that all hope is lost, however. Combinations of Anisotropic Filtering and Trilinear Filtering (specifically intended to blend samples between mipmap levels) may help mitigate this. Similarly, thanks to an old forum post, there are non-zero options for manually adding Mipmaps, which may be a viable alternative option.
thank you that was very helpful definitely going to help me through my journey of solving this
Answer by Razputin · Jul 29, 2021 at 02:17 AM
Have you tried using some form of anti-aliasing?
If by blurry you mean the jagged edges anti aliasing will take care of that, unless you meant something else.
no i meant the floor, you see the further it goes the more it gets blurry
Your answer
Follow this Question
Related Questions
Texture grid displayed oddly when width =/= height 1 Answer
blurry textures 2 Answers
Random Tiling Textures 0 Answers
Exporting multiple terrain tiles as one heightmap 0 Answers
How to make different Rule Tiles interact with each other? 0 Answers