BGE performance worse than Cycles fly mode

Hello all.

I’m developing a workflow at the moment which involves exporting from Revit to Blender then baking lighting to the model with Cycles. That gives me a model that other team members can walk around.

The thing is that I currently give them the file with Blender and tell them to start Fly Mode with shift-F. It would be much neater to give them a standalone executable. That would also let me add things like collisions.

Unfortunately when I switch the render engine to Game and press P, or if I stay in Cycles and press P, the peformance is poor. Even in wireframe mode it can take a few minutes before it’s up and running. It’s like the game engine has far lower performance than the 3D view (where fly mode works immediately and is smooth).

I am talking about a single mesh with maybe 200,000 vertices and 500,000 faces, so perhaps the game engine just isn’t set up for that sort of mesh.

Does anyone have any ideas for things to try? Should I try exporting to Torque3D? I’ve had a quick look, but it’s not as straightforward as I had hoped and I really want to stay within Blender if possible, to keep the workflow simple.

Thanks in advance.

I suspect physics, you need to set it all to no collision,

also, turn on scene frame rate and profiler, (it will let you know where your issues are)

The Game Engine should handle 500,000 polies in just a couple of seconds. So, a couple of questions:

  • What size are the textures?
  • If the lights are baked, did you remove them before entering the game engine (this will make a huge difference)

Turn on the profiler (Game -> Show framerate and profiler) and tell us what is using up the processor time.

@BPR:
I doubt it is the physics, that doesn’t usually impact startup time.

Creating physics meshes for such high-poly models takes some time. You could try creating a simpler mesh to use for physics and then set the high-poly mesh to No Collision. However, before going through the effort, try setting the high-poly mesh to No Collision to verify if this is indeed the problem.

Make sure that your logic isn’t doing something stupid like repeating a loop that doesn’t need to be run, and make a physics bounding box.
Set the objects to shadeless too and make sure you have no lights (especially sun/spot lamps with buffer shadows).
Remember that in Blender, there is vertex-buffer-object rendering which is much faster than rendering tris.

Can you post a .blend so we can make sure that there is nothing wrong with your set-up?

Thank you all for your answers. I am struggling to reproduce the problem reliably. One model is immediately running at 60fps, another takes 10 seconds before running normally, still another slowly fills up my RAM for several minutes.

Ah ha! Looks like I had to Remove Doubles in the problematic mesh. 8000 verts gone and now it plays almost immediately.

I shall investigate further with textures to see how performance is looking now and report back. On holiday from tomorrow, so it’ll be a week or so before I’m back here.

Thanks again for the input.