|
@@ -1494,7 +1494,7 @@ void CTeaSort::calculate_stem_cut_position_opt(
|
|
|
|
|
|
//检查center_pt附近,是否有目标,如果有就用center_pt点作为切割点
|
|
|
|
|
|
- int nnr = 7;
|
|
|
+ int nnr = 3;
|
|
|
int cx, cy, knn, x, y;
|
|
|
cx = int(center_pt.x);
|
|
|
cy = int(center_pt.y);
|
|
@@ -1519,6 +1519,8 @@ void CTeaSort::calculate_stem_cut_position_opt(
|
|
|
///////////////////////////////////////////////////////////////////////////////////////////////////////
|
|
|
// 否则通过骨架化图,找到旁边的点(适用于茎弯曲的情况)
|
|
|
int min_x, min_y;
|
|
|
+ min_x = cx;
|
|
|
+ min_y = cy;
|
|
|
double min_loss = 1.0e6;
|
|
|
|
|
|
double ref_angle = grab_angle + CV_PI / 2.0;
|