|
Post by tenochtitlanuk on Oct 18, 2022 16:08:20 GMT -5
We are coming up to the Fifth of November, when Brits celebrate with fire and fireworks. It has usually-forgotten origins in an attempt to overthrow a king ( hurray!) or Parliament ( Boo!) or Catholicism- but even further back in ancient autumn season celebrations. I decided to throw together a seasonal animation- set fire to a fuse which wanders round the screen but never crosses itself, and finally detonates. And use my own LB/JB fill routines so it would run on each platform, rather than the dll route.
Draw by hand a single-pixel wide trace in black on a near-black background without crossing- almost impossible 'cos you can't see the track. So, at first, use a colour like red. Yup, nice wiggly trace to the centre. Start a fill- and find it stops at some random place. Try drawing a 2-pixel trace. Now it stops somewhere and goes back to the reds it missed on its curtailed path! Do a bit of thinking and screen-magnifying.Ahah! It's a problem when you HAVE to fill diagonally. Von Neumann or Moore neighbourhoods to any one familiar with the Game of Life. So -rewrite my fill to include diagonal steps as well as vertical/horizontal. Nearly right- but there is still a hidden problem, especially if you allow thicker parts of the fuse... anyway..... here's a Zip file file which is a working version. Not optimised- I wanted a slow fuse! PS The zipfile name is a tribute to a song of my youth- dedicated to the downtrodden and oppressed of Watts and other ghettos...
|
|
|
Post by tenochtitlanuk on Oct 19, 2022 14:21:10 GMT -5
Animated gif of result.. Looks better run in LB of course!
|
|