diff --git a/vloed.py b/vloed.py index 03b6800..96f2c17 100755 --- a/vloed.py +++ b/vloed.py @@ -9,6 +9,7 @@ __version__ = 0.2 __author__ = "Jan Klopper " import pygame +from pygame.locals import * import struct import time from gevent import spawn, socket, monkey @@ -49,7 +50,9 @@ class Canvas(object): def canvas(self, width=1366, height=768): """Init the pygame canvas""" pygame.init() - self.screen = pygame.display.set_mode((width, height)) + pygame.mixer.quit() + flags = DOUBLEBUF + self.screen = pygame.display.set_mode((width, height), flags) def clear(self, r=0, g=0, b=0): # pylint: disable=C0103 """ Fill the entire screen with a solid colour (default: black)""" @@ -78,6 +81,7 @@ class Canvas(object): else: preamble = struct.unpack_from("