Simple tree foliage reduces productivity on mobile devices. What is the reason?

Godot Version

4.4 rc1

Question


I know that you can write to me to provide more information…

The project was created using the Compatibility mode, with low shadows and the simplest textures. The rest is all by default. I won’t say anything about 3D models, except for the tree itself.

How many times have I tried to import the most optimized trees, but nothing works!

My fps without tree foliage = 60 is great, but once you add foliage, the fps becomes 23. You’ll say it’s because of the shadows- NO! It’s the same without shadows…

Does anyone know how to optimize foliage on trees, or is there a normal 3D model?

an optimized tree has two different meshes, each with a different material. one for the trunk and one for the leaves.

trees from the internet I’ve seen with 3 different sets of leaves.

texture size is also important, that looks about 1024x1024 which is too much for a transparent material. try reducing the size of the leaves texture.
also, texture should be preferably power of 2, like 128x128 or 256x256, this is very important for older GPUs.

then material, godot’s default StandardMaterial3D is PBR using burley, but this could be too heavy for a phone. try changing it to lambert or even toon, disabling specular is also a good idea. also, the fewer textures, the better. for leaves I would have only an albedo with transparency. roughness and normal map will have a negative effect in performance.
finally, transparency must be set to scissor (alpha clip). you can try hash too. but alpha transparency (the default) is the most expensive, and even more so with depth prepass, which prevents clipping glitches.

Disable dynamic shadows: Whenever possible, use static shadows or baked lighting for static environments.

Optimize texture resolution: Limit the resolution of textures to 256x256 for opaque elements and 128x128 for transparent ones. Consider using texture compression (such as ETC or ASTC) to save memory.

Disable normal and specular maps: If necessary, use low-resolution versions or optimized shaders to minimize performance impact.

Reduce rendering resolution: For mobile devices, use lower resolutions like 360p or 480p, and implement scalable rendering (smaller render targets with upscaling).

Minimize draw calls: Combine textures into atlases and group objects with similar materials. Use tools like “Mesh Merge” to reduce the number of meshes drawn per frame.

Use reduced precision in shaders (lowp float): Apply this to calculations and variables where high precision isn’t essential. This can save processing power on mobile GPUs.

Simplify geometry: Reduce the polygon count wherever possible while maintaining acceptable visual quality.

Disable unnecessary post-processing: Effects like bloom, depth of field (DOF), and SSAO can be heavy on mobile devices. Carefully choose which effects are truly necessary.

Optimize physics and collisions: Simplify collision shapes and disable physics on objects that don’t require dynamic interaction.

Use Level of Detail (LOD): For distant objects, use lower-quality meshes and textures to save resources.