scoreType_(scoreType), patchSize_(patchSize),\r
fastDetector_(DEFAULT_FAST_THRESHOLD)\r
{\r
+ CV_Assert(patchSize_ >= 2);\r
+\r
// fill the extractors and descriptors for the corresponding scales\r
float factor = 1.0f / scaleFactor_;\r
float n_desired_features_per_scale = nFeatures_ * (1.0f - factor) / (1.0f - std::pow(factor, nLevels_));\r
\r
// pre-compute the end of a row in a circular patch\r
int half_patch_size = patchSize_ / 2;\r
- vector<int> u_max(half_patch_size + 1);\r
+ vector<int> u_max(half_patch_size + 2);\r
for (int v = 0; v <= half_patch_size * std::sqrt(2.f) / 2 + 1; ++v)\r
u_max[v] = cvRound(std::sqrt(static_cast<float>(half_patch_size * half_patch_size - v * v)));\r
\r