-
released this
2026-10-24 13:12:09 +02:00 | 0 commits to main since this releaseorthographicOffCenter*take (left, right, bottom, top, near, far)
(breaking, silently): the order of DirectXMath and GLM. They took top before
bottom, inherited from zmath. All six parameters aref32, so a call in the
old order still compiles -- and flips the projection vertically. Swap the
third and fourth arguments of every call.- NaN propagates through
min,max,clamp,saturate(breaking): they
returned the other operand, soclamp(NaN, 0, 1)was 0 and a NaN colour came
out ofrgbToHsl/rgbToSrgbas a plausible one. Now NaN in gives NaN, and
the colour functions follow. The old behaviour is there by name:minNum,
maxNum,clampNum,saturateNum(IEEE 754 minimumNumber;@min/@max,
one instruction on arm64). The*Fastforms are documented as NaN result
unspecified, for finite input only. asinandacosare NaN outside [-1, 1] (breaking): they clamped, so
asin(1.1)andasin(100000)were pi/2. That is DirectXMath's SIMD
behaviour; Sony's Vector Math, NumPy and IEEE give NaN, as Lin now does. For
input that can overshoot by rounding, clamp first:acos(clamp(d, -1, 1)).mul(v, m)follows the FMA mode: vector times matrix was a plain
multiply-and-add in every mode. It now uses the same twomulAddchains as
mul(m0, m1), somul(v, m)is bit for bit the matching row of a matrix
product (in strict mode too, where the summation order changed). A test pins
what each mode does: one rounding or two.lerpandlerpVfollow the FMA mode: one subtract and onemulAdd
(they were a plain multiply and add in every mode). Their comment now says
what they guarantee: exact at t = 0 and for equal ends, exact at t = 1 only
up to rounding.- Stricter tests: trig tolerances from the measured errors (
acoswas
checked to 0.1, now 1e-6), tests forlerp,adjustContrast,norIntand
every matrix load/store layout, and the FMA modes' rounding pinned. - CI on the urverk forge:
.forgejo/workflows/test.ymlrunsscripts/gate
on every push, on thezig-arm64runner with Zig 0.17.0. zmath's GitHub
workflow (ubuntu/windows/macos runners, which the forge does not have) is
gone; it never ran.
Downloads
-
Source code (ZIP)
0 downloads
-
Source code (TAR.GZ)
0 downloads