Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Playing with code: a circle function using triangle math
#2
this might be interesting:
Code: (Select All)
Screen _NewImage(400, 400, 32)
r = 100
cx = _Width / 2: cy = _Height / 2
For x = 0 To r
    y = Sqr(r * r - x * x)
    PSet (cx - x, cy - y)
    PSet (cx + x, cy - y)
    PSet (cx - x, cy + y)
    PSet (cx + x, cy + y)


    ' remove comments for no holes
    PSet (cx - y, cy - x)
    PSet (cx + y, cy - x)
    PSet (cx - y, cy + x)
    PSet (cx + y, cy + x)
Next
b = b + ...
Reply


Messages In This Thread
RE: Playing with code: a circle function using triangle math - by bplus - 09-13-2023, 07:50 PM



Users browsing this thread: 1 Guest(s)