Skip to content

Commit 7a1c6c1

Browse files
committed
✨ Add visualization for STL models using FastPointQuery
1 parent 78be3f0 commit 7a1c6c1

1 file changed

Lines changed: 19 additions & 1 deletion

File tree

example/3d.jl

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,4 +9,22 @@ stl_model1 = readSTL3D(stl_path1)
99
stl_model2 = readSTL3D(stl_path2)
1010

1111
pip_query(stl_model1, points; nsamples=3, dev="CPU:0")
12-
pip_query(stl_model2, points; nsamples=5)
12+
pip_query(stl_model2, points; nsamples=5)
13+
14+
let
15+
h = 1
16+
pts = FastPointQuery._get_pts_voxel(stl_model1, h)
17+
fig = Figure()
18+
ax = LScene(fig[1, 1])
19+
scatter!(ax, pts, markersize=1)
20+
display(fig)
21+
end
22+
23+
let
24+
h = 5
25+
pts = FastPointQuery._get_pts_voxel(stl_model2, h; fill=true)
26+
fig = Figure()
27+
ax = LScene(fig[1, 1])
28+
scatter!(ax, pts, markersize=1)
29+
display(fig)
30+
end

0 commit comments

Comments
 (0)