mirror of
https://github.com/opencv/opencv.git
synced 2024-11-27 20:50:25 +08:00
[move sift.cpp] opencv: use cv::AutoBuffer<>::data()
original commit: fc69aa57bc
This commit is contained in:
parent
9badb0d903
commit
fd46684bf8
@ -306,7 +306,7 @@ static float calcOrientationHist( const Mat& img, Point pt, int radius,
|
||||
|
||||
float expf_scale = -1.f/(2.f * sigma * sigma);
|
||||
AutoBuffer<float> buf(len*4 + n+4);
|
||||
float *X = buf, *Y = X + len, *Mag = X, *Ori = Y + len, *W = Ori + len;
|
||||
float *X = buf.data(), *Y = X + len, *Mag = X, *Ori = Y + len, *W = Ori + len;
|
||||
float* temphist = W + len + 2;
|
||||
|
||||
for( i = 0; i < n; i++ )
|
||||
@ -719,7 +719,7 @@ static void calcSIFTDescriptor( const Mat& img, Point2f ptf, float ori, float sc
|
||||
int rows = img.rows, cols = img.cols;
|
||||
|
||||
AutoBuffer<float> buf(len*6 + histlen);
|
||||
float *X = buf, *Y = X + len, *Mag = Y, *Ori = Mag + len, *W = Ori + len;
|
||||
float *X = buf.data(), *Y = X + len, *Mag = Y, *Ori = Mag + len, *W = Ori + len;
|
||||
float *RBin = W + len, *CBin = RBin + len, *hist = CBin + len;
|
||||
|
||||
for( i = 0; i < d+2; i++ )
|
||||
|
Loading…
Reference in New Issue
Block a user