Außerdem: sub_brands in AMS-Config übergeben damit sync_ams_list()
bei ID-Kollisionen (z.B. OGFL04 = Overture + eSUN) den korrekten
Hersteller per Namens-Prefix bevorzugt.
Der vorherige Fix griff nur beim Umbenennen. Beim normalen Speichern
läuft Preset::save() — dort wird jetzt ebenfalls eine MD5-basierte ID
generiert wenn das User-Filament-Preset noch keine hat.
Wenn ein Filament-User-Preset noch keine filament_id hat, wird beim
Speichern/Umbenennen automatisch eine MD5-basierte ID (P + 7 Zeichen)
generiert. Damit kann der Moonraker-Filament-Matcher das Preset korrekt
einem Slot zuordnen statt auf Generic PLA zurückzufallen.
Presets die via 'Save As' angelegt werden haben keine filament_id.
Statt sie zu überspringen werden sie per Namen gematcht und ihr
Preset-Name als Identifier zurückgegeben.
When a user creates a new filament preset by inheriting from an
existing one (e.g., "Brand ABS @BBL H2D" inheriting from "Generic
ABS @BBL H2D"), the resulting preset previously had no filament_id
of its own. This caused two problems:
1. The AMS sync pipeline could not distinguish the user preset from
its parent, so syncing filaments from the printer always resolved
to the generic base preset instead of the user's custom one.
2. External tools that rely on filament_id for preset identification
(e.g., Bambuddy, see maziggy/bambuddy#1053) could not assign or
recognize user-created inherited presets in AMS slots.
The root cause was twofold:
- No filament_id was generated during save_current_preset() for
inherited filament presets. Only base (non-inheriting) presets
received one via the CreatePresetsDialog flow.
- The AMS matching logic in sync_ams_list(), get_ams_cobox_infos(),
and get_filament_presets() filtered candidates with
`get_preset_base(f) == &f`, which by definition excludes any
preset with a non-empty inherits() field.
This commit:
- Generates a unique filament_id (MD5 hash of preset name, prefixed
with "P", truncated to 8 chars) when creating a new filament
preset in PresetCollection::save_current_preset(). This matches
the existing ID generation scheme used for base filaments in
CreatePresetsDialog::get_filament_id().
- Persists filament_id into the JSON when saving inherited presets
via Preset::save() and get_differed_values_to_update().
- Broadens the AMS filament matching predicates to also consider
user presets that carry their own filament_id, rather than
requiring them to be base presets.
Files changed:
src/libslic3r/Preset.cpp - ID generation, save, lookup
src/libslic3r/PresetBundle.cpp - AMS sync matching predicates
Pass 1: nur is_compatible Presets (wie bisher)
Pass 2: alle sichtbaren Presets unabhängig von is_compatible
Behebt: Hersteller wie eSUN, Eryone, Elegoo haben globale Base-Presets
aber keine druckerspezifischen Profile für den Kobra X →
is_compatible=false → bisher immer Generic PLA.
Mit Pass 2 werden diese Base-Presets als Fallback gefunden.
Wenn die Bridge eine tray_info_idx sendet (z.B. GFL99 für Bambu Lab PLA)
die kein kompatibler Preset für den aktiven Drucker hat, wird jetzt
trotzdem der Vendor+Type+Color-Match versucht statt direkt auf Generic
zurückzufallen.
Behebt: Bridge sendet GFL99 (Bambu-ID) für Slot mit vendor='Bambu Lab'
→ kein Kobra-X-kompatibler Preset für GFL99 → bisher Generic PLA
→ jetzt Vendor-Match → findet besten Bambu-Lab-PLA-Preset
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Pass 1: kompatible + sichtbare Presets (wie bisher)
Pass 2 (neu): wenn Pass 1 leer → alle Base-Presets des Vendors + Typs
durchsuchen, unabhängig von is_compatible/is_visible.
Behebt: Elegoo PLA (@base, instantiation=false) und ähnliche Hersteller
die ein globales Base-Preset haben aber kein druckerspezifisches Profil
für den Kobra X → bisher immer "Generic PLA", jetzt "Elegoo PLA".
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
KX-Bridge sendet bereits konkrete Filament-IDs und Vendor-Hints im
AMS-JSON, aber MoonrakerPrinterAgent überschreibt sie unbedingt mit
filament_id_by_type() → erstes sichtbares Preset alphabetisch gewinnt.
Patch:
- AmsTrayData um filament_vendor erweitert
- Liest tray_info_idx + filament_vendor aus Bridge-JSON
- Wenn tray_info_idx leer + vendor vorhanden: Vendor+Type+Color-Match
(gleiche Logik wie SnapmakerPrinterAgent)
- Sonst: alter filament_id_by_type-Fallback (unverändertes Verhalten)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
PR #13388 added resources/printers/N6.json for X2D support but did not
bump resources/printers/version.txt. PresetUpdater only copies files
from the install's resources/printers/ to the user's data_dir/printers/
when the resources version is newer than the user's stored version, so
every existing install stays at 02.00.00.29 and never receives N6.json.
At runtime, json_diff::load_compatible_settings("N6", "") reads from
data_dir/printers/N6.json; the silent file-missing failure leaves
is_support_bed_leveling, is_support_pa_calibration, and
SupportCalibrationNozzleOffset at their defaults, hiding the Bed
Leveling and Nozzle Offset Calibration checkboxes in the Send Print
Job dialog for the X2D.
Bumping the patch version triggers the existing propagation logic on
next startup.
Fixes#13780Fixes#13794
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Ignore SIGPIPE at startup to prevent crash on dropped printer connection
Writing to a closed printer network socket raised SIGPIPE, whose default
action terminated the whole process (exit 141, no crash report). Set
SIGPIPE to SIG_IGN once at main() entry (POSIX only) so such writes return
EPIPE to the existing networking error handling instead of killing the app.
Fixes#13787
- Added missing translations for various UI elements and messages.
- Improved existing translations for clarity and accuracy.
- Ensured consistency in terminology across the localization file.
After pulling the latest presets from the cloud, changed values such as Layer height kept showing the old value until the user switched tabs. Refresh the active settings tab on sync so updates appear immediately.
The Emboss text-cut workflow can crash with SIGBUS at a stack-guard page
on macOS (and equivalent on Linux) when CGAL's
Polygon_mesh_processing::corefine falls back from filtered interval
arithmetic (Epick) to exact rational arithmetic (Epeck / mpq_class).
On near-degenerate inputs -- coplanar triangles in the projection
footprint, very thin font stems, sharp edges or seams under the text --
CGAL's Filtered_predicate_with_state cascade ends up inside
Triangulation_2<Projection_traits_3<Epeck>>::march_locate_2D, whose
recursive walk plus mpq_class arithmetic frames overflows the worker's
4MB default stack. The fault address sits exactly inside the next
thread's guard page, which is the textbook macOS signature.
Crash trace (BambuStudio v02.07.00.55, macOS 26.4.1 arm64, embossing
text into a model):
__gmpn_mul_1
__gmpz_mul / __gmpq_mul
CGAL::determinant<mpq_class>
Projected_orientation_with_normal_3
Filtered_predicate_with_state::operator()
Triangulation_2<...>::orientation
Triangulation_2<...>::march_locate_2D
Surface_intersection_visitor::triangulate_intersected_faces
Polygon_mesh_processing::corefine
Slic3r::cut_surface
Emboss::cut_surface_to_its
Emboss::GenerateTextJob::get_text_mesh
PlaterWorker::PlaterJob::process
The thread's stack region in the report was exactly 4128K -- the
default 4MB plus a small TLS overhead -- and the faulting address hit
the adjacent guard page. We have one observed reproducer; the 16 MB
value is chosen as 4x defensive headroom over that, not as a measured
upper bound. Future heavier emboss inputs may need more.
Cumulative cost on a 64-bit target. Slic3r::create_thread has 22
callsites across the codebase. Realistic peak concurrent live count is
on the order of 10-15 workers (Plater UI worker, slicing process, FDM-
support gizmo, STEP loader, network sync helpers, per-task sender
threads in TaskManager up to MaxSendingAtSameTime, per-machine info
threads in device-list dialogs, long-lived sync helpers in GUI_App).
At 16 MB reserve x ~15 = ~240 MB of address-space commitment in the
worst case, which is bounded on any 64-bit target.
Resident memory remains proportional to actual stack depth on all three
platforms: macOS / Linux mmap the thread stack and defer-commit pages on
touch, and Boost.Thread on Win32 passes STACK_SIZE_PARAM_IS_A_RESERVATION
to _beginthreadex (verified at libs/thread/src/win32/thread.cpp), so on
Windows the bumped value is the reserve, not the initial commit.
The 32-bit branch of the previous (sizeof(void*) == 4) ternary is
removed: BambuStudio doesn't ship a 32-bit build today, and the literal
makes the value easier to read at the callsite.
(cherry picked from commit e150b502b3d2afc98b83dcc9e5720e998f9eb79a)
Co-authored-by: Abdel Gomez-Perez <nabdel07@icloud.com>
* feat(viewer): Display travel distance and move count in G-code summary
This commit introduces a new feature that enhances the G-code viewer by displaying the total travel distance and the total number of travel moves in the 'Line Type' summary.
This provides users with more detailed statistics about their prints, helping them to better understand the printer's behavior and identify opportunities to optimize travel moves for faster print times.
This commit also fixes a critical bug in the G-code processor where the travel distance was being calculated incorrectly. The distance variable was not being updated for non-extruding travel moves, leading to inaccurate statistics. The calculation has been corrected to ensure it is performed for all relevant move types, resulting in accurate travel distance reporting.
* Subfix segments
kilo mega giga tera peta exa
* Add missing values
* Grams to Kilos and tons
* add distance
* Fix tool view
* Record and display seam distances
Track seam-related distances in print statistics and show them in the GCode viewer. Added total_seam_gap_distance and total_seam_scarf_distance to PrintEstimatedStatistics (with initialization). In GCode::extrude_loop the code now computes seam gap and scarf distances and accumulates them for external perimeters. GCodeViewer uses the summed seam distance when the Seams option is selected in the legend.
* Fix travel / wipe distances
* Update GCode.cpp
* Filament changes estimated time
---------
Co-authored-by: Steve Scargall <37674041+sscargal@users.noreply.github.com>
Handle user_ticket_login
Legacy Bambu network plugins completed embedded login with
user_login, which the WebView dialog already handled.
Newer Bambu login flows can complete with user_ticket_login and
return only a short-lived ticket. The external browser path already
worked because the local HTTP callback server exchanges that ticket
for tokens, fetches the user profile, and passes the resulting session
payload to change_user.
Mirror that ticket exchange path for embedded WebView login so the
dialog can handle user_ticket_login instead of silently ignoring it
after verification-code submission.
2026-05-21 13:44:17 +08:00
Aleksandr Dobkinimg src=404 onerror=alert(document.domain)