Commit Graph

1635 Commits (942bf3f35409ac58b3f2bc90144dea67a96f6200)

Author SHA1 Message Date
ruevs 942bf3f354 Remove Q3DO export.
It was added in 3a3a2755b as a potential way to export colorful meshes
to Horizon EDA but ended up being supported only by SolveSpace. Since no
software can consume the exported q3do files the feature is superfluous.

See https://github.com/solvespace/solvespace/issues/795 for details.
2020-11-21 13:02:39 -05:00
Maximilian Federle 427a29abb2 Travis: build snaps in LXD containers
With arm64-graviton2 now providing full VM virtualization, LXD containers
can be used to build snaps on all architectures.

This is beneficial for us as having snapcraft manage the whole build
environment is likely to yield better/more consistent results than
running the builds on the Travis images directly.
2020-11-19 19:26:36 +01:00
ruevs bcb8cd2c03 Fix unsequenced modification and access warnings.
Found by clang 11. They are a potential problem.

[ 21%] Building CXX object src/CMakeFiles/solvespace-core.dir/exportstep.cpp.obj
.\src\exportstep.cpp:293:61: warning: unsequenced modification and access to 'id'      [-Wunsequenced]
        fprintf(f, "#%d=FILL_AREA_STYLE_COLOUR('',#%d);\n", ++id, id - 1);
                                                            ^     ~~
.\src\exportstep.cpp:294:56: warning: unsequenced modification and access to 'id'      [-Wunsequenced]
        fprintf(f, "#%d=FILL_AREA_STYLE('',(#%d));\n", ++id, id - 1);
                                                       ^     ~~
.\src\exportstep.cpp:295:59: warning: unsequenced modification and access to 'id'      [-Wunsequenced]
        fprintf(f, "#%d=SURFACE_STYLE_FILL_AREA(#%d);\n", ++id, id - 1);
                                                          ^     ~~
.\src\exportstep.cpp:297:98: warning: unsequenced modification and access to 'id'      [-Wunsequenced]
        fprintf(f, "#%d=SURFACE_STYLE_RENDERING_WITH_PROPERTIES(.NORMAL_SHADING.,#%d,(#%d));\n", ++id, id - 5, id - 1);
                                                                                                 ^     ~~
.\src\exportstep.cpp:298:64: warning: unsequenced modification and access to 'id'      [-Wunsequenced]
        fprintf(f, "#%d=SURFACE_SIDE_STYLE('',(#%d, #%d));\n", ++id, id - 3, id - 1);
                                                               ^     ~~
.\src\exportstep.cpp:300:62: warning: unsequenced modification and access to 'id'      [-Wunsequenced]
        fprintf(f, "#%d=SURFACE_STYLE_USAGE(.BOTH.,#%d);\n", ++id, id - 1);
                                                             ^     ~~
.\src\exportstep.cpp:301:67: warning: unsequenced modification and access to 'id'      [-Wunsequenced]
        fprintf(f, "#%d=PRESENTATION_STYLE_ASSIGNMENT((#%d));\n", ++id, id - 1);
                                                                  ^     ~~
.\src\exportstep.cpp:302:56: warning: unsequenced modification and access to 'id'      [-Wunsequenced]
        fprintf(f, "#%d=STYLED_ITEM('',(#%d),#%d);\n", ++id, id - 1, advFaceId);
                                                       ^     ~~
8 warnings generated.
2020-11-18 17:07:56 +02:00
Maximilian Federle 898fb6f4f5 Travis: deploy tagged & master commits to GitHub
Our implicit deploy conditions were previously only met by untagged commits
on master. As the stage conditions filter everything except branch = master
and tagged commits, we can just use all_branches: true to also deploy tagged
builds.

Also clean up the snap deploy sections.
2020-11-18 15:52:33 +01:00
Maximilian Federle 1b2d47cd86 Travis: deploy tagged commits & edge tagging fixes
With the recent Travis changes, we prevented the deploy
stage from running for tagged commits as branch=tag
for tagged commits. Fix this by also running deploy for
tagged commits.

