#2d #grid #sparse-grid

sark_grids

A set of grids for storing and accessing data in a grid-like way

19 unstable releases (4 breaking)

0.5.6 Dec 27, 2022
0.5.5 Nov 13, 2022
0.5.1 Sep 29, 2022
0.5.0 Jul 30, 2022
0.1.5 Jan 14, 2022

#1 in #2d-grid

Download history 17/week @ 2022-10-18 48/week @ 2022-10-25 51/week @ 2022-11-01 84/week @ 2022-11-08 51/week @ 2022-11-15 44/week @ 2022-11-22 39/week @ 2022-11-29 42/week @ 2022-12-06 31/week @ 2022-12-13 49/week @ 2022-12-20 67/week @ 2022-12-27 133/week @ 2023-01-03 35/week @ 2023-01-10 22/week @ 2023-01-17 51/week @ 2023-01-24 70/week @ 2023-01-31

235 downloads per month
Used in 5 crates (3 directly)

MIT license

105KB
2.5K SLoC

License: MIT Crates.io docs

A set of grids for storing and accessing data in a grid-like way.

This crate provides three types of grids:

  • Grid: A dense grid that stores it's internal data in a Vec. The size of the grid is constant and elements cannot be removed, only changed. Provides fast iteration and access speed.

  • SparseGrid: A grid that stores it's internal data in a BTreeMap. Elements don't take up any memory until they're inserted and can be removed as needed, but iteration and access speed will be slower than a Grid for large full grids.

  • WorldGrid: A utility for translating between aligned grid points and world space.


lib.rs:

A set of grids for storing and accessing data in a grid-like way.

Dependencies

~2MB
~56K SLoC