Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
570dee1
Basically replace skin edge support by basic bridging
wawanbreton Nov 28, 2025
52f6fe7
Basically working bridging skin support
wawanbreton Dec 3, 2025
ea7b3c1
Apply clang-format
wawanbreton Dec 3, 2025
8f3c7b3
Fix some non-working skin support cases
wawanbreton Dec 3, 2025
895978e
Fix last cases of unexpected skin support
wawanbreton Dec 4, 2025
f599050
Optimized skin support calculation
wawanbreton Dec 8, 2025
be69c8a
Clean and document code
wawanbreton Dec 9, 2025
4948ff4
Basically working new skin support calculation
wawanbreton Dec 10, 2025
de05a89
Fix edge case and remove first version
wawanbreton Dec 10, 2025
1414a37
Simplify output polygon
wawanbreton Dec 10, 2025
bea0980
Optimize skin support calculation
wawanbreton Dec 11, 2025
a17dbfa
Remove bridging over infill
wawanbreton Dec 11, 2025
a6445ea
Fix skin support with multiple meshes
wawanbreton Dec 11, 2025
c6bb31a
Apply clang-format
wawanbreton Dec 11, 2025
aac4365
Remove extra infill lines data
wawanbreton Dec 11, 2025
e181857
Fix skin support when whole infill area is bridging
wawanbreton Dec 11, 2025
6727810
Finalize code cleaning and documentation
wawanbreton Dec 11, 2025
e73ff2b
Simplify dead code
wawanbreton Dec 11, 2025
a3faf58
Add unit test
wawanbreton Dec 11, 2025
b557589
Fix and disable unit tests
wawanbreton Dec 11, 2025
17f4221
Apply code suggestions
wawanbreton Dec 16, 2025
baf8a1c
Move structures to their own files and convert to classes
wawanbreton Dec 17, 2025
57cd44e
Merge remote-tracking branch 'origin/CURA-12833_improve-bridge-lines-…
wawanbreton Dec 17, 2025
b072037
Merge branch 'main' into CURA-12361_add-skin-support
HellAholic Dec 17, 2025
97b1ed0
Remove constexpr constructors
wawanbreton Dec 18, 2025
dffbbf0
Fix incorrect forward-declaration
wawanbreton Dec 18, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,6 @@ endif ()

