Wednesday 2 May 2007
Art and music
Tonight, Sean’s out of town and M. is performing in a musical uptown, so the house will be free for Flickershow recording, hooray!
Only yesterday I was reading Muffy’s reports from the Open Ears festival and wishing I’d made it back to KW to catch it. I don’t generally get to see many shows, and the reason mostly boils down to Too Damn Busy. Either I’m working late (Sean and I seem to be home at 10pm as often as not), recording or playing with Flickershow, or recovering from the above.
I’m determined to change things around now. Coming home at a more reasonable time, for one thing; for another, working Saturday and staying home to work on music in the middle of the week, when the house is empty.
And I think I’ll have to check out some of the events at Deep Wireless: A Festival Of Radio Art. (Thanks, Torontoist.)
Here’s the latest version of the particle sim - the particles attract this time around, and have random values for mass.
I’ve cleaned up the source and commented the hell out of it, and collected most of the major parameters so they’re easy to adjust before compiling.
Source plus the containing FLA file:
Particles1_8.zip

// Interaction of particles
for (i=numParticles; i; i—) {
for (j=numParticles; j-1; j—) {
should run a bit faster - this is a Cheap Time Optimization that i really ought to get in the habit of using. It works in pretty much any language that has a ‘for’ construct modeled after C.
basically, it runs faster because the check becomes a simple boolean truth check instead of a variable retrieve and compare. It’s a little harder to read, of course. Time optimizations always are. It tends to make a big difference when you iterate an interpreted language over any sizeable number of objects, though!
Also if I was doing this I’d have probably defined the area by throwing a movieclip on the stage and getting bounds from that. And would’ve probably tried to write it such that all the variables live on that clip - that way I could have a couple particle objects in the scene, if I wanted to. (I’ve done this, when I built a simple ‘snow’ particle system - define the area by movie clips, and layer a few with different parameters.)