diff options
| author | Tim Redfern <tim@herge.(none)> | 2013-07-30 13:52:22 +0100 |
|---|---|---|
| committer | Tim Redfern <tim@herge.(none)> | 2013-07-30 13:52:22 +0100 |
| commit | c2237c2116ca551c0755821beadae3fac54547e7 (patch) | |
| tree | b032707e22b6bf01b9442cb6a5cc0108096514ae /rotord/src/cvimage.cpp | |
| parent | f4170d6bfb763ad0af4002277a37dcd1692534d5 (diff) | |
perfecting draw node
Diffstat (limited to 'rotord/src/cvimage.cpp')
| -rw-r--r-- | rotord/src/cvimage.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/rotord/src/cvimage.cpp b/rotord/src/cvimage.cpp index c18c585..a03d81c 100644 --- a/rotord/src/cvimage.cpp +++ b/rotord/src/cvimage.cpp @@ -3,6 +3,13 @@ using namespace std; namespace Rotor { + //space out to 32 bit RGB padding for cairo + void Image::convert24(){ + cv::cvtColor(rgb,rgb, CV_RGBA2RGB); + } + void Image::convert32(){ + cv::cvtColor(rgb,rgb, CV_RGB2RGBA); + } Image & Image::operator+=(const Image &other) { if (other.w!=w||other.h!=h) { cerr<<"Rotor: cannot add images with different sizes! (wanted "<<w<<"x"<<h<<", got "<<other.w<<"x"<<other.h<<")"<<endl; |
