diff options
author | Logan Hunt <loganhunt@simponic.xyz> | 2021-12-06 21:44:51 -0700 |
---|---|---|
committer | Logan Hunt <loganhunt@simponic.xyz> | 2021-12-06 21:44:51 -0700 |
commit | 253b267f1cee377a834860fb4deac54ef9a78b7a (patch) | |
tree | d5eb10133097ba38b46c448683debba766162785 /mpi/include/game.h | |
parent | b3df69fd3ddd8f4ee88903bf74df67926898fd0c (diff) | |
download | gol-253b267f1cee377a834860fb4deac54ef9a78b7a.tar.gz gol-253b267f1cee377a834860fb4deac54ef9a78b7a.zip |
MPI
Diffstat (limited to 'mpi/include/game.h')
-rw-r--r-- | mpi/include/game.h | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/mpi/include/game.h b/mpi/include/game.h new file mode 100644 index 0000000..135fd8a --- /dev/null +++ b/mpi/include/game.h @@ -0,0 +1,19 @@ +#include <stdlib.h> +#include <stdio.h> +#include <string.h> + +#ifndef GAME_H +#define GAME_H + +struct GAME { + unsigned char* grid; + int padding; + int width; + int height; +}; + +int neighbors(struct GAME* game, int x, int y, unsigned char* halo_above, unsigned char* halo_below); +void next(struct GAME* game, unsigned char* halo_above, unsigned char* halo_below); +void randomize(struct GAME* game); + +#endif // GAME_H |