Unity Terrain Bug? Segments of Terrain seem to disappear/flicker
Hello,
I am currently working on generating some terrain with TerrainComposer2. The scene that I created looks good from afar, but when I hit the play button, parts of the generated terrain seem to disappear. It only appears to happen when objects like trees or parts of the terrain, block the view of the segments that disappear from the camera. Although, when the player reaches a certain part of the map, almost the entire terrain disappears (Seems to also flicker on and off when the player is moved). Here are some pictures that demonstrate my issue:
What the terrain looks like at first when the camera is not in motion...
What terrain looks like when the camera is moved...the hills in the foreground either disappear or they appear in segments.
Is this some kind of optimization feature I am unaware of? I never touched the Occlusion Culling tool, so this issue can't be caused by that. Please help, I have been knocking my head off my table for days trying to figure out this bug!
What solved the problem for you? I'm on 2019.3.8f1 and ran into this problem, tried rebaking Occlusion Culling multiple times but that didn't solve it, even if i remove Occlusion Culling i still get this.
Answer by G_Sacristan · Oct 07, 2016 at 07:29 AM
Whats the target platform?
Remove Occlusion Culling;
If there are several cameras rendering the scene. Disable all except main;
Disable custom shaders if any;
If nothing above works. Try adding Textures and their materials to resources folder. (note that this is just a debug, you shouldnt use Resources folder unless there is no choice)
You could also add https://www.assetstore.unity3d.com/en/#!/content/12047 and then check if there are any errors on target device when running build.
Answer by Neiist · Oct 04, 2016 at 04:06 PM
Hello @PixelShield,
I have almost the same issue in my game:
Except that when I'm using the editor, either in the scene view or in the game view using play mode, the terrain shows as it should without any problem.
But when I build the game and run the executable, a big part of the terrain textures are simply... not there. Everything else regarding the terrain works, collisions too, but a wide area isn't showing its textures at all, making it transparent. Moving the camera around has no effect in my case.
It appeared when I updated Unity from version 5.3.5f1 to 5.4.1f1 ...
Did you managed to solve your issue? Does anyone solved it or is having the same problem?
EDIT: Okay, it looks like updating unity from 5.4.1 to 5.4.3 solved my issue so far.
U could reapply textures to Terrain. Sometimes it does the trick. Unity sometimes tends to f* up references
Answer by loliconest · Apr 11, 2019 at 12:29 PM
I also had this problem when I edited the shape of my terrain, and it only happened on the part that I modified.
Cleared my Occlusion Culling and it's back to normal, but have to re-bake it.
Answer by OZAV · Dec 20, 2020 at 07:00 AM
Yep, good work-around advice to try, we have also addressed that (repeating) issue on the high quality RFPS forum, hope it helps, see the page 117: https://forum.unity.com/threads/realistic-fps-prefab-released.176985/page-117#post-6611503
Your answer
Follow this Question
Related Questions
Unity camera render performance with many terrains 2 Answers
Unity Texture Rendering Second Camera After Build 0 Answers
Am I able to add a video clip in VR project (Google VR and Cardboard) in Unity? 1 Answer
My 3rd Person camera doesnt collide with Terrain... Please Help 0 Answers
Is there a Unity intervisibility sample? 0 Answers