Commit Graph

17755 Commits

Author SHA1 Message Date
SoftFever
50abe02f18 Make AMS trays read-only in laser mode and add the gradient fill helper 2026-07-17 05:06:09 +08:00
SoftFever
7265a2fbfe Resync the AMS control and item widgets 2026-07-17 04:30:45 +08:00
SoftFever
db51d8ab9b Mark the accent-color divergence in the best-position popup 2026-07-17 03:50:29 +08:00
SoftFever
d4e95e3269 Resync the device tab widgets and add the AMS best-position popup 2026-07-17 03:37:18 +08:00
SoftFever
0feca8d442 Port accessory firmware versions, cold-pull state and filament checks 2026-07-17 02:49:45 +08:00
SoftFever
8d211ce878 Move axis, calib, chamber, status and upgrade handling into DeviceCore 2026-07-17 02:04:25 +08:00
SoftFever
8a6609f282 Restore the extruder name fallback and fix the loading-busy check 2026-07-17 01:16:47 +08:00
SoftFever
4bca7b3008 Resync the DeviceCore state models 2026-07-17 00:49:04 +08:00
SoftFever
550ab5d438 Guard the don't-remind command parse and init the checker index 2026-07-16 20:09:50 +08:00
SoftFever
56ac4e1281 Mark deliberate porting divergences 2026-07-16 20:07:55 +08:00
SoftFever
5fd1aa6e8b Add firmware print-option toggles to the print options dialog 2026-07-16 19:28:50 +08:00
SoftFever
eeec8ab06b Parse the new detection bits on the live push path 2026-07-16 18:51:25 +08:00
SoftFever
28b7fd90d0 Restructure DevPrintOptions around a detection-option map 2026-07-16 18:40:53 +08:00
SoftFever
4a1c53e76e Stop the pending storage check when jumping to the timelapse page 2026-07-16 18:18:51 +08:00
SoftFever
3ec074edb2 Stop the timelapse storage check when the send dialog closes 2026-07-16 18:11:01 +08:00
SoftFever
615deefa87 Check timelapse storage space before sending a print 2026-07-16 17:52:28 +08:00
SoftFever
ffda4282eb Add timelapse storage location selection 2026-07-16 16:59:16 +08:00
SoftFever
5cf7e27c23 Show combined nozzle mapping when a filament switch is installed 2026-07-16 16:35:11 +08:00
SoftFever
8bb093b50b Map switch-bound AMS trays to both extruders 2026-07-16 15:54:56 +08:00
SoftFever
47f7e09e84 Block TPU on the left extruder without firmware support 2026-07-16 15:21:35 +08:00
SoftFever
e8f8a4bb7d Add purification and don't-remind actions to the device error dialog 2026-07-16 15:15:40 +08:00
SoftFever
c7581e590c Warn when a filament will switch extruders mid-print 2026-07-16 14:58:58 +08:00
SoftFever
5f3f892a6b Fix inverted MQTT jog on i3-arch printers 2026-07-16 14:54:16 +08:00
SoftFever
0f58f23853 Destroy the network-plugin agent before unloading its DLL
A network-plugin hot reload unloaded the DLL without destroying the agent
handle it created, so the plugin's m_agent was left dangling into freed
memory. On reload create_agent() short-circuited on has_agent() and kept the
stale handle, and the next call into the new DLL (install_device_cert from the
device-refresh timer) dereferenced it and crashed with an access violation.
unload() now destroys the agent first, so a reload always gets a fresh handle.
2026-07-16 10:53:28 +08:00
SoftFever
7cc572be47 Add PA-profile sharing toggle to the device send dialog 2026-07-16 02:47:47 +08:00
SoftFever
d591d50ca0 Show the print-failure snapshot in the device error dialog
When a print fails, DeviceErrorDialog now fetches the printer's captured camera
frame of the failure and shows it in place of the generic HMS illustration,
falling back to the local image and a drawn placeholder on older plugins or errors.

