Anonymous user
Bitmap/Midpoint circle algorithm: Difference between revisions
m
use <lang>
(CL code) |
m (use <lang>) |
||
Line 206:
Based upon the OCaml version.
<
(labels ((foo (x y)
(funcall draw-function x y))
Line 234:
(+ m 4 (* 8 x))))))))
(put 0 radius (- 5 (* 4 radius)))
(values)))</
<
:element-type 'bit)))
(draw-circle (lambda (x y)
(setf (bit buffer x y) 1)) 15 15 10)
buffer)</lang>
<pre>;; edited for your convenience
(( )
( 1 1 1 1 1 1 1 )
|