Commit graph

369 commits

Author SHA1 Message Date
HellAholic
52ad25ad71 Bump Simulation View plugin version to 1.2.0
Updated the version in plugin.json from 1.1.0 to 1.2.0 to reflect new changes or improvements in the Simulation View plugin.
2025-12-21 15:48:54 +01:00
HellAholic
b8be24cc52 Enhance slider label with detailed layer info
Replaces the single layer height display with a grid showing current height, time elapsed, layer print time, and time remaining. Updates property to accept a data dictionary and adds localization for labels to improve user information and internationalization.
2025-12-21 15:48:47 +01:00
HellAholic
d3b1c48e73 Replace layerHeight with layerData in LayerSlider
Updated LayerSlider.qml to use 'layerData' instead of 'layerHeight' for upper and lower handles, reflecting changes in SimulationView properties.
2025-12-21 15:48:40 +01:00
HellAholic
4e59253dee Replace layer height properties with layer data maps
Replaces currentLayerHeight and minimumLayerHeight properties with currentLayerData and minimumLayerData, returning all relevant layer data as QVariantMap. This provides more comprehensive information for each layer, including height, time elapsed, layer time, and time remaining.
2025-12-21 15:48:29 +01:00
HellAholic
af6a915cf1 Refactor layer cache to include time metrics
Replaces the layer heights cache with a unified layer data cache that stores both height and formatted time metrics (elapsed, per-layer, and remaining) for each layer. Adds parsing of gcode for ;TIME_ELAPSED comments and updates public API to provide all layer data in a single dict. Improves efficiency and enables time-based features in SimulationView.
2025-12-21 15:48:21 +01:00
HellAholic
f5a9cb2f65 Fix layer heights cache to use layer_data id
Updated the caching logic in SimulationView to use the id of the layer_data object instead of the node. This ensures the cache is correctly invalidated when layer_data changes, preventing potential issues when nodes are reused.
2025-12-14 23:54:32 +01:00
HellAholic
749d81c4d9 Optimize layer heights cache in SimulationView
Added logic to track which node's layer heights are cached and only recalculate the cache if the data source changes. This improves performance by avoiding unnecessary recalculations and ensures cache validity when the scene changes.
2025-12-14 23:33:18 +01:00
HellAholic
d591e7fcfc Cache layer heights to improve performance
Introduced a cache for layer heights to avoid recalculating them on every query. Added a method to populate the cache for all layers at once, and updated layer height retrieval methods to use the cache, improving efficiency when accessing layer height data.
2025-12-10 12:45:29 +01:00
HellAholic
f4430718c7 Show layer height in Simulation View slider labels
Adds display of the current and minimum layer heights (in mm) to the Simulation View slider labels. Implements new properties and logic in SimulationView and SimulationViewProxy to retrieve accurate layer heights for both sliced and gcode data. Bumps plugin version to 1.1.0.
2025-12-09 17:22:32 +01:00
HellAholic
89a6708f19 Show warning only for enabled extruders
Some checks failed
conan-package-resources / conan-package (push) Has been cancelled
conan-package / conan-package (push) Has been cancelled
printer-linter-format / Printer linter auto format (push) Has been cancelled
unit-test / Run unit tests (push) Has been cancelled
conan-package-resources / signal-curator (push) Has been cancelled
Updated warning icon visibility logic to display warnings only for enabled extruders in the simulation view menu. This prevents warnings from appearing for extruders that are not active.
2025-11-26 09:01:50 +01:00
HellAholic
57fcd1e3c8 Fix extruder warning visibility logic
Updated the warning icon visibility check to only consider extruders that exist in the current printer, preventing false warnings for non-existent extruders.
2025-11-19 13:05:59 +01:00
HellAholic
851ba0e04b Rename SchemeTypeLabel to schemeTypeLabel
id should start with lowercase
2025-11-19 10:02:04 +01:00
HellAholic
932f139c95 Rename lineTypeLabel to SchemeTypeLabel
Updated the id from lineTypeLabel to SchemeTypeLabel and adjusted references accordingly for clarity and consistency in SimulationViewMenuComponent.qml.
2025-11-19 09:58:42 +01:00
HellAholic
6b01d85fb1 Add warning icons for extruder visibility in SimulationView
Introduces warning icons in the SimulationView menu to indicate when extruder visibility is low or unchecked. Updates layout logic to accommodate the new icons and increments the plugin version to 1.0.2.
2025-11-19 09:54:41 +01:00
Erwan MATHIEU
df31cc8e31 Use separate node attribute to indicate assigned to disabled extruder
CURA-12742
2025-10-16 09:50:09 +02:00
Erwan MATHIEU
e69a436942 Fix sometimes wrongly displayed view
Some checks are pending
conan-package / conan-package (push) Waiting to run
unit-test / Run unit tests (push) Waiting to run
CURA-12660
This required a refactoring of the management of the active view. The previous behavior was that anyone could set the active view, depending on certain conditions. But now we also have a view that is set by a tool, so sometimes the actually set view would be incorrect. Now each Stage requests an active view, and each tool CAN also request an active view. Then the Controller decides which view should actually be active depending on the active stage and tool.
2025-08-06 16:15:05 +02:00
Erwan MATHIEU
b6b2da0c14 Change wording as suggested
Some checks failed
unit-test / Run unit tests (push) Waiting to run
conan-package / conan-package (push) Has been cancelled
CURA-11978
"Unretraction" is a barbaric word, better use "Priming" instead
2025-06-12 08:39:59 +02:00
Erwan MATHIEU
f84923185d Use proper English word for "plane"
Some checks failed
conan-package-resources / conan-package (push) Has been cancelled
conan-package / conan-package (push) Has been cancelled
printer-linter-format / Printer linter auto format (push) Has been cancelled
unit-test / Run unit tests (push) Has been cancelled
conan-package-resources / signal-curator (push) Has been cancelled
CURA-12544
The word in French to describe a geometric flat surface if "plan", which is a valid word in English but it doesn't have the same meaning, this got me confused. So replacing "plan" by "plane" because we are actually dealing with a geometrical "plane" (although it doesn't fly).
2025-06-10 11:21:17 +02:00
Erwan MATHIEU
b940179c54 Set proper tooltip text color
Some checks failed
conan-package / conan-package (push) Has been cancelled
unit-test / Run unit tests (push) Has been cancelled
CURA-11978
2025-06-04 11:01:51 +02:00
Erwan MATHIEU
1003d750b9
Merge branch 'main' into CURA-11978_retract-and-unretract-in-a-travel
Some checks failed
conan-package-resources / conan-package (push) Has been cancelled
conan-package / conan-package (push) Has been cancelled
printer-linter-format / Printer linter auto format (push) Has been cancelled
unit-test / Run unit tests (push) Has been cancelled
conan-package-resources / signal-curator (push) Has been cancelled
2025-05-27 08:51:07 +02:00
Erwan MATHIEU
e1d579c6c8 Display legend tooltip for travel types
CURA-11978
2025-05-26 16:53:34 +02:00
Erwan MATHIEU
86777ac666 Add new travel types and display z-hops
CURA-11978
2025-05-26 11:52:53 +02:00
Erwan MATHIEU
a6ee53c944 Fix visibility settings not being applied for lower layers
CURA-12272
2025-03-10 14:55:46 +01:00
HellAholic
9bc6abc5eb
Merge branch 'main' into CURA-12192_replay-preview-at-last-layer 2024-11-21 11:07:13 +01:00
Erwan MATHIEU
0991c3c01d Loop back to the beginning when ending simulation playback
CURA-12192
2024-11-11 16:14:32 +01:00
Remco Burema
a6a223bcc1 Prevent 'too small' starts from not rendering.
Not actually part of CURA-12188 but I was in the neighbourhood anyway.
2024-10-24 09:50:03 +02:00
Erwan MATHIEU
b583711c70 Handle segments with null feed rate
CURA-12213
2024-10-18 16:13:15 +02:00
Saumya Jain
3e1ee4b266 Updated shader for support seams
Added changes in shader to show the start of the support walls too along with the model walls

