6 releases

0.3.3 Mar 12, 2023
0.3.2 Aug 8, 2022
0.2.0 Aug 4, 2022
0.1.0 Aug 4, 2022

#1820 in Algorithms

Download history 48/week @ 2024-02-20 21/week @ 2024-02-27 3/week @ 2024-03-12 98/week @ 2024-03-19 278/week @ 2024-03-26 106/week @ 2024-04-02 65/week @ 2024-04-09 121/week @ 2024-04-16 175/week @ 2024-04-23 133/week @ 2024-04-30 5/week @ 2024-05-07 8/week @ 2024-05-14 46/week @ 2024-05-21 48/week @ 2024-05-28 28/week @ 2024-06-04

130 downloads per month
Used in 2 crates (via chuot-macros)

MIT/Apache

34KB
820 lines

Packr2

Implements some relevant of packing algorithms, currently StripPacker (simplest), SkylinePacker (good for unsorted data) and SplitPacker (best for bake data using the pack function)

  • It uses almost the same interface as texture_packer.
  • The SplitPacker was ported from rectpack2D but it sorts all split globably

Work left

  • Implement pack_with_best_size function to find the best packing with the lower used area

lib.rs:

Rectangle packing algorithm

No runtime deps