[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [pygame] How fast is pygame meant to be?



Christian Perfect wrote:

>Hi,
>	I'm a Blitz Basic (www.blitzbasic.com) user who's been playing
>aroudn with pygame, so the first thing I decided to do was to make a pygame
>version of the "firepaint" demo that comes with BB. It's a simple demo that
>shoots sparks from your mouse cursor that fall to the screen when you click
>the mouse. I'm no good at optimising, so the code just follows the BB
>firepaint demo pretty closely. When I ran the demo, it ran *much* slower
>than the BB demo, at 8fps, whereas in BB it runs at my refresh rate (80fps+)
>Is pygame just not meant to be used for this kind of thing, and just
>blitting a few images and playing some sounds, or is there some secret
>different way of doing things I haven't found yet? :)
>If you're interested, I've uploaded my firepaint demo to
>www.ebizimonkey.com/firepaint.py
>
>	Christian Perfect
>____________________________________
>pygame mailing list
>pygame-users@seul.org
>http://pygame.seul.org
>
Ahh, Blizt Basic remember it form my Amiga days... Didn't know it 
excised for the PC :-).
The main thing to remember with python is that it's not a compiled 
language as I think Blitz Basic is and thus not even in the same 
ballpark when it comes to this sort of programming.
I think this is a typical trap with python(pygame), you have to know the 
language to avoid the pitfalls, know the limitations and the workarounds.

The pop trick that Jozef submitted is a good example, It's a hell of a 
lot faster deleting frags when count increase.

Cheers.
Fredrk

____________________________________
pygame mailing list
pygame-users@seul.org
http://pygame.seul.org