Commit Graph

1824 Commits (6edeb66e3dcb76721864084987ea04288f01cce9)

Author SHA1 Message Date
phkahler 0a061b6f9e NFC: Performance. For step-and-repeat groups, create the copies first (in parallel) and then combine them using unions of equal size shells to reduce the total time spent on booleans. 2020-09-22 16:30:03 -04:00
Reini Urban 7c766c72f4 translate_solvespace updates
for all languages. See PR #705

my russian is not good enough to fix the remaining ru and uk strings.
german and french are now complete.
2020-09-22 15:45:00 -04:00
phkahler d49c8a1aef add debug message showing the name of a group whose linked file can't be found. 2020-09-22 15:28:17 -04:00
phkahler d575da8611 Add cmake option ENABLE_LTO for link time optimization on Release builds. 2020-09-21 17:26:10 -04:00
phkahler 39f419e28c Flip sign of exportCanvas dx and dy. Fixes issue #523 2020-09-20 19:54:26 -04:00
phkahler 704bb4a3be Fix view centering and directions or cli thumbnail function. 2020-09-19 15:03:01 -04:00
Christoph Dittmann 34328c9756 solvespace-cli: Fix --view
This fixes issues #499. The --view option changes projUp and
projRight. For --view to affect the camera, the camera needs to be
initialized using these values.
2020-09-18 21:15:53 -04:00
Reini Urban 2adf5decb5 de_DE: missing translations 2020-09-18 16:39:09 -04:00
phkahler 6e515b6735 Fix 699: Allow dragging linked objects in an assembly. 2020-09-17 17:55:04 -04:00
phkahler 094eff755b Fix 197 Update the state of checkboxes in menus after failed workplace activation. 2020-09-17 11:34:22 -04:00
phkahler 668fe6f493 Make the redundant constraint timeout a configuration value and add the config UI elements to edit that value. 2020-09-16 16:39:43 -04:00
phkahler 615708440f Fix #131. Prevent UI freeze by having a timeout when finding which constraints can be removed to fix jacobian. 2020-09-16 16:39:43 -04:00
phkahler e74185b639 Fix #696. Account for multiple coincident edges when looking for naked edges. 2020-09-14 12:07:17 -04:00
phkahler d8f5a8da32 Fix issue #296.
We need to recognize two consecutive bridges as a non-ear.
2020-09-08 18:54:02 -04:00
phkahler 705249627a Fix #693 issues.
This set of changes covers all triangulation errors in issue 693. A point coincident with a triangle vertex is OK and needed for bridges, but sometimes the middle point has edges cutting through the triangle that make it a non-ear. We fix that and a couple of off-by-one error (that fixes one of the test cases).
2020-09-08 18:54:02 -04:00
phkahler 0413c1b926 NFC:Triangulation - don't add zero-length bridges to avoid list. 2020-09-08 18:54:02 -04:00
phkahler b208cd8cae NFC, Performance: Use OpenMP for boolean function MakeItersectionCurvesAgainst.
This is the last long-running single-threaded part of the boolean code. On one test model this took Regenerate form 27 seconds down to 18s. The critical sections needed a name (into) because that object must not be modified while in use in different places.
2020-09-06 12:43:24 -04:00
nabijaczleweli 360b347ad7 Export backgrounds in vector files
VectorFileWriter::Background() is an empty impl, except that it writes
  * a rectangle the size of the output for EPS and PDF, and
  * a <style> element setting background-color for SVG

Ref: #525
2020-09-05 20:58:07 -04:00
nabijaczleweli 028b613f10 Add ExportBackgroundColor config to GUI and CLI 2020-09-05 20:58:07 -04:00
phkahler d3da2c8b22 Performance: Don't call std::inplace_merge for IdList::AddAndAssignID() via Add() because it is redundant. 2020-08-29 15:34:48 -04:00
phkahler 6894b0c9c3 NFC: remove a critical section, runs faster. 2020-08-19 17:55:42 -04:00
phkahler d974615d0e NFC replace 2 nested loops with 1 loop and a lookup for speed improvement. 2020-08-19 17:55:42 -04:00
phkahler bc4924ae47 Don't duplicate points when connecting contours with zero length bridge. Fixes #303 2020-08-14 16:39:09 -04:00
phkahler 04b332dfd0 Ratpoly - Less noise in terminal. Comment out expected dbg print and try harder to converge. 2020-08-13 16:56:18 -04:00
Paul 4cceaa5310 NURBS boolean improvement.
The 3-plane intersection code fails to converge when a curve joins two tangent NURBS patches. This adds a new function for intersecting exact curves with a surface to avoid those failures. Fixes simplified test model for issue #315.
2020-08-13 16:56:18 -04:00
phkahler f9529916c4 Fix issue161 and 174. Use the same logic for selction and dragging, but ignore entites that are inherently undraggable.
This allows the selection to reach through entities to their corresponding ones on the underlying sketch which can be dragged if they are not fully constrained. This is decided in a new function Entity::CanBeDragged().
2020-08-09 19:55:33 -04:00
phkahler 575ddb5aaa Add a pass in triangulation to create convex triangle fans. These triangles will have smaller bounding boxes and look better. 2020-08-07 15:47:01 -04:00
phkahler b3eb589240 Fix issue659 - Problems constraining to ends of Helix.
Create a new copy type for faces that includes the translation aspect of helical extrusions. Also swap the end remappings when the shell is inside out - this was also affecting some Revolve extrusions.
2020-08-07 15:16:47 -04:00
phkahler 6ae417adb5 Update mimalloc to v1.6.4 2020-08-07 14:46:09 -04:00
whitequark a2962207dd Improve text screen for a selected entity.
* Add a link to its request, unless it's the first entity in that
    request (which would just select the same entity again).
  * Add a link to its group.
  * Add a link to its workplane.
  * Add a link to its style; and hide the style row for entities that
    aren't stylable.
  * Show constraints and measurements (reference constraints) in
    separate lists.
  * For curve entities, show constraints that apply to the points
    related to the curve, not just to the curve itself.
