Skip to main content

rasterrocket_render/simd/
mod.rs

1//! SIMD-accelerated hot paths for the rasterizer.
2//!
3//! All SIMD code is gated behind `#[cfg(target_arch = "x86_64")]` and uses
4//! runtime feature detection (`is_x86_feature_detected!`) so the binary runs
5//! correctly on machines that lack the required extensions.
6//!
7//! # Sub-modules
8//!
9//! - [`aa_coverage`]   — per-pixel AA coverage counts (`aa_coverage_span`)
10//! - [`blend`]         — solid-colour fill (`blend_solid_rgb8`, `blend_solid_gray8`)
11//! - [`composite`]     — AA per-pixel blend (`composite_aa_rgb8_opaque`)
12//! - [`glyph_unpack`]  — 1-bit-per-pixel mono glyph expansion (`unpack_mono_row`)
13
14// SIMD functions are inherently unsafe; unsafe_code is required throughout this module tree.
15#![expect(
16    unsafe_code,
17    reason = "SIMD intrinsics require unsafe throughout this module tree"
18)]
19
20pub mod aa_coverage;
21pub mod blend;
22pub mod composite;
23pub mod glyph_unpack;
24
25pub use aa_coverage::aa_coverage_span;
26pub use blend::{blend_solid_gray8, blend_solid_rgb8};
27pub use composite::composite_aa_rgb8_opaque;
28pub use glyph_unpack::unpack_mono_row;