mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-19 12:47:50 -06:00
FIX: fix the out range of array of seam algining
Signed-off-by: qing.zhang <qing.zhang@bambulab.com> Change-Id: I655e7a0a5cdac6c05ddd8a6c7f38e1f97a7d0f96
This commit is contained in:
parent
bae334a77e
commit
d42d6bec87
1 changed files with 2 additions and 2 deletions
|
@ -1236,8 +1236,8 @@ void SeamPlacer::align_seam_points(const PrintObject *po, const SeamPlacerImpl::
|
||||||
SeamCandidate adjust_point = seamcandiate[index];
|
SeamCandidate adjust_point = seamcandiate[index];
|
||||||
// BBS. pick projection point as seam point
|
// BBS. pick projection point as seam point
|
||||||
if (seam_string[index].second != adjust_point.perimeter.seam_index) {
|
if (seam_string[index].second != adjust_point.perimeter.seam_index) {
|
||||||
int prev_index = seam_string[index].second == adjust_point.perimeter.start_index ? adjust_point.perimeter.end_index : seam_string[index].second - 1;
|
int prev_index = seam_string[index].second == adjust_point.perimeter.start_index ? adjust_point.perimeter.end_index - 1 : seam_string[index].second - 1;
|
||||||
int next_index = seam_string[index].second == adjust_point.perimeter.end_index ? adjust_point.perimeter.start_index : seam_string[index].second + 1;
|
int next_index = seam_string[index].second == adjust_point.perimeter.end_index - 1 ? adjust_point.perimeter.start_index : seam_string[index].second + 1;
|
||||||
SeamCandidate prev_point = layers[seam_string[index].first].points[prev_index];
|
SeamCandidate prev_point = layers[seam_string[index].first].points[prev_index];
|
||||||
SeamCandidate next_point = layers[seam_string[index].first].points[next_index];
|
SeamCandidate next_point = layers[seam_string[index].first].points[next_index];
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue