Terrain flickering, really annoying please help
Asked Answered
A

7

0

When I have the terrain option: cast shadows enabled, I have really bad flickering happening. I’m using a directional light, tried messing with every single setting in the light properties, shadows, rendering quality, terrain properties, nothing seems to fix it.

Using the standard grass texture painting and 1 duplicated scaled up tree.

vid

Accused answered 8/3 at 13:34 Comment(2)

Well it seems like it's not even the trees causing the issue, I only have terrain with some grass now look at this video of in the scene view- http://www.youtube.com/watch?v=VRhDr4Flo9k

Accused

terrain is 10,000 x 10,000

Accused
C
0

I think it may be a shader problem…

Collette answered 6/6, 2023 at 2:27 Comment(1)

Shader? Well I made a completely new scene, created a terrain, added a texture, added a directional light, added one default grass & tree , put on deferred render and still get the problem. I didn't use any special shaders or choose any shaders

Accused
G
0

This might come in very late, but I think it’s still useful. The ONLY permanent fix for this, as far as I can tell, is reducing the terrain size. The memory and computational resources involved in rendering large terrains causes errors, simply because the hardware is pushed over its limit.

By trial and error I found that the maximum size for each individual terrain I can work with is 3000 x 3000, anything larger causes the shadow flickering issue.

So if your world is say, 9000 x 9000, use 9 terrain tiles, each 3000 x 3000, and stitch them together. Flickering gone.

Gilmer answered 6/6, 2023 at 2:14 Comment(1)

My terrain is only 600 x 500...

Saintsimon
I
0

This might be a camera problem.
Try increasing the near clipping plane. That often helps this kind of problems.

Infirm answered 8/3 at 14:41 Comment(1)

This fixed my issue, default near clipping plane is set to 0.1 in our editor, I had to bump this up to 0.7 to completely remove the flickering. At 0.5 it was "better" but could still be seen on the tops of buildings and certain terrain tiles when player is flying around.

Swann
P
0

Hey, this can also be the camera I found out. If your rendering is set to deferred change it back to ‘Graphics Setting’

Phonics answered 6/6, 2023 at 2:32 Comment(0)
C
0

This is many years late but I was having this issue and and the comment that mentioned terrain size made me realize what the problem is. With big terrain sizes you start to run into floating point issues. See this video for an example of the issues this causes and how to fix it with the floating origin technique: Endless Runner: Floating Origin: Solve Long Distance Glitches (Unity3D Tutorial) - YouTube

Canaan answered 28/1, 2021 at 7:4 Comment(0)
P
0

What helped for me is increasing the near clipping plane on the camera. I had near / far values of 0.1 / 1000 and realized that everything is still rendered with 100 / 500. It removed the flickering on the terrain on the Android build.

Potable answered 13/5, 2022 at 17:10 Comment(0)
K
0

What helped me is decrease Shadow Distance in Project Settings → Quality → Shadows section. Also, I changed Shadow Bias value from 0.05 to 0.1 in directional light component. Bias description exactly says this “Useful for avoiding false self-shadowing artifacts”.

The problem for me appeared just after I changed Shadow Distance from 150 to 1000
appears that 300 is enough for me, and it affected flickering - it almost disappeared.

Krystakrystal answered 8/3 at 5:8 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.