Skip to content

Commit

Permalink
Return correct result in canInterlock
Browse files Browse the repository at this point in the history
The result was inversed

CURA-10355
  • Loading branch information
casperlamboo committed Mar 3, 2023
1 parent 0c7684f commit d866140
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/InterlockingGenerator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ void InterlockingGenerator::generateInterlockingStructure(std::vector<Slicer*>&
Slicer& mesh_b = *volumes[mesh_b_idx];
size_t extruder_nr_b = mesh_b.mesh->settings.get<ExtruderTrain&>("wall_0_extruder_nr").extruder_nr;

if (mesh_a.mesh->canInterlock() && mesh_b.mesh->canInterlock())
if (! mesh_a.mesh->canInterlock() || ! mesh_b.mesh->canInterlock())
{
continue;
}
Expand Down
2 changes: 1 addition & 1 deletion src/mesh.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ bool Mesh::isPrinted() const

bool Mesh::canInterlock() const
{
return settings.get<bool>("infill_mesh") || settings.get<bool>("anti_overhang_mesh");
return ! settings.get<bool>("infill_mesh") && ! settings.get<bool>("anti_overhang_mesh");
}

int Mesh::findIndexOfVertex(const Point3& v)
Expand Down

0 comments on commit d866140

Please sign in to comment.