Looking for tips to reduce draw calls and gain performance for a large scene

Starting with the modeling program, what is a good way to make sure that I’m going to keep ahead in performance? Let’s say I have an interior room. This room has over 500 objects. From floors, ceilings, walls, cabinets, shelves, decor, etc, etc.

I obviously can group some things together as far as uvmapping is concerned, but I still can’t get the amount of objects vs materials to decrease that much. . Basically, what I’m wondering is a good solid way to import large scenes like this warehouse I’ve created, and get the most out performance.

Would it be a good idea for me to take this entire object from max, and import it into UE4 as one object with a bunch of different materials assigned to it? I can use the same 0,1 UV space, and just assign mats to the right stuff… But then wouldn’t that increase my draw calls for the 50+ materials I would probably end up having?

Is there any good forum topics or tutorials out there that are kind of specific to this type of thing? (I didn’t have a lot of luck finding a lot of documentation about this) I found a bunch of stuff about using instanced static meshes, but that won’t work for me here because all the models are unique right?

There are “Some” similar objects that I could merge together, but not too many, and that would mean importing them seperately in ue4. I guess I’m just not really sure about the best way to do this. Would it be possible to use a single material for this scene?

The only way I really know about doing this is to either have everything separated by mat IDs, or to import the objects 1 at a time and have them use their own UV map and material. But this way is crazy on draw calls. At this point, I guess I just really need to learn some of the tips/tricks devs use to reduce draw calls. More or less on the texturing side.

How big is the scene? Is culling going to matter?

The first thing you could try is grouping small props together: i.e. if you have a rock, a lamp and a flower pot next to each other, merge them into one object (you don’t have to do it in your modeling program, you can do it in UE 4.14.).

Also your best bet would be to import stuff into ue4 in various configurations (one mesh, multiple meshes) and see what ends up working the best.

Generally speaking it is not good to export one gigantic Mesh. This is because using many self contained object Meshes in a Scene will use Culling of objects not currently in the Camera view.

If your Warehouse is one gigantic Mesh including all the props and what not, every time the slightest piece of the Warehouse is in the Camera view, the whole object needs to be rendered even if you don’t see most of this gigantic Mesh.

Now with 4.14 it’s even easier to make LOD’s for Meshes if your Artist doesn’t set that up.

Without knowing more information about the Scene you are creating, I would say it’s safe to recommend going separate Meshes to start with. And only group things together after carefully evaluating performance problems later on.

Our current project we have a 2048x2048 Terrain used as a World Map for strategic layer. We have full of Vegetation (Trees, bushes, some grass, rocks), particle effects like smoke and clouds around Mountains. And about 100 AI Armies moving around.

Granted this is aimed for bigger hardware such as GTX970-980 or 1070/1080 cards and preferable i7+ processors.

However my point is that the only thing we have so far needed to optimise a bit is the vegation (easy to make new LODs and took like 30min to do) and of course make sure AI is threaded using EQS for Perception queries and such.
No Level Streaming is used, and no “LOD” on AI either. Meaning a AI being on the other side of the map (not visible to the Player) they still Tick as frequent as the closer ones. They are combating each other and sometimes they go really crazy.

FPS with a GTX980 + i5 goes around 40-60 without any spiky dips. This is with full AO and what not, but without AA on 1440p resolution. In combat maps (usually 512 maps) we use 200+ soldiers with rather complex animations (High/Med/Low attacks, Parry and Dodge) along with Formations.

Everything in our World map is still “in pieces”. So a Mesh of a City on the World Map is made up of many small Meshes rather than being a solid one-mesh-to-rule-them-all. However they are ofc grouped together in Blueprints most of the time for inheritance and easy handling of, as an example, a City Mesh. This is not the same though as having them as a solid welded together mega-mesh for the purpose of Culling.

You can start first by attaching objects that use the same materials. If you have a bunch of low-poly models then it’s better to merge them together. But also keep in mind lighting, each object can have only a single lightmap so if you merge too many objects together then the lightmap might not be able to get enough detail on all of them. With things like walls, there’s a lot of surface area so you can try splitting up walls into multiple parts split by the corners.