Fix a GCC 9 warning:
assimp/include/assimp/material.inl: In member function 'aiReturn aiMaterial::Get(const char*, unsigned int, unsigned int, aiColor3D&) const': assimp/include/assimp/material.inl:176:33: error: implicitly-declared 'aiColor3D& aiColor3D::operator=(const aiColor3D&)' is deprecated [-Werror=deprecated-copy] 176 | pOut = aiColor3D(c.r,c.g,c.b);pull/2528/head
parent
ff662a6104
commit
ab55fb27c3
|
@ -161,7 +161,14 @@ struct aiColor3D
|
||||||
explicit aiColor3D (ai_real _r) : r(_r), g(_r), b(_r) {}
|
explicit aiColor3D (ai_real _r) : r(_r), g(_r), b(_r) {}
|
||||||
aiColor3D (const aiColor3D& o) : r(o.r), g(o.g), b(o.b) {}
|
aiColor3D (const aiColor3D& o) : r(o.r), g(o.g), b(o.b) {}
|
||||||
|
|
||||||
/** Component-wise comparison */
|
aiColor3D &operator=(const aiColor3D &o) {
|
||||||
|
r = o.r;
|
||||||
|
g = o.g;
|
||||||
|
b = o.b;
|
||||||
|
return *this;
|
||||||
|
}
|
||||||
|
|
||||||
|
/** Component-wise comparison */
|
||||||
// TODO: add epsilon?
|
// TODO: add epsilon?
|
||||||
bool operator == (const aiColor3D& other) const
|
bool operator == (const aiColor3D& other) const
|
||||||
{return r == other.r && g == other.g && b == other.b;}
|
{return r == other.r && g == other.g && b == other.b;}
|
||||||
|
|
Loading…
Reference in New Issue