Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Wireframe animation
#1
Code: (Select All)
Screen _NewImage(1920, 1080, 256): centerX = 1920 / 2: horizonY = 520
Const roadWidth = 1920: Const maxZ = 50: Type LinePoint: z As Single: y As Single: End Type
Dim lines(maxZ) As LinePoint: For i = 0 To maxZ: lines(i).z = i + .1: Next
Do: Cls: For i = 0 To maxZ: z = lines(i).z: scale = 1024 / z: y = horizonY + scale
        Line (centerX - roadWidth * scale / 2, y + 1)-(centerX + roadWidth * scale / 2, y + 1), 11
        Line (centerX - roadWidth * scale / 2, y)-(centerX + roadWidth * scale / 2, y), 3
        Line (centerX - roadWidth * scale / 2, horizonY - (y - horizonY) + 40)-(centerX + roadWidth * scale / 2, horizonY - (y - horizonY) + 40), 5
        lines(i).z = lines(i).z - 0.1: If lines(i).z < 1 Then lines(i).z = maxZ
        Next: For x = -90 + r To 90 + r: px = x / 10! * roadWidth / 640
        x1 = centerX + px * (1080 / 1): y1 = horizonY + (1080 / 1): x2 = centerX + px * (1080 / maxZ): y2 = horizonY + (1080 / maxZ)
        Line (x1, y1 + 1)-(x2, y2 + 1), 15: Line (x1, y1)-(x2, y2), 11
Line (0, 1)-(1919, 1079), 11, B: Next: _Display: _Delay 0.016: Loop


[Image: Screenshot-2025-08-09-162919.png]
Reply


Messages In This Thread
Wireframe animation - by SquirrelMonkey - 08-09-2025, 09:31 PM
RE: Wireframe animation - by Unseen Machine - 08-10-2025, 04:55 PM
RE: Wireframe animation - by SquirrelMonkey - 08-10-2025, 05:19 PM
RE: Wireframe animation - by Unseen Machine - 08-10-2025, 07:11 PM
RE: Wireframe animation - by TempodiBasic - 08-10-2025, 10:12 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Pringle-like Shape Animation SierraKen 0 477 05-24-2025, 12:38 AM
Last Post: SierraKen
  color wheel animation / screensaver madscijr 3 1,043 04-20-2025, 07:20 PM
Last Post: madscijr
  Planetary System Animation James D Jarvis 11 2,312 10-13-2022, 07:33 PM
Last Post: SierraKen
  DNA Animation SierraKen 26 4,659 08-02-2022, 09:53 PM
Last Post: OldMoses

Forum Jump:


Users browsing this thread: 1 Guest(s)