#2d #grid #sparse-grid

sark_grids

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

21 releases

0.5.8 Jul 12, 2023
0.5.7 Mar 6, 2023
0.5.6 Dec 27, 2022
0.5.5 Nov 13, 2022
0.2.6 Mar 8, 2022

#655 in Algorithms

Download history 100/week @ 2023-10-29 128/week @ 2023-11-05 93/week @ 2023-11-12 91/week @ 2023-11-19 131/week @ 2023-11-26 85/week @ 2023-12-03 49/week @ 2023-12-10 146/week @ 2023-12-17 113/week @ 2023-12-24 38/week @ 2023-12-31 81/week @ 2024-01-07 67/week @ 2024-01-14 67/week @ 2024-01-21 85/week @ 2024-01-28 51/week @ 2024-02-04 130/week @ 2024-02-11

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

MIT license

110KB
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

~3MB
~90K SLoC