|
|
"bob h" <omn### [at] charternet> wrote in message
news:3d0eda62$1@news.povray.org...
> sin(clock*pi)*TheFloatOrVector // use your own color float or vector
>
> Same could be put in as the transparency value instead, for the color map
> for example. You need to multiply the clock in that sin() by double number
> of times you want it to pulsate. So 8*clock equals 4 pulses.
Ahem! Please allow me to correct myself. The sin(clock*pi) doesn't go from 0
to 1 it instead goes from 0 to 1 and back to 0 again. And when clock is
greater than 1 it actually circulates into the negative, onward to -1 then
back to 0. In other words, sin(clock*0.5*pi) is 0 to 1, and sin(clock*3*pi)
is 0 to 1 (half) to 0 (one) to -1 to 0 (two) to 1 to 0 (three). Make sense?
;-) I sure hope so, because I'm not even sure now. Okay, it is, I just
checked.
Sorry, it's not something I know by memory. Perhaps you know something of
math that I don't anyhow. Just trying to give my idea.
This means you'd have to either wrap abs() around it or compensate for the
negatives in another way, use another method, etcetera. Reason I say that is
probably obvious, negative color values usually aren't conducive for color
mapping and lights unless for some intended purpose.
bob h
Post a reply to this message
|
|