mirror of
https://git.mirrors.martin98.com/https://github.com/prusa3d/PrusaSlicer.git
synced 2025-08-14 03:15:51 +08:00
Fix compilation
This commit is contained in:
parent
f43bb9eb75
commit
fde6e2e61d
@ -54,7 +54,7 @@ PerimeterGenerator::process()
|
||||
for (Surfaces::const_iterator surface = this->slices->surfaces.begin();
|
||||
surface != this->slices->surfaces.end(); ++surface) {
|
||||
// detect how many perimeters must be generated for this island
|
||||
const size_t loop_number = this->config->perimeters + surface->extra_perimeters -1; // 0-indexed loops
|
||||
const int loop_number = this->config->perimeters + surface->extra_perimeters -1; // 0-indexed loops
|
||||
|
||||
Polygons gaps;
|
||||
|
||||
@ -66,7 +66,7 @@ PerimeterGenerator::process()
|
||||
ThickPolylines thin_walls;
|
||||
|
||||
// we loop one time more than needed in order to find gaps after the last perimeter was applied
|
||||
for (size_t i = 0; i <= loop_number+1; ++i) { // outer loop is 0
|
||||
for (int i = 0; i <= loop_number+1; ++i) { // outer loop is 0
|
||||
Polygons offsets;
|
||||
if (i == 0) {
|
||||
// the minimum thickness of a single loop is:
|
||||
@ -169,16 +169,16 @@ PerimeterGenerator::process()
|
||||
}
|
||||
|
||||
// nest loops: holes first
|
||||
for (size_t d = 0; d <= loop_number; ++d) {
|
||||
for (int d = 0; d <= loop_number; ++d) {
|
||||
PerimeterGeneratorLoops &holes_d = holes[d];
|
||||
|
||||
// loop through all holes having depth == d
|
||||
for (size_t i = 0; i < holes_d.size(); ++i) {
|
||||
for (int i = 0; i < (int)holes_d.size(); ++i) {
|
||||
const PerimeterGeneratorLoop &loop = holes_d[i];
|
||||
|
||||
// find the hole loop that contains this one, if any
|
||||
for (size_t t = d+1; t <= loop_number; ++t) {
|
||||
for (size_t j = 0; j < holes[t].size(); ++j) {
|
||||
for (int t = d+1; t <= loop_number; ++t) {
|
||||
for (int j = 0; j < (int)holes[t].size(); ++j) {
|
||||
PerimeterGeneratorLoop &candidate_parent = holes[t][j];
|
||||
if (candidate_parent.polygon.contains(loop.polygon.first_point())) {
|
||||
candidate_parent.children.push_back(loop);
|
||||
@ -190,8 +190,8 @@ PerimeterGenerator::process()
|
||||
}
|
||||
|
||||
// if no hole contains this hole, find the contour loop that contains it
|
||||
for (size_t t = loop_number; t --> 0;) {
|
||||
for (size_t j = 0; j < contours[t].size(); ++j) {
|
||||
for (int t = loop_number; t >= 0; --t) {
|
||||
for (int j = 0; j < (int)contours[t].size(); ++j) {
|
||||
PerimeterGeneratorLoop &candidate_parent = contours[t][j];
|
||||
if (candidate_parent.polygon.contains(loop.polygon.first_point())) {
|
||||
candidate_parent.children.push_back(loop);
|
||||
@ -206,16 +206,16 @@ PerimeterGenerator::process()
|
||||
}
|
||||
|
||||
// nest contour loops
|
||||
for (size_t d = loop_number; d --> 0;) {
|
||||
for (int d = loop_number; d >= 1; --d) {
|
||||
PerimeterGeneratorLoops &contours_d = contours[d];
|
||||
|
||||
// loop through all contours having depth == d
|
||||
for (size_t i = 0; i < contours_d.size(); ++i) {
|
||||
for (int i = 0; i < (int)contours_d.size(); ++i) {
|
||||
const PerimeterGeneratorLoop &loop = contours_d[i];
|
||||
|
||||
// find the contour loop that contains it
|
||||
for (size_t t = d-1; t --> 0;) {
|
||||
for (size_t j = 0; j < contours[t].size(); ++j) {
|
||||
for (int t = d-1; t >= 0; --t) {
|
||||
for (int j = 0; j < contours[t].size(); ++j) {
|
||||
PerimeterGeneratorLoop &candidate_parent = contours[t][j];
|
||||
if (candidate_parent.polygon.contains(loop.polygon.first_point())) {
|
||||
candidate_parent.children.push_back(loop);
|
||||
@ -456,7 +456,7 @@ PerimeterGenerator::_variable_width(const ThickPolylines &polylines, ExtrusionRo
|
||||
ExtrusionPath path(role);
|
||||
ThickLines lines = p->thicklines();
|
||||
|
||||
for (size_t i = 0; i < lines.size(); ++i) {
|
||||
for (int i = 0; i < (int)lines.size(); ++i) {
|
||||
const ThickLine& line = lines[i];
|
||||
|
||||
const coordf_t line_len = line.length();
|
||||
|
Loading…
x
Reference in New Issue
Block a user