Commit Graph

5595 Commits

Author SHA1 Message Date
0f6182d5a6 Fix of #6650 - show estimated print time on ruler is not working
+ Parent center of the MessageDialogs
2021-06-24 13:59:48 +02:00
3773ebe354 Fixed after removing TBB deprecated APIs 2021-06-23 15:24:05 +02:00
50b4f08e37 drop deprecated TBB components (#6590)
Quite some time ago, many of the TBB components were deprecated in favor
of their near-equivalents in the STL or, in the case of task_scheduler_init,
were broken up and reconstituted under a less ad-hoc logic. Every time a header
file marked deprecated gets included, a rather loud warning is emitted, which
leads to a complete TBB's domination over the stderr stream during build time,
making it harder to notice _legitimate_ warnings.

Instead of merely muting the output with TBB_SUPPRESS_DEPRECATED_MESSAGES,
perform a genuine migration away from the deprecated components with the added
benefit of achieving a source compatibility with oneTBB, the successor to TBB
which has dropped the deprecated API for good.

What got replaced for what?

| Deprecated				| Replacement					|
| ------------------------------------- | --------------------------------------------- |
| `tbb::atomic`				| `std::atomic`					|
| `tbb::mutex`				| `std::mutex`					|
| `tbb::mutex::scoped_lock`		| `std::scoped_lock<std::mutex>`		|
| `tbb::mutex::scoped_lock` (empty)	| `std::unique_lock<std::mutex>` (deferred)	|
| `tbb::task_scheduler_init`		| `tbb::global_control`				|
| `tbb::this_thread`			| `std::this_thread`				|

Signed-off-by: Roman Beranek <roman.beranek@prusa3d.com>
2021-06-23 11:48:48 +02:00
198b5f21b9 Fixed warning 2021-06-23 10:30:15 +02:00
44a8032917 Fixing previous commit 2021-06-22 10:05:03 +02:00
e31e3dc00f Win32 specific: SEH handler on background thread. Catches Windows
structured exceptions (hard crashes, segmentation faults...),
converts them to Slic3r::HardCrash exceptions and displays the exception
using the usual PrusaSlicer way.
The SEH handler is installed on the main background slicing thread
as of now, therefore hard crashes in TBB worker threads are not handled.
2021-06-22 09:54:08 +02:00
8863e34917 DoubleSlider: Fixed out of range assert 2021-06-21 14:30:28 +02:00
52dd514295 Fixes Linux (and probably MacOS) build: wx/msw/registry.h is only available on Windows. (#6634) 2021-06-19 11:45:48 +02:00
313742997c Some code beautification for the last commit
+ Fix of the TabPresetComboBox layout for "light mode" + "tabs as a menu items" preferences
2021-06-18 21:54:20 +02:00
ffd33d6494 DarkMode for MSW (#6632)
* MSW specific: Dark Mode: First implementation

* Use menu instead of NoteBook

* Implemented MessageDialog
+ Fixed DarkMode for all dialogs and ColorPicker

* MSW DarkMode: Added missed updates for the switching between modes

* MSW DarkMode: Updated all existed context menus after switching of the mode
+ Added markers for the menu item witch is related to the selected tab

* Used wxFrame instead of wxDialog for SettingsDialog
(this change allow us to use menu bar in SettingsDialog)

+ fix for #6548 - Prusa Slicer 2.3.1 not activating non-modal settings window if settings window is minimized

* Implemented "Always use Dark mode colors" preference option

* Fixes for non_MSW build

* Next fixes for non-MSW builds

* Preferences: Fixed selection of the Settings Layout for non-MSW platforms
+ Updated DarkMode for colorpickers

* Windows DarkMode next fixes

* MSWDarkMode: Suppress to use system color to the PrusaSlicer
Select "Preferences -> Use Dark color mode (experimental)" to allow dark mode for the application

* Fixed MSW build

* MSWDarkMode: Upadteed color mode for ExtruderSequenceDialog and for dialogs related to the DoubleSlider

* Implemented Auto recreation of the PrusaSlicer when color mode is changed.

* Preferences: Added option "Set settings tabs as menu items (experimental)"
2021-06-18 19:46:04 +02:00
54f84010b3 Follow-up e3000c5305 - Fixed OSX build 2021-06-18 12:22:59 +02:00
fc39dfcf49 Implementation of the FR #3856 - Add option to replace stl in object list (right panel) 2021-06-17 21:29:18 +02:00
35a30fe65b Fixed the following crash:
1) Start PrusaSlicer

2) Add a box to the plater

3) Open Seam Painting or Paint - on supports gizmo

4) Save project

->crash
2021-06-17 08:16:54 +02:00
c2f2fd0234 Follow up 0b5ea8f429
- Un-select random sequence by default
- Added a check for interval height. It have to be bigger then print layer height
2021-06-16 18:20:26 +02:00
d7e663e2ef Fixed a multi-material painting gizmo crash when extruders colors aren't initialized, which happens when switching between SLA and FDM printer. 2021-06-16 17:05:24 +02:00
e3f18b4fc3 Fixed incorrectly displayed custom supports and seams in the support and seam gizmos after 7377fc34ac. 2021-06-16 13:41:35 +02:00
83af107009 Fixed an issue for multi-volume objects where the seed fill visualization in the multi-material gizmo didn't disappear after the mouse was moved to another volume. 2021-06-16 06:06:34 +02:00
8fbd9f40e7 Refactoring and cleanup of painting gizmos. 2021-06-16 06:06:34 +02:00
ce2c69676c Modified MMU painting gizmo behavior so that all triangles aren't painted by default by the first extruder, which was causing several problems.
This commit also fixed the following issues:
1) After loading a 3MF with painted triangles using the MMU painting gizmo, the painted triangles might not be displayed correctly in the MMU painting gizmo.
2) The MMU segmentation was unnecessarily executed for all layers and not just for the painted layers.
3) Object's base color wasn't changed when the assigned extruder for that object was changed while the MMU paint gizmo was opened.
4) Changing the base color of an object was only possible by removing all painted triangles.
2021-06-16 06:06:34 +02:00
8079bf0139 Fixed a possible crash when closing the MMU painting gizmo cause by a non-virtual destructor. 2021-06-16 06:06:33 +02:00
7c58250e5b Fixed cracks in MMU painting gizmo. All triangles, even not painted triangles, are now rendered inside MMU painting gizmo.
The cracks were caused by using glPolygonOffset to resolve Z-fighting. All triangles of the object were firstly rendered entirely with a base color. And then paint triangles were drawn over these already rendered triangles.
2021-06-16 06:06:33 +02:00
1316e17053 Follow-up of 39fd8065a1: Apply changes also for MMU painting gizmo, so shader->start_using() is called only once. 2021-06-16 06:06:33 +02:00
bea06e46a3 Show info about multi-material segmentation in ObjectList. 2021-06-16 06:06:33 +02:00
3bf82f2204 Random extruder sequence for MMU.
Related to https://github.com/prusa3d/PrusaSlicer/issues/1866
2021-06-15 12:38:05 +02:00
611ea4383d TriangleSelector - some memory optimization.
Don't store traingle normal, but reference the source triangle,
which stores its normal.
2021-06-11 12:27:58 +02:00
eb7ce6429b Code refactoring to avoid a call of update_ui_from_settings() every time when switching between "3D-View" and "Preview" 2021-06-11 10:34:13 +02:00
a9430f2f3f TriangleSelector::get_facets() refactoring to share vertices.
TriangleSelector::valid refactored to m_valid and valid()
and bool members moved next to each other to shrink data structure
size due to memory alignment.
2021-06-10 12:43:31 +02:00
872b1c6c5e Fixed a bug in update of the ObjectList when switching between 3d-View and Preview
Steps to repro:
1. start PrusaSlicer
2. add a box
-> watch the object list: only one item is shown in the list
3. switch to preview
-> the item in the object list gets a child
2021-06-09 17:21:39 +02:00
9fa6016324 Follow-up of 2d9953069a 2021-06-08 15:10:01 +02:00
d697ee9d7d Merge branch 'tm_its_refactor_3' 2021-06-08 12:22:28 +02:00
75f0b81bdd Do not close application when user select 'Cancel' in the save dirty project dialog 2021-06-08 11:51:41 +02:00
0ecba516a3 Get rid of Contour3D 2021-06-08 10:28:23 +02:00
c451fc94ba Refactored hollowing backend to use indexed_triangle_mesh 2021-06-08 10:28:23 +02:00
cf1731feea Tech ENABLE_ALLOW_NEGATIVE_Z -> Added threshold to detect if an object is sinking 2021-06-08 10:07:47 +02:00
55658979b7 Fixed two more locales-related issues
One warning was also fixed
2021-06-07 12:31:41 +02:00
d9e9e76467 #6587 - Fixed temporary .gcode file locked by gcode window visualizator while exporting to gcode 2021-06-07 11:54:16 +02:00
41cbb28062 Remove const_cast<> introduced with 0e3090fb28 2021-06-04 16:53:05 +02:00
8480895d40 Remove const_cast<> introduced with 4da8de5f49 2021-06-04 10:23:31 +02:00
800f031202 Fixed clipping plane when used with painter gizmos (follow-up of 94877a0) 2021-06-04 09:34:55 +02:00
5e1a9a728f Added name for items in undo/redo stack inside multi-material gizmo. 2021-06-03 18:11:48 +02:00
83b14502a6 Fixed the wrong transformation matrix for "Clipping of view" when is used a printer with multiple extruders. 2021-06-03 08:00:46 +02:00
392bf4f2d0 Follow-up 7eebd56b5f - fixed a typo
+ added add_negative.svg for dark mode
2021-06-02 14:36:49 +02:00
611b91bc1f Fixed DnD for "Model part" volumes inside the object
Fixed volumes order inside the object
2021-06-02 12:54:56 +02:00
2eba5223fa Removed unnecessary const_cast calls inside Camera. 2021-06-02 12:19:55 +02:00
ebcd48a725 Fixing a regression crash in Preset Hints. 2021-06-02 11:28:55 +02:00
54b4459a29 Merge remote-tracking branch 'remotes/origin/master' into vb_print_regions 2021-06-01 12:46:37 +02:00
1a9b72eb5e Show sequential print clearance regions when Move/Rotate/Scale gizmos are active 2021-06-01 11:36:12 +02:00
5681489621 Merge remote-tracking branch 'remotes/origin/master' into vb_print_regions 2021-06-01 11:19:53 +02:00
da95f2a753 New parameter "Slicing Mode" for supporting 3DLabPrint airplane models.
S3D's strategy for merging self intersecting models is "Even / Odd"
which PrusaSlicer now supports as an alternative to "Positive" rule.
Also added a "Close Holes" option to fill in all internal structures.
3D-Labprint Models aren't sliceable (till years) #3062 #3708
2021-06-01 11:10:12 +02:00
862eac6589 Changed logic to avoid saving a project while a gizmo is in editing mode 2021-06-01 08:32:58 +02:00