Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

turbopack

Tiny and efficient rect packer. The algorithm is very similar to and is heavily inspired by rectpack2D and the blog post it's based on.

Usage

const pack = @import("turbopack");

var ctx: pack.Context = try .create(allocator, w, h, .{});
defer ctx.deinit();

var rects: [4096]pack.Rect = @splat(.{ .w = 16, .h = 16 });
try pack.pack(pack.Rect, &ctx, &rects, .{});

About

Tiny and efficient rect packer

Topics

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages