(self, window_width, window_height)
| 9 | |
| 10 | class FloodFill: |
| 11 | def __init__(self, window_width, window_height): |
| 12 | self.window_width = int(window_width) |
| 13 | self.window_height = int(window_height) |
| 14 | |
| 15 | pygame.init() |
| 16 | pygame.display.set_caption("Floodfill") |
| 17 | self.display = pygame.display.set_mode((self.window_width, self.window_height)) |
| 18 | self.surface = pygame.Surface(self.display.get_size()) |
| 19 | self.surface.fill((0, 0, 0)) |
| 20 | |
| 21 | self.generateClosedPolygons() # for visualisation purposes |
| 22 | |
| 23 | self.queue = [] |
| 24 | |
| 25 | def generateClosedPolygons(self): |
| 26 | if self.window_height < 128 or self.window_width < 128: |
nothing calls this directly
no test coverage detected