Skip to content

Releases: mrdav30/FixedMathSharp

FixedMathSharp v4.0.0

18 May 17:08

Choose a tag to compare

FixedMathSharp 4.0.0 is a major geometry, transform, packaging, and reliability release. This version expands the deterministic fixed-point API with frustum, plane, ray, and 4D vector support while hardening several core math paths.

Breaking Changes

  • Removed the public IBound abstraction and generic Intersects(IBound) dispatch. Use the new strongly typed Contains(...) and Intersects(...) overloads on BoundingBox, BoundingArea, BoundingSphere, BoundingFrustum, FixedPlane, and FixedRay.
  • Renamed the no-MemoryPack build/package path from ReleaseNoMemoryPack / FixedMathSharp.NoMemoryPack to ReleaseLean / FixedMathSharp.Lean.

Added

  • Added BoundingFrustum with matrix/plane construction, containment checks, intersection checks, corners, planes, and clamp support.
  • Added FixedPlane, FixedPlaneIntersectionType, and ContainmentType for richer deterministic spatial queries.
  • Added FixedRay with intersections against planes, boxes, areas, spheres, and frustums.
  • Added Vector4d with arithmetic, comparisons, normalization, distance/dot helpers, matrix transforms, fuzzy equality helpers, JSON support, and MemoryPack support.
  • Added expanded Fixed4x4 transform helpers, including translation, rotation, scale, look-at, world, orthographic, perspective, inversion, point transforms, and Vector4d transforms.
  • Added Lean package output for FixedMathSharp.FluentAssertions.Lean.

Improved

  • Hardened BoundingBox, BoundingArea, BoundingSphere, and frustum behavior with typed containment/intersection APIs.
  • Hardened quaternion normalization, rotation, Euler conversion, division, interpolation, and matrix conversion behavior.
  • Improved Fixed4x4 affine handling and transform/inversion coverage.
  • Improved release automation with centralized archive output and a NuGet publishing workflow for standard and Lean packages.
  • Reorganized source files by domain while preserving the public FixedMathSharp namespace.

Fixed

  • Fixed a Fixed64 multiplication saturation edge case where overflow during rounded 128-bit shifting could wrap before saturation.
  • Fixed release-configuration test discrepancies, including Lean/MemoryPack-disabled scenarios.
  • Removed unreachable/dead bounding-sphere merge code surfaced during coverage hardening.

Quality

  • Expanded tests across geometry, bounds, matrices, quaternions, vectors, assertions, serialization-related paths, and Lean builds.
  • Added complexity exception documentation for intentionally complex performance-sensitive methods.
  • Refreshed README and contributor-facing guidance for the current API and release workflow.

Full Changelog: 1bec7da...be39470

FixedMathSharp v3.0.1

18 Apr 03:39

Choose a tag to compare

Fixed

  • Fixed a Fixed64 initialization issue that could trigger circular static-constructor errors when operators were used during type initialization.
  • Updated internal max/min fallback paths to avoid relying on static members during early initialization.

Added

  • Added a NoMemoryPack build/package variant for consumers that want to use FixedMathSharp without the MemoryPack dependency.
  • Added a compile-time shim so the library can build cleanly when MemoryPack is disabled.

Changed

  • Updated build and packaging scripts to produce both standard and NoMemoryPack release outputs.
  • Migrated the solution to .slnx and refreshed CI/workflow configuration accordingly.
  • Improved public documentation and README guidance, including package selection and Unity/Burst recommendations.

FixedMathSharp v3.0.0

14 Apr 16:20

Choose a tag to compare

  • Breaking Changes
    • Removed float-based numeric/vector overloads to enforce deterministic usage across Vector2d and Vector3d.
    • Core precision API refactor:
      • Fixed64.Precision replaced with Fixed64.MinIncrement.
      • Default epsilon/tolerance semantics were redefined (FixedMath.DEFAULT_TOLERANCE_L / Fixed64.Epsilon), which can change fuzzy-comparison behavior.
  • Added
    • FixedMath.InvertedPI constant.
    • New Vector3d.SnapSmallComponentsToZero(...) helper for zeroing tiny components under a threshold.
  • Changed
    • Degree/radian conversion paths in trigonometry moved to fixed-point math paths for deterministic consistency.
    • Vector epsilon guards improved across vector/component comparison logic.
  • Fixed
    • Hardened Fixed64 scalar multiply/divide operator behavior, including improved 128-bit intermediate rounding/saturation handling.
    • Quaternion math corrections:
      • Euler conversion alignment (YXZ order consistency).
      • Rotation extraction stabilization (including matrix-based paths).
    • Additional Fixed64 operator corrections from #48.
  • Maintenance
    • Project/test setup cleanup and release metadata housekeeping commits.
  • Migration Notes
    • Replace uses of Fixed64.Precision with Fixed64.MinIncrement.
    • Remove/update any call sites relying on removed float overloads.
    • Re-validate tolerance-sensitive tests/simulations due to epsilon behavior changes.

