Commit Graph

10101 Commits

Author SHA1 Message Date
Vojtech Bubnik
adb467286f Documented the seam placement corner penalty with an image. 2022-04-25 12:42:51 +02:00
Vojtech Bubnik
853b8adf80 Little refactoring of SeamPlacer.
Moved color mapping functions to Color.hpp
Removed the "extern" keyword from Color.hpp
2022-04-25 12:42:51 +02:00
Vojtech Bubnik
f5709345ad GCode export: Replaced std::strings in G-code comments with string_views.
Seam placer: Detecting perimeter by the pointer and size of the
comment_perimeter string_view, only placing seams for perimeters.
2022-04-25 12:42:51 +02:00
PavelMikus
fb2621c03c Negative volumes raycasting fix - normal was flipped between iterations, incorrect algorithm for hit detection
Debug files export fix after refactoring
2022-04-25 12:42:51 +02:00
Vojtech Bubnik
8ce36e9137 Refactoring of SeamPlacer:
Replaced shared_ptr<> with deque.
Merged multiple vectors into one.
Refactoring using common helper functions (prev/next_idx_modulo(),
angle(), ...)
AABBTreeIndirect::intersect_ray_all_hits(): Reuse memory of the hits cache.
2022-04-25 12:42:51 +02:00
PavelMikus
3b8cfc62da fixed drawing seams on multipart objects
removed oversampling for blockers
improved drawing seams over sharp features
2022-04-25 12:42:51 +02:00
PavelMikus
47fc39a4ba fixed misleanding or wrong comments of the fitting function 2022-04-25 12:42:51 +02:00
PavelMikus
ae89d65e3e added description for the parameter count increase 2022-04-25 12:42:51 +02:00
PavelMikus
396d3215bd Refactoring of curve fitting algorithm:
removal of artificial extension at the ends of the curve
removal of observation points normalization
added clamping of parameter index which compensates for under-represented spline segments
added parameter for level of freedom at the ends of the curve
2022-04-25 12:42:51 +02:00
Vojtech Bubnik
c19770189f Follow-up to 1c9ba291fe32bc4a4c78cabbab0639b0c164f23f
Refactoring of Curves.hpp for better memory management and vectorization
2022-04-25 12:42:51 +02:00
Vojtech Bubnik
42e802c1b8 Refactoring of Curves.hpp for better memory management and vectorization
(replaced vector of vectors with Eigen 2D matrices).
2022-04-25 12:42:51 +02:00
Vojtech Bubnik
bd8ce6fabd Follow-up to 9cb51caead9dee5c4d12a4ef5f925b5efeb00b75
Fixing compilation on GCC
2022-04-25 12:42:51 +02:00
Vojtech Bubnik
7d02647ebf Removed various Point::ccw() and Point::ccw_angle() methods, they were
provided for Perl bindings and their semantic was confusing.
Implemented free function angle() to measure angle between two vectors.
Reworked Polygon::convex/concave_points(), changed the meaning of their
angle threshold parameter.
Removed some unused methods from Perl bindings and tests.
Reworked the "wipe inside at the external perimeter" function
after Point::ccw_angle() was removed.
2022-04-25 12:42:51 +02:00
PavelMikus
156a60017d fixed ExPolygons dealocation while using EdgeGrid
fixed warnings in Bicubic.h file
2022-04-25 12:42:51 +02:00
PavelMikus
965803822e remove invalid comment 2022-04-25 12:42:51 +02:00
PavelMikus
1164449d4e compute overhang distance using SDF
detect embedded (inner) perimeter points and prefer them for seam placement
2022-04-25 12:42:51 +02:00
PavelMikus
191e788aa0 make Random seams disaligned 2022-04-25 12:42:51 +02:00
PavelMikus
15135ef2ed fixes, central enforced point preference 2022-04-25 12:42:51 +02:00
PavelMikus
5c23d471de BSplines, Polynomial fitting 2022-04-25 12:42:51 +02:00
PavelMikus
bbcd6be250 Implemented piecewise data (curve) fitting with variable kernels 2022-04-25 12:42:51 +02:00
PavelMikus
bb89b630d9 implemented occlusion estimation for objects with negative volumes 2022-04-25 12:42:51 +02:00
PavelMikus
ca259caf33 fix ccw angle computation in Point.cpp 2022-04-25 12:42:51 +02:00
PavelMikus
177a1fd54a finalize integration into GCode.cpp export functions, remove unused
edge grids
2022-04-25 12:42:51 +02:00
PavelMikus
6dbc7149be parameter fixes, alignemnt for enforcers simplified 2022-04-25 12:42:51 +02:00
PavelMikus
c640fb854f bug fix: using trafo() instead of trafo_centred() caused
misalignment between occlusion mesh and seam candidates
2022-04-25 12:42:51 +02:00
PavelMikus
2274965079 alignment from best candidate 2022-04-25 12:42:51 +02:00
PavelMikus
eccf1c1553 refactored raycasting - inverted direction of raycasting - now each face is tested
fixed bug with custom seam drawings - square distance parameter named incorrectly
2022-04-25 12:42:51 +02:00
PavelMikus
a9f5330ad2 using gauss function to smoothen criteria skips 2022-04-25 12:42:51 +02:00
Godrak
ab3c8d0fe8 implemented smooth angle penalty function 2022-04-25 12:42:51 +02:00
PavelMikus
a92d5038bd debug export svg info,
fixing problem with weird seam placement caused by disconnected scoring function
2022-04-25 12:42:51 +02:00
PavelMikus
962282c9ef split occlusion and enforcers/blockers into separate functions
added weights to polynomial fitting
2022-04-25 12:42:51 +02:00
PavelMikus
f837759928 fixed problem with multipart objects
fixed bug : model volume trafo was not considered
2022-04-25 12:42:51 +02:00
PavelMikus
a775bf2978 improved enforcers blockers oversampling, renamed parameter 2022-04-25 12:42:51 +02:00
PavelMikus
8f7b86915a oversample polygons where necessary, due to seam enforcers & blockers 2022-04-25 12:42:51 +02:00
PavelMikus
87c276b7a4 comments and bugfix 2022-04-25 12:42:51 +02:00
PavelMikus
ad819850f9 tweaked parameters,
fixed minor bugs
2022-04-25 12:42:51 +02:00
PavelMikus
c72687c96c computing smooth score instead of binary decision when picking seams
some basic documentation
2022-04-25 12:42:51 +02:00
PavelMikus
105b67c9a7 presorting seams before alignemnt
mesh decimation for speed up
2022-04-25 12:42:51 +02:00
PavelMikus
f018160e72 implemented polynomial alignment,
however, initital seam placement is not ideal
- hard to balance visual cues and angle information
2022-04-25 12:42:51 +02:00
PavelMikus
ffc7452d9e improved visibility calculation - it now considers normals and
accordingly counts only hits which have similar normal
2022-04-25 12:42:51 +02:00
PavelMikus
38a9d870c0 implemented seam alignment using exponential smoothing 2022-04-25 12:42:51 +02:00
PavelMikus
596bd68f18 refactoring, created perimters struct to store info,
removed alignment iterations, created dynamic ray count estimation
2022-04-25 12:42:51 +02:00
PavelMikus
53ff4a69e0 implemented debug files export 2022-04-25 12:42:51 +02:00
PavelMikus
3029053d43 fixed some problems according to code review
simplified blockers and enforcers
Pre-Refactoring version
2022-04-25 12:42:51 +02:00
PavelMikus
5a03f60c31 fixed bug: wrong estimation of angles inside holes 2022-04-25 12:42:51 +02:00
PavelMikus
356ed93ad7 Raft layers cause SeamPlacer crash - fix 2022-04-25 12:42:51 +02:00
PavelMikus
132f4bb590 bugfix: usage of undeclared M_PIf32 instead of PI 2022-04-25 12:42:51 +02:00
PavelMikus
4b3db29d32 refactoring into floats, fixed problems with float/double mixing,
returned to fixed ray count, yields better results
2022-04-25 12:42:51 +02:00
PavelMikus
8226061da4 so far best version 2022-04-25 12:42:51 +02:00
PavelMikus
36a4906536 refactored init method - split into several parts,
added blur filter to seam placement distribution
2022-04-25 12:42:51 +02:00