2040 for slider
This commit is contained in:
parent
1a8a77a52f
commit
637448fcd2
29160
20-2040.dxf
Normal file
29160
20-2040.dxf
Normal file
File diff suppressed because it is too large
Load Diff
25
slider.py
Normal file
25
slider.py
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
import cadquery as cq
|
||||||
|
from cadquery import exporters
|
||||||
|
|
||||||
|
slider_length=700
|
||||||
|
slider_width=50
|
||||||
|
|
||||||
|
path='20-2040.dxf'
|
||||||
|
|
||||||
|
bar_l = (
|
||||||
|
cq.importers.importDXF(path)
|
||||||
|
.wires().toPending()
|
||||||
|
.extrude(slider_length)
|
||||||
|
.translate((0, -slider_width/2, 0))
|
||||||
|
)
|
||||||
|
|
||||||
|
bar_r = (
|
||||||
|
cq.importers.importDXF(path)
|
||||||
|
.wires().toPending()
|
||||||
|
.extrude(slider_length)
|
||||||
|
.translate((0, slider_width/2, 0))
|
||||||
|
)
|
||||||
|
|
||||||
|
# Render
|
||||||
|
show_object(bar_l, name='Left Bar', options={"color": (20, 20, 20)})
|
||||||
|
show_object(bar_r, name='Right Bar', options={"color": (20, 20, 20)})
|
Loading…
x
Reference in New Issue
Block a user