set(engine_SRCS # Except main.cpp.
src/Application.cpp
src/bridge.cpp
src/ConicalOverhang.cpp
src/ExtruderPlan.cpp
src/ExtruderTrain.cpp
Expand Down Expand Up @@ -99,6 +98,12 @@ set(engine_SRCS # Except main.cpp.
src/BeadingStrategy/WideningBeadingStrategy.cpp
src/BeadingStrategy/OuterWallInsetBeadingStrategy.cpp

src/bridge/bridge.cpp
src/bridge/ExpansionRange.cpp
src/bridge/SegmentOverlappingData.cpp
src/bridge/TransformedSegment.cpp
src/bridge/TransformedShape.cpp

src/communication/ArcusCommunication.cpp
src/communication/ArcusCommunicationPrivate.cpp
src/communication/CommandLine.cpp
Expand Down
139 changes: 139 additions & 0 deletions doc/bridging_skin_support.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion include/ExtruderPlan.h
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ class ExtruderPlan
FRIEND_TEST(ExtruderPlanPathsParameterizedTest, BackPressureCompensationFull);
FRIEND_TEST(ExtruderPlanPathsParameterizedTest, BackPressureCompensationHalf);
FRIEND_TEST(ExtruderPlanTest, BackPressureCompensationEmptyPlan);
friend class FffGcodeWriterTest_SurfaceGetsExtraInfillLinesUnderIt_Test;
friend class DISABLED_FffGcodeWriterTest_SurfaceGetsExtraInfillLinesUnderIt_Test;
#endif
public:
size_t extruder_nr_{ 0 }; //!< The extruder used for this paths in the current plan.
Expand Down
5 changes: 2 additions & 3 deletions include/FffGcodeWriter.h
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ struct MeshPathConfigs;
class FffGcodeWriter : public NoCopy
{
friend class FffProcessor; // Because FffProcessor exposes finalize (TODO)
friend class FffGcodeWriterTest_SurfaceGetsExtraInfillLinesUnderIt_Test;
friend class DISABLED_FffGcodeWriterTest_SurfaceGetsExtraInfillLinesUnderIt_Test;

private:
coord_t max_object_height; //!< The maximal height of all previously sliced meshgroups, used to avoid collision when moving to the next meshgroup to print.
Expand Down Expand Up @@ -749,9 +749,8 @@ class FffGcodeWriter : public NoCopy
* \param mesh the mesh containing the layer of interest
* \param part \param part The part for which to create gcode
* \param infill_line_width line width of the infill
* \return true if there needs to be a skin edge support wall in this layer, otherwise false
*/
static bool partitionInfillBySkinAbove(
static void partitionInfillBySkinAbove(
Shape& infill_below_skin,
Shape& infill_not_below_skin,
const LayerPlan& gcode_layer,
Expand Down
8 changes: 7 additions & 1 deletion include/LayerPlan.h
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ class LayerPlan : public NoCopy
friend class LayerPlanBuffer;
#ifdef BUILD_TESTS
friend class AddTravelTest;
friend class FffGcodeWriterTest_SurfaceGetsExtraInfillLinesUnderIt_Test;
friend class DISABLED_FffGcodeWriterTest_SurfaceGetsExtraInfillLinesUnderIt_Test;
friend class AntiOozeAmountsTest;
FRIEND_TEST(AntiOozeAmountsTest, ComputeAntiOozeAmounts);
#endif
Expand Down Expand Up @@ -167,6 +167,8 @@ class LayerPlan : public NoCopy

bool min_layer_time_used = false; //!< Wether or not the minimum layer time (cool_min_layer_time) was actually used in this layerplan.

std::map<const SliceMeshStorage*, MixedLinesSet> infill_lines_; //!< Infill lines generated for this layer

const std::vector<FanSpeedLayerTimeSettings> fan_speed_layer_time_settings_per_extruder_;

enum CombBoundary
Expand Down Expand Up @@ -417,6 +419,10 @@ class LayerPlan : public NoCopy
*/
void planPrime(double prime_blob_wipe_length = 10.0);

void setGeneratedInfillLines(const SliceMeshStorage* mesh, const MixedLinesSet& infill_lines);

const MixedLinesSet getGeneratedInfillLines(const SliceMeshStorage* mesh) const;

/*!
* Add an extrusion move to a certain point, optionally with a different flow than the one in the \p config.
*
Expand Down
19 changes: 14 additions & 5 deletions include/LayerPlanBuffer.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
#ifndef LAYER_PLAN_BUFFER_H
#define LAYER_PLAN_BUFFER_H

#include <condition_variable>
#include <list>
#include <vector>

Expand All @@ -17,6 +18,7 @@ namespace cura
class LayerPlan;
class ExtruderPlan;
class GCodeExport;
struct LayerIndex;

/*!
* Class for buffering multiple layer plans (\ref LayerPlan) / extruder plans within those layer plans, so that temperature commands can be inserted in earlier layer plans.
Expand Down Expand Up @@ -57,6 +59,9 @@ class LayerPlanBuffer
*/
std::list<LayerPlan*> buffer_;

std::mutex buffer_mutex_;
std::condition_variable buffer_condition_variable_;

public:
LayerPlanBuffer(GCodeExport& gcode)
: gcode_(gcode)
Expand All @@ -66,11 +71,6 @@ class LayerPlanBuffer

void setPreheatConfig();

/*!
* Push a new layer plan into the buffer
*/
void push(LayerPlan& layer_plan);

/*!
* Push a new layer onto the buffer and handle the buffer.
* Write a layer to gcode if it is popped out of the buffer.
Expand All @@ -85,6 +85,15 @@ class LayerPlanBuffer
*/
void flush();

/*!
* Gets the layer plan for the given layer, once it has been completed. It will wait for completion if necessary
* @param layer_nr The layer number to get the plan for
* @return The completed layer plan
* @warning Make sure you always ask for a layer plan below the one that is being processed. Since the layers processing is started bottom to top and the engine can be run
* mono-threaded, asking for a layer above could lead to a deadlock because the processing of this layer will never start.
*/
const LayerPlan* getCompletedLayerPlan(const LayerIndex& layer_nr) const;

private:
/*!
* Process all layers in the buffer
Expand Down
1 change: 0 additions & 1 deletion include/TreeModelVolumes.h
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@

namespace cura
{
constexpr coord_t EPSILON = 5;
constexpr coord_t FUDGE_LENGTH = 50;

class SliceDataStorage;
Expand Down
Loading
Loading