I'm using 0.5 svn head, and I'm trying East language display.
When I use few characters, it seems OK,
but if I display some more different characters(about 300 ~ 500 chinese characters), it's very slow and so crazy memory used ( about 70MB+).
I had add a debug trace at
void FreeTypeFont::rasterize (utf32 start_codepoint, utf32 end_codepoint)
{
....
Imageset *is = ImagesetManager::getSingleton ().createImageset (
d_name + "_auto_glyph_images_" + int (s->first),
System::getSingleton ().getRenderer ()->createTexture ());
d_glyphImages.push_back (is);
//
OutputDebugString("Create a texture!!");
With DbgVIEW, it seems that this code segment was called more than 4000 times.
plz help, thanks a lot !
So Crazy Memory Used, plz Help.
Moderators: CEGUI MVP, CEGUI Team
- lindquist
- CEGUI Team (Retired)
- Posts: 770
- Joined: Mon Jan 24, 2005 21:20
- Location: Copenhagen, Denmark
The font system needs to render the glyphs when you request them.
You may be much better off predefining sets of frequent glyphs. I know basically nothing about asian languages, so I'm not sure how these codepoints are distributed in the unicode set...
The new font system is much better than the old in this regard, but, it still has a somewhat shortcoming, in that it will try to render pages of 256 glyphs. in a language where there could be hundreds/thousands between each used glyph this might not be a very optimal solution.
HTH and please let us know how this can be improved.
You may be much better off predefining sets of frequent glyphs. I know basically nothing about asian languages, so I'm not sure how these codepoints are distributed in the unicode set...
The new font system is much better than the old in this regard, but, it still has a somewhat shortcoming, in that it will try to render pages of 256 glyphs. in a language where there could be hundreds/thousands between each used glyph this might not be a very optimal solution.
HTH and please let us know how this can be improved.
Return to “Modifications / Integrations / Customisations”
Who is online
Users browsing this forum: No registered users and 6 guests