Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Fractals
#1
Here is my favorite of all time! I imagined it in college 1976 let's say, way before I've heard term fractals and it took 40 years to get around to drawing it as imagined thanks to Alpha coloring in QB64, sort of had it with SmallBASIC but needed alpha to get the full spectrum of shading of overlapping squares. 

Code: (Select All)
_Title "recurring squares 2017-10-26 by bplus"
' Now with Alpha coloring!
'reoccuring squares SmallBASIC translation from
Rem reoccuring squares NaaLaa started 2015-05-14 MGA/B+

Const xmax = 700
Const ymax = 700

Screen _NewImage(xmax, ymax, 32)
_ScreenMove 360, 30 'adjust as needed _MIDDLE needs a delay .5 or more for me
Common Shared dimmer
sq = 700: dir = 1
While 1
    Cls
    white& = _RGB(255, 255, 255)
    fRecStep 0, 0, sq, sq, white&
    sqPlus sq / 2, sq / 2, sq / 2
    _Display
    _Limit 20
    dimmer = dimmer + dir
    If dimmer > 255 Then dimmer = 255: dir = dir * -1: _Delay .5
    If dimmer < 0 Then dimmer = 0: dir = dir * -1: _Delay .5
Wend

Sub fRecStep (x1, y1, x2, y2, c&)
    Line (x1, y1)-Step(x2, y2), c&, BF
End Sub

Sub sqPlus (x, y, side)
    cx = x - side / 2: cy = y - side / 2
    fRecStep cx, cy, side, side, _RGBA(0, 0, 0, dimmer)
    If side < 10 Then Exit Sub
    ns = side / 2: nc = colorNumber - 35
    sqPlus cx, cy, ns
    sqPlus cx + side, cy, ns
    sqPlus cx, cy + side, ns
    sqPlus cx + side, cy + side, ns
End Sub

   
I have an 40 year old Ink Wash Drawing that looks very close to this snapshot.
b = b + ...
Reply


Messages In This Thread
Fractals - by bplus - 05-19-2022, 07:34 PM
RE: Fractals - by bplus - 05-19-2022, 07:46 PM
RE: Fractals - by bplus - 05-19-2022, 07:52 PM
RE: Fractals - by bplus - 05-19-2022, 08:03 PM
RE: Fractals - by bplus - 05-19-2022, 08:25 PM
RE: Fractals - by bplus - 05-19-2022, 08:33 PM
RE: Fractals - by TarotRedhand - 05-19-2022, 10:33 PM
RE: Fractals - by bplus - 05-20-2022, 01:14 AM
RE: Fractals - by TarotRedhand - 05-20-2022, 07:01 AM
RE: Fractals - by bplus - 05-20-2022, 03:55 PM
RE: Fractals - by TarotRedhand - 05-21-2022, 10:12 PM
RE: Fractals - by bplus - 05-21-2022, 11:16 PM
RE: Fractals - by bplus - 05-21-2022, 11:33 PM
RE: Fractals - by bplus - 06-03-2022, 03:37 PM
RE: Fractals - by bplus - 06-03-2022, 03:43 PM
RE: Fractals - by bplus - 10-02-2024, 08:01 PM



Users browsing this thread: 2 Guest(s)