| SPXL.TVblog | contactgallery | videoflash | processingmyspace | facebook

Subpixel Visuals – 14 Dec 2007 6 January, 2008 at 9:49 am

Okay, so this seems a little out of date already… but it is about as recent as things are at the moment. I still don’t know how to properly write a .fx shader program (can someone direct me to a resource on this?), but I can figure out enough from some sample effects that came with Neon v2 to make some new ones!

Something I’ve been wanting to do for a while is to mask a layer with another layer, or at least a mask (especially my ‘widescreen’ mask). Why is that important? Well, since the final visual is created by building layers on top of each other, and some effects are built up from a few layers, the ordering becomes rather important, and makes some things impossible to do.

Using some magic from the ‘DeformByTex.fx’ filter I figured out how to set the alpha value based on another image – I didn’t just take the alpha value of the image, or a grey scale, I decided to get fancy and allow you to use the red, green, and blue channels as separate masks, and add combinations of them (and their inverses!). This of course means a lot of slider controls, but maybe that’s just what you want sometimes, even if you mostly don’t.

Then I took things another step further – one of my favourite effects, traced edges (by a sobel algorithm) applied selectively to masked areas. This was a bit tricker, but I eventually got it sorted! Deciding what it means to ‘subtract’ the edges from a (now possibly) semi-transparent ‘base’ image is a bit weird, though, so probably doesn’t make the best sense in the world. Basically, if I’m ‘subtracting’ the edge, I want the edge to appear as dark, which might mean to have an increased opacity, to show the ‘blackness’.

Anyhow, that’s probably already more than you want to know, so I’ll try to get on now with adding a screenshot or two.



Okay, so these stills don’t do the animated visuals justice… as per usual! I’ll see about getting some video evidence happening soon! I haven’t sussed out embedding video here yet. In the meantime, check out my clips under spxl on YouTube.


Leave a Reply