LibGfx: Add method to Matrix that determines if the matrix is invertible

This commit is contained in:
Luke Wilde 2023-02-27 18:01:41 +00:00 committed by Andreas Kling
parent fcd3b16d63
commit dec09333a3
Notes: sideshowbarker 2024-07-16 23:40:28 +09:00

View file

@ -223,6 +223,11 @@ public:
return result;
}
constexpr bool is_invertible() const
{
return determinant() != 0.0;
}
private:
T m_elements[N][N];
};