VecKeyPoint.generate constructor
Implementation
factory VecKeyPoint.generate(int length, KeyPoint Function(int i) generator, {bool dispose = true}) {
final pp = calloc<cvg.VecKeyPoint>()..ref.length = length;
pp.ref.ptr = calloc<cvg.KeyPoint>(length);
for (var i = 0; i < length; i++) {
final v = generator(i);
pp.ref.ptr[i] = v.ref;
if (dispose) v.dispose();
}
return VecKeyPoint.fromPointer(pp);
}