macaroon
19th August 2003 10:50 UTC
hue change
It is possible to change the hue of what's on the avs (on a beat) through either random colours or a random colour from a previously set of pre-defined colours? ie on a beat everything goes red, next beat goes green etc..
Cheers
Magic.X
19th August 2003 11:23 UTC
UnConeD made an APE (additional Plugin) that will do fine. It's called ColorMap. Get it here.
Deamon
19th August 2003 11:49 UTC
Yep, that'll do the trick. Unless it's scopes you want to color, you can change color of scopes onbeat (or any trigger you want) as well. add rgb values to per point data.
x=i*2-1;
y=v/2;
r=1;
g=0;
b=0;
will result into a red colored scope. Values go from 0 to 1. You can of course always use all of avs coding terms, like sin, cos, abs and whatnot.
shreyas_potnis
19th August 2003 12:49 UTC
To change the hue of a color in a ssc, use this:
tpi=2*acos(-1) //twice pi 6.28...
hue=0..6.28;
red=sin(hue+tpi*.33)*.5+.5;
green=sin(hue+tpi*.66)*.5+.5;
blue=sin(hue+tpi*.99)*.5+.5;
dirkdeftly
20th August 2003 01:30 UTC
that's not really a hue setting, but it works okay....
and shreyas, that should be
red=abs(sin(hue));
green=abs(sin(hue+pi/3));
blue=abs(sin(hue-pi/3));
works correctly (as far as i can tell yours doesn't but i haven't tried it yet) and with less operators...
an actual hue shifter that was remotely customizeable would be hard because making a code parser even as simple as avs's in an ape is (afaik) pretty hard to do. unfortunately for us ape's don't come with internal avs language support. but i do think a simple hueshifter that shifted at a constant rate would be pretty easy....
shreyas_potnis
20th August 2003 06:50 UTC
Its all there in the Tips and Tricks thread, and btw mine works fine.
dirkdeftly
20th August 2003 07:51 UTC
it may work fine but it's --ing stupid. what the hell is *.99 about anyway? :P
Zevensoft
20th August 2003 08:27 UTC
You could set up a basic assembler-like language for use in a APE with no more than about 20KB worth of code. The problem is whether people would figure it out. Hell, Commodore made an entire BASIC interpreter in 8KB, and on a CPU without any floating point or division/multiplication instructions.