1 | initial version |
so, there are several ORB descriptors in your vector, each of them has 32 uint32_t items, and descriptors.size() / 32
is the correct count ?
2 | No.2 Revision |
so, since there are will be several ORB descriptors in your vector, and each of them has 32 4 uint32_t items, and descriptors.size() /
324is should be the correct count ?count.
you could try:
std::vector<uint32_t> descriptors = ....
assert(descriptors.size()%4==0); // must be multiple of 4!
int count = descriptors.size() / 4;
Mat ocv_desc(count, 32, CV_8U, (uchar*)descriptors.data());
3 | No.3 Revision |
so, since there will be several ORB descriptors in your vector, and each of them has 4 8 uint32_t items, descriptors.size() /
should be the correct count.48
you could try:
std::vector<uint32_t> descriptors = ....
assert(descriptors.size()%4==0); assert(descriptors.size()%8==0); // must be multiple of 4!
8!
int count = descriptors.size() / 4;
8;
Mat ocv_desc(count, 32, CV_8U, (uchar*)descriptors.data());