Created
July 29, 2016 14:09
-
-
Save lithuak/c645b48f3cb89abd219f25436a68a940 to your computer and use it in GitHub Desktop.
PyGame mini-main
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
import pygame | |
from pygame.locals import * | |
from OpenGL.GL import * | |
from OpenGL.GLU import * | |
def main(): | |
pygame.init() | |
display = (800, 600) | |
pygame.display.set_mode(display, DOUBLEBUF|OPENGL) | |
while True: | |
event = pygame.event.wait() | |
if event.type in (pygame.KEYDOWN, pygame.QUIT): | |
pygame.quit() | |
break | |
if __name__ == '__main__': | |
main() | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment