Browse Source

IndexedTriangle's user data parameter should have a default value for the API to stay backwards compatible

Jorrit Rouwe 1 year ago
parent
commit
8feb90cf41
1 changed files with 1 additions and 1 deletions
  1. 1 1
      Jolt/Geometry/IndexedTriangle.h

+ 1 - 1
Jolt/Geometry/IndexedTriangle.h

@@ -75,7 +75,7 @@ public:
 	using IndexedTriangleNoMaterial::IndexedTriangleNoMaterial;
 
 	/// Constructor
-	constexpr		IndexedTriangle(uint32 inI1, uint32 inI2, uint32 inI3, uint32 inMaterialIndex, uint inUserData) : IndexedTriangleNoMaterial(inI1, inI2, inI3), mMaterialIndex(inMaterialIndex), mUserData(inUserData) { }
+	constexpr		IndexedTriangle(uint32 inI1, uint32 inI2, uint32 inI3, uint32 inMaterialIndex, uint inUserData = 0) : IndexedTriangleNoMaterial(inI1, inI2, inI3), mMaterialIndex(inMaterialIndex), mUserData(inUserData) { }
 
 	/// Check if two triangles are identical
 	bool			operator == (const IndexedTriangle &inRHS) const