Commit Graph

67 Commits

Author SHA1 Message Date
bubnikv
5d2537af35 WIP: Transformations of an instance in world coordinate system
from the side panel.
2019-04-24 11:01:59 +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
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
Enrico Turri
50516e3b7d Attempt to fix Ctrl+C from 3D scene on Mac 2019-04-17 10:27:33 +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
Enrico Turri
d8f28bc31a Follow-up of 1fbdf7bdaa -> Fixed grabbers size for move gizmo and grabbers dragging size 2019-04-15 15:05:26 +02:00
bubnikv
80afb6da78 Fixed SLA clippling plane & picking. 2019-04-12 16:08:40 +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
bubnikv
112f218c03 Merge branch 'lm_sla_gizmo_clipping_plane' 2019-04-11 15:45:49 +02:00
bubnikv
4a210aeecf Vojtech's improvements in the SLA preview cutting dialog. 2019-04-11 15:44:32 +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
bubnikv
7b8b8b97ef Fixed Cmd-A selection in the SLA gizmo. 2019-04-10 10:16:04 +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
Enrico Turri
6ca49c05df Merge branch 'master' of https://github.com/prusa3d/Slic3r into et_canvas_gui_refactoring 2019-04-05 11:55:56 +02:00
Vojtech Kral
251747e6fa GLGizmoCut: Scale input field 2019-04-04 12:31:13 +02:00
Enrico Turri
6d9180ba92 Merge branch 'master' of https://github.com/prusa3d/Slic3r into et_canvas_gui_refactoring 2019-04-04 09:03:25 +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
Enrico Turri
89a0c84c83 Fixed conflicts after merge with master 2019-04-02 15:13:26 +02:00
Vojtech Kral
9d5eb2cd48 Fix build 2019-04-02 10:56:30 +02:00
Vojtech Kral
c542413962 imgui: More refactoring, cut gizmo window positioning 2019-04-02 10:36:24 +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
Enrico Turri
d87b478d60 Camera refactoring
1) All camera related OpenGL calls moved into class

2) The Camera class now stores the view matrix, the projection matrix and the viewport

3) The Camera class now exposes methods to get the camera orientation vectors, the camera position, the view matrix, the projection matrix and the viewport

4) All the code operating on the camera or requiring camera data has been modified to use the new methods
2019-04-01 10:00:10 +02:00
Enrico Turri
1ce3bb690c Merge branch 'master' of https://github.com/prusa3d/Slic3r into et_canvas_gui_refactoring 2019-04-01 08:28:38 +02:00
Lukas Matena
32ed064797 SLA gizmo fix: occasional crashes after deleting objects 2019-03-29 13:38:33 +01:00
Enrico Turri
9b3f1a8942 Small refactoring -> GLGizmosManager gets model from selection and not from canvas 2019-03-28 09:30:01 +01:00
Enrico Turri
8459410e3c Fixed conflicts after merge with master 2019-03-27 14:57:05 +01:00
Enrico Turri
d795f07e7b Added glsafe() around OpenGL calls where missing 2019-03-27 14:42:09 +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
Enrico Turri
c44b6a30f9 Fixed conflicts after merge with master 2019-03-27 12:51:40 +01:00
Enrico Turri
000542f48d Merge branch 'master' of https://github.com/prusa3d/Slic3r into et_canvas_gui_refactoring 2019-03-27 08:33:48 +01:00
Enrico Turri
fee0a6b6b5 void GLCanvas3D::update_gizmos_data() moved into void GLGizmosManager::update_data(GLCanvas3D& canvas) 2019-03-26 15:55:47 +01:00
Enrico Turri
1fbdf7bdaa Gizmos' grabbers size made uniform as the mean value of the selection's bounding box sides 2019-03-26 14:53:32 +01:00
Enrico Turri
47c39f51e5 Handling of gizmos related key events moved into new method GLGizmosManager::on_key() 2019-03-26 14:38:30 +01:00