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

[pygame] display driver



What is the correct way to get hardware acceleration with Pygame + PyOpenGL? The snippet below seems to indicate that I've got software rendering with the DirectX driver, and my CPU usage hits 80% with just a simple rotating wireframe teapot so I'm inclined to agree. This is on a Win2K system with an Nvidia card and recent drivers.

>>> import pygame
>>> from pygame.locals import *
>>> pygame.init()
(6, 0)
>>> pygame.display.set_mode((1024,768), OPENGL|DOUBLEBUF)
<Surface(1024x768x32 SW)>
>>> pygame.display.get_driver()
'directx'

I've read Pete's DisplayModes tutorial and the NewbieGuide and run through the online docs, but ended up with no definitive answers. HWSURFACE, HWPALETTE, FULLSCREEN, HW_ACCEL - what is the magic incantation?

Dave