mirror of
				https://github.com/SoftFever/OrcaSlicer.git
				synced 2025-10-30 20:21:12 -06:00 
			
		
		
		
	WIP: Reworked slicing
1) Slicing code moved to TriangleMeshSlicer.cpp,hpp from TriangleMesh.cpp,hpp 2) Refactored to use as little as possible of admesh.
This commit is contained in:
		
							parent
							
								
									68d2427a34
								
							
						
					
					
						commit
						308d6b7809
					
				
					 24 changed files with 1828 additions and 1594 deletions
				
			
		|  | @ -6,6 +6,7 @@ | |||
| 
 | ||||
| #include "sla_test_utils.hpp" | ||||
| 
 | ||||
| #include <libslic3r/TriangleMeshSlicer.hpp> | ||||
| #include <libslic3r/SLA/SupportTreeMesher.hpp> | ||||
| #include <libslic3r/SLA/Concurrency.hpp> | ||||
| 
 | ||||
|  | @ -48,9 +49,7 @@ TEST_CASE("Support point generator should be deterministic if seeded", | |||
|     sla::SupportPointGenerator::Config autogencfg; | ||||
|     autogencfg.head_diameter = float(2 * supportcfg.head_front_radius_mm); | ||||
|     sla::SupportPointGenerator point_gen{emesh, autogencfg, [] {}, [](int) {}}; | ||||
|      | ||||
|     TriangleMeshSlicer slicer{&mesh}; | ||||
|      | ||||
|          | ||||
|     auto   bb      = mesh.bounding_box(); | ||||
|     double zmin    = bb.min.z(); | ||||
|     double zmax    = bb.max.z(); | ||||
|  | @ -59,7 +58,7 @@ TEST_CASE("Support point generator should be deterministic if seeded", | |||
|      | ||||
|     auto slicegrid = grid(float(gnd), float(zmax), layer_h); | ||||
|     std::vector<ExPolygons> slices; | ||||
|     slicer.slice(slicegrid, SlicingMode::Regular, CLOSING_RADIUS, &slices, []{}); | ||||
|     slice_mesh(mesh, slicegrid, CLOSING_RADIUS, slices); | ||||
|      | ||||
|     point_gen.seed(0); | ||||
|     point_gen.execute(slices, slicegrid); | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Vojtech Bubnik
						Vojtech Bubnik