Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: Draw(Text) performance issue  (Read 14324 times)

0 Members and 1 Guest are viewing this topic.

dabo

  • Sr. Member
  • ****
  • Posts: 260
    • View Profile
    • http://www.dabostudios.net
Draw(Text) performance issue
« Reply #15 on: July 17, 2008, 07:59:20 pm »
Take your time, no hurry.

dabo

  • Sr. Member
  • ****
  • Posts: 260
    • View Profile
    • http://www.dabostudios.net
Draw(Text) performance issue
« Reply #16 on: July 29, 2008, 04:40:51 pm »
I read the road map and I noticed this:

Done - ready for next version
- SYSTEM Added types and conversion functions to handle all Unicode formats
- GENERAL SFML now uses UTF-32 for all text related stuff instead of UCS-2

Will this speed up the SetText-method for visual studio that you were talking about earlier or is it something else?

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32504
    • View Profile
    • SFML's website
    • Email
Draw(Text) performance issue
« Reply #17 on: July 29, 2008, 05:12:27 pm »
Actually, the performances issue with strings was a stupid thing which is fixed.

I'm also going to improve the sf::String rendering code to optimize it, but it's already way faster than before.
Laurent Gomila - SFML developer

Avency

  • Full Member
  • ***
  • Posts: 113
    • View Profile
Draw(Text) performance issue
« Reply #18 on: July 29, 2008, 05:45:33 pm »
It definitely got faster. I got 5000 fps before, now I get 24000 fps.
I almost thought that there was something wrong with my message box rendering code. :P

SirJulio

  • Full Member
  • ***
  • Posts: 241
    • View Profile
Draw(Text) performance issue
« Reply #19 on: July 29, 2008, 06:03:09 pm »
Quote from: "Avency"
It definitely got faster. I got 5000 fps before, now I get 24000 fps.
I almost thought that there was something wrong with my message box rendering code. :P


OMFG ! You work on a Cray XT5 ? =D

I confirm, string is now a lot faster than before.

Avency

  • Full Member
  • ***
  • Posts: 113
    • View Profile
Draw(Text) performance issue
« Reply #20 on: July 29, 2008, 06:20:07 pm »
Nope, it's a 8800GTX, rendering nothing but a message box (only a few lines of OpenGL code) + fps string in a 320x240 window (it drops to an average 15000 fps if I change the resolution to 640x480).
Don't worry, it gets slower the more I draw on the screen. :wink:

Daazku

  • Hero Member
  • *****
  • Posts: 896
    • View Profile
Draw(Text) performance issue
« Reply #21 on: July 29, 2008, 06:41:02 pm »
Quote from: "Avency"
Nope, it's a 8800GTX, rendering nothing but a message box (only a few lines of OpenGL code) + fps string in a 320x240 window (it drops to an average 15000 fps if I change the resolution to 640x480).
Don't worry, it gets slower the more I draw on the screen. :wink:


lollll 320X240... I will draw an fps string in a 10X100 window and we will see wich fps i will get XD.
Pensez à mettre le tag [Résolu] une fois la réponse à votre question trouvée.
Remember to add the tag [Solved] when you got an answer to your question.

dabo

  • Sr. Member
  • ****
  • Posts: 260
    • View Profile
    • http://www.dabostudios.net
Draw(Text) performance issue
« Reply #22 on: July 29, 2008, 07:22:26 pm »
Sounds great. So I don't have to change any of my code to get this speed up, only download the new source?

SirJulio

  • Full Member
  • ***
  • Posts: 241
    • View Profile
Draw(Text) performance issue
« Reply #23 on: July 29, 2008, 07:30:17 pm »
@Dabo :

Yeap, maybe you'll need to do some changes on your code with the new unicode stuffs. If you don't use wchar at all, just update your svn.

dabo

  • Sr. Member
  • ****
  • Posts: 260
    • View Profile
    • http://www.dabostudios.net
Draw(Text) performance issue
« Reply #24 on: July 29, 2008, 08:52:37 pm »
It's faster for sure  :)  Great job!

Avency

  • Full Member
  • ***
  • Posts: 113
    • View Profile
Draw(Text) performance issue
« Reply #25 on: July 30, 2008, 08:46:53 am »
Quote from: "Daazku"

lollll 320X240... I will draw an fps string in a 10X100 window and we will see wich fps i will get XD.


Any results? :wink:

Daazku

  • Hero Member
  • *****
  • Posts: 896
    • View Profile
Draw(Text) performance issue
« Reply #26 on: July 30, 2008, 02:19:49 pm »
ROFL!!! I will do it this night if you really want a result XD.
Pensez à mettre le tag [Résolu] une fois la réponse à votre question trouvée.
Remember to add the tag [Solved] when you got an answer to your question.

fixus971

  • Jr. Member
  • **
  • Posts: 76
    • View Profile
    • http://www.fixweb.it
Draw(Text) performance issue
« Reply #27 on: August 23, 2008, 11:46:47 am »
Hi boys.. I have the same problem and read all but not see results..
I'm using SFML 1.3 too as wrote on first post.

updated/fixed SFML Code that work faster with SetText
is 1.3 or is in SVN source?? :?:

Thanks
^_^=>Il calcolatore è straordinariamente veloce, accurato e stupido. Gli uomini sono incredibilmente lenti, imprecisi e creativi. L'insieme dei due costituisce una forza incalcolabile. (Albert Einstein)

SirJulio

  • Full Member
  • ***
  • Posts: 241
    • View Profile
Draw(Text) performance issue
« Reply #28 on: August 23, 2008, 06:24:45 pm »
The svn source. =)

fixus971

  • Jr. Member
  • **
  • Posts: 76
    • View Profile
    • http://www.fixweb.it
Draw(Text) performance issue
« Reply #29 on: August 24, 2008, 10:45:08 am »
Hi Sir.
Yesterday I try svn source but without different results.
I just put svn include/lib dirs into sfml 1.3 sdk and recompile all.
I'm using VC9.
Now I'm working using wstringstream.
^_^=>Il calcolatore è straordinariamente veloce, accurato e stupido. Gli uomini sono incredibilmente lenti, imprecisi e creativi. L'insieme dei due costituisce una forza incalcolabile. (Albert Einstein)