I’ve searched around a bit, and most of the questions about text in the game engine seem to be “how do I make it”. I don’t know if anyone else has run into this problem.
I have a scene with multiple Text object instances. I’ve done this before with no problem, but recently have been running into problems. I can have as many text objects as I want with no slowdown, but as soon as I have three or more text objects with different sizes, the framerate drops to 3-4fps. It even happens in blender files with nothing BUT the text.
Looking at the Framerate and Profile reveals that the Rasterizer is what’s taking up all the time, so I assume it’s something to do with text rendering.
What’s odd about this problem is that it’s inconsistent, so I imagine it’s hardware dependent.
At University, the computers will take longer to initialize the game engine if you have texts with different sizes. Let’s say you have a text object, and you press P. It will load no problem. Duplicate it a few times, and then scale them up and down, and it can take upwards of 30 seconds to respond after you press P. Once it HAS loaded though, it’s 60FPS. And if you press P again, after exiting out, but without making any changes, it loads instantly, implying that the processing that was done has been stored somewhere.
At home, where I have a more powerful computer, the problem is that it will just slow down to 3-4fps.
A] Using textured planes instead of text for the text items. However, this is really inconvenient in some cases, where the text is dynamic. It could be used in some places, but as this project is supposed to be multilingual, dynamic text would be ideal
B] Have the same size text for all objects. This would completely ruin any creative freedom over the interface, but would speed it up.
C] Using the old style text (textured plane). This would probably work, and shouldn’t have any slow down, but it wouldn’t look as nice.
D] Perhaps playing with the resolution number with python to make them all the same.
I’m wondering if anyone has run into this problem, or can replicate it, or knows how to get round it.
EDIT - May have found a possible cause, using orthographic cameras with large focal lengths. For that reason, I had to scale up the text. Scaled up text seems to cause the slowdown. Will double check when I get home. (feel like a fool)