Skip to content

mattstief/pyMaze

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

30 Commits
 
 
 
 
 
 
 
 

Repository files navigation

pyMaze

Dec 2022: I realized that I have encoded the GIF data incorrectly, with 3 Bytes per pixel rather than one. No idea how it works still.

maze generator with optional gif creation

stuff to tweak is at the top of the helper file


GIF

  • The pink represents the head. It visits unvisited cells until it reaches a dead end.

  • The shades of red represent a backtrack. This happens when a dead end is reached. The head will backtrack until it reaches a cell with unvisited neighbors. Once all cells are visited, the head will backtrack to the beginning cell, indicating completion.

  • The end of the gif shows a completed maze with the exits marked with light blue.

  • Blocky and jagged hall style choices

    60x60_Maze0 45x45_Maze0 30x30_Maze0 20x20_Maze0


The maze size is greatly limited if creating a gif. I can do 80x80 on my PC.

If gif creation is off, the maze can be much larger. I got up to 4000x4000 on my PC.

The bottleneck in both cases is primarily the amount RAM. Thrashing slows the program to a crawl. However, gif creation for "smaller" mazes (<100) is mainly CPU bound.

1000x1000 1000x1000_Maze

1800x1800 1800x1800_Maze

About

maze generator with gif creation

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages