Lukas Matena
52ab8a5f19
Wipe tower fix (do not skip the first toolchange when printing without the wipe tower)
...
Also, test multi.t updated so it matches new logic of inserting custom gcodes
2019-07-16 13:10:09 +02:00
Lukas Matena
dc80616bf6
Fixed a use-after-free problem in object list
...
this was uncovered by ASAN when attempting to Delete All objects with multiple instances
2019-07-15 17:09:06 +02:00
Lukas Matena
004e2719b1
Merge branch 'master' into lm_warnings
2019-07-15 13:26:55 +02:00
Lukas Matena
63cf5edf28
Updated tooltips on custom gcodes to match actual PrusaSlicer behaviour to reflect recent changes
2019-07-15 11:49:30 +02:00
Lukas Matena
e674c586b0
Merge branch 'lm_improving_wipe_tower'. Summary of changes:
...
- wipe tower respects max volumetric flow, slowing down with PVA etc is not hardcoded anymore
- wipe tower is now allowed for multiple-extruder printers. single extruder stuff is not used in that case (ramming, cooling, etc.)
- start/end filament and toolchange custom gcodes are now inserted differently than before - see 41164a9
- some refactoring, e.g. the abstract WipeTower class was eradicated
2019-07-15 10:25:38 +02:00
Lukas Matena
45db42ca3b
Merge branch 'lm_drop_to_bed'
2019-07-12 13:38:18 +02:00
Lukas Matena
2ee572bd31
GCodeAnalyzer now recognizes tool-changing commands with MakerWare and Sailfish flavor
...
These firmwares use M135 Tn and M108 Tn commands for changing active tool, which the analyzer did not recognize. The toolpaths were then rendered in wrong color, extruder offset etc. This surfaced in issue https://github.com/prusa3d/PrusaSlicer/issues/2566
2019-07-12 12:56:41 +02:00
Lukas Matena
4b9e366f00
Multimaterial print - making sure that temperatures will be changed with SE printer without the wipe tower
2019-06-26 14:50:12 +02:00
Lukas Matena
d2136ab625
ObjectList no longer caps number of extruders to 9 (fixes https://github.com/prusa3d/PrusaSlicer/issues/2558 )
2019-06-26 13:12:25 +02:00
Lukas Matena
d845332de1
Fixed a crash when using place to bed function with the layer editing active
...
This was caused by trying to render a deleted layer height profile. Other gizmos were
not affected because they are not dragging at the time of their action, so the profile
was correctly recalculated for them.
2019-06-26 11:51:18 +02:00
Lukas Matena
cb916c4dda
Fixed warnings in libslic3r
2019-06-25 16:04:29 +02:00
Lukas Matena
471331e8c1
CMake: -Wignored-attributes is not supported in GCC<6.1
...
-turned off -Wunknown-pragmas for GCC
2019-06-25 16:04:24 +02:00
Lukas Matena
743a08f0cf
WipeTower - fixed a crash in extrude_explicit when called from finish_layer before the first toolchange
2019-06-21 10:58:20 +02:00
Lukas Matena
82de7bedb1
WipeTowerDialog.cpp - wxEXPAND conflicted with wxALIGN_CENTER_HORIZONTAL (triggered a wxWidgets assert)
2019-06-19 14:52:42 +02:00
Lukas Matena
0481f33ceb
Drop to bed function now accounts for instance transformation
2019-06-19 11:53:08 +02:00
Lukas Matena
3d8c3804fa
Added 'drop to bed' button into object manipulation panel
2019-06-19 11:04:12 +02:00
Lukas Matena
5a1e1bc10c
GUI_ObjectManipulation.cpp - Removed implicit capture by value in some of the lambdas
2019-06-19 11:04:12 +02:00
Lukas Matena
95ad76a0dc
Wipe tower - fixed a long existent bug that sometimes resulted in inexact feedrate on the loading moves
2019-06-17 12:59:30 +02:00
Lukas Matena
1152bd5a09
Fixup of 41164a9
...
The WipeTowerWriter did not now which tool is being used, so it limited the volumetric flow based on different filament settings
2019-06-17 11:22:17 +02:00
Lukas Matena
a643a22151
Wipe tower - renaming files (to conclude work from previous commit and not lose history of those files)
2019-06-17 10:26:33 +02:00
Lukas Matena
05e6dbbe4b
Wipe tower - refactoring (removed the abstract WipeTower class)
...
- abstract class WipeTower and its descendant WipeTowerPrusaMM were merged into a single (non-abstract) WipeTower class
- all uses of WipeTower::xy struct were replaced by Eigen Vec2f (it is no longer necessary to be independent on libraries that PrusaSlicer uses)
- the WipeTowerPrusaMM.hpp/.cpp will be renamed in the next commit (hopefully it will retain its git history that way)
2019-06-17 10:16:07 +02:00
Lukas Matena
7b07a8da83
Reset buttons: synchronization of instances/volumes
2019-06-14 15:28:09 +02:00
Lukas Matena
980c6673d4
Reset buttons - fixed rotation of instances with multiple volumes
...
Mirroring buttons now hide where appropriate
2019-06-14 15:28:09 +02:00
Lukas Matena
a3c1644ead
Added mirroring buttons into object manipulation panel
2019-06-14 15:03:42 +02:00
Lukas Matena
9f236bc603
Added transformation reset buttons in object manipulation panel
2019-06-14 15:03:42 +02:00
Lukas Matena
0eecfc6604
Wipe tower - removed the obsolete material_type enum
...
no longer necessary because the speed overrides that the enum controlled were recently removed
the comment in gcode is now just about appending the config string
2019-06-14 14:44:22 +02:00
Lukas Matena
678d0e18a7
WipeTowerIntegration class: print_z is not passed around, ToolChangeResult objects are aware of it
2019-06-14 14:43:40 +02:00
Lukas Matena
aee376762e
Changed handling of priming extrusions to allow injection of filament and toolchange custom gcodes
...
The priming extrusions were handled separately from the rest of the wipe tower toolchanges. In order to be able to use the logic from previous commit for them (custom toolchange gcodes etc), some unpleasant code shuffling was needed
2019-06-14 14:42:07 +02:00
Lukas Matena
41164a9cb3
Multimaterial printing: Changed the way how custom gcodes are inserted
...
Each toolchange now emits:
- end filament custom gcode
- toolchange custom gcode; if not provided, a standard Tn command is inserted
- start filament gcode
Hopefully it is now consistent for SE/ME printers with/without the wipe tower
The priming line does not work - will be fixed in the next commit
2019-06-14 14:38:58 +02:00
Lukas Matena
9df93c0125
Mostly refactoring of the wipe tower improvements
...
- setting of the wipe tower parameters based od whether SE MM printer is selected is done in the WipeTowerPrusaMM constructor, so it does not distract in Print.cpp
- WipeTowerPrusaMM.cpp conditions checking for SE MM printer are now using a more descriptive const member variable, not the loading/unloading speeds (hopefully the functionality is the same)
2019-06-14 14:35:50 +02:00
Lukas Matena
079e63e190
The wipe tower now respects filament max volumetric flow
...
The odd commands that lowered the speed override values for PVA, FLEX etc. were removed
Now the wipe tower backups user speed override, sets it to 100%, does what is needed
and restores the old value when finished. There are no special cases - lowering
the speed for certain materials can be achieved by lowering the volumetric flow.
2019-06-14 12:28:52 +02:00
Lukas Matena
6f7051c3b1
GCode preview shows correct volumetric flow for the wipe tower
...
The neccessary annotations for the GCodeAnalyzer were missing
2019-06-14 12:28:52 +02:00
Lukas Matena
66a56941a5
SLA dialog: Prevented the slider to have zero width, even in case the text width is calculated incorrectly
2019-05-27 15:36:51 +02:00
Lukas Matena
07282eb24d
Fixed unit tests when run with range checks on std::vector
...
There was a bug in unit tests that led to generating the wipe tower with non-normalized preset.
This caused out-of-bounds access into max_layer_height vector in fill_wipe_tower_partitions.
The problem surfaced in https://github.com/prusa3d/PrusaSlicer/issues/2288 .
I quickly patched additional normalization of the preset to prevent this from happening.
Also, an assert in the same function turned out to trip on one of the tests.
This one was commented out for now and will (hopefully) be looked into later.
Function Print::apply_config was renamed to apply_config_perl_tests_only so everyone
sees its current purpose and does not mistake it for the more important Print::apply.
2019-05-22 16:48:20 +02:00
Lukas Matena
03a62e5721
Fixed rendering of support points in SLA gizmo for mirrored objects
2019-05-20 16:33:57 +02:00
Lukas Matena
1e99454602
Hopefully fixed SLA dialog scaling issues on OSX
2019-05-13 15:10:01 +02:00
Lukas Matena
76c3da9aba
An attempt to fix the SLA gizmo dialog so it does not crop long description on the sliders
2019-05-13 15:10:01 +02:00
Lukas Matena
5dbcec5126
Turn off the SLA gizmo when switching to FFF printer profile
2019-05-10 11:32:30 +02:00
Lukas Matena
cf3b992269
GCode.cpp: Update the 'current_extruder' placeholder even if filament start gcode is empty
2019-05-06 14:48:59 +02:00
Lukas Matena
e9a53e49db
Arrange is accounting for the wipe tower now
2019-05-06 08:14:45 +02:00
Lukas Matena
5f226c5d7f
Allow wipe tower rotation by the rotation gizmo
2019-05-06 08:14:45 +02:00
Lukas Matena
3ec17fae67
A hotfix for #2179 (GCode preview crash on T-1 in GCode)
2019-04-29 14:26:46 +02:00
Lukas Matena
ae692635da
Selection rectangle moved into a separate class
2019-04-24 13:25:41 +02:00
Lukas Matena
08cb5bc2c7
Wipe tower uses correct gcodes for RepRap gcode flavor (M907->M906, M900->M572 - should fix #1843 )
...
Also, fixed proper setting of the extruder current during toolchange (was broken since 6da83c7 )
2019-04-24 12:09:58 +02:00
Lukas Matena
7185125f9c
Fixed out-of-bouds access in RammingChart.cpp in case the ramming was turned off
2019-04-24 10:12:23 +02:00
Lukas Matena
55c07394e5
Added dialog with shortcuts to the SLA gizmo, tried to improve the dialog look
2019-04-18 15:46:35 +02:00
Lukas Matena
cfbd7f8093
Fixed conflicts after cherry-picking c8b4aa5a786e579abfdbf800b5eb1a0f0b04ff92
2019-04-18 10:32:47 +02:00
Lukas Matena
0c1e223414
SLA gizmo clipping plane is now not necessarily perpendicular to camera direction
2019-04-17 14:27:20 +02:00
Lukas Matena
8df2a19974
SLA clipping plane can now be controlled by Ctrl + mouse wheel rotation
2019-04-17 14:27:20 +02:00
Lukas Matena
19759b4315
SLA gizmo clipping - changed color on the cuts of supports, turned their rendering in editing mode (when the supports are not shown)
2019-04-17 09:39:51 +02:00
Lukas Matena
63ce3c3150
SLA gizmo now does not make redundant copies of the object and supports meshes
2019-04-16 09:04:04 +02:00
Lukas Matena
f33e9bf609
TriangleMeshSlicer is now initialized by const-pointer to the mesh, responsibility for calling require_shared_vertices is left to the caller
2019-04-16 09:04:04 +02:00
Lukas Matena
a177a7e1da
SLA gizmo clipping now also triangulates the cuts on support structure
2019-04-16 09:04:04 +02:00
Lukas Matena
4abcf7bec4
SLA gizmo dialog height increased so the new clipping plane slider fits
2019-04-12 14:25:41 +02:00
Lukas Matena
096d23f971
SLA gizmo fix: Discarding manual edits on autogenerated points removed all the points from the gizmo cache
2019-04-10 15:27:44 +02:00
Lukas Matena
678c513cb9
Merge branch 'master' into lm_sla_gizmo_clipping_plane
2019-04-10 13:43:02 +02:00
Lukas Matena
e6439ad010
SLA gizmo fix: recalculation of the mesh was sometimes skipped
2019-04-10 13:33:58 +02:00
Lukas Matena
3a09f66e51
Fixed a literal in vertex shader that refused to compile on OSX
2019-04-08 16:05:18 +02:00
Lukas Matena
f71e14a4d9
SLA gizmo now uses ctrl to add to selection and alt to remove from selection
2019-04-08 15:34:42 +02:00
Lukas Matena
837bc43c9f
SLA gizmo on_set_state code is now called through CallAfter to prevent repeated wxMessageDialog appearances (seen on OSX)
2019-04-08 11:56:13 +02:00
Lukas Matena
eadf7daa37
Merge branch 'master' into lm_sla_gizmo_clipping_plane
2019-04-08 10:50:10 +02:00
Lukas Matena
09cf1b9b00
Allowed general object transformation and SLA z-shift (clipping plane)
2019-04-08 10:31:53 +02:00
Lukas Matena
7531f2d5e7
Selection rectangle now respects the clipping plane position
2019-04-08 10:31:22 +02:00
Lukas Matena
bbda1896f9
The gizmo is now able to triangulate and show the cut, the triangulated cut is cached
2019-04-08 10:31:19 +02:00
Lukas Matena
9b7857aaab
SLA gizmo clipping plane logic moved to fragment shader
...
This means the clipping now works again with both legacy and modern OpenGL
2019-04-08 10:31:16 +02:00
Lukas Matena
273fcf68a1
SLA gizmo now uses glClipPlane instead of touching projection matrix
...
Messing with the projection matrix invalidates the z-buffer
This currently only works in OpenGL legacy mode
2019-04-08 10:31:13 +02:00
Lukas Matena
bc9164e40c
SLA gizmo now respects the clipping plane when rendering points and raycasting mouse onto mesh
2019-04-08 10:31:10 +02:00
Lukas Matena
fd1f9d65fb
First steps on SLA clipping plane
2019-04-08 10:31:04 +02:00
Lukas Matena
177f5b02fa
Disabled layer editing mode for SLA
2019-04-05 09:51:58 +02:00
Lukas Matena
69027b53fd
SLA gizmo now allows to deselect a point
2019-04-03 14:44:24 +02:00
Lukas Matena
2269e1b183
Deliberately setting the SLA dialog a bit too large
...
It is not possible to precisely calculate actual window size before the rendering, so I added a safety margin.
It would be nicer to let the window autoscale and only use the inflated dimension for possible moving the window upward to prevent collision with the bottom panel, but...
ImGui autoscaling does not work properly for some reason (the window size autoscales only after a mouse move), so this is a workaround.
2019-04-03 10:41:45 +02:00
Lukas Matena
e20ffbfd85
SLA gizmo uses CallAfter to trigger SLA supports calculation to prevent recursive rendering calls
2019-04-02 09:36:16 +02:00
Lukas Matena
5f66a2d181
SLA gizmo dialog now respects system font settings
2019-04-01 14:51:18 +02:00
Lukas Matena
32ed064797
SLA gizmo fix: occasional crashes after deleting objects
2019-03-29 13:38:33 +01:00
Lukas Matena
490074a2dd
SLA gizmo now turns off in case someone adds an object/instance (to prevent rendering points in thin air, etc.)
...
Also, a bug appering when adding an object larger than the bed and scaling it down was fixed (sla gizmo did not work correctly in that case)
2019-03-27 14:19:12 +01:00
Lukas Matena
3f7f8f978e
Fix of sla gizmo (it sometimes showed supports for hidden objects)
2019-03-24 13:35:09 +01:00
Lukas Matena
0848617fd3
SLA gizmo fix: adding points to selection by Shift+click should now work again (was broken by 8466c55)
2019-03-22 10:56:51 +01:00
Lukas Matena
8b73608e9f
SLA gizmo can be activated if the supports are outside the bed
...
Otherwise there is a possibility that the object gets out of bed when the gizmo is active (supports are generated with object close to the edge), which the gizmo does not expect
2019-03-20 15:37:13 +01:00
Lukas Matena
9f06dbd615
Added a mention of ASAN in the wiki
2019-03-20 15:19:27 +01:00
Lukas Matena
8466c55b78
SLA gizmo - points are added on leftdown event, not leftup as before
2019-03-20 14:04:59 +01:00
Lukas Matena
df01af975a
SLA gizmo now forces objects to use their normal color (not SELECTED_COLOR)
2019-03-20 14:04:20 +01:00
Lukas Matena
2728e45646
Renamed function mouse_event to gizmo_event
2019-03-20 13:44:34 +01:00
Lukas Matena
4ceba39d99
Decreased number of polygons on the SLA support point marks for faster rendering
2019-03-20 10:13:16 +01:00
Lukas Matena
e813a562a1
Removed technology ENABLE_IMGUI
2019-03-18 11:45:15 +01:00
Lukas Matena
d3c8e3166e
Separated gizmos into individual files
2019-03-18 11:45:15 +01:00
Lukas Matena
5f81328aa4
Fixed a case when the SLA gizmo did not calculate igl mesh and aabb tree even though it should
2019-03-15 18:40:49 +01:00
Lukas Matena
ef939905b1
Another fix of the gizmo grabber color picking
2019-03-15 11:04:08 +01:00
Lukas Matena
32c9e8b168
A small fix of the gizmo grabbers picking
2019-03-15 10:15:23 +01:00
Lukas Matena
2750a8113d
SLA gizmo now shows arrows pointing at the points so they are easy to see
2019-03-13 15:38:27 +01:00
Lukas Matena
03beb1870b
SLA gizmo - combo replaced by slider, autogeneration uses config value for head_diameter
2019-03-13 12:02:33 +01:00
Lukas Matena
63b65bb3c8
Wipe tower brim lines are now printed with overlaps as they should be
2019-03-13 10:46:50 +01:00
Lukas Matena
cbe96906eb
SLA support points are correctly appointed as user-modified
...
SLA gizmo point cache is reloaded when appropriate
2019-03-11 15:05:36 +01:00
Lukas Matena
e4dca04a4b
Added wxBusyCursor on AABB tree calculation for SLA gizmo
2019-03-08 20:34:22 +01:00
Lukas Matena
8b74cc48eb
Prevented instance move event when SLA gizmo is active so right panel is not needlessly updated
2019-03-08 09:26:42 +01:00
Lukas Matena
79fbf08409
An attempt to fix sla gizmo imgui dialog scaling on osx and hidpi screens
2019-03-06 10:11:02 +01:00
Lukas Matena
f147f192b4
Disabled object context menu when the SLA gizmo is active
2019-03-06 10:10:10 +01:00
Lukas Matena
2fe542e0fc
Merge branch 'lm_sla_gizmo_render'
2019-03-04 14:52:21 +01:00
Lukas Matena
02c68ed895
Prevented the sla gizmo dialog to overlap the bottom toolbar
2019-03-04 14:52:08 +01:00
Lukas Matena
9c5194c89b
An attempt to fix an OSX crash when manipulating the ImGui sliders
2019-03-04 12:47:02 +01:00
Lukas Matena
ee4496f59f
An attempt to fix an unwanted cancellation caused by improper frontend-backend data synchronization (SLA support points)
2019-03-01 16:17:23 +01:00