|
|
@ -603,8 +603,8 @@ inline void elbp_(InputArray _src, OutputArray _dst, int radius, int neighbors) |
|
|
|
dst.setTo(0); |
|
|
|
dst.setTo(0); |
|
|
|
for(int n=0; n<neighbors; n++) { |
|
|
|
for(int n=0; n<neighbors; n++) { |
|
|
|
// sample points
|
|
|
|
// sample points
|
|
|
|
float x = static_cast<float>(-radius * sin(2.0*CV_PI*n/static_cast<float>(neighbors))); |
|
|
|
float x = static_cast<float>(radius * cos(2.0*CV_PI*n/static_cast<float>(neighbors))); |
|
|
|
float y = static_cast<float>(radius * cos(2.0*CV_PI*n/static_cast<float>(neighbors))); |
|
|
|
float y = static_cast<float>(-radius * sin(2.0*CV_PI*n/static_cast<float>(neighbors))); |
|
|
|
// relative indices
|
|
|
|
// relative indices
|
|
|
|
int fx = static_cast<int>(floor(x)); |
|
|
|
int fx = static_cast<int>(floor(x)); |
|
|
|
int fy = static_cast<int>(floor(y)); |
|
|
|
int fy = static_cast<int>(floor(y)); |
|
|
|