#grid #iterator #collection #2d

neighborgrid

A 2-D grid datastructure with easy to use iterators and adjacent cell methods

1 unstable release

0.1.0 Jun 11, 2023

#1878 in Data structures

MIT license

81KB
1.5K SLoC

A collection that represents a 2-D grid with equal amount of cells in each row and equal number of cells in each column. Supports different origin (location of 0,0) configurations, and includes methods to get neighbors of cells, iterators, and more. Behind the scenes, the data is stored in a 1-D Vec to improve performance, but interaction with grid is done through normal (x,y) grid location methods.

See the documentation for more details.

This has just been a result of messing around with grid problem, nothing high-end scientific / mathmatical / or production based. Enjoy!

No runtime deps