50% framerate slowdown with 6 lines of text

For help with anything that CEGUI doesn't offer straight out-of-the-box, e.g.:
- Implementation of new features, such as new Core classes, widgets, WindowRenderers, etc. ...
- Modification of any existing features for specific purposes
- Integration of CEGUI in new engines or frameworks and writing of new plugins (Renderer, Parser, ...) or modules

Moderators: CEGUI MVP, CEGUI Team

Rakkar
Not too shy to talk
Not too shy to talk
Posts: 34
Joined: Tue Aug 15, 2006 02:49

50% framerate slowdown with 6 lines of text

Postby Rakkar » Tue May 22, 2007 22:57

I'm getting this problem.
http://www.ogre3d.org/phpBB2/viewtopic.php?t=32277

I can't ship my game like this. So I need to spend some time to see what I can do to fix this. Maybe nothing, since such a widespread and evident problem likely does not have any easy fix. The alternative is to use Ogre's font system and write my own thing, but I might as well try to do what I can.

Now the problem is clear - it is because every character is individually rendered. I believe the solution is also clear - if the static text does not change, render to texture, then blit that one texture, rather than each character. For big strings this can give you 100X the performance.

I've done this 3 times in other engines, but with CEGUI I'm totally unfamiliar with where to start. So a few questions:

1. Does CEGUI have the ability to write text to a texture, rather than to screen?
2. What difficulties are there that have blocked you from doing this already?
3. Assuming I write the text to a texture, is there any particular way I should draw to the screen?

Any feedback that will save time is appreciated.

User avatar
scriptkid
Home away from home
Home away from home
Posts: 1178
Joined: Wed Jan 12, 2005 12:06
Location: The Hague, The Netherlands
Contact:

Postby scriptkid » Wed May 23, 2007 07:48

Hi,

i read the thread and it seems you did try some changes / hacks. Did those changes (like caching texts and only redraw when required) help a bit? If they did, it might give us some insights in where to start.

Thanks and good luck!


Return to “Modifications / Integrations / Customisations”

Who is online

Users browsing this forum: No registered users and 1 guest