static batching in U3 vs. manually combining meshes?

Hi!

I’m trying to build a system for Unity developers to build models from parts - sort of building blocks, but I was afraid of bad performance if the number of blocks gets very high and started figuring out how I could combine the user-built model in Unity via scripts.

But then I got introduced to the new static batching features - and now I’m a bit confused :smile: Does batching make combining useless performance-wise? Does it even matter anymore if they share the same material?

This and this page seem almost a bit contradictory now :shock:

Any education on this would be very welcome!

The docs specifically mention that the material must be shared; that’s the whole thing that batching depends on. I imagine that static batching still has at least a little overhead compared to pre-combined meshes, but on the other hand separate meshes using static batching can use occlusion culling effectively, and pre-combined meshes can’t.

–Eric

Thanks, Eric

The reason I mentioned the materials, was this thread, see dreamora’s answer to question 2.

In the case I’m working now, the blocks would share the same material and same texture atlas anyway - so for that project it’s more about how to best combine the geometry. I guess combining by scripts would be more universal at least, as afaik the batching is pro only, so people with regular Unity would be lost with my blocks, then.

I can’t see how it would be physically possible to batch with different materials. I certainly don’t get batched draw calls with static batching unless objects share materials.

Static batching is pro-only, dynamic batching isn’t.

–Eric