- Agent: add get_hms_snapshot through NetworkAgent / IPrinterAgent (BBL calls the
  bound plugin symbol; other agents no-op, so old plugins degrade gracefully).
- DeviceManager: parse and clear m_print_error_img_id from the print-error message.
- Dialog: tiered cloud/local/placeholder image reusing the single image widget,
  with a liveness-guarded async callback decoded on the UI thread.
2026-07-16 01:44:43 +08:00
SoftFever
aa44d57eac Bind the 02.08.01.52 plugin's new ABI symbols
Add the 11 functions the newer plugin exports (HMS snapshot, GoLive camera
URL, consent report, cloud filament-spool CRUD, AMS-filament sync, login-state
and studio-info hooks) plus their four parameter structs. Everything resolves
to null on older plugins and no caller invokes them yet, so this is inert ABI
surface for later features.
2026-07-16 00:48:56 +08:00
SoftFever
bf4fb64c8a Make 02.08.01.52 the default network plugin and match its ABI
The newer plugin adds four PrintParams fields (task_timelapse_use_internal,
extruder_cali_manual_mode, svc_context, slicer_uid) and an extra dev_model
argument to bind. Both cross the by-value C ABI boundary, so match the struct
layout and thread dev_model through the bind chain, else start_print and bind
corrupt the stack on the newer plugin. Keep 02.03.00.62 selectable as a fallback.
2026-07-16 00:17:01 +08:00
SoftFever
0849c44ae0 Merge branch 'main' into dev/ams-heat 2026-07-15 19:45:27 +08:00
Kris Austin
d500ba4e9e test: fix flaky k-medoids goldens added with H2C/A2L support (#14773)
The filament-group golden harness landed with H2C/A2L support (#14685). Its
"FilamentGroup golden regression" / stress_66 case fails intermittently on
Windows x64, on main and on unrelated PRs alike. The test depends on how fast the
runner is.

The k-medoids clustering these goldens exercise is an anytime search bounded by a
3 second wall clock. Every restart is seeded from its own index, so nothing about
it is random. What varies is how many restarts fit in the budget, and the best
cost is a minimum over completed restarts, so a slower runner is never better.
Grading a score produced that way measures the machine as much as the code.

Add a ClusteringBudget struct and let the tests set it. The defaults are the
current 3 seconds and 30 restarts, so slicing behavior is unchanged. A
non-positive timeout removes the wall clock and bounds the search by restart
count alone.

The goldens are then graded under a fixed budget of four restarts, where every
one of them reaches the BambuStudio reference within 3%, so the score becomes a
property of the code. This retires the machine-specific 125103 lock on stress_66.

The default wall-clock path keeps its own test, asserting the grouping is valid
and the search does not run away. It makes no score assertion, because under a
wall clock that number is not a property of the code.

The golden test also checks the run fits in ten times the default wall clock.
Slicing quality depends on how many restarts fit in the budget, so a search an
order of magnitude slower would degrade real groupings while a fixed-budget score
gate stayed green.

The 3% tolerance stays as the parity allowance against the goldens. It also
covers a small spread across standard libraries: the k-medoids search seeds each
restart with std::shuffle, whose algorithm the C++ standard leaves unspecified,
so libstdc++, libc++ and the MSVC STL permute the same seed differently, start
from different medoids, and settle on slightly different groupings, about 3e-4
apart and only on the goldens heavy enough to reach the k-medoids search.
2026-07-15 16:59:55 +08:00
SoftFever
be165c97de Add --outdir to profile validator to save sliced g-code 2026-07-15 16:52:02 +08:00
SoftFever
8ac478be26 Add real slice validation for all printers (#14771)
# Description

Adds a --slice (-s) mode to the profile validator that slices a
two-colour cube through every shipped printer, expanding all custom
g-code (change_filament_gcode, machine start/end, etc.). This catches
invalid-placeholder / bad-flow / slicing errors that the static JSON
checks and unit tests can't see.

Included:
- Validator: new -s sweep mode; per-profile error attribution in the
log; resolves the synthetic 2nd-filament nozzle-mapping so multi-nozzle
BBL printers (incl. the Direct-Drive+Bowden X2D) validate cleanly.
- CI, two complementary paths:
- check_profiles.yml — runs the sweep on profile-only PRs (nightly
binary).
- build_all.yml — new parallel slice_check_linux job runs it on
engine/src PRs with the PR-built binary (build_all doesn't trigger on
resources/**, so no overlap). Runs off the build's artifact, so it
doesn't lengthen the build leg.
- Profile fixes surfaced by the sweep: Creality, FLSun, Ginger, Qidi,
RatRig, iQ.
- Engine: whitelist BBL firmware T-opcodes (T1001/T65279/T65535) in the
time estimator (log-only, no g-code change); dedupe a
per-filament/per-layer log flood in get_config_index.

# 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-07-15 16:32:09 +08:00
Noisyfox
691fd5892d Trigger auto perspective on 3D mouse rotation (#14768) 2026-07-15 15:06:17 +08:00
Mqrius
c84d5c7943 Add top/bottom surface fill order control (Outward/Inward) for Concentric, Archimedean Chords and Octagram Spiral (#14179)
Co-authored-by: Ian Bassi <ian.bassi@outlook.com>
2026-07-14 15:34:13 -03:00
SoftFever
f1fd49c12f Add slice-validation sweep for shipped profiles 2026-07-15 01:49:04 +08:00
Valerii Bokhan
50768e0716 Feature: Retract amount after wipe (#11015)
Co-authored-by: Ian Bassi <ian.bassi@outlook.com>
2026-07-14 14:42:16 -03:00
SoftFever
28bb05ac83 Suppress excessive warnings 2026-07-15 00:06:13 +08:00
Noisyfox
8fe7a33ae6 Merge branch 'main' into dev/ams-heat 2026-07-14 17:05:53 +08:00
Kris Austin
3c0338f462 fix: wipe tower height crash triggered by H2C/A2L support (#14758)
The new "Prime-tower visits..." test from #14685 (H2C/A2L support) throws
"Coordinate outside allowed range" at random on CI, on both Windows arm64 and
Linux x86_64. It's an uninitialized read of WipeTowerData::height.

#10780 (H2D/H2S) added a second wipe tower path, generate_new(), that fills in
depth, bbx, brim_width and rib_offset but not height. The older generate() sets
height, and clear() never did, so on the generate_new path it stays garbage.

first_layer_wipe_tower_corners() passes height to get_wipe_tower_cone_base() as
R = tan(cone_angle/2) * height. The stray bytes are usually zero, so R is zero
and the slice is fine, which is why it passes most runs on every platform. When
they aren't zero the cone radius runs past ClipperLib's limit and the slice
throws. Nothing selects for it, so it just flakes around.

#14685's test is the first to exercise this path, so that's when it started
showing up.

Initializing height in clear() fixes it, same as the m_origin fix in #13712. The
BBL generate_new path has no stabilization cone, so height = 0 is right.
2026-07-14 11:22:25 +08:00
Noisyfox
246f2d32bf Merge branch 'main' into dev/ams-heat
# Conflicts:
#	src/libslic3r/Preset.cpp
#	src/libslic3r/PrintConfig.hpp
#	src/slic3r/GUI/DeviceCore/CMakeLists.txt
#	src/slic3r/GUI/DeviceCore/DevDefs.h
#	src/slic3r/GUI/DeviceCore/DevFilaSystem.cpp
#	src/slic3r/GUI/DeviceCore/DevFilaSystem.h
#	src/slic3r/GUI/DeviceCore/DevUtilBackend.cpp
#	src/slic3r/GUI/DeviceCore/DevUtilBackend.h
#	src/slic3r/GUI/DeviceManager.cpp
#	src/slic3r/GUI/DeviceManager.hpp
#	src/slic3r/GUI/SelectMachine.cpp
#	src/slic3r/GUI/SelectMachine.hpp
2026-07-14 10:10:19 +08:00
SoftFever
74813b401f Merge remote-tracking branch 'origin/main' into feature/h2c_support_clean
# Conflicts:
#	localization/i18n/fr/OrcaSlicer_fr.po
#	localization/i18n/list.txt
2026-07-14 02:54:20 +08:00
SoftFever
df1e114b72 resolve current_filament_id/current_nozzle_id in layer_change_gcode - enhanced 2026-07-14 02:12:09 +08:00
SoftFever
56f672ecbd resolve current_filament_id/current_nozzle_id in layer_change_gcode (fixes X2D) 2026-07-14 01:26:34 +08:00
SoftFever
9aa90fa6a8 update BBL H2D and X2D profiles 2026-07-14 00:52:54 +08:00
foXaCe
c41e685a69 i18n: wrap hardcoded GUI strings (undo/redo labels, dialogs, notifications) + FR (#14729) 2026-07-13 12:19:33 -03:00
SoftFever
35ffe49b17 Fix sending print jobs to Bambu H2C printer 2026-07-13 18:13:15 +08:00
packerlschupfer
88262ee504 CLI: guard 4 null derefs when loading a 3mf without preset ids (#14580)
CLI: guard 4 null derefs when loading a 3mf with no preset ids

At OrcaSlicer.cpp:1700-1704 the post-load block reads printer_settings_id,
print_settings_id, filament_settings_id, and nozzle_diameter from the
config that the 3mf carries. If the 3mf is a BBL/BBS-flavored 3mf but
was produced by a non-GUI writer (e.g. CLI --export-3mf without a
loaded preset) any of those keys can be absent, and config.option<T>(...)
returns nullptr — the ->value / ->values deref then SIGSEGVs.

Wrap each optional lookup in an if-let. printer_model, printer_extruder_variant,
and print_extruder_variant already pass create_if_missing=true and are safe.

Repro (BEFORE this patch):
  orca-slicer --export-3mf out.3mf in.stl   # produces preset-less 3mf
  orca-slicer --info out.3mf                # SIGSEGV at :1700
  bt: __cxx11::basic_string::_M_assign
    -> Slic3r::CLI::run @ OrcaSlicer.cpp:1700

AFTER: --info out.3mf returns exit 0 with the mesh summary.

The same failure mode affected --inspect-mesh, --inspect-paint, and
every other action that has to walk the loaded model's config; --slice
would only survive because it always injects a printer via
--load-settings.
2026-07-13 15:10:33 +08:00
bobomb
4eb9a85a49 Fix filament sync targeting wrong printer after switching printer presets (#12506) (#14587)
For non-BBL host printers (Moonraker/Klipper, Qidi, Snapmaker, Creality), switch_printer_agent() only re-selected the machine when the agent type changed. Switching between two printer presets that use the same agent left the selected machine and the agent's cached device_info pointing at the previously active preset's host, so filament sync kept hitting the old printer.

Re-select the machine when the agent type is unchanged but the target host differs, so the selected machine and device_info always follow the active printer preset.

Co-authored-by: Noisyfox <timemanager.rick@gmail.com>
2026-07-13 15:08:53 +08:00
Walter Almada
5a53d2eb88 Fix use-after-free crash on exit during GLCanvas3D teardown (#14588)
Plater's pImpl (unique_ptr<priv> p) is destroyed before the wxWindow base
destructor runs DestroyChildren(), so child GLCanvas3D windows are torn down
after p is gone. GLCanvas3D::~GLCanvas3D() -> reset_volumes() then dereferences
the freed p through two paths:
  - Selection::clear() -> plater()->canvas3D() -> p->get_current_canvas3D()
  - _set_warning_notification() -> plater()->get_notification_manager()

Guard both with the existing wxGetApp().is_closing() flag; both are UI-only
side effects that are no-ops during shutdown, so normal-use behavior is
unchanged.

Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-13 14:54:42 +08:00
Noisyfox
49282858a4 Merge branch 'main' into dev/ams-heat 2026-07-13 14:43:45 +08:00