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

Re: [pygame] pygame.display.flip() and framerate



It's the way drivers act.  Some do vsync, and some don't.

Try using gl_set_attribute with GL_SWAP_CONTROL
http://pygame.org/docs/ref/display.html#pygame.display.gl_set_attribute

That's only available in recent SDL/pygame (SDL 1.2.12 +, and pygame
1.8.x + I think).


cheers,

On Mon, Feb 9, 2009 at 11:01 AM, Ian Mallett <geometrian@xxxxxxxxx> wrote:
> I know, but my question is more why OpenGL + pygame doesn't act like SDL +
> pygame?  The latter can run > 60 fps.  The former can't.  I don't see why
> there should be a difference.  I can obviously work my way around it, in
> ways like you just pointed out, but I'm curious why the framerate is limited
> with OpenGL.
> Ian
>