Commit graph

1551 commits

Author SHA1 Message Date
Leonardo Zide
ec4044dcfa Use QGraphicsScene::selectionChanged. 2021-01-15 14:43:31 -08:00
Leonardo Zide
d4084ffb00 Added step number properties. 2021-01-15 14:24:44 -08:00
Leonardo Zide
26c34e3609 Initial background color support. 2021-01-14 18:19:58 -08:00
Leonardo Zide
449f405d17 Offset minifig accessories a bit. 2021-01-14 15:24:17 -08:00
Leonardo Zide
a85bbec789 Updated deprecated functions. 2021-01-14 14:51:43 -08:00
Leonardo Zide
dce4aa0644
Fixed typo. 2021-01-14 10:09:49 -08:00
Leonardo Zide
9009a974ad Case insensitive submodel compare. Fixes #533. 2021-01-13 15:36:12 -08:00
Leonardo Zide
5febd5f25f Fixed parsing step number. Fixes #599. 2021-01-13 11:39:55 -08:00
Leonardo Zide
661d002109 Fixed /w4 not getting set. 2021-01-13 11:11:31 -08:00
Leonardo Zide
1b0a47f692 Fixed aarch compile error. 2021-01-12 18:29:11 -08:00
Leonardo Zide
8f30690ee2
Merge pull request #596 from sisco0/fix-compile-warning-reorder
Fixed initialization order at compile time
2021-01-12 15:47:46 -08:00
Leonardo Zide
f74c2cb71c Updated version string. 2021-01-12 15:40:44 -08:00
Leonardo Zide
548bb3fe16 Updated version number. 2021-01-12 15:12:48 -08:00
Leonardo Zide
2a156cf182 Removed instructions from menu. 2021-01-12 15:10:38 -08:00
Leonardo Zide
b8a8cb6730 Removed direct GL function calls. 2021-01-12 14:29:56 -08:00
Leonardo Zide
4e4fc504da Removed unused param. 2021-01-12 13:58:05 -08:00
Leonardo Zide
92227eda8b Removed unused variable. 2021-01-12 13:48:04 -08:00
Leonardo Zide
c92c423e3f Added option to color grid origin lines. Fixes #372. 2021-01-11 18:49:57 -08:00
Leonardo Zide
e873ba2a35 Split console output into stdout and stderr. 2021-01-11 09:54:56 -08:00
Leonardo Zide
7222e8db14 Fixed default preview placement. 2021-01-11 08:59:29 -08:00
Leonardo Zide
9a681bff0f Print message when saving files from the command line. 2021-01-10 18:07:27 -08:00
Francisco J. Solis-Munoz
bdd4dcdf3d Fixed initialization order at compile time 2021-01-10 19:59:01 -06:00
Leonardo Zide
f13e4ad056 Refactored command line parsing. 2021-01-10 17:45:28 -08:00
Leonardo Zide
5ca460c0bf Set default surface format before creating lcApplication instance. Fixes #594 , #577. 2021-01-10 11:03:54 -08:00
Leonardo Zide
6bfc4ff9b1 Removed Tex2DMS functions. 2021-01-09 18:01:03 -08:00
Leonardo Zide
a0867c9b80 Framebuffer cleanup. 2021-01-09 17:57:24 -08:00
Leonardo Zide
31ce044a65 Cleanup. 2021-01-09 16:37:32 -08:00
Leonardo Zide
138f749053 Use part color for wireframe lines. 2021-01-09 16:02:23 -08:00
Leonardo Zide
601eb56322 Fixed edge around parts list images. 2021-01-08 15:11:02 -08:00
Leonardo Zide
dbb4c9e44b QGLWidget cleanup. 2021-01-08 11:25:24 -08:00
Leonardo Zide
ab9df4a712 Require Qt 5.4. 2021-01-08 10:57:39 -08:00
Leonardo Zide
b70fab3059 Require Qt5. 2021-01-08 10:35:52 -08:00
Leonardo Zide
e6397a98ac Added background override. 2021-01-07 17:04:19 -08:00
Leonardo Zide
5058455666 Better page layout. 2021-01-07 11:48:43 -08:00
Leonardo Zide
ea83db6987 Added Page Setup Dialog. 2021-01-07 10:46:57 -08:00
Leonardo Zide
1abc81e02f Qt4 fix. 2021-01-06 18:02:56 -08:00
Leonardo Zide
f89ae87c26 Fixed runtime warning when saving images. 2021-01-06 17:55:38 -08:00
Leonardo Zide
f4461756bd Added Page Setup controls. 2021-01-06 17:45:38 -08:00
Leonardo Zide
5c2a5aa167 Dockable page list widget. 2021-01-06 14:06:15 -08:00
Leonardo Zide
2d5d719902 Fixed wrong signal. 2021-01-06 13:40:16 -08:00
Leonardo Zide
47661710db Don't create widgets when saving images from the command line. 2021-01-06 09:55:03 -08:00
Leonardo Zide
39af536301 Multiple rows/columns instructions. 2021-01-05 18:48:12 -08:00
Leonardo Zide
e6d2c6bdce Maybe clang fix. 2021-01-05 15:43:23 -08:00
Leonardo Zide
52ab6c4f59 gcc fixes. 2021-01-05 15:19:53 -08:00
Leonardo Zide
f9c025f3b9 Show preview widget when double clicking. Fixes #589. 2021-01-05 12:32:03 -08:00
Leonardo Zide
176b238faa Array cleanup. 2021-01-05 12:27:45 -08:00
Leonardo Zide
cb710206b7 Moved key functions into a separate class. 2021-01-05 11:26:01 -08:00
Leonardo Zide
660bb38bdd Fixed typo. 2021-01-03 15:01:28 -08:00
Leonardo Zide
098ee45e5b Better ortho zoom. 2021-01-03 12:19:57 -08:00
Leonardo Zide
725901e97e Fixed Qt4 error. 2021-01-03 11:26:47 -08:00
Leonardo Zide
28c27d8326 Fixed hidden floating dockwidgets flashing at startup. Fixes #588. 2021-01-02 10:49:56 -08:00
Leonardo Zide
cfe3fc0284 Fixed zoom extents direction. Fixes #587. 2021-01-02 10:40:30 -08:00
Leonardo Zide
80f5eb5582 Reorganized application shutdown. 2021-01-02 10:23:51 -08:00
Leonardo Zide
72763ddc11 Create offscreen context at startup and reuse it. 2021-01-01 18:41:28 -08:00
Leonardo Zide
6b2f8fa68c Viewpoint name parsing cleanup. 2021-01-01 15:04:27 -08:00
Leonardo Zide
3d77537408 Clear placeholder model mesh. Fixes #586. 2021-01-01 14:28:08 -08:00
Leonardo Zide
2e2b1f0bb5 Resize view before setting camera when saving images from the command line. 2021-01-01 12:14:30 -08:00
Leonardo Zide
6c06e329e6 Customizable marquee colors. Fixes #544. 2020-12-31 15:54:28 -08:00
Leonardo Zide
24f3bbb45a Better ortho zoom extents math. 2020-12-31 14:46:31 -08:00
Leonardo Zide
69cfc71f3b Removed global placeholder mesh. 2020-12-31 14:23:08 -08:00
Leonardo Zide
499e648673 Use individual bounding boxes for zoom extents. 2020-12-31 10:22:12 -08:00
Leonardo Zide
e99c776878 More readable startup code. 2020-12-30 18:22:02 -08:00
Leonardo Zide
9f6c0abf23 Set MSAA from application. 2020-12-30 16:43:23 -08:00
Leonardo Zide
98411ecebc Added text color option. Fixes #581. 2020-12-30 13:44:08 -08:00
Leonardo Zide
801aab7cce Show error message if save option used without a file name. 2020-12-30 11:06:38 -08:00
Leonardo Zide
12089cca33 Removed properties widget margins. 2020-12-30 10:48:51 -08:00
Leonardo Zide
7ec71d8602 Reorganized view sphere and preview options. Fixes #584. 2020-12-30 10:39:04 -08:00
Leonardo Zide
855ca66018 Removed margins. 2020-12-29 19:27:40 -08:00
Leonardo Zide
58981f9580 Added option to paint selected pieces. Fixes #561. 2020-12-29 19:20:03 -08:00
Leonardo Zide
3358553e1d Moved clear functions to context. 2020-12-29 15:32:11 -08:00
Leonardo Zide
80adb54acf Always keep 1 context valid. 2020-12-29 14:42:59 -08:00
Leonardo Zide
6cc91c0f20 Use offscreen context for the parts list. 2020-12-29 12:23:36 -08:00
Leonardo Zide
1367a5d6f4 Fixed parts list icons when MSAA is on but not supported. 2020-12-28 18:10:54 -08:00
Leonardo Zide
129e0f886f Compile fix. 2020-12-28 17:54:24 -08:00
Leonardo Zide
125d4a1349 Compile fix. 2020-12-28 17:41:56 -08:00
Leonardo Zide
4ed04e4e25 Use an offscreen buffer when saving images from the command line. 2020-12-28 17:30:41 -08:00
Leonardo Zide
985fb8b778 Fixed MSAA check. 2020-12-28 14:36:04 -08:00
Leonardo Zide
0499e055e1 Crash fix #578. 2020-12-28 12:08:10 -08:00
Leonardo Zide
7c9e3a34ee Don't show context menu when a clickable tool is assigned to the right button. 2020-12-28 10:42:51 -08:00
Leonardo Zide
542304f82e Use recalculated up vector. Fixes #574. 2020-12-28 10:16:40 -08:00
Leonardo Zide
7ef1d7b733 Fixed crash when MSAA is not available. Fixes #573. 2020-12-28 09:42:13 -08:00
Leonardo Zide
4e6cbca31c Switch to QOpenGLWidget. 2020-12-27 13:05:55 -08:00
Leonardo Zide
2ccdc85f00 Workaround for what looks like a Qt crash when closing the app with a floating preview. 2020-12-26 18:16:01 -08:00
Leonardo Zide
24c9335c7f Added Q_OBJECT. 2020-12-26 18:15:35 -08:00
Leonardo Zide
81fb79b805 Use fewer draw calls for the axis. 2020-12-26 16:30:28 -08:00
Leonardo Zide
81817ac4ad Merged duplicate preview view sphere settings. 2020-12-26 16:00:51 -08:00
Leonardo Zide
18ad850e1a Fixed preview overlays and zoom extents. 2020-12-26 12:10:14 -08:00
Leonardo Zide
ddd8405c7e Color entire axis arrows. 2020-12-26 11:53:35 -08:00
Leonardo Zide
c26b52ea5e Fixed preview axis. Fixes #571. 2020-12-26 11:44:41 -08:00
Leonardo Zide
17cada38b6 Warning fix. 2020-12-26 11:09:15 -08:00
Leonardo Zide
7de5d4eb22 Renamed view class. 2020-12-25 10:54:33 -08:00
Leonardo Zide
939e80ab4b Renamed view files. 2020-12-25 10:43:22 -08:00
Leonardo Zide
620ac457e5 Merged View and lcGLWidget. 2020-12-25 10:37:59 -08:00
Leonardo Zide
56daed4182 Removed OnInitialUpdate. 2020-12-24 17:14:36 -08:00
Leonardo Zide
c8eebe5d77 Detect files that have Name or Author on the first line. Fixes #568. 2020-12-24 12:10:47 -08:00
Leonardo Zide
e27b235936 Derive preview from view. 2020-12-24 11:32:56 -08:00
Leonardo Zide
72bb41e8aa Added shortcut to toggle the grid. 2020-12-23 19:10:54 -08:00
Leonardo Zide
95bf7e43ff Rotate view around the minifig center. 2020-12-23 18:45:34 -08:00
Leonardo Zide
bcfbaa3080 Crash fix. 2020-12-23 18:30:01 -08:00
Leonardo Zide
2718a4253c Cleanup. 2020-12-23 18:16:00 -08:00
Leonardo Zide
0282a88c87 Sort part counts numerically. 2020-12-23 18:07:12 -08:00
Leonardo
9f5782294e Fixed view preferred size. 2020-12-21 17:34:42 -08:00
Leonardo Zide
aa1d802c04 Removed strlwr. 2020-12-20 12:06:14 -08:00
Leonardo Zide
d1991b9264 Moved Minifig Dialog. 2020-12-20 11:24:50 -08:00
Leonardo Zide
f5ddd46776 Flush text stream before writing. Fixes #562. 2020-12-20 11:13:57 -08:00
Leonardo Zide
95bdf1a615 Fixed minifig wizard not updating. 2020-12-19 18:51:54 -08:00
Leonardo Zide
546ab19785 Cleanup. 2020-12-19 16:13:25 -08:00
Leonardo Zide
b77210db22 Use a regular View for the Minifig Wizard. 2020-12-19 16:05:29 -08:00
Raymond S Brand
fd24accea7 Fix warnings 2020-12-19 14:48:06 -08:00
Leonardo Zide
84af94164d Fixed warnings. 2020-12-19 11:12:31 -08:00
Leonardo Zide
228d17bd28
Merge pull request #559 from j6t/master
Small code modernization around file handling during parts loading.
2020-12-19 09:55:29 -08:00
Johannes Sixt
b176cb421b Keep ZIP file objects in std::unique_ptr<> to clarify ownership. 2020-12-19 10:52:57 +01:00
Johannes Sixt
ac9954972d Pass file objects in std::unique_ptr<> to clarify ownership. 2020-12-19 10:52:57 +01:00
Johannes Sixt
f3683ee93e Remove unused parts library pathname member variables. 2020-12-19 10:52:57 +01:00
Leonardo Zide
e5a8eebdb8 Try to place new pieces near existing parts or the origin #548. 2020-12-18 19:13:03 -08:00
Leonardo Zide
1925c476d6 Show more models in the menu. Fixes #558. 2020-12-18 16:34:11 -08:00
Leonardo Zide
baa0a70de2 Refactored duplicate code. 2020-12-18 12:15:35 -08:00
Leonardo Zide
dcf8ddfd95 Crash fix restoring layout. 2020-12-18 11:04:16 -08:00
Raymond S Brand
34d61040f6 Add invocation option parameter checks 2020-12-18 10:51:24 -08:00
Leonardo
a492a935b6 Renamed lcQGLWidget to lcViewWidget. 2020-12-17 17:59:11 -08:00
Leonardo Zide
25d3bd63cd Merge branch 'master' of https://github.com/leozide/leocad 2020-12-16 15:16:17 -08:00
Leonardo
6c6c5c8f6d Update focus view correctly. 2020-12-16 10:28:43 -08:00
Leonardo
348b83155e Fixed warnings. Fixes #467. 2020-12-16 10:00:31 -08:00
Leonardo
6a48e8ddc8 Fixed warnings. 2020-12-16 09:41:19 -08:00
Leonardo Zide
dac9b599a5 Replaced includes with forward declares. 2020-12-15 18:47:58 -08:00
Leonardo Zide
c2d1b5ce7c Use events for view focus changes. 2020-12-15 18:27:54 -08:00
Leonardo Zide
de29c49608 Reorganized redraw. 2020-12-15 17:19:32 -08:00
Leonardo Zide
a0385a3783 Merged menu update functions. 2020-12-15 10:20:14 -08:00
Leonardo Zide
71ea45f085 Updated deprecated functions. 2020-12-14 15:08:43 -08:00
Leonardo Zide
3eec496047 Warning fixes. 2020-12-14 14:18:06 -08:00
Raymond S Brand
2ac471cca8 Add invocation option syntax checking 2020-12-14 14:16:20 -08:00
Leonardo Zide
86ef52e403 Added --camera-position-ldraw. 2020-12-13 18:23:52 -08:00
Leonardo Zide
581c4ce523 Compile fix. 2020-12-13 17:14:33 -08:00
Leonardo Zide
9a7e256c72 Set fov and clip planes before viewpoint so zoom extents is correct. 2020-12-13 17:10:25 -08:00
Leonardo Zide
fd92710cf8 Compile fix. 2020-12-13 17:05:27 -08:00
Leonardo Zide
65ef0d3b77 Compile fix. 2020-12-13 16:53:49 -08:00
Leonardo Zide
336afdba8a QString fix. 2020-12-13 16:30:01 -08:00
Leonardo Zide
2d7aba8895 Use QString for object names. 2020-12-13 16:27:21 -08:00
Leonardo Zide
1012fc20cd Cleanup. 2020-12-13 12:05:54 -08:00
Leonardo Zide
05963fc8b0
Merge pull request #549 from j6t/master
Work around ambiguous operator== reported by modern clang.
2020-12-13 10:34:47 -08:00
Leonardo Zide
1ce80b8c2c Have the view use signals to pass camera changes to the main window. 2020-12-13 10:33:42 -08:00
Leonardo Zide
fd8aca92df Scoped enum lcViewpoint. 2020-12-12 16:58:40 -08:00
Leonardo Zide
ea99066465 Disable stud logo options from preferences when unofficial parts are missing. 2020-12-12 15:21:30 -08:00
Leonardo Zide
847cbfeb87 Added camera command line options. 2020-12-12 15:03:06 -08:00
Johannes Sixt
515c0c183c Work around ambiguous operator== reported by modern clang.
The warning is about an ambiguity between a regular call and one with the
argument order reversed. Mark the operator const so that both operands are
treated equally.
2020-12-12 21:31:31 +01:00
Leonardo Zide
70d5daaac4 New command line options. 2020-12-12 11:27:06 -08:00
Leonardo Zide
489f5e6f7e Merged DrawViewport(). 2020-12-11 18:01:04 -08:00
Leonardo Zide
c758ef2910 Qt deprecated cleanup. 2020-12-11 15:49:32 -08:00
Leonardo
6ae6fbade7 Removed deprecated functions. 2020-12-11 14:51:46 -08:00
Leonardo
eda0a705de Removed deprecated QResource usage. 2020-12-11 14:14:54 -08:00
Leonardo
caed332b3f Warn when assigning a keyboard shortcut that is already assigned to something else. Fixes #517. 2020-12-10 14:59:13 -08:00
Leonardo
14f891bd08 Update current step item in the timeline widget. 2020-12-09 13:58:44 -08:00
Leonardo Zide
db7259b7a5 Fixed ugly border in the Minifig Wizard. 2020-12-06 19:33:15 -08:00
Leonardo Zide
e52ea0ab63 Added LC_ARRAY_SIZE_CHECK for static array checks. 2020-12-06 11:26:55 -08:00
Leonardo Zide
c6c0718d18 Hide cursor while dragging. 2020-12-06 11:15:23 -08:00
Leonardo Zide
b981de80c5 Widget merge. 2020-12-06 10:52:57 -08:00
Leonardo Zide
28ccd8f681 Widget merge. 2020-12-05 12:17:09 -08:00
Leonardo Zide
8d09f90c54 Compile fix. 2020-12-05 11:19:11 -08:00
Leonardo Zide
60a0f9190d Widget merging. 2020-12-05 11:02:10 -08:00
Leonardo Zide
21d36bbac4 View Sphere cleanup. 2020-12-05 10:29:39 -08:00
Leonardo Zide
20a42e8fef Cleanup. 2020-12-05 08:50:12 -08:00
Leonardo Zide
a9fac6110b Inlined lcInputState. 2020-12-05 08:45:29 -08:00
Leonardo
525df8ad21 Widget cleanup. 2020-12-04 16:52:57 -08:00
Leonardo
7b320edc7a Scoped lcTrackTool. 2020-12-04 16:06:39 -08:00
Leonardo
366018ee8c Scoped lcTool. 2020-12-04 15:38:49 -08:00
Leonardo
256d3792b1 Widget cleanup. 2020-12-04 12:49:01 -08:00
Leonardo
194e02c74c Widget cleanup. 2020-12-04 11:40:53 -08:00
Leonardo Zide
9e12b480ce Moved DrawBackground to lcGLWidget. 2020-11-26 12:07:41 -08:00
Leonardo Zide
ef2220ffdc Moved background color to global options. 2020-11-26 11:51:50 -08:00
Leonardo Zide
462897caf7 Handle some malformed mpd files. Fixes #533.
- Skip duplicate submodels
- Skip recursive includes
2020-11-25 19:54:32 -08:00
Leonardo Zide
e2fb7b2ed9 Widget cleanup. 2020-11-14 12:47:55 -08:00
Leonardo Zide
f8ca2b848b Fix for GLES. 2020-11-06 18:55:36 -08:00
Leonardo Zide
6decd02761 Fixed crash on exit. Fixes #520. 2020-10-17 14:41:59 -07:00
Leonardo Zide
f7e89ee5c8 Better decorated part match. Fixes #510. 2020-10-17 10:32:22 -07:00
Trevor SANDY
a9912cc28c 3D Preview - add to toolbars menu and popup. Treats #514 2020-10-13 01:26:39 +02:00
Trevor SANDY
c5426abf24 3D Preview - update background from submodel properties. Treats #513 2020-10-13 01:26:39 +02:00
Leonardo Zide
28437d16f7 Fixed memory leak. 2020-10-11 17:29:32 -07:00
Leonardo Zide
8dad9dd269 Fixed AA not being applied to the preview widget. 2020-10-11 17:22:18 -07:00
Trevor SANDY
bdc4061a79 3D Preview - ignore update if existing piece and color matches 2020-10-08 15:17:31 +02:00
Trevor SANDY
959c815ad1 3D Preview - only update timeline item on double-click when in 'Floating' position
Remove duplicate updates in because when in 'Dockable' position, updates are triggered by single-click via the property tree
2020-10-08 14:00:52 +02:00
Trevor SANDY
b4e376a90d 3D Preview - treat object management and add missed call 2020-10-07 16:56:49 +02:00
Trevor SANDY
07d0365167 3D Preview - add preview display lock 2020-10-07 15:44:14 +02:00
Trevor SANDY
11966ca428 3D Preview - refactor and enable on property tree 2020-10-07 15:44:14 +02:00
Trevor SANDY
506b7a175f 3D Preview - Leo's fixes and formatting 2020-10-07 12:08:14 +02:00
Trevor SANDY
a239e504ec 3D Preview
3D Preview - restore doc format
2020-10-03 16:20:59 +02:00
Leonardo Zide
33679e4f70 Added shortcut to toggle axis display. Fixes #498. 2020-09-13 10:04:34 -07:00
Leonardo Zide
546eaf47cd Added option to duplicate submodels. Closes #502. 2020-09-07 11:29:37 -07:00
Leonardo Zide
0b4984672d Fixed selection/zoom region not being drawn in some cases. Fixes #491. 2020-08-23 10:16:54 -07:00
Leonardo Zide
8958e822a0 Added option to import/export mouse shortcuts. Fixes #490. 2020-08-22 18:47:03 -07:00
Leonardo Zide
0828fd1e2c Added mesh LOD distance option. 2020-08-15 16:16:26 -07:00
Leonardo Zide
e17a5719d9 Qt 4.8 fix. 2020-07-25 17:48:48 -07:00
Leonardo Zide
f4ddf94729 Old Qt fix. 2020-07-25 13:25:45 -07:00
Leonardo Zide
3903e905fe Dark color theme. 2020-07-25 13:21:22 -07:00
Leonardo Zide
92d75c4963 Support assigning shortcuts to toolbars. Fixes #463. 2020-07-11 12:22:01 -07:00
Leonardo Zide
0cead36c7f Added option to select the overlay and axis colors. Fixes #464. 2020-07-11 10:47:52 -07:00
Leonardo Zide
7ca69e37b7 Fixed crash on exit with Qt 5.15. 2020-07-11 09:17:43 -07:00
Leonardo Zide
aefe36dbca Use AA lines when AA is enabled. 2020-06-06 11:15:39 -07:00
Leonardo Zide
899c4c3cec
Merge pull request #479 from j6t/synth-update
Support small linear actuators; handle move large actuators and a new universal joint.
2020-06-01 12:31:20 -07:00
Leonardo Zide
cc68126a48 gcc fix. 2020-06-01 12:29:30 -07:00
Johannes Sixt
7ab0928fed Synthesize another universal joint.
The LDraw 2019-03 library update brought a new universal joint piece.