Furthermore, clean up .travis.yml by pulling the edge
tagging logic into a separate script.
A logic change is introduced to prevent git tag --force being
run on set tags as this would turn annotated tags into
lightweight tags.
2020-11-18 11:13:52 +01:00
phkahler 5a3f45ed2a ran make translate_solvespace. cleaned out some obsolete strings in en_US.po 2020-11-17 22:31:56 -05:00
phkahler 142252ddf8 Add z distance checking to entity picking. Fixes issue 521 2020-11-17 18:58:18 -05:00
Jason Lenz 6c2b967790 Use recent flatbuffers commit to solve compiling issue on OpenBSD 2020-11-14 14:00:15 -05:00
Koen Schmeets d0876d5f43 Update README.md (by @nii236) 2020-11-07 21:57:15 +01:00
phkahler 5945d556a6 Add end marker to text window and increase max rows. 2020-11-07 21:57:15 +01:00
Koen Schmeets 953c472897 Travis: add clean edge script 2020-11-07 20:23:49 +01:00
phkahler 6ff8db93e8 Use zOrder for selections within the same group 2020-10-31 11:58:14 -04:00
Maximilian Federle d973405c8c adjust logo size 2020-10-29 15:32:57 -04:00
Maximilian Federle 078fb99cfa add logo in heading 2020-10-29 15:32:57 -04:00
Maximilian Federle ef7e2c7ec2 README: Add Travis & Snap Store badges 2020-10-29 15:32:57 -04:00
phkahler 8a3e5b4d56 Don't do numeric surface intersections if an exact curve has been copied. We don't want 2 overlapping but different sets of PWLs. 2020-10-29 14:02:57 -04:00
phkahler eadeac44f0 use VERY_NEGATIVE and VERY_POSITIVE instead of numeric values which is some cases were 1e-10 instead of -1e10 2020-10-28 13:37:54 -04:00
phkahler 6c4b075eef Increase MAX_UNDO to 100 2020-10-28 13:37:54 -04:00
ruevs 7e99ba0096 UI: Fix the Property Browser window scrollbar
- Scrolling with the scrollbar now works properly.

- Do not scroll with the mouse wheel while an edit field is active in
  the property browser.

Fixes: https://github.com/solvespace/solvespace/issues/782
2020-10-28 13:37:30 -04:00
Koen Schmeets 3694c9b3ee Travis: sign libomp.dylib 2020-10-26 03:38:32 +01:00
Koen Schmeets 73bbbdef83 Travis: include libomp in macOS .app 2020-10-26 02:26:54 +01:00
ruevs 88b26aabdb Update the year in the About dialog 2020-10-25 19:16:34 -04:00
ruevs 7292c32e6f Performance: inline the Bernstein functions
This is another small profiling driven optimization.
Moving the initialization of `const double *c` as part of the definition
also helps with the generated assembler.
2020-10-25 19:16:22 -04:00
Koen Schmeets 5388e10649 Travis: use force to overwrite tag 2020-10-25 22:30:57 +01:00
Koen Schmeets 57f8b37270 Travis: skip build if tag is edge, staple to the .dmg 2020-10-25 19:50:14 +01:00
Koen Schmeets 5fbb1b8f53 Travis: remove old secrets from .travis.yml 2020-10-25 17:59:52 +01:00
Maximilian Federle 24720a0024 Revert "CMake: use sanitizer flags for internal targets only"
This reverts commit 68b1abf77f.

