Commit Graph

30296 Commits

Author SHA1 Message Date
Noisyfox
213161b7cd Merge branch 'main' into dev/ffmpeg-player 2026-08-27 08:44:57 +08:00
Kris Austin
142c63ab0e build: clear 143 -Woverloaded-virtual warnings in GUI widgets (#15377) 2026-08-26 19:14:30 -03:00
Noisyfox
dbcb196f4e Merge branch 'main' into dev/ffmpeg-player 2026-08-26 21:47:20 +08:00
SoftFever
5552ed6cf1 Keep mixed-color filaments intact when the extruder count changes (#15385)
* Keep mixed-color filaments intact when the extruder count changes

The extruder-count spinner resized the filament arrays in bulk at the tail,
which is where mixed-color slots live, so a new filament landed behind the
mix and the sidebar skipped a slot number. It now adds and removes one slot
at a time through the same calls the sidebar's +/- buttons use, so a new
slot opens ahead of the mixed tail and a removal renumbers object filament
ids, painted facets, custom g-code and mixed components rather than
clamping them away.

Drops the vector overload of set_num_filaments(), which this leaves without
callers.
2026-08-26 19:06:33 +08:00
Ian Bassi
9dc9b42475 Pass closure state to fuzzy skin (#15378)
Update perimeter traversal to pass each extrusion's closed/open state into `apply_fuzzy_skin`. This lets fuzzy skin logic distinguish contours from closed loops when processing perimeters.

Co-authored-by: Rodrigo Faselli <162915171+RF47@users.noreply.github.com>
2026-08-26 07:39:23 -03:00
Kris Austin
1e4b48c548 build: clear 227 warnings - dead private fields, malformed comments (#15376)
build: drop dead private fields, close malformed comments (227 warnings)

Clears 227 of the clang-cl warnings tracked in #15374, taking a full
Windows build from 1,491 to 1,264. Five of the six changes are in
headers, which are re-diagnosed in every translation unit that includes
them, so the count is large for a 14-line diff.

Tabbook.hpp: delete two private fields, unread since the 2022 import.
m_parent also shadowed wxWindowBase::m_parent.

GUI_Utils.hpp: the wxEVT_SYS_COLOUR_CHANGED lambda body is empty on
Windows, so its `this` capture is unused there. (void) this; leaves the
handler bound, which is what stops the event propagating.

DevFirmware.h: mark m_owner [[maybe_unused]]. The class is never
instantiated, and the file tracks BambuStudio, so this is the smallest
divergence.

Eight DeviceTab/ files, AMSItem.cpp and SelectMachine.cpp: block
comments malformed so that they read as a nested /*.

No behavior change. -Wcomment goes to zero, and only the three intended
categories move.
2026-08-26 07:38:52 -03:00
Valerii Bokhan
24967b543a Fix contour cleanup across coplanar triangles (#15366)
* Fix contour cleanup across coplanar triangles

Avoid generic collinear simplification after slicing. Skip only junctions created by shared edges between coplanar faces so contours stay stable without altering shallow geometry.

Fixes #15364

* Fix contour cleanup across coplanar triangles (code review fixes)

---------

Co-authored-by: Ian Bassi <ian.bassi@outlook.com>
2026-08-25 19:31:09 -03:00
Ian Bassi
ea4a4a60f1 Refresh dynamic filament list on mixed slot changes (#15375)
Call update_dynamic_filament_list() alongside update_mixed_filament_list() in two places: after editing a mixed filament slot and when the filament count doesn't change (e.g., adding a mixed/virtual slot). This ensures per-feature filament lists reflect the updated blended colour and type without requiring a full filament count change.
2026-08-25 16:18:45 -03:00
Ian Bassi
a5223279ac Fix uneven corner rounding in multiline infill (#15352)
* Skip straight-run splits in corner smoothing

Teach `CornerSmoother` to treat vertices that only continue a straight segment as part of the same leg instead of rounding them as corners. The smoother now keeps a three-point window so it can emit a corner only once both adjoining legs are known, which avoids unnecessary corner processing while preserving real turns such as hairpins.

* Add regression test for split-leg smoothing

Adds a FillCornerSmoothing regression test covering polylines with an extra collinear vertex in a straight run. The test ensures corner smoothing treats split and unsplit geometry identically, preventing inconsistent rounding radii in triangular/grid infill paths.
2026-08-25 12:46:34 -03:00
Kris Austin
265ae16160 chore: ignore CMakeUserPresets.json (#15354)
CMake reads CMakeUserPresets.json for developer-local presets, and its
documentation states the file should not be checked into version control:
https://cmake.org/cmake/help/latest/manual/cmake-presets.7.html#introduction

It is the preset equivalent of CMakeLists.txt.user, ignored on the line
above.
2026-08-25 12:13:45 -03:00
SoftFever
9e34dde632 Color mixing feature (#15347)
# Description

This PR ports the color mixing feature from BambuStudio.
The port is based on the previous work by @ianalexis in #15231.
This PR completes the port and fixes various bugs.

Several improvements were also made during the porting process.

WIP


# Screenshots/Recordings/Graphs

<!--
> Please attach relevant screenshots to showcase the UI changes.
> Please attach images that can help explain the changes.
-->

## Tests

<!--
> Please describe the tests that you have conducted to verify the
changes made in this PR.
-->

<!--
> A guide for users on how to download the artifacts from this PR.
-->

[How to Download Pull Requests Artifacts for
Testing](https://www.orcaslicer.com/wiki/how_to_download_pr_artifacts)
2026-08-25 22:10:49 +08:00
SoftFever
bfe5f7e63c fix text error 2026-08-25 21:35:43 +08:00
Kris Austin
56f9edc572 build: mark missing overrides and drop unused lambda captures (1,156 clang warnings) (#15334)
* chore: mark every declaration that overrides a base virtual

clang-cl reports 42 member functions across 28 files that override a
base virtual without being marked `override`, inside classes that
already mark their other overrides. That is every occurrence of
-Winconsistent-missing-override in the tree, so the category drops to
zero and -Werror=inconsistent-missing-override becomes available as a
guard against it coming back.

Behaviour is unchanged. Each keyword goes only where clang had already
resolved the declaration to a base virtual, so it records what the
compiler already worked out and cannot affect overload resolution or
dispatch. If any of these signatures had not really overridden a base
method, the build would have failed rather than warned.

Where a declaration already carried `virtual` it is left alone and the
keyword appended, matching the surrounding declarations. Plain
`override` is used rather than the wxWidgets `wxOVERRIDE` macro, which
wx/defs.h defines as `override` beneath a comment marking it obsolete,
and which the rest of src/slic3r already avoids by 1742 occurrences to
113.

A full clang-cl build takes -Winconsistent-missing-override from 1,146
warning lines to 0. Those 42 declarations produce that many lines
because a header is re-diagnosed in every translation unit that
includes it. CalibrationWizardStartPage.hpp alone accounts for 336 of
them from 4 declarations.

* chore: drop unused lambda captures in GUI/Widgets

clang-cl reports 10 lambda captures in src/slic3r/GUI/Widgets that are
never read. Removing them changes nothing at runtime.

Every capture removed is `this` or a raw pointer. clang does not report
a capture whose type has a non-trivial destructor, since such a capture
can be held purely for its effect on an object's lifetime, so nothing
that owns or extends a lifetime is touched. The std::weak_ptr captured
beside the removed `this` in MultiNozzleSync.cpp stays.

This clears the category in GUI/Widgets only. A full clang-cl build
takes -Wunused-lambda-capture from 312 warning lines to 302, leaving
235 sites in other directories for a follow-up.
2026-08-25 08:18:48 -03:00
yw4z
2f9ef86e97 match style of dialog buttons 2026-08-25 00:04:14 +03:00
yw4z
fbe4cdff23 fix mixed filaments area cannot be hidden 2026-08-24 23:07:11 +03:00
yw4z
a3231aa723 rebuild menus from scratch to remove duplicate item check and match "delete" item order 2026-08-24 22:02:47 +03:00
yw4z
ce75a66e7c fix duplicate decompose menu item 2026-08-24 21:38:51 +03:00
Valerii Bokhan
524fd5e9c0 Fix: resolve 23 MSVC compiler warnings (#15280)
* fix: resolve MSVC compiler warnings and build error

C4101 - unreferenced local variables:
  - STEP.cpp, FilamentGroup.cpp: remove unused catch variable 'e'
  - GLGizmoMeasure.cpp: remove unused 'direction_on_model'
  - PartPlate.cpp: remove unused 'origin1, origin2'
  - DevStatus.cpp: suppress unused 'e' via (void)e

C4005 - macro redefinition:
  - Wrap NOMINMAX defines in #ifndef guards (OrcaSlicer.cpp, Preset.cpp,
    SupportTreeBuilder.cpp, OpenVDBUtils.cpp, GUI.cpp)
  - Remove conflicting DESIGN_INPUT_SIZE redefine in DownloadProgressDialog.cpp

C4172 - return address of local/temporary:
  - Config.cpp: return static const double instead of temporary 0

C4996 - deprecated API usage:
  - ImGuiWrapper.cpp: use GetText().Length() instead of GetTextLength()
  - OrcaCloudServiceAgent.cpp: replace deprecated wxPATH_NORM_ALL with
    explicit flags matching old default behavior
  - ASCIIFolding.cpp: replace deprecated std::wstring_convert/codecvt_utf8
    with boost::locale::conv::utf_to_utf (already used in same function)

C2440 - build error from deprecated wxTipWindow constructor:
  - Button.hpp/cpp: replace raw wxTipWindow* with wxTipWindow::Ref (weak
    reference). Ref auto-nulls when the tip window closes, eliminating
    the manual Bind(wxEVT_DESTROY) handler. delete uses operator->() to
    access the raw pointer since Ref is non-owning

* fix: avoid duplicate GetText() call in ImGuiWrapper clipboard handler

Capture wxTextDataObject::GetText() result in a local variable instead
of calling it twice (for .Length() check and into_u8()). GetText()
returns wxString by value, so this avoids an extra allocation/copy.

* fix: resolve MSVC compiler warnings (code review fixes)

* fix: resolve MSVC compiler warnings (code review fixes)
2026-08-24 15:37:47 -03:00
SoftFever
0fa25acda8 Match OrcaSlicer's color theme in the color-mixing UI 2026-08-25 00:47:25 +08:00
SoftFever
1631d3cf01 fix flatpak build 2026-08-24 17:30:39 +08:00
SoftFever
55812a7a8d Merge branch 'main' into color-mixing 2026-08-24 16:26:33 +08:00
SoftFever
e342698d8e Update sublayer option check. Add validation warning for gradient mixed filament without sublayer mixing 2026-08-24 15:30:02 +08:00
Kris Austin
d61e0cb7bf build: unify the warning policy across compilers (clang-cl: 124k warnings -> 2.7k, 21% faster) (#15328) 2026-08-23 19:55:48 -03:00
TheLegendTubaGuy
07b81cfdc9 Fix Qidi X-Max 4 chamber heating profiles (#15244) 2026-08-23 13:10:41 -03:00
Valentin
d7fed95390 Fix Ukrainian translation typo (#15333) 2026-08-23 12:42:30 -03:00
GlauTech
c72908e377 Update OrcaSlicer_tr.po (#15309)
* Update OrcaSlicer_tr.po

* Update OrcaSlicer_tr.po

Fixed inaccurate AI-generated text and updated missing translations.

* REmoive # AI Translated

* Update OrcaSlicer_tr.po

The following changes were made in this version:
- The term "Instance" was changed to "Eş kopya".
- The term "Jerk" was changed to "sarsıntı".
- Semantic discrepancies regarding certain words were corrected.

* Update OrcaSlicer_tr.po

The necessary arrangements have been made.

* Update OrcaSlicer_tr.po

* Update OrcaSlicer_tr.po

The necessary updates have been made.

* G-kodu to G-code

---------

Co-authored-by: Ian Bassi <ian.bassi@outlook.com>
2026-08-23 12:34:51 -03:00
Ian Bassi
ea376e858c Show move length in Previewr panel (#15326)
Adds a new "Length" row to the sequential marker position popup in GCodeViewer and updates row capacity accordingly.
For arc commands (G2/G3) that are split into multiple vertices, it now sums segment distances across vertices with the same gcode_id so the displayed value reflects the full move length instead of a single chord.
2026-08-23 12:18:22 -03:00
Ian Bassi
877180829c Unify colinear simplify tolerance in Arachne (#15314)
Introduced a shared `colinear_vertex_tolerance()` helper in `ExtrusionLine.hpp` and updated both simplify paths (`ExtrusionLine.cpp` and `WallToolPaths.cpp`) to use it instead of duplicated hardcoded `0.005` scaled thresholds. This keeps the near-colinear early-out tied to `SCALED_EPSILON` (rounding-noise scale) and avoids unintended curve decimation from larger tolerances, while documenting the geometric impact in code.
2026-08-23 12:18:06 -03:00
SoftFever
2b1499a087 clean up comments 2026-08-23 22:43:41 +08:00
SoftFever
7934814077 fix wrong size of the last swatch of each row in Mixing Recommendations 2026-08-23 22:11:49 +08:00
SoftFever
4a32a9e066 Match mixed filament swatches to the editor's gradient preview
The sidebar Mixed Filament list, the extruder icons, the color painting
gizmo and the canvas filament bar now show the same bottom-to-top fade the
Edit Mixed Filament preview shows, custom gradient curves included, instead
of a horizontal fade between the two component colours. Ordinary and vendor
multi-colour filaments are drawn exactly as before.
2026-08-23 22:11:49 +08:00
SoftFever
ff35dacf4c Fix UI hanging on Mac 2026-08-23 22:11:49 +08:00
SoftFever
6f32d59997 Fixed an issue that gradient color button in color painting gizmo don't have number 2026-08-23 22:11:49 +08:00
SoftFever
f02423074c Warn about mixed color sublayer when adding height ranges 2026-08-23 22:11:49 +08:00
SoftFever
38d51783ae Refresh the mixed filament list when a component preset changes 2026-08-23 22:11:49 +08:00
SoftFever
af5397d678 Close the single-extruder mixed filament warning by type 2026-08-23 22:11:49 +08:00
SoftFever
9985688b5b Blend mixed slots in the machine-send and AMS-sync thumbnails 2026-08-23 22:11:49 +08:00
SoftFever
d27766aff0 Reject a mixed filament as the wipe tower filament 2026-08-23 22:11:49 +08:00
SoftFever
cfeca9b9ff Hide mixed slots from the support and wipe tower filament dropdowns 2026-08-23 22:11:49 +08:00
SoftFever
716bba53df Refuse to slice a broken mixed filament 2026-08-23 22:11:49 +08:00
SoftFever
8965b0be21 Skip mixed slots in flush volume auto-calculation
Mixed-colour slots are virtual and never flushed. Guard auto_calc_flushing_volumes_internal against them as BambuStudio does, and make the flushing dialog's default matrix and the sidebar 'modified' comparison physical-only so the untouched mixed rows no longer count as a user edit and the Re-calculate result matches the physical-only table.
2026-08-23 22:11:49 +08:00
SoftFever
0c3d7c6ed1 Expand mixed slots in by-object filament bookkeeping 2026-08-23 22:11:49 +08:00
SoftFever
2131ef0560 Keep mixed filaments across app restarts 2026-08-23 22:11:49 +08:00
SoftFever
6745a33d53 Fix deleting mixed filaments from the sidebar 2026-08-23 22:11:49 +08:00
SoftFever
b2e1870a14 Restore sublayer prompt when enabling gradient mixing 2026-08-23 22:11:49 +08:00
SoftFever
6e52c091f3 Initialize parse output in string_to_double_decimal_point 2026-08-23 22:11:49 +08:00
SoftFever
1b5b8fce54 Port mixed filament dialog fixes from BambuStudio 2026-08-23 22:11:49 +08:00
SoftFever
b1e3cdc666 Port colored OBJ import pipeline from BambuStudio 2026-08-23 22:11:49 +08:00
SoftFever
94a1cd6c93 Port color decompose recipe data and interpolation from BambuStudio 2026-08-23 22:11:49 +08:00
SoftFever
fcdfcae427 Port mixed filament engine fixes from BambuStudio 2026-08-23 22:11:49 +08:00