2049x2049 Terrain -> 7 hours light calculation + 20 GiB data?

Hi!

I’ve been playing with the new lighting system a bit and thought that the new indirect light would be ideal for realistic lighting on big terrains. So I created a 2049x2049 terrain and scaled it by a factor of 2.

Now Unity has been bouncing light for 7 hours and my poor gamedev partition ran out of space (the GICache is about 20 GiB) :smile:

Can I somehow exclude certain game objects (like the terrain) from GI?
Or will this still result in a sane deployment size if I give it enough hard drive space and let it finish its calculations, however long it may take?

Here: Enlighten... slow or stalled? - Unity Engine - Unity Discussions

Ah, thank you.

So its the lightmaps that take endlessly to calculate? I tried disabled static lightmaps for the terrain, but now Unity is running out of memory during the “clustering…” step and Windows either reboots or kills the process with a “Your computer ran out of memory” message :slight_smile:

Mind you, there’s RAM and swap space aplenty…

I’ll watch your other thread. Hopefully I can find a workaround and/or terrains will become usable in a later beta.

Are you running the 64-bit version of the editor?

Hi,

If you find terrain is baking slowly, you can try create a new LightmapParameter for terrain and use lower Resolution and Cluster Resolution (for start try 0.1 for both, approximately means GI is evaluated per 10 units on terrain). This helps to reduce the baking time especially in Clustering stage.

In a future release we will probably use this lower resolution baking parameter for terrain by default.

2 Likes

FYI: A large custom mesh (used for terrain, but not a Unity Terrain object) seems to stall in (or take a very long time in) the Clustering stage, until I reduce the quality by setting Lighting/Object/Advanced Parameters to Default-VeryLowResolution. My test mesh has about 50k triangles.

Does this mean the artists will need to break their Terrain, or ground meshes, into smaller chunks, to play nice with Enlighten?

Terrain is automatically split into chunks for you. Currently you can set the terrain chunk size (default is 500x500) in Lighting/Object tab, but we are considering to hide this option and figure out an optimal value.

For large ground mesh, my suggestion would be first try a real low resolution to see if the resulting lightmap is good enough for your needs.

3 Likes