Foliage + Lightmaps

In the current version of UE4 you can’t use static lightning with vegetation placed by the foliage tool.

I need lightmaps because of their superior quality but if you want a forest for example, you need a lot of vegetation and for every plant you place there is at least one draw call (depending on your material even more) added because there is no batching if you place them without the foliage tool.

I have experianced that small foliage like grass, which is placed very often in the map, has very poor performance because they are dynamicly lit.

At the current state there is the battle between draw calls vs dynamic light. Both decrease your performance with larger numbers.

I am curios what is the problem that does not allow foliage to be lightmaped. Are there technical limitations or is this feature not requested by a lot of people.


Daniel Wright has previously answered this in the thread below. It’s not in the engine at the moment but it’s definitely on the list! :slight_smile:

Have you set up any culling volumes or set up any LODs for your foliage inside the paint tool? This can impact your FPS.

In the two images below you’ll see there is a 12-13 fps difference when using culling and not. Try this and see if this helps your scene.

Culling used
Culling Used.JPG

Culling Not used
Not using culling.JPG

Here is the documentation for using Cull Distance Volumes that are not used with the foliage paint tool.

Here is the documentation for using Cull Distance with foliage Paint tool: Specifically look at Clustering and Culling to get your desired look and feel that performs well.

If you have any other questions feel free to ask!


Thank you for your reply. I know about culling and LODs but I wanted to see the performance limitations for very dense vegetation like grass that covers the ground (2000+ instances).

I know that you can’t tell me when this feature will come and the general answer is “when it’s done” but if you had to guess will it be befor 2015?

Unfortunately, there really is no timeline at the moment for when this will make it in to the engine. It’s certainly something that will be implemented in the future though! :slight_smile:


Hi Tim, so what is the best way to make grass over large areas with as little FPS impact as possible you think?

EDIT: My project is using a lot of foliage and quite big areas and it is planned to be using oculus as well, problem is I am having rather low FPS with a bigger amount of foliage around which is a problem for me. I suppose the problem shouldn’t lie in my hardware either, I am running a intel i5 4690k, Sapphire R9 290x Tri-x as well as 16gb of ram.

As far as I know the only way is with culling and low poly meshes. :slight_smile:

Even with culling I am having issues with grass popping in if too low (obviously) and if I have it at a decent number the performance just isn’t good enough (read my edit in the post above). Maybe if I did bigger patches of grass and then had lods to thin it out at longer distance but it seems like there would be a better way to do this…

You can thin it out in the material: (bottom of the page). But even without culling you can create pretty large fields (the character stands at the end of the field -> same size as the char in the 3rd person bp template + the grass meshes even have a wind effect):

I don’t know what hardware you are running but as you see you have currently ~40FPS which is in my case not enough (will make you dizzy with a oculus rift etc). Add to that some trees and bushes and you will have some real performance issues, currently on my setup I can stay somewhere around 90fps but not in 1080p and it is a rather limited area as well. Maybe what I am asking is not possible, oh well I’ll make a topic if I figure something out. :slight_smile:

the grass shouldn’t cast shadows, this will impact big the fps. And of course have no collision. Both can to be setup in the foliage tools.

If this still doesn’t help, make the material and mesh simple as possible and don’t use a 2048 * 2048 texture for the grass, use with lower resolution

About the lighting, set the directional light which is the sun as stationary with cascaded shadows map, so the light is static and only in the near dynamic

Typically for high foliage density, the best setup is to use the foliage tool. That said, you are going to want to set up your grass as either low poly or with several LODs, and you will probably want to stick with 1k textures (though I don’t think a higher res texture will make a HUGE difference). Then you want to make sure that you have culling enabled at a decent distance (but not too close); use larger foliage to help mask the effect, and use different culling volumes if you are getting close to a clearing or something. These are just a few thoughts I would consider. Hope it helps!

Is something changed here? :slight_smile:

Oh, this changelist looks promising :wink:
“Static lighting/shadowing support for instanced static meshes (including foliage)”