compat.pixman
#includepixman 0.46.4 — low-level pixel manipulation, with per-architecture SIMD (x86_64 SSE2/SSSE3, aarch64 NEON)
#include <pixman.h>
mcpp add compat.pixman@0.46.4
Usage
From this repository's own test project — built and run by CI, not written for the website.
// compat.pixman — behavioral test.
//
// The interesting thing about this package is not that it links; it is that
// pixman dispatches to architecture-specific SIMD at runtime — SSE2 and SSSE3
// with per-file `-msse2` / `-mssse3` on x86_64, A64 NEON assembly on aarch64,
// and generic C fallback elsewhere.
//
// So the test exercises three real pixel operations that route through those
// paths (solid fill, alpha-blended OVER, and bilinear-scaled SRC — which is
// what reaches `pixman-ssse3.c` on x86_64 and `pixman-arma64-neon-asm-bilinear.S`
// on aarch64) plus region arithmetic.
//
// Every one of them is checked against an exact expected value, and the whole
// suite runs TWICE: once with pixman's default runtime dispatch, and once in a
// re-executed copy of this program with every SIMD implementation switched off
// through pixman's own `PIXMAN_DISABLE`. The second pass is the generic + fast-path C code —
// exactly what an architecture with no SIMD block in the descriptor (riscv64,
// i686, ...) runs — so it is covered on EVERY architecture, including the ones
// CI does not build. Two passes agreeing with the same exact values is also the
// differential check that the SIMD paths and the C paths compute the same thing.
//
// No display, no GPU, no threads.
// …
tests/examples/pixman/tests/pixman.cpp · project tests/examples/pixman
Build
- targets
pixman-1 (lib)- language
c++23- C standard
c11- import std
- no
- include dirs
*/pixman, mcpp_generated
Sources (32)
*/pixman/pixman.c*/pixman/pixman-access.c*/pixman/pixman-access-accessors.c*/pixman/pixman-arm.c*/pixman/pixman-bits-image.c*/pixman/pixman-combine32.c*/pixman/pixman-combine-float.c*/pixman/pixman-conical-gradient.c*/pixman/pixman-edge.c*/pixman/pixman-edge-accessors.c*/pixman/pixman-fast-path.c*/pixman/pixman-filter.c*/pixman/pixman-glyph.c*/pixman/pixman-general.c*/pixman/pixman-gradient-walker.c*/pixman/pixman-image.c*/pixman/pixman-implementation.c*/pixman/pixman-linear-gradient.c*/pixman/pixman-matrix.c*/pixman/pixman-mips.c*/pixman/pixman-noop.c*/pixman/pixman-ppc.c*/pixman/pixman-radial-gradient.c*/pixman/pixman-region16.c*/pixman/pixman-region32.c*/pixman/pixman-region64f.c*/pixman/pixman-riscv.c*/pixman/pixman-solid-fill.c*/pixman/pixman-timer.c*/pixman/pixman-trap.c*/pixman/pixman-utils.c*/pixman/pixman-x86.c
Generated files
mcpp_generated/pixman-config.hmcpp_generated/pixman-version.h