Add cloth painting tools to Editor

This commit is contained in:
Wojtek Figat
2023-07-13 23:30:37 +02:00
parent 3b90e75307
commit 24c03c0e4b
15 changed files with 873 additions and 43 deletions

View File

@@ -312,7 +312,7 @@ void Float3::FindBestAxisVectors(Float3& firstAxis, Float3& secondAxis) const
template<>
float Float3::TriangleArea(const Float3& v0, const Float3& v1, const Float3& v2)
{
return (v2 - v0 ^ v1 - v0).Length() * 0.5f;
return ((v2 - v0) ^ (v1 - v0)).Length() * 0.5f;
}
template<>
@@ -626,7 +626,7 @@ void Double3::FindBestAxisVectors(Double3& firstAxis, Double3& secondAxis) const
template<>
double Double3::TriangleArea(const Double3& v0, const Double3& v1, const Double3& v2)
{
return (v2 - v0 ^ v1 - v0).Length() * 0.5;
return ((v2 - v0) ^ (v1 - v0)).Length() * 0.5;
}
template<>