diff --git a/HomographySharp/Double/DoubleHomographyMatrix.cs b/HomographySharp/Double/DoubleHomographyMatrix.cs
index ce0cd14..cf73aa1 100644
--- a/HomographySharp/Double/DoubleHomographyMatrix.cs
+++ b/HomographySharp/Double/DoubleHomographyMatrix.cs
@@ -26,6 +26,9 @@ internal DoubleHomographyMatrix(double[] elements)
///
public override ReadOnlySpan ElementsAsSpan() => _elements;
+ ///
+ public override ReadOnlyMemory ElementsAsMemory() => _elements;
+
public override int RowCount => 3;
public override int ColumnCount => 3;
diff --git a/HomographySharp/HomographyMatrix.cs b/HomographySharp/HomographyMatrix.cs
index c309f08..b0238ea 100644
--- a/HomographySharp/HomographyMatrix.cs
+++ b/HomographySharp/HomographyMatrix.cs
@@ -17,11 +17,6 @@ internal HomographyMatrix()
///
public abstract IReadOnlyList Elements { get; }
- ///
- /// Row-major order
- ///
- public abstract ReadOnlySpan ElementsAsSpan();
-
public abstract T this[int row, int column] { get; }
public abstract int RowCount { get; }
@@ -32,6 +27,16 @@ internal HomographyMatrix()
public abstract Matrix ToMathNetMatrix();
+ ///
+ /// Row-major order
+ ///
+ public abstract ReadOnlySpan ElementsAsSpan();
+
+ ///
+ /// Row-major order
+ ///
+ public abstract ReadOnlyMemory ElementsAsMemory();
+
public abstract string ToString(IFormatProvider? provider);
public abstract string ToString(string? format);
diff --git a/HomographySharp/Single/SingleHomographyMatrix.cs b/HomographySharp/Single/SingleHomographyMatrix.cs
index a7748cf..7bd8b08 100644
--- a/HomographySharp/Single/SingleHomographyMatrix.cs
+++ b/HomographySharp/Single/SingleHomographyMatrix.cs
@@ -26,6 +26,9 @@ internal SingleHomographyMatrix(float[] elements)
///
public override ReadOnlySpan ElementsAsSpan() => _elements;
+ ///
+ public override ReadOnlyMemory ElementsAsMemory() => _elements;
+
public override int RowCount => 3;
public override int ColumnCount => 3;