#game #sprite #rotation #blit

rotsprite

Rotate sprites using the rotsprite algorithm

4 releases

✓ Uses Rust 2018 edition

0.1.3 Feb 19, 2020
0.1.2 Feb 18, 2020
0.1.1 Feb 18, 2020
0.1.0 Feb 8, 2020

#44 in Rendering

22 downloads per month
Used in 2 crates

AGPL-3.0-or-later

80KB
420 lines

rotsprite

Rust implementation/library of the RotSprite algorithm.

Build Status Version Rust Documentation License

Works with many types of pixel buffers.

Example

Small Large

Left: Source Image Middle: Rotation using RotSprite Right: Naive rotation

Run the example

On Linux you need the xorg-dev package as required by minifb. sudo apt install xorg-dev

cargo run --example minifb

Credits

RotSprite algorithm - Xenowhirl
Pixel Art - Redshrike

Dependencies

~455–770KB
~18K SLoC