[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[pygame] Lousy FPS



I was messing with a Pygame/OpenGL version of my tile graphics engine,
and am alarmed by a framerate issue.
This is the OpenGL version, which looks this bad because of hastily
drawn textures, full lighting, etc.:
http://kschnee.xepher.net/pics/3dthing.jpg
This is the older version using isometric tiles:
http://kschnee.xepher.net/pics/shiningsea060630-0.jpg

In each case the underlying world data is the same. My thinking in doing
the GL version was that I wouldn't have to draw those awkward diagonal
tiles, and that I'd be able to rotate to any angle. I tested it just now
and got 12 FPS (using a time.sleep(.05) call so the max would be 20).
OK, I said, the tradeoff is that the Pygame isometric version would be faster than the OpenGL.


So I tested the isometric version. 6 FPS, even with the logo and interface turned off. Not good. How can my pasting tiles on a 2D surface be slower than calling an OpenGL list of lists of 3D cube-drawing instructions?

I'll post the complete "Pearl3D" code if you want to see it.

Kris