[Solved] Much faster static text widget
Posted: Sat Jul 30, 2011 07:03
I need to do what CE suggested in this thread... however I have no idea how to do this.
" I would suggest skinning DefaultWindow using the Falagard/Default window renderer to create a basic label class and replace the static text instances with that, since - unless you want scrollbars and a bunch of other bloat in your labels - this will lighten the load considerably IMO."
viewtopic.php?f=10&t=5229&p=25505&hilit=static+text#p25505
Right now, I create all my windows using the create("") function in C++, I don't usually mess with layouts, looknfeels or schemes.
I tried modifying the existing windows such as WindowsLook/StaticText but it gives errors, I'm guessing i would have to change the CEGUI source code for this method to work.
the reason why I am doing this is for performance reasons, it seems like static text is about 10 times slower to create than a static image. Hopefully I can make them equal.
I am really lost here... maybe someone can give me a list of steps on how to do this?
Heres what I have:
1. Add a new entry to windowslook.looknfeel.
2. Add a new entry to windowslook.scheme and windowslookwidgets.scheme (why is there 2?)
3. Start using it in the code.
I'm using cegui 7.5.
" I would suggest skinning DefaultWindow using the Falagard/Default window renderer to create a basic label class and replace the static text instances with that, since - unless you want scrollbars and a bunch of other bloat in your labels - this will lighten the load considerably IMO."
viewtopic.php?f=10&t=5229&p=25505&hilit=static+text#p25505
Right now, I create all my windows using the create("") function in C++, I don't usually mess with layouts, looknfeels or schemes.
I tried modifying the existing windows such as WindowsLook/StaticText but it gives errors, I'm guessing i would have to change the CEGUI source code for this method to work.
the reason why I am doing this is for performance reasons, it seems like static text is about 10 times slower to create than a static image. Hopefully I can make them equal.
I am really lost here... maybe someone can give me a list of steps on how to do this?
Heres what I have:
1. Add a new entry to windowslook.looknfeel.
2. Add a new entry to windowslook.scheme and windowslookwidgets.scheme (why is there 2?)
3. Start using it in the code.
I'm using cegui 7.5.