removed alg123d

This commit is contained in:
Bernhard 2023-03-21 20:36:39 +01:00
parent 7903e4f640
commit 2c652ff978
11 changed files with 19 additions and 29 deletions

View file

@ -1,5 +1,6 @@
from build123d import *
from build123d.part_operations import *
# from build123d.part_operations import *
b = Box(3, 3, 3)
b2 = Rot(0, 0, 45) * extrude(Rectangle(1, 2), 0.2)

View file

@ -1,5 +1,4 @@
from build123d import *
from build123d.part_operations import *
import build123d.alg_compat as COMPAT
logo_text = Text("123d", font_size=10, align=(Align.MIN, Align.MIN))

View file

@ -1,6 +1,5 @@
from itertools import product
from build123d import *
from build123d.part_operations import *
x_coords = product(range(65 // 5), (-15, -10, 10, 15))
y_coords = product((30, 35), range(30 // 5 - 1))

View file

@ -1,5 +1,4 @@
from build123d import *
from build123d.part_operations import *
import build123d.alg_compat as COMPAT
# 35x7.5mm DIN Rail Dimensions

View file

@ -1,5 +1,4 @@
from build123d import *
from build123d.part_operations import *
import build123d.alg_compat as COMPAT
segment_count = 6

View file

@ -1,6 +1,4 @@
from build123d import *
from build123d.part_operations import *
import alg123d as ad
pipes = Rot(10, 20, 30) * Box(10, 10, 10)
@ -12,7 +10,7 @@ for plane in [Plane(f) for f in pipes.faces()]:
last = pipes.edges()
pipes += extrude(pipe, amount=10)
pipes = ad.fillet(pipes, pipes.edges() - last, radius=0.2)
pipes = fillet(pipes, pipes.edges() - last, radius=0.2)
if "show_object" in locals():
show_object(pipes, name="intersecting pipes")

View file

@ -1,6 +1,5 @@
from build123d import *
from build123d.part_operations import *
import alg123d as ad
import build123d.alg_compat as COMPAT
pip_count = 6
@ -24,7 +23,7 @@ wall_thickness = 1.2
plan = Rectangle(width=block_length, height=block_width)
# Subtract an offset to create the block walls
plan -= ad.offset(
plan -= COMPAT.offset(
plan,
amount=-wall_thickness,
kind=Kind.INTERSECTION,

View file

@ -1,7 +1,6 @@
from math import pi, sin
from build123d import *
from build123d.part_operations import *
import alg123d as ad
import build123d.alg_compat as COMPAT
slice_count = 10
@ -12,7 +11,7 @@ for i in range(slice_count + 1):
art = loft(art)
top_bottom = art.faces(GeomType.PLANE)
art = ad.shell(art, openings=top_bottom, amount=0.5)
art = COMPAT.shell(art, openings=top_bottom, amount=0.5)
if "show_object" in locals():
show_object(art, name="art")

View file

@ -1,6 +1,5 @@
from build123d import *
from build123d.part_operations import *
import alg123d as ad
import build123d.alg_compat as COMPAT
height, width, thickness, padding = 60, 80, 10, 12
screw_shaft_radius, screw_head_radius, screw_head_height = 1.5, 3, 3
@ -8,19 +7,19 @@ bearing_axle_radius, bearing_radius, bearing_thickness = 4, 11, 7
# Build pillow block as an extruded sketch with counter bore holes
plan = Rectangle(width, height)
plan = ad.fillet(plan, plan.vertices(), 5)
plan = COMPAT.fillet(plan, plan.vertices(), 5)
pillow_block = extrude(plan, thickness)
plane = Plane(pillow_block.faces().max())
pillow_block -= plane * ad.CounterBore(
pillow_block -= plane * COMPAT.CounterBore(
pillow_block, bearing_axle_radius, bearing_radius, bearing_thickness
)
for loc in GridLocations(width - 2 * padding, height - 2 * padding, 2, 2):
pillow_block -= (
plane
* loc
* ad.CounterBore(
* COMPAT.CounterBore(
pillow_block, screw_shaft_radius, screw_head_radius, screw_head_height
)
)

View file

@ -1,5 +1,4 @@
from build123d import *
import alg123d as ad
powerup = Spline(
(0, 0, 0),
@ -8,7 +7,7 @@ powerup = Spline(
tangents=((1, 0, 0), (1, 0, 0)),
tangent_scalars=(0.5, 2),
)
corner = ad.RadiusArc(powerup @ 1, (100, 60, 0), -30)
corner = RadiusArc(powerup @ 1, (100, 60, 0), -30)
screw = Pos(75, 40, 15) * Helix(75, 150, 15, direction=(-1, 0, 0))
roller_coaster = powerup + corner + screw

View file

@ -1,11 +1,10 @@
from build123d import *
from build123d.part_operations import *
import alg123d as ad
import build123d.alg_compat as COMPAT
l1 = Line((0, 0), (12, 0))
l2 = ad.RadiusArc(l1 @ 1, (15, 20), 50)
l2 = RadiusArc(l1 @ 1, (15, 20), 50)
l3 = Spline(l2 @ 1, (22, 40), (20, 50), tangents=(l2 % 1, (-0.75, 1)))
l4 = ad.RadiusArc(l3 @ 1, l3 @ 1 + Vector(0, 5), 5)
l4 = RadiusArc(l3 @ 1, l3 @ 1 + Vector(0, 5), 5)
l5 = Spline(
l4 @ 1,
l4 @ 1 + Vector(2.5, 2.5),
@ -19,14 +18,14 @@ outline += Polyline(
(0, (l5 @ 1).Y + 1),
l1 @ 0,
)
profile = ad.make_face(outline)
profile = COMPAT.make_face(outline)
vase = revolve(profile, axis=Axis.Y)
vase = ad.shell(vase, openings=vase.faces().max(Axis.Y), amount=-1)
vase = COMPAT.shell(vase, openings=vase.faces().max(Axis.Y), amount=-1)
top_edges = vase.edges(GeomType.CIRCLE).filter_by_position(Axis.Y, 60, 62)
vase = ad.fillet(vase, top_edges, radius=0.25)
vase = fillet(vase, top_edges, radius=0.25)
vase = ad.fillet(vase, vase.edges().sort_by(Axis.Y)[0], radius=0.5)
vase = fillet(vase, vase.edges().sort_by(Axis.Y)[0], radius=0.5)
if "show_object" in locals():
show_object(vase, name="vase")