Simple question about frame rates and timing
in
Programming Questions
•
2 years ago
Hello,
My basic code is;
int s = second(); // Values from 0 - 59
int m = minute(); // Values from 0 - 59
int h = hour(); // Values from 0 - 23
float a = 0;
void setup() {
size (1200,600);
noStroke();
smooth();
colorMode(HSB);
}
void draw() {
fill (180,a,360);
rect (0,0,200,600);
a = a + 3;
if(a>=360) {
a=0;
}
}
and i would like to the blue strip to go from 0 saturation to 360 saturation in 1 second, and then reset...
is this possible?
any help would have a great knock on effect for the other things i am trying to do.
Thanks
James
1