Adjust titles of the other joint that were updated at the same time.
2020-06-01 19:20:42 +02:00
Johannes Sixt
303b42ba12 Synthesize Technic Linear Actuator 4 x 1 x 1. 2020-06-01 18:23:20 +02:00
Johannes Sixt
48d6f14532 Synthesize linear actuators with new IDs.
Technic Power Functions Linear Actuators were moved to a new ID in the
2017-01 LDraw library update and then renamed in the 2019-03 update.
2020-06-01 18:22:48 +02:00
Leonardo Zide
44fa79ecb6 Instructions Dialog mockup. 2020-05-31 18:46:36 -07:00
Leonardo Zide
9e8400cbba Support local transforms for translations. 2020-05-08 17:53:53 -07:00
Leonardo Zide
f309d3fb0a Fixed translucent parts drawn with shading in flat shaded mode. Fixes #470. 2020-05-07 11:50:43 -07:00
Leonardo Zide
2390feb88f Deleted unsafe default operations. 2020-05-03 15:39:39 -07:00
Leonardo Zide
9fa660313a Use scoped enum. 2020-05-03 13:04:40 -07:00
Leonardo Zide
13ae577533 Use simple multiplicative tint for fade. 2020-05-03 12:39:04 -07:00
Leonardo Zide
b94b401b06 Save files with OMR style header. 2020-05-03 12:11:51 -07:00
Leonardo Zide
ab6b325b0a Fixed not being able to disable lines in flat shading mode. Fixes #466. 2020-04-28 16:11:52 -07:00
Leonardo Zide
53ed56e60f Added option to rotate pieces around their local center. Closes #430. 2020-04-26 20:01:35 -07:00
Leonardo Zide
a5fde91ee9 Configurable fade color. 2020-04-25 12:16:37 -07:00
Leonardo Zide
acd7dd3f9a Allow highlight color to be set by the user. 2020-04-25 11:36:28 -07:00
Leonardo Zide
b7f57c03f0 Skip faded passes when fade is disabled. 2020-04-24 18:13:53 -07:00
Leonardo Zide
47755fd4a0 Don't draw faded translucent parts in the prepass. 2020-04-24 18:08:48 -07:00
Leonardo Zide
4e6306a649 Translucent step fade. 2020-04-19 20:21:18 -07:00
Leonardo Zide
5a76f4c870 Scoped enums. 2020-04-18 19:45:21 -07:00
Leonardo Zide
a5c2e617d5 Array cleanup. 2020-04-18 19:38:29 -07:00
Leonardo Zide
ad45bb9a47 Paste pieces to the current step. Fixes #452. 2020-04-12 13:01:28 -07:00
Leonardo Zide
5e8baffcf7 Added shortcut option for Fade Previous Steps. Fixes #420. 2020-04-11 11:16:21 -07:00
Leonardo Zide
70da56bb05 More accurate bounding box calculation for submodels. 2020-04-11 11:04:27 -07:00
Johannes Sixt
ca73f3e3ad
Synthesis of Technic Universal Joints (#456)
* Split synth info initialzation by type.

We are going to remove the type enumeration and use a class hierarchy
instead. This preparation will then be helpful.

* Make Add...Parts() overrides of a virtual AddPart() function.

Since we have a class hierarchy for the different synthesized pieces, we
can now turn a case distinction into a virtual function call.

* Move initialization based on type to derived class constructors.

Move initialization of end transformations of flexible parts into
class lcSynthInfoCurved.

* Make GetDefaultControlPoints() virtual with overrides.

* Remove obsolete enum lcSynthType.

We have replaced its purpose by derived classes by now.

* Initialize shock absorbers' spring part ID early.

This removes the awkward early return that is needed in the if-else
cascade.

* Split lcSynthInfo into derived classes for curved and straight pieces.

* Only curved parts have varying sections, start, middle, and end properties.

Move the properties from the base class to the derived class that needs
them.

* Use derived classes to mark synthesized objects of different kinds.

We will extend the derived classes in the upcoming commits.

* PieceInfo is only needed to synthesize some hoses and shock absorbers.

* Initialize edge part IDs of flexible hoses early.

This removes another case distinction in AddParts().

* Verify the number of control points loaded from a model file.

* Synthesize Technic universal joints.

The direction of one end can be changed so that it points to the control
point.

* Technic universal joints need only the position of the control point.

* Synthesize legacy universal joints.
2020-03-30 12:17:08 -07:00
Leonardo Zide
b9662dd3e0 gcc fix. 2020-03-22 20:32:04 -07:00
Leonardo Zide
7275c4256d Added const qualifiers. 2020-03-22 20:18:52 -07:00
Leonardo Zide
66bed1a8f0 gcc fix. 2020-03-22 16:19:15 -07:00
Leonardo Zide
a5bb4a3051 Removed std::exchange. 2020-03-22 16:07:07 -07:00
Leonardo Zide
7c9773f228 Fixed override and virtual function qualifiers. 2020-03-22 15:44:41 -07:00
Leonardo Zide
90f1336a48 Scoped enums and constexpr. 2020-03-22 13:44:20 -07:00
Leonardo Zide
ade7334fa1 Support up to 10 control points and prevent the user from adding more. 2020-03-22 11:12:15 -07:00
Leonardo Zide
fab6a8fa11 Don't flag submodels as decorated parts. Fixes #453. 2020-03-14 11:24:56 -07:00
Leonardo Zide
85a9b19b2c Warning fixes. 2020-02-24 14:31:08 -08:00
Leonardo Zide
93ef9e0edc Fixed view size on retina displays. Fixes #447. 2020-02-24 12:58:38 -08:00
Leonardo Zide
e9c38e4f39 Added scoped enums. 2020-02-15 11:36:06 -08:00
Leonardo Zide
e5d06a29a2 Renamed pipette to color picker and fixed indentation. 2020-02-15 11:14:12 -08:00
RenateZwei
aa3ead6504
Added color picker (#446)
Added color picker
2020-02-15 10:59:14 -08:00
Leonardo Zide
bee37f0bc6 Fixed incorrect bounding box drawing when dragging a new submodel. 2020-02-01 11:42:22 -08:00
Leonardo Zide
fb7f952e98 Fixed a case where drag and drop a submodel didn't do anything. 2020-02-01 11:34:56 -08:00
Leonardo Zide
60aca425a0 Fixed crash using undo while dragging a new part. 2020-02-01 10:58:19 -08:00
Leonardo Zide
d626048a64 Fixed view not refreshing after cancelling a drop. 2020-02-01 10:42:29 -08:00
Leonardo Zide
be2f4caf65 Include parts in submodels in the 'Parts in Use' category. Fixes #436. 2020-02-01 10:33:51 -08:00
Leonardo Zide
9b7c7563a2 Added option to insert steps after the current step to avoid confusion. Fixes #373 and #408. 2020-01-26 18:41:31 -08:00
Leonardo Zide
bbc40d5a22 Start new model when closing the last tab. Fixes #422. 2020-01-26 11:31:21 -08:00
Leonardo Zide
59098436b7 Use menu names for the keyboard preferences. Fixes #411. 2020-01-26 11:03:41 -08:00
Leonardo Zide
a87a19f9c9 Fixed crash unzipping uncompressed files. 2020-01-25 12:44:50 -08:00
Leonardo Zide
93e8f4a85e Fixed possible buffer overflow. 2020-01-24 13:12:34 -08:00
Leonardo Zide
3b8b22493a Reorganized PLI function. 2020-01-20 15:39:20 -08:00
Leonardo Zide
ddf6f9dbba Automatically zoom out parts in the parts list image if needed. 2020-01-18 18:47:15 -08:00
Leonardo Zide
b698686420 Fixed compiler warnings. 2020-01-18 16:53:33 -08:00
Leonardo Zide
58957440cf Fixed crash loading certain parts. 2020-01-17 14:44:35 -08:00
Leonardo Zide
51fe5416b4 Replaced HTML parts list with BOM style image. 2020-01-14 12:48:18 -08:00