Core: Make Color constexpr
This commit is contained in:
@@ -35,9 +35,9 @@ namespace Nz
|
||||
|
||||
struct Material
|
||||
{
|
||||
Color ambient = Color::White;
|
||||
Color diffuse = Color::White;
|
||||
Color specular = Color::White;
|
||||
Color ambient = Color::White();
|
||||
Color diffuse = Color::White();
|
||||
Color specular = Color::White();
|
||||
std::string alphaMap;
|
||||
std::string ambientMap;
|
||||
std::string bumpMap;
|
||||
|
||||
@@ -60,9 +60,9 @@ namespace Nz
|
||||
inline SimpleTextDrawer& operator=(const SimpleTextDrawer& drawer);
|
||||
inline SimpleTextDrawer& operator=(SimpleTextDrawer&& drawer) noexcept;
|
||||
|
||||
static inline SimpleTextDrawer Draw(const std::string& str, unsigned int characterSize, TextStyleFlags style = TextStyle_Regular, const Color& color = Color::White);
|
||||
static inline SimpleTextDrawer Draw(const std::string& str, unsigned int characterSize, TextStyleFlags style = TextStyle_Regular, const Color& color = Color::White());
|
||||
static inline SimpleTextDrawer Draw(const std::string& str, unsigned int characterSize, TextStyleFlags style, const Color& color, float outlineThickness, const Color& outlineColor);
|
||||
static inline SimpleTextDrawer Draw(const std::shared_ptr<Font>& font, const std::string& str, unsigned int characterSize, TextStyleFlags style = TextStyle_Regular, const Color& color = Color::White);
|
||||
static inline SimpleTextDrawer Draw(const std::shared_ptr<Font>& font, const std::string& str, unsigned int characterSize, TextStyleFlags style = TextStyle_Regular, const Color& color = Color::White());
|
||||
static inline SimpleTextDrawer Draw(const std::shared_ptr<Font>& font, const std::string& str, unsigned int characterSize, TextStyleFlags style, const Color& color, float outlineThickness, const Color& outlineColor);
|
||||
|
||||
private:
|
||||
|
||||
@@ -8,8 +8,8 @@
|
||||
namespace Nz
|
||||
{
|
||||
inline SimpleTextDrawer::SimpleTextDrawer() :
|
||||
m_color(Color::White),
|
||||
m_outlineColor(Color::Black),
|
||||
m_color(Color::White()),
|
||||
m_outlineColor(Color::Black()),
|
||||
m_style(TextStyle_Regular),
|
||||
m_colorUpdated(true),
|
||||
m_glyphUpdated(true),
|
||||
|
||||
Reference in New Issue
Block a user