1
0
mirror of https://github.com/JustinSDK/dotSCAD.git synced 2025-08-15 03:05:41 +02:00

it's in voxel

This commit is contained in:
Justin Lin
2020-05-22 12:51:34 +08:00
parent 1fc3cd6c7e
commit 2c62b46021
3 changed files with 0 additions and 25 deletions

View File

@@ -1,6 +0,0 @@
use <../util/sort.scad>;
use <../util/has.scad>;
function px_difference(points1, points2) =
let(sorted = sort(points2, by = "vt"))
[for(p = points1) if(!has(sorted, p, sorted = true)) p];

View File

@@ -1,11 +0,0 @@
use <../util/sort.scad>;
use <../util/has.scad>;
function px_intersection(points1, points2) =
let(
leng1 = len(points1),
leng2 = len(points2),
pts_pair = leng1 > leng2 ? [points1, points2] : [points2, points1],
sorted = sort(pts_pair[1], by = "vt")
)
[for(p = pts_pair[0]) if(has(sorted, p, sorted = true)) p];

View File

@@ -1,8 +0,0 @@
use <../util/sort.scad>;
use <../util/dedup.scad>;
function px_union(points1, points2) =
dedup(
sort(concat(points1, points2), by = "vt"),
sorted = true
);