Commit Graph

37 Commits

Author SHA1 Message Date
Vojtech Bubnik
f58ee46687 WIP Refactoring of exceptions:
1) All slicer's exceptions are now derived from Slic3r::Exception.
2) New exceptions are defined for slicing errors.
3) Exceptions are propagated to the Plater to show.
It remains to modify the slicing back-end to throw the new SlicingError
exceptions instead of std::runtime_error and to show the other exceptions
by a message dialog instead of a notification.
2020-09-14 18:03:22 +02:00
enricoturri1966
90b78deae6 Refactoring to allow to quickly build the various options to show the estimated printing time in gcode viewer scene 2020-08-05 15:43:46 +02:00
enricoturri1966
6287e13e13 ENABLE_GCODE_VIEWER -> Partial refactoring in preparation for removal of old time estimator 2020-07-21 09:34:54 +02:00
enricoturri1966
2ab525e82b ENABLE_GCODE_VIEWER -> Integration of time estimator into GCodeProcessor 2020-07-16 11:09:21 +02:00
enricoturri1966
32e5d73a53 GCodeViewer -> Added imgui dialog for estimated printing times 2020-07-08 13:33:50 +02:00
YuSanka
06dacd1c84 Editing of the custom GCodes like ColorChange and PausePrint 2020-06-07 22:42:54 +02:00
Lukas Matena
e8e004ab5e Fixed few warnings 2020-05-26 16:06:11 +02:00
enricoturri1966
37cc7f9ea5 3rd attempt to fix build on AppleClang 2020-04-02 08:11:25 +02:00
enricoturri1966
feaa214f8b Follow-up of cfb6ac76fc - Another attempt to fix the build on AppleClang (std::array in lambdas) 2020-04-01 16:47:35 +02:00
enricoturri1966
31d57c4b31 Fixed build on AppleClang 2020-04-01 15:54:25 +02:00
enricoturri1966
70da70cc9c Fixed conflicts after merge with master 2020-04-01 15:06:30 +02:00
bubnikv
7bddfde708 Optimization of the GCodeTimeEstimator to only keep a fixed number
of trapeziodal blocks around. The number is hard coded to 64,
and 3x64 blocks are flushed everytime the queue grows over 4x64 blocks.
This time estimator is slightly more close to what the firmware does, which
keeps a fixed number of blocks and it recalculates all the blocks
every time a new block is added while the oldest block is pushed out
of the queue. Therefore this optimization shall produce negligible
differences to what the previous code produced.
2020-04-01 13:42:26 +02:00
Enrico Turri
378db9fbda Reduced ram used by GCodeTimeEstimator by removing unused data from GCodeTimeEstimator::Block 2020-03-05 14:58:03 +01:00
Enrico Turri
fd88644755 Reduced ram used by GCodeTimeEstimator by removing unused redundant data from GCodeTimeEstimator::Block::Trapezoid 2020-03-05 12:16:58 +01:00
YuSanka
422e7e818e Implemented time estimation for PausePrint (#3544)
DoubleSlider: fixed get_color_for_color_change_tick()
2020-02-20 17:33:43 +01:00
bubnikv
8d4f8375f5 Fix of d81f7d8465
(SlicedInfo: Removed secondes from estimated times):
GCodeTimeEstimator::_get_time_dhm() shall round to minutes, old
code rounded down to minutes, new code rounds to 1/2.
2020-02-10 14:40:21 +01:00
YuSanka
b3445d2d01 SlicedInfo: Removed secondes from estimated times 2020-02-10 12:52:32 +01:00
Enrico Turri
16782b488c Fixed GCodeAnalyzer and GCodeTimeEstimator to avoid artifacts while rendering toolpaths due to numerical issues on extruder coordinate 2020-01-13 15:27:37 +01:00
Enrico Turri
e12702de8c ENABLE_GIT_3010_FIX set as default 2019-10-14 10:03:27 +02:00
Enrico Turri
346a773f91 Fixed crash into GCodeTimeEstimator::post_process() while processing custom end g-code 2019-10-02 09:38:19 +02:00
Enrico Turri
33057ee090 #3010 - Added tech ENABLE_GIT_3010_FIX - GCodeAnalyzer and GCodeTimeEstimator modified to properly process gcode lines G92 2019-10-01 09:48:42 +02:00
Enrico Turri
8c76b3888d Improved time estimator post-processing 2019-09-05 09:54:44 +02:00
Enrico Turri
c9f6db630e Temporary human readable form for print color change tag for time estimate 2019-08-21 16:06:56 +02:00
Enrico Turri
7b1cb9a5e2 GCodeTimeEstimator uses annotated gcode in place of processing m600 lines to detect color print changes.
WARNING -> After this commit the exported gcode will contain the extra lines used by the time estimator. They will be removed by a future commit when a new post-process method will be implemented.
2019-08-21 14:43:14 +02:00
bubnikv
08d001931b Reworked the rename_file() function on Windows to work reliably and
atomically. The code was taken from the llvm project, it is complex
and hopefully it covers all the Windows file system quirks. Vojtech
has highest hopes, that this will fix the various PrusaSlicer.ini
file corruptions.

Enabled the locales switching and error handling on Linux as well,
where now the missing locales are reported and running the locale-gen
tool is recommended.
2019-08-20 16:19:30 +02:00
Enrico Turri
9c95deef96 Follow-up of c791ba776f -> Estimated times for color print layed-out as 'time for color (remaining time at color start)' 2019-08-03 08:51:03 +02:00
Enrico Turri
e7234c1002 Added absolute time to estimated time for color print and fixed a bug in showing estimated times for print color for silent mode 2019-08-02 12:05:02 +02:00
Enrico Turri
96ea3c6de8 Color change time estimates 2019-07-08 08:40:20 +02:00
Enrico Turri
1797bd1591 #2433 - Time Estimator: clamp accelerate/decelerate distances to avoid them to become negative 2019-06-24 12:35:20 +02:00
Enrico Turri
ed17290bc4 Fix of #1380 - Wrong estimated time when using extruder absolute coordinates 2019-04-15 12:54:57 +02:00
Enrico Turri
621808ff8a Fix of #2082 -> Added lines M73 P100 and M73 Q100 to gcode to signal that print is finished 2019-04-08 11:54:58 +02:00
bubnikv
8a03d85fec Fix of G-code remaining times export, that I broke with my optimizations. 2018-12-19 12:02:17 +01:00
bubnikv
6464dfc470 Logging of memory usage for the GCodeAnalyzer and GCodePreviewData. 2018-12-18 15:55:45 +01:00
bubnikv
038b56aaa2 Time estimator: Added consumed memory tracing, replaced std::map
with std::vector for lower memory consumption.
2018-12-18 14:10:31 +01:00
bubnikv
89678fb2fe Fixed M203 processing by the time estimator for Smoothieware.
Fixes "Print time estimate incorrect for Smoothie flavor with M203 #1259"
2018-12-17 09:57:24 +01:00
Enrico Turri
1d4d84e432 New selection -> removed obsolete methods\n+\nFixed a few compile warnings 2018-10-08 15:17:36 +02:00
bubnikv
1260b8deb3 WIP: Moved sources int src/, separated most of the source code from Perl.
The XS was left only for the unit / integration tests, and it links
libslic3r only. No wxWidgets are allowed to be used from Perl starting
from now.
2018-09-19 11:02:24 +02:00