append return value in Color3f/4f::operator =

This commit is contained in:
2023-11-01 18:33:27 +08:00
parent ac8565e338
commit b5c66fe2cd
5 changed files with 18 additions and 12 deletions

View File

@@ -39,7 +39,7 @@ namespace hgl
b=lum;
}
//--------------------------------------------------------------------------------------------------
bool Color3f::operator == (const Color3f &v)
bool Color3f::operator == (const Color3f &v) const
{
if(r!=v.r)return(false);
if(g!=v.g)return(false);
@@ -48,7 +48,7 @@ namespace hgl
return(true);
}
//--------------------------------------------------------------------------------------------------
bool Color3f::operator != (const Color3f &v)
bool Color3f::operator != (const Color3f &v) const
{
if(r!=v.r)return(true);
if(g!=v.g)return(true);

View File

@@ -40,7 +40,7 @@ namespace hgl
b=lum;
}
//--------------------------------------------------------------------------------------------------
bool Color4f::operator == (const Color4f &v)
bool Color4f::operator == (const Color4f &v) const
{
if(r!=v.r)return(false);
if(g!=v.g)return(false);
@@ -50,7 +50,7 @@ namespace hgl
return(true);
}
//--------------------------------------------------------------------------------------------------
bool Color4f::operator != (const Color4f &v)
bool Color4f::operator != (const Color4f &v) const
{
if(r!=v.r)return(true);
if(g!=v.g)return(true);