compat.pixman
#includepixman 0.46.4 — low-level pixel manipulation, with runtime-dispatched x86 SIMD
#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 on the CPU at runtime, and this index compiles the SSE2
// and SSSE3 implementations with per-file `-msse2` / `-mssse3` so that the
// compiler may emit those instructions THERE and nowhere else. If the flags
// had been package-wide, code running before pixman's own CPUID check could
// carry SSSE3 — an illegal instruction on an older machine, from a library
// whose entire design is to avoid exactly that.
//
// So the test does two things a "does it link" check would not:
//
// * asks pixman which implementation it CHOSE, through a real composite;
// * composites actual pixels and reads them back, because the SIMD paths
// are only reached with enough work to be worth dispatching to.
//
// No display, no GPU, no threads.
#ifdef __linux__
#include <pixman.h>
// …
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 (34)
*/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*/pixman/pixman-sse2.c*/pixman/pixman-ssse3.c
Generated files
mcpp_generated/pixman-version.hmcpp_generated/pixman-config.h