Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

The problem is internal realocation of vector data in

detector->detect(img, features);

which does not retain the correct alignment of data (for me it was 32 -bit). I solved the problem (for OpenCV 2.4.13 ) by reservation of vector size to prevent realocation. For example:

vector<KeyPoint> features;
features.reserve(10000);
detector->detect(img, features);

The problem is internal realocation of vector data in

detector->detect(img, features);

which does not retain the correct alignment of data (for me it was 32 -bit). -bit), so Visual dealoc cast assertion when deleting such vector. I solved the problem (for OpenCV 2.4.13 ) by reservation of vector size to prevent realocation. For example:

vector<KeyPoint> features;
features.reserve(10000);
detector->detect(img, features);