mirror of
https://github.com/minetest/irrlicht.git
synced 2024-11-18 05:33:52 +01:00
Avoid ambigious conversions when compiling with c++20
Yay, more ugly casts needed. git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6427 dfc29bdd-3216-0410-991c-e03cc46cb475
This commit is contained in:
parent
98df6eae77
commit
a7f9afd289
@ -150,21 +150,21 @@ struct S3DVertex2TCoords : public S3DVertex
|
||||
//! Equality operator
|
||||
bool operator==(const S3DVertex2TCoords& other) const
|
||||
{
|
||||
return ((static_cast<S3DVertex>(*this)==other) &&
|
||||
return ((static_cast<S3DVertex>(*this)==static_cast<const S3DVertex&>(other)) &&
|
||||
(TCoords2 == other.TCoords2));
|
||||
}
|
||||
|
||||
//! Inequality operator
|
||||
bool operator!=(const S3DVertex2TCoords& other) const
|
||||
{
|
||||
return ((static_cast<S3DVertex>(*this)!=other) ||
|
||||
return ((static_cast<S3DVertex>(*this)!=static_cast<const S3DVertex&>(other)) ||
|
||||
(TCoords2 != other.TCoords2));
|
||||
}
|
||||
|
||||
bool operator<(const S3DVertex2TCoords& other) const
|
||||
{
|
||||
return ((static_cast<S3DVertex>(*this) < other) ||
|
||||
((static_cast<S3DVertex>(*this) == other) && (TCoords2 < other.TCoords2)));
|
||||
((static_cast<S3DVertex>(*this) == static_cast<const S3DVertex&>(other)) && (TCoords2 < other.TCoords2)));
|
||||
}
|
||||
|
||||
static E_VERTEX_TYPE getType()
|
||||
@ -225,14 +225,14 @@ struct S3DVertexTangents : public S3DVertex
|
||||
|
||||
bool operator==(const S3DVertexTangents& other) const
|
||||
{
|
||||
return ((static_cast<S3DVertex>(*this)==other) &&
|
||||
return ((static_cast<S3DVertex>(*this)==static_cast<const S3DVertex&>(other)) &&
|
||||
(Tangent == other.Tangent) &&
|
||||
(Binormal == other.Binormal));
|
||||
}
|
||||
|
||||
bool operator!=(const S3DVertexTangents& other) const
|
||||
{
|
||||
return ((static_cast<S3DVertex>(*this)!=other) ||
|
||||
return ((static_cast<S3DVertex>(*this)!=static_cast<const S3DVertex&>(other)) ||
|
||||
(Tangent != other.Tangent) ||
|
||||
(Binormal != other.Binormal));
|
||||
}
|
||||
@ -240,8 +240,8 @@ struct S3DVertexTangents : public S3DVertex
|
||||
bool operator<(const S3DVertexTangents& other) const
|
||||
{
|
||||
return ((static_cast<S3DVertex>(*this) < other) ||
|
||||
((static_cast<S3DVertex>(*this) == other) && (Tangent < other.Tangent)) ||
|
||||
((static_cast<S3DVertex>(*this) == other) && (Tangent == other.Tangent) && (Binormal < other.Binormal)));
|
||||
((static_cast<S3DVertex>(*this) == static_cast<const S3DVertex&>(other)) && (Tangent < other.Tangent)) ||
|
||||
((static_cast<S3DVertex>(*this) == static_cast<const S3DVertex&>(other)) && (Tangent == other.Tangent) && (Binormal < other.Binormal)));
|
||||
}
|
||||
|
||||
static E_VERTEX_TYPE getType()
|
||||
|
Loading…
Reference in New Issue
Block a user