hp
toc

Flare

2015-10-17, post № 73

programming, Pygame, Python, #black, #glow, #mouse, #mouse controlled, #pixels, #red, #specs, #spread, #vector, #vector maths

Tinkering around with vectors, I created this fancy program. By left-clicking you spawn a white circle at your current mouse position. This circle then will emit a specific quantity of red pixels (which is 𝑐 = 𝟤 𝜋 𝑟 with 𝑟 = 𝟧𝟢). Those red pixels then get pushed across the screen until they eventually die out.

Controls

  • Left click spawns in a circle,
  • ‘Space’ saves a screenshot.
flare-15.png
flare-20.png
flare-19.png
Source code: flare.py
Jonathan Frech's blog; built 2024/04/13 20:55:09 CEST