minor changes: removed trailing spaces in some files

This commit is contained in:
Vladimir Dudnik 2011-04-18 19:34:51 +00:00
parent dd45fe13d1
commit 8e7768379f
4 changed files with 92 additions and 93 deletions

View File

@ -567,6 +567,7 @@ struct SURFInvoker
DW[i*PATCH_SZ+j] = G_desc.at<float>(i,0) * G_desc.at<float>(j,0); DW[i*PATCH_SZ+j] = G_desc.at<float>(i,0) * G_desc.at<float>(j,0);
} }
} }
void operator()(const BlockedRange& range) const void operator()(const BlockedRange& range) const
{ {
/* X and Y gradient wavelet data */ /* X and Y gradient wavelet data */

View File

@ -10,7 +10,8 @@
#define min(a,b) (((a) < (b)) ? (a) : (b)) #define min(a,b) (((a) < (b)) ? (a) : (b))
#endif #endif
static inline int sign(float r){ static inline int sign(float r)
{
if(r > 0.0001f) return 1; if(r > 0.0001f) return 1;
if(r < -0.0001f) return -1; if(r < -0.0001f) return -1;
return 0; return 0;

View File

@ -334,10 +334,10 @@ void HOGDescriptor::computeGradient(const Mat& img, Mat& grad, Mat& qangle,
ippsCartToPolar_32f((const Ipp32f*)Dx.data, (const Ipp32f*)Dy.data, (Ipp32f*)Mag.data, pAngles, width); ippsCartToPolar_32f((const Ipp32f*)Dx.data, (const Ipp32f*)Dy.data, (Ipp32f*)Mag.data, pAngles, width);
for( x = 0; x < width; x++ ) for( x = 0; x < width; x++ )
{ {
if(pAngles[x] < 0.f) pAngles[x]+=(Ipp32f)(CV_PI*2.); if(pAngles[x] < 0.f)
pAngles[x] += (Ipp32f)(CV_PI*2.);
} }
ippsNormalize_32f(pAngles, pAngles, width, 0.5f/angleScale, 1.f/angleScale); ippsNormalize_32f(pAngles, pAngles, width, 0.5f/angleScale, 1.f/angleScale);
ippsFloor_32f(pAngles,(Ipp32f*)hidxs.data,width); ippsFloor_32f(pAngles,(Ipp32f*)hidxs.data,width);
ippsSub_32f_I((Ipp32f*)hidxs.data,pAngles,width); ippsSub_32f_I((Ipp32f*)hidxs.data,pAngles,width);

View File

@ -4,7 +4,8 @@
#include <assert.h> #include <assert.h>
#include <math.h> #include <math.h>
IplImage * resize_opencv (IplImage * img, float scale){ IplImage* resize_opencv(IplImage* img, float scale)
{
IplImage* imgTmp; IplImage* imgTmp;
int W, H, tW, tH; int W, H, tW, tH;
@ -16,11 +17,7 @@ IplImage * resize_opencv (IplImage * img, float scale){
tH = (int)(((float)H) * scale + 0.5); tH = (int)(((float)H) * scale + 0.5);
imgTmp = cvCreateImage(cvSize(tW , tH), img->depth, img->nChannels); imgTmp = cvCreateImage(cvSize(tW , tH), img->depth, img->nChannels);
cvResize( cvResize(img, imgTmp, CV_INTER_AREA);
img,
imgTmp,
CV_INTER_AREA
);
return imgTmp; return imgTmp;
} }