FixedMathSharp v2.1.1

01 Apr 22:12

Choose a tag to compare

v2.1.1 is a hardening release focused on correctness, packaging reliability, and overall library quality.

This update adds a few small API improvements, including component-wise epsilon helpers for Vector2d and Vector3d, a convenience Fixed4x4.NormalizeRotationMatrix() extension, and a new companion package, FixedMathSharp.FluentAssertions, for reusable assertions in downstream test projects.

It also fixes several edge cases uncovered during the hardening pass: negative midpoint rounding in FixedMath.Round, clamped-dot handling in Vector3d.Slerp, FixedCurve nullability and small-array construction issues that triggered MemoryPack warnings, and incomplete hashing in Fixed4x4.GetHashCode. On the packaging side, .NET Standard 2.1 dependency handling was cleaned up and the temporary JSON shim was removed in favor of explicit System.Text.Json dependency handling.

Internally, BoundingArea.Intersects, BoundingBox.Intersects, and Vector3d.ClosestPointsOnTwoLines were refactored to reduce complexity without changing behavior, and an unreachable branch in FixedTrigonometry.Pow2 was removed. Along the way, test coverage was expanded substantially across the core math surface, and the repository now publishes coverage reports as part of the project’s documentation and release quality bar.

FixedMathSharp v2.1.0

07 Mar 14:55

Choose a tag to compare

This release focuses on serialization cleanup and compatibility rather than numeric behavior changes.

Refactor

  • Improved serialization support across core numerics and bounds types, including Fixed64, vectors, matrices, quaternions, ranges, curves, BoundingArea, BoundingBox, and BoundingSphere.
  • Added explicit System.Text.Json metadata so JSON round-trips no longer depend on IncludeFields or IgnoreReadOnlyProperties.
  • Added non-.NET 8 JSON attribute shims to keep serialization annotations working across older target frameworks.
  • Simplified BoundingBox serialization to a state-based payload using Min and Max, removing the old versioned serialization field.
  • Expanded JSON and MemoryPack round-trip test coverage for the affected types.
  • Added .editorconfig and normalized formatting across the touched files.

Migration Note

If you relied on BoundingBox’s old (min, max, version) constructor or serialized Version field, update to the new state-based contract.

FixedMathSharp v2.0.0

04 Mar 05:49
ecc188b

Choose a tag to compare

Breaking changes

  • Dropped .NET Framework 4.8 support.
  • Added/standardized support on netstandard2.1 (with net8 retained).
  • Serialization stack changed from MessagePack to MemoryPack.

Updated tooling/runtime settings

  • C# language version bumped to 11.0.
  • Test project modernized:
    • moved to net8
    • updated test SDK/packages (including xUnit v3-related packages and newer test tooling).

Internal/maintenance

  • Added basic AGENTS.md.
  • Minor hash code implementation cleanup in core numeric structs (no API expansion, but behavior may differ for hash-based scenarios).

What's Changed

Full Changelog: v1.3.4...2.0.0

FixedMathSharp v1.3.4

12 Feb 17:15
973b4b1

Choose a tag to compare

  • BugFix
    • refactored BoundingBox to use a canonical min/max representation internally
      • removes dual-state risk of tracking scope and size separately

FixedMathSharp v1.3.3

01 Oct 02:22
b3971a3

Choose a tag to compare

  • New Features
    • Added new DeterministicRandom struct.
      • Switched to using xoroshiro128++ with splitmix64 seeding to ensure no allocations, no time/GUID.
  • Notice
    • Marked ThreadLocalRandom obsolete
      • DeterministicRandom gives explicit, reproducible streams keyed to your world/feature, independent of threading.

FixedMathSharp v1.3.2

11 Jul 15:45

Choose a tag to compare

  • BugFix
    • Updated intersection logic to correctly detect intersections between flat (zero-thickness) BoundingAreas in any primary plane.
      • Previously, coplanar and edge-touching areas were not recognized as intersecting due to 3D AABB logic.
      • Now uses 2D overlap checks when both bounds are flat in the same axis.

Full Changelog: v1.3.1...v1.3.2

FixedMathSharp v1.3.1

20 Jun 17:47

Choose a tag to compare