# messing about with solid 3D geometry

Just a sketch, playing with “extruded shapes” – basically, 3D geometry in a big long cheese log, doped up with some sinusoidal harmonics.

Some code:

```(require fluxus-016/shapes
scheme/list)

(clear)

(define l (build-list 20 (lambda (i)
(vector 0 0 (+ 10 (* -1 i))))))

(define w (build-list 20 (lambda (i)
(* 1 (+ 1 (sin (* 3.14156 (/ i 20))))))))

;(define w (build-list 10 (lambda (i) 4)))

(hint-wire)

(define (sinuside circ complexity)
(define (_ c n)
(cond [(< n 1) empty]
[else
(cons (vadd (car c) (vmul (car c)
(* 0.3 (sin (* (* complexity 3.1415) (/ n (length circ)))))))
(_ (cdr c) (- n 1)))
])
)
(_ circ (length circ))
)

(define circle (sinuside (build-circle-points 80 1) 16))

(define pe
(with-state
(rotate (vector 0 0 90))
(build-partial-extrusion circle l 1)))

(recalc-normals 1)

(define (draw-extr e)
(with-primitive e
(partial-extrude
;(* (length l) (+ 0.5 (* 0.25 (+ (sin (time)) 1))))
(length l)
(sinuside (build-circle-points 80 1) (round (* (time) 16)))
l
w
#(0 1 0)
1)
)
)

(define (animator)

(draw-extr pe)
)

(every-frame (animator))

```

This site uses Akismet to reduce spam. Learn how your comment data is processed.