3 ms·
This is fun! I was going to try to draw a circle but was missing sin/sqrt. Then I thought of using a lookup table but got stumped. Do you have any pointers f
by nottwo 1y ago
This is fun!
I was going to try to draw a circle but was missing sin/sqrt. Then I thought of using a lookup table but got stumped.
Do you have any pointers for drawing a circle?
I'm looking at demo #4 (https://susam.net/fxyt.html#XYpTN1srN255pTN1sqD https://susam.net/fxyt.html#XYpTN1srN255pTN1sqD) to see where the circular shapes are coming from.
Have you seen Forth Haiku? https://forthsalon.appspot.com/ https://forthsalon.appspot.com/
- onirom 1y agodoesn't need to be accurate, could do something like this (distance + treshold) : https://susam.net/fxyt.html#XN128dXN128dpYN128dYN128dpsN4096lN255pC https://susam.net/fxyt.html#XN128dXN128dpYN128dYN128dpsN4096... smaller with dup : https://susam.net/fxyt.html#XN128dDpYN128dDpsN4096lN255pC https://susam.net/fxyt.html#XN128dDpYN128dDpsN4096lN255pC circles pattern : https://susam.net/fxyt.html#XDpYDpsN8qN3riN255pC https://susam.net/fxyt.html#XDpYDpsN8qN3riN255pC PS: fun tool !
- nottwo 1y agoOh, thanks! X^2 + y^2 > z^2 ? 1 : 0
- mabster 1y agoWas also gonna jump in with the old way of doing circle boundaries, which can be done all integer: https://en.m.wikipedia.org/wiki/Midpoint_circle_algorithm https://en.m.wikipedia.org/wiki/Midpoint_circle_algorithm