CURA-11227
2024-04-23 14:28:35 +02:00
c.lamboo
1046b24ee5 Fix crash in similation view
CURA-11758
2024-03-20 11:14:16 +01:00
Remco Burema
d441130e3b Defensive programming: Fix current path can be None.
should fix CURA-11741 (sentry cura '708')
2024-03-19 10:43:11 +01:00
Remco Burema
778bd11a71
Review comments to add a comment.
Done as part of CURA-11521
2024-03-13 11:13:03 +01:00
Remco Burema
5dcab95358
Code review: change name to 'vertex_distance_ratio'.
To be better in line with the other variables.

Done as part of CURA-11521

Co-authored-by: Saumya Jain <70144862+saumyaj3@users.noreply.github.com>
2024-03-13 11:10:04 +01:00
Remco Burema
d6295171dd Add the last line (when time-sim active) as a separate batch instead.
part of CURA-11521
2024-03-13 08:43:41 +01:00
Remco Burema
6e75eb34af Make lines update in real-time in the simulation-view too.
This approach does suffer from returning to exactly the same point, which can mess up the view.

part of CURA-11521
2024-03-12 23:38:09 +01:00
Erwan MATHIEU
c944903029 Fix crash after re-slicing
CURA-11438
2024-01-24 12:49:17 +01:00
c.lamboo
18302d6213 attempt to fix binary search 2024-01-07 11:10:22 +01:00
saumya.jain
ee7ecc1acc offset removed
CURA-7647
2024-01-03 09:16:04 +01:00
saumya.jain
0bb1f0b7c3 Case of simulation with multiple extruders
CURA-7647
2024-01-02 12:05:55 +01:00
saumya.jain
632c10db51 Guard against index for edge case
CURA-7647
2023-12-27 10:12:40 +01:00
c.lamboo
7fab301866 Guard against index out of bound
CURA-7647
2023-12-22 18:02:23 +01:00
saumya.jain
411b40d78c Simulation speed made 3X
case where no polygon in layer is also addressed

