34 releases (breaking)

0.31.1 Mar 5, 2025
0.30.0 Dec 16, 2024
0.29.1 Oct 1, 2024
0.28.1 Jul 5, 2024
0.10.0 Feb 28, 2021

#890 in GUI

Download history 58595/week @ 2024-11-22 61478/week @ 2024-11-29 60615/week @ 2024-12-06 63681/week @ 2024-12-13 38986/week @ 2024-12-20 30445/week @ 2024-12-27 55525/week @ 2025-01-03 62235/week @ 2025-01-10 56236/week @ 2025-01-17 55910/week @ 2025-01-24 69600/week @ 2025-01-31 125844/week @ 2025-02-07 138102/week @ 2025-02-14 184361/week @ 2025-02-21 208020/week @ 2025-02-28 163446/week @ 2025-03-07

731,137 downloads per month
Used in 980 crates (19 directly)

MIT/Apache

130KB
3K SLoC

emath - egui math library

Latest version Documentation unsafe forbidden MIT Apache

A bare-bones 2D math library with types and functions useful for GUI building.

Made for egui.


lib.rs:

Opinionated 2D math library for building GUIs.

Includes vectors, positions, rectangles etc.

Conventions (unless otherwise specified):

  • All angles are in radians
  • X+ is right and Y+ is down.
  • (0,0) is left top.
  • Dimension order is always x y

Integrating with other math libraries.

emath does not strive to become a general purpose or all-powerful math library.

For that, use something else (glam, nalgebra, …) and enable the mint feature flag in emath to enable implicit conversion to/from emath.

Feature flags

Dependencies

~220KB