From 1d05d2380bb4f1fd265aef55744f432af38b08aa Mon Sep 17 00:00:00 2001 From: Comment Date: Sun, 8 Dec 2013 10:55:03 +0000 Subject: switched signals to double and random to uint16 --- rotord/src/cvimage.cpp | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) (limited to 'rotord/src/cvimage.cpp') diff --git a/rotord/src/cvimage.cpp b/rotord/src/cvimage.cpp index 7aae63e..21e4e2f 100644 --- a/rotord/src/cvimage.cpp +++ b/rotord/src/cvimage.cpp @@ -191,47 +191,47 @@ namespace Rotor { //scalar operations allocate a new image. //maybe this could not be the case if the data is owned by this image? //need to look into auto_ptr - Image & Image::operator*=(const float &amount) { + Image & Image::operator*=(const double &amount) { //cerr<<"amount: "<rgb=rgb*amount; return other; } - Image * Image::operator+(const float &amount) { - uint8_t amt=(uint8_t)(amount*255.0f); + Image * Image::operator+(const double &amount) { + uint8_t amt=(uint8_t)(amount*255.0); Image *other=new Image(w,h); other->rgb=rgb+amt; return other; } - Image * Image::operator-(const float &amount) { - uint8_t amt=(uint8_t)(amount*255.0f); + Image * Image::operator-(const double &amount) { + uint8_t amt=(uint8_t)(amount*255.0); Image *other=new Image(w,h); other->rgb=rgb-amt; return other; } - Image * Image::operator/(const float &amount) { + Image * Image::operator/(const double &amount) { Image *other=new Image(w,h); other->rgb=rgb/amount; return other; -- cgit v1.2.3