CURA-11289
2023-12-22 10:37:51 +01:00
Saumya Jain
152cb27232
Update plugins/SimulationView/SimulationView.py
review fix

Co-authored-by: Casper Lamboo <c.lamboo@ultimaker.com>
2023-12-21 14:30:43 +01:00
saumya.jain
0de4f612b3 fixing review comments. Cache only for the current layer
CURA-7647
2023-12-21 14:13:16 +01:00
saumya.jain
3f8908f53a cleanup
CURA-7647
2023-12-21 10:42:52 +01:00
saumya.jain
e2e94b7f6b fps made 15 for lower GPU load
- reinitialisation of cummulative_time for new model

CURA-7647
2023-12-21 10:33:05 +01:00
saumya.jain
41efdbabe0 Path change possible by user
- simulation speed increased
- no buffering in between layers
- fps made 30
CURA-7647
2023-12-20 18:16:04 +01:00
saumya.jain
cfec5e0cc1 Proof of concept for simulation
Co-authored-by: Casper Lamboo <c.lamboo@ultimaker.com>

CURA-7647
2023-12-19 10:12:56 +01:00
saumya.jain
84565b7daa removal of magic number
CURA-7647
2023-12-12 16:53:34 +01:00
saumya.jain
a9aba2df74 maintenence.
CURA-7647
2023-12-12 16:06:22 +01:00
saumya.jain
3c0b9a65db removing commented code
CURA-7647
2023-12-12 14:59:41 +01:00