Most of the implementation is the same as the original C code with some bug fixes, some features added and several parts have been made more Rust-y. Rendering is done via one OpenGl (ES) 3.0+ backend.
Screenshots
Demo
Run with cargo run --example demo
Breakout
Run with cargo run --example breakout
SVG
Run with cargo run --example svg
Text
Run with cargo run --example text
Features
Anti-aliasing
Bézier paths filling and stroking
Solid color and image pattern fills and strokes
Gradients - box, linear, radial (including two-point / focal), and conic, with multi-stop colors and gradient transforms
Stroke width and miterlimit
Stroke caps: butt, round and square
Stroke joins: miter, round and bevel
Stroke dashing with dash offset
Fill rules - EvenOdd/NonZero
Rectangle scissoring (with rounded corners) and arbitrary-path clipping (Canvas 2D clip / SVG clip-path, nonzero and evenodd)
Image filters - gaussian blur, color matrices (the CSS filter functions), Perlin turbulence (SVG feTurbulence) and the sRGB transfer curve, chained in a single call
Layers - group capture with declared opacity and layer filters (Canvas 2D beginLayer/endLayer, SVG group effects)
Layer masks - luminance and alpha (SVG mask / mask-type)
Global alpha
Text filling and stroking
Text shaping
Text alignment: (left center right), (top, middle, alphabetic, bottom)