Rendering costs between static meshes and a blueprints

Hi all!

I have a question about performance in UE4 that I’m quite sure what the answer is, but I wouldn’t know quantitatively how right or wrong I am. Let’s see if someone more knowledgeable than me can shed some light on this matter, fingers crossed!

So at the moment I have a billboard of a tree, consisting of two intersecting planes, that I plan to scatter across a square kilometre of terrain. I can do this through two different methods:

1/ Scatter it on a 3d editing software such as 3ds Max or Blender and then import all of those scattered billboards as one object into Unreal.

2/ Create a blueprint in Unreal which scatters one billboard on many different spawn points according to a CSV which would feed the position, scale and rotation for each billboard.

What do you think is more efficient? In my head the static mesh from option 1 is way more efficient, as I would have one single draw call for that object in Unreal. I’d love to hear your thoughts on this though, and see if someone can shed some more light into the matter.

Thanks in advance for your time reading this :slight_smile:

Hey. Option 2 actually has the capability to outperform option 1, while giving you extra control if you require it. Create a blueprint that uses an Instanced Static Mesh component, and populate that component with your individual billboard mesh from a CSV file. An instanced static mesh component uses only one drawcall, similar to combining all the billboards into one mesh, but you would have much more control over the instances, such as being able to cull them based on distance, to lower your overall polycount - plus the single billboard would be much smaller in file and memory size than a mesh that consists of possibly hundreds of thousands of individual billboards.

If you are using Forest Pack, it actually has options for exporting a nearly perfect file, that with a bit of formatting, you can use to scatter the objects. Let me know if you’d like more help, as I built a blueprint to do exactly this not too long ago.

Hi VaSSiLi, thanks for your comment! I hadn’t thought of using an instanced mesh, as I’m not familiar with that type of actor, but thanks a lot for your contribution - I will definitely try to use that to improve performance. I’ll come back to this post if I have trouble using this instanced methodology, but let me know if the following is true:

I have an actor blueprint, which in turn is made up an “Instanced Static Mesh” component. That component, on the construction graph, is set to be spawned at a particular location, with a scale and rotation value being fed by a CSV file. Does this seem like the correct approach, and if so, would this only imply a drawcall for all of the instanced created by that CSV?

Also, I am not using Forest Pack, but I could be looking at it in the future - I do have an account for it for 3ds Max, so if there’s something to be won using it that would be great as well.

Thanks a lot for your answer, and kind regards!

Hey,

Yea that’s exactly right. If all your scatter objects are the same mesh, I believe that will be a total of one drawcall (or maybe 2 (One for mesh, one for material? I forget). The blueprint itself is pretty simple, depending on the complexity of what you are trying to do. I only ask if you are using Forest Pack because it can export .xml files with a ton of data, but if you already have a way to export your .csv data, that’s not important.