Text causes massive slowdown

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.

Potential Solutions
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)

i have the same problem.
i added 10 fontObjects without scaling. game run with 60 fps. i just scale 2 fontobjects and framerate drops to 2 fps :confused:
i think i drawing my texts by using bgl and blf module :smiley: or using alpha textured planes for static texts.

I think I’ve found a solution. Use a different font.

I noticed that I had a file with three different text sizes, and it caused blender to crash, telling me my system didn’t meet the requirements. Another file had over 10 different text files, and ran fine. The only difference was that I had used a custom font in one. I think that rasterizing the default blender font has a performance problem. This is still only partially tested, but it seems to work, try it out.

I never noticed this or had a problem with it. I have a scene with many text objects and they all play perfectly