21 breaking releases

Uses new Rust 2024

0.24.0 Dec 23, 2025
0.23.0 Oct 16, 2025
0.22.1 Sep 18, 2025
0.20.0 Jul 6, 2025
0.1.0 Dec 31, 2023

#1616 in Algorithms

Download history 435/week @ 2025-09-23 705/week @ 2025-09-30 1848/week @ 2025-10-07 2001/week @ 2025-10-14 660/week @ 2025-10-21 321/week @ 2025-10-28 367/week @ 2025-11-04 242/week @ 2025-11-11 330/week @ 2025-11-18 265/week @ 2025-11-25 320/week @ 2025-12-02 303/week @ 2025-12-09 293/week @ 2025-12-16 433/week @ 2025-12-23 365/week @ 2025-12-30 320/week @ 2026-01-06

1,471 downloads per month
Used in 5 crates (3 directly)

MIT/Apache

525KB
12K SLoC

Provides 2D geometry and image processing functions.

This includes:

  • 2D vectors and related math
  • 2D shapes and associated algorithms: [Point], [Line], [Rect], [RotatedRect], [Polygon]
  • Rudimentary drawing functions
  • Algorithms for finding the contours of connected components in an image ([find_contours])
  • Algorithms for simplifying polygons and finding various kinds of shape that contain a polygon: [simplify_polygon], [min_area_rect], [convex_hull]

rten-imageproc

Library for pre and post-processing image data stored in matrices. It includes functionality for:

  • Finding contours of objects in segmentation masks
  • Working with axis-aligned and oriented bounding boxes / rectangles
  • Simplifying polygons
  • Simple drawing of shapes

The genesis of this library was a need in the ocrs OCR engine for a Rust implementation of a subset of the geometry and image processing functionality provided by libraries like OpenCV and Shapely in Python.

Dependencies

~1.5MB
~31K SLoC