2020-08-07 18:06:42 +00:00
whitequark afa9e2890e Improve text screen for a selected constraint.
* Show the type of a constraint.
  * Show the workplane a constraint is in, for constraints which can
    be both projected to workplane or be free in 3d space.
  * Clearly distinguish reference from non-reference constraints.
  * Add a checkbox for toggling the reference option.
  * When showing requests a constraint applies to, highlight on hover
    the specific entity being constrained, not just the first one.
2020-08-07 18:06:42 +00:00
phkahler fef6a39a17 Don't init srand(0) because rand isn't used any more. 2020-08-03 15:41:47 -04:00
phkahler 3c2f82b7f1 Remove the Random() function and use a fixed table of arbitrary vectors in raycast.cpp
This also fixes issue #666.
2020-08-03 10:30:54 -04:00
phkahler fd2dfe87f6 Fix #656 by making SSurface::SplitInHalf thread safe.
SSurface::SplitInHalf was modifying the surface and then restoring it at the end. Make temporary copy instead.
2020-08-01 11:52:20 -04:00
whitequark d8b76ef7f1 Drop backtrace generation.
This has been completely broken since 2018 (commit a93283df), and no
one noticed, so it probably wasn't useful. Instead of fixing it, just
drop the feature and a bunch of odd nonportable code.
2020-07-28 14:56:55 +00:00
whitequark bbf402bfe3 Fix "Sketch → In Workplane" not updating the UI immediately. 2020-07-28 14:10:19 +00:00
whitequark 56e2592e2a Make "Toggle Reference" remember undo state.
Turning a reference dimension into a constraint one can make
the sketch unsolvable, which suggests Edit → Undo, which would undo
either too much or nothing at all.
2020-07-28 13:12:14 +00:00
phkahler e0fa99bad4 remove another redundant pass checking earness 2020-07-22 10:27:01 -04:00
phkahler 2640034124 NFC: Remove a redundant pass over all verticies in ear triangulation. 2020-07-22 10:27:01 -04:00
whitequark b0fc1912ea Create mimalloc heaps only when necessary.
The mimalloc temporary heap is a thread-local object that uses RAII
to manage heap lifetimes even in threads that are created implicitly,
e.g. by OpenMP. However, not all threads are necessarily created by
the application; graphics drivers may create their own threads, and
this can lead to deadlocks when combined with library unloading.

Fixes #657.
2020-07-22 11:05:01 +00:00
phkahler 188b2e26ce Implement #524 Allow flat colors. Adds an edit control for Ambient lighting. 2020-07-18 02:15:41 +00:00
phkahler c75b2e473e Fix #647 Helix mesh defects.
Use the grid spacing algorithm for helical curve PWL creation.
This makes the grid and trim curves have similar spacing.
2020-07-12 19:09:26 -04:00
xzcvczx f0623fa5ba
CMake: don't install mimalloc. 2020-07-12 20:57:02 +00:00
наб c4ca4be91e Replace {Alloc,FreeAll}Temporary() with mimalloc
The heaps are wrapped in a RAIIish thread_local handler,
since being affined affined to a single thread for allocations is
required by the API

Ref: #642
2020-07-12 02:37:07 +00:00
наб cbac182edf Add and build mimalloc at 07c6e60a5a3bd7de09e4a170cd97bafba59cfafd 2020-07-12 02:37:07 +00:00
phkahler 9802b5d1ee Better helical triangulation - issue 489.
Resolve issue #489 helix has stairsteps.
Force helix axis line to 8 segments.
Grid triangulation to use a minimum of 4 segments for degree>1.
Adds twist dependence for grid triangulation with degree=1.
Added a max_dt parameter for PWL creation and use that for helical edges.
2020-07-11 14:29:18 -04:00
наб 873085edbd
README: fix extlib/q3d{o,} typo 2020-07-09 09:19:21 +00:00
whitequark 211ae8c446 Show area of closed contour with SI units.
Similar to the way that Analyze → Measure Area... works.

Fixes #639.
2020-06-23 02:39:57 +00:00
whitequark 35c6af4929 Show center of mass using the same format as for constraints. 2020-06-23 01:16:58 +00:00
whitequark 586b0477d2 Delete all entities on a workplane request that is being deleted.
Fixes #628.
2020-06-23 01:05:51 +00:00