Clamp color arguments to [0, 1] in cases where we don’t support values outside of that range internally.

--HG--
branch : minor
This commit is contained in:
Alex Szpakowski
2017-03-09 21:15:56 -04:00
parent 1a9262dda9
commit a8e4db8e1e
5 changed files with 47 additions and 24 deletions
+2 -2
View File
@@ -72,7 +72,7 @@ public:
*
* @param color The color to use for the following sprites.
*/
void setColor(const Color &color);
void setColor(const Colorf &color);
/**
* Disable per-sprite colors for this SpriteBatch. The next call to
@@ -83,7 +83,7 @@ public:
/**
* Get the current color for this SpriteBatch.
**/
const Color &getColor(bool &active) const;
Colorf getColor(bool &active) const;
/**
* Get the number of sprites currently in this SpriteBatch.