Skip to content

Aardvark 5.3 changelog

Martin edited this page Aug 6, 2024 · 4 revisions

Aardvark.Base 5.3 moves from .NET 6 (support ends on November 12, 2024) to .NET 8 and F# 8. We use this transition as an opportunity to release a new major version with some breaking changes that have been pending for some time. This document details the changes to help developers port their applications to the new version.

SixLabors.ImageSharp dependency

The built-in dependency on SixLabors.ImageSharp has been removed from Aardvark.Base.Tensors in favor of a separate package. If you want to continue using the ImageSharp loader simply reference the Aardvark.PixImage.ImageSharp package. You may also use another loader from the Aardvark.Data repository.

Currently, Aardvark.PixImage.ImageSharp only supports SixLabors.ImageSharp 2.x, which is no longer being actively developed. We plan to migrate to version 3.x (.NET Standard 2.1 only) in the future. Having a separate package allows us to do this without being forced to drop support for .NET Standard 2.0 for the whole Aardvark platform (at least it should be less of a hassle to support both).

PixImage related changes

Some changes to PixImage and related types may require your attention. IPix and related interfaces and types have been removed or renamed:

  • IPixImage is renamed to IPix
  • PixImageCube and PixCubeMap: Use PixCube instead.
  • PixMipMap2d: Use PixImageMipMap instead.

PixImageMipMap has been reworked and cleaned up:

  • Removed generic PixImageMipMap<T>
  • Removed MipMapOptions, static Create() method takes multiple optional parameters instead. The default interpolation method is now linear.

Both PixImage and PixVolume have been cleaned up and made more consistent:

  • Made Array and Data consistent with tensors where Array is untyped and Data is typed. As a consequence, the non-generic PixImage and PixVolume only define Array.
  • Deprecated PixImage.IntStride in favor of Stride and StrideL
  • Added PixVolume.BytesPerChannel
  • Added PixVolume.ToCanonicalDenseLayout
  • Added Add PixImage<T>.Transformed (abstract PixImage.Transformed is renamed to PixImage.TransformedPixImage)
  • Removed obsolete loading API

SRTP methods

Some SRTP member methods for FSharpMath functions have been renamed due to conflicts with methods introduced in .NET 7 (e.g. Double.Log2). If you are using FSharpMath with custom types you will have to rename the static methods:

  • Acosh -> Acoshb
  • Asinh -> Asinhb
  • Atanh -> Atanhb
  • Cbrt -> CubeRoot
  • Log2 -> LogBinary
  • CopySign -> CopySgn
  • Lerp -> LinearInterp
  • Exp2 -> PowerOfTwo

Other changes

  • Added Aardvark.Base.Fonts from the Aardvark.Rendering repository.
  • Optimized partial active patterns by using struct representation
  • Added F# tensor utilities and math functions using SRTP
  • Fixed return type of LengthSquared for integer-based vectors. Now returns integer instead of floating-point values.
  • Added missing readonly modifiers for structs
  • RenamedCIeLuvf to CieLuvf
  • Deprecated GenericValues.zero
  • Added IPixLoader.CanEncode and IPixLoader.CanDecode. These members indicate if a loader should be considered for saving and loading images respectively.

Removed obsolete APIs

Some obsolete APIs have been removed:

  • [Color] obsolete conversion functions
  • [Color] Parse() overload with IFormatProvider parameter
  • Async.AwaitTask (already in FSharp.Core)
  • Caching.cacheFunction
  • IDictionary.GetValueOrDefault
  • broken UnsafeCoerce utilities
  • CameraExtrinsics and CameraIntrinsics
  • float variants of Constant
  • IPol.SlerpShortest
  • Cell.Parse() with offset parameter
  • M44x.PerspectiveProjectionTransformLH
  • Trafo.PerspectiveProjectionOpenGl
  • Trafo.PerspectiveProjectionLH
  • Trafo.OrthoProjectionOpenGl
  • RangeSet and RangeSet64
  • RangeSet1*.insert and window
  • Time and TimeLink
  • ExecutableMemory
  • Dictionary.TryRemove and GetOrAdd
  • Seq.forany and Array.forany (use exists instead)
  • Strings module
  • ConversionHelpers lookup table utilities (use utilities from LookupTable module instead)
  • Assembler related types and functions (use Aardvark.Assembler instead)