[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[libcvd-members] libcvd/cvd vision.h
From: |
Gerhard Reitmayr |
Subject: |
[libcvd-members] libcvd/cvd vision.h |
Date: |
Mon, 18 Feb 2008 17:27:31 +0000 |
CVSROOT: /cvsroot/libcvd
Module name: libcvd
Changes by: Gerhard Reitmayr <gerhard> 08/02/18 17:27:31
Modified files:
cvd : vision.h
Log message:
added default value for untouched pixels in output image
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/libcvd/cvd/vision.h?cvsroot=libcvd&r1=1.26&r2=1.27
Patches:
Index: vision.h
===================================================================
RCS file: /cvsroot/libcvd/libcvd/cvd/vision.h,v
retrieving revision 1.26
retrieving revision 1.27
diff -u -b -r1.26 -r1.27
--- vision.h 28 Sep 2007 13:27:04 -0000 1.26
+++ vision.h 18 Feb 2008 17:27:31 -0000 1.27
@@ -389,7 +389,7 @@
* @Note: this will collide with transform in the std namespace
*/
template <class T>
-int transform(const BasicImage<T>& in, BasicImage<T>& out, const
TooN::Matrix<2>& M, const TooN::Vector<2>& inOrig, const TooN::Vector<2>&
outOrig)
+int transform(const BasicImage<T>& in, BasicImage<T>& out, const
TooN::Matrix<2>& M, const TooN::Vector<2>& inOrig, const TooN::Vector<2>&
outOrig, const T defaultValue = T())
{
const int w = out.size().x, h = out.size().y, iw = in.size().x, ih =
in.size().y;
const TooN::Vector<2> across = M.T()[0];
@@ -451,7 +451,7 @@
if (0 <= p[0] && 0 <= p[1] && p[0] < x_bound && p[1] < y_bound)
sample(in,p[0],p[1],out[i][j]);
else {
- zeroPixel(out[i][j]);
+ out[i][j] = defaultValue;
++count;
}
}
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [libcvd-members] libcvd/cvd vision.h,
Gerhard Reitmayr <=