Add scalar multiply for colour

This commit is contained in:
Danny Robson 2011-10-29 21:17:28 +11:00
parent d3baffc2e5
commit b774a6490d
2 changed files with 10 additions and 0 deletions

View File

@ -23,6 +23,15 @@
using namespace util; using namespace util;
colour&
colour::operator*= (double v) {
red *= v;
green *= v;
blue *= v;
alpha *= v;
return *this;
}
const json::node& const json::node&

View File

@ -27,6 +27,7 @@
namespace util { namespace util {
struct colour { struct colour {
colour& operator*= (double);
double red; double red;
double green; double green;