The warnings are valuable and shouldn't be cast aside.
As of 8f509f1, we special case macOS and don't set -fno-sanitize-recover
to allow CI to succeed.
In the future, this could be made stricter again by only suppressing
known bugs, which ideally should also be fixed or reported upstream.
2020-10-24 17:10:47 +02:00
Koen Schmeets da87a68093 Travis: try fixing deploy secret (sorry, has to happen on master) 2020-10-24 12:11:00 +02:00
Koen Schmeets 8f509f1452
Travis: CI improvements and fixing edge builds (#766)
- Fix release notes by using edge deploy provider, see: https://github.com/travis-ci/dpl/pull/1069
- Deploy only on master branch
- Move to arm64-graviton2
- Rename debian -> ubuntu
- Remove appveyor.yml
- Remove redundant deploy stage in build step names
- Get rid of bash code in files using sh, and explicitly use bash in sign-macos.sh script
- Add missing newline to build-windows.sh
- Build x86 for Windows
- Enable OpenMP in test builds
- Disable sanitizers on macOS test build
- Disallow failures on snap build
2020-10-24 11:08:40 +02:00
ruevs 7035071526 Performance optimization of the Vector class
Profiling with MSVC 2019 showed that many of the Vector methods are on
a critical path (not surprising). They are changed to be inline and
unnecessary temporaries are removed.

On the example below generate times decreased from 102s. to 64s.
At the same time the executable size shrank from 5569536	to 5150208 bytes
in release mode (with global optimizations).

This should not stop us from working on optimizing inner loops e.g. https://github.com/solvespace/solvespace/issues/759 .

[Test model](https://github.com/solvespace/solvespace/files/5414683/PrismConeNURBSNormalsTangents300.zip)
2020-10-23 20:08:43 -04:00
Maximilian Federle 68b1abf77f CMake: use sanitizer flags for internal targets only
Previously sanitizer flags were set unconditionally for
all code, including that of external libraries.
Set them only for targets in src/, tests/ and exposed/.

Unfortunately, the linker equivalent to add_compile_options,
add_link_options, is only available for CMake version >= 3.13.
So add the sanitizer flags manually to each target's linker options.
2020-10-23 19:39:36 +02:00
phkahler c674bc8fb9 Add OpenMP parallel for to SShell::CopyCurvesSplitAgainst 2020-10-23 12:53:54 -04:00
phkahler 0f1ece2b8e Resovle a huge performance regression introduced by commit ab10e38 while still fixing the NURBS issues resolved by that commit with only modest speed penalty. The performance is significantly improved by using bounding box tests on curves prior to doing complex intersection testing. 2020-10-23 12:52:27 -04:00
ruevs 0761339ec9 STEP Export: include colors and alpha
Make the color export work in KiCAD and Horison EDA which do not support
transparency.

Fixes: https://github.com/solvespace/solvespace/issues/452
https://github.com/solvespace/solvespace/pull/763
2020-10-22 09:59:35 +03:00
ruevs 400056cded CMake: Give ENABLE_LTO a default and a description so it shows up in cmake-gui 2020-10-21 19:32:11 -04:00
Maximilian Federle aa83681da7 snap: enable OpenMP and LTO 2020-10-21 19:04:34 -04:00
ruevs 32e695bfee STEP Export: include colors and alpha
The implementation may be sub-optimal, since the colour and alpha is
defined for each NURBS surface instead of on group level, but the STEP
export currently does not represent group structure at all and I am not
familiar with the format in order to change this.

Fixes: https://github.com/solvespace/solvespace/issues/452
2020-10-21 17:19:12 -04:00
Koen Schmeets b3cd92899e Travis: release macOS and Windows edge builds
- Fixes windows build type
- Revert `cleanup: false` back to `skip_cleanup: true`
- Waits 10 seconds to get notarize_uuid for macOS since it would sometimes fail
2020-10-21 16:20:34 -04:00
Maximilian Federle 8a2e77d035 CMake: fix LTO on Linux
LTO/IPO with non-Intel compilers on Linux requires policy CMP0069 to be set to NEW.
Set it explicitly until cmake_minimum_required is raised to >= 3.9

Also explicitly check whether the current environment actually supports IPO.
2020-10-20 19:47:22 -04:00
Koen Schmeets f3f33d3f26 Travis: optimize macOS deploy build
- Turns on the -DENABLE_LTO flag during deploy
- Turns off the -DENABLE_OPENMP flag during test
2020-10-20 12:38:05 -04:00
phkahler ab10e38d44 Add vertexes to curve intersection list in addition to surface intersections.
Sometimes a vertex can be used to split a curve where surface intersections can't. Those unsplit curves can cause boolean failures.
2020-10-20 12:37:18 -04:00
phkahler 6b5936b2f6 remove zh_CN.mo 2020-10-20 11:46:16 -04:00
ZHOU You 2be2e428d3 Chinese translation added. 2020-10-20 11:08:34 -04:00
Koen Schmeets 9d2641a5de Travis: update travis and macos build configs
- Fixing warnings in .travis.yml
- Enable building on all cores for macOS build
- Quote variables
2020-10-20 11:03:13 -04:00
Koen Schmeets 3af8127e8f macOS: add NSOpenGLPFADoubleBuffer to NSOpenGLPixelFormatAttribute 2020-10-20 10:59:58 -04:00
Koen Schmeets 8e7416f3fd
Travis: Build improvements and fixes (#751)
- Add OpenMP to macOS build
- Use as many cores as possible in CI
- Update travis osx image to xcode12.2
- Ignore .vscode folder
- In `.travis/sign-macos.sh`, only create keychain when `CI` variable is present
- Only run macOS deploy stage when a tag is pushed
2020-10-20 09:39:26 +02:00
phkahler b28499ea48 initial support (disabled) for keepout regions in IDF files. 2020-10-19 18:26:45 -04:00
phkahler b12bcc5889 Fix some IDF file curves. 2020-10-19 18:26:45 -04:00
Koen Schmeets 0548702043 macOS CI fixes 2020-10-19 09:36:52 -04:00
phkahler 408128a138 Avoid zero tangnet vectors on degenerate NURBS edges. Fixes #652 2020-10-18 14:54:00 -04:00