How about adding a count(#) function where # is a certain number of seconds or frames that it counts up to before reseting to 0 and starting again.
Seems do-able just not sure what you'd use it for.
Count function
23 posts
Frame or beat section, frame for the number of frames per second, or fps, shown at the bottom of the editor, beat for beats:
t=t+0.05;
0.05 is just an example, just stick in a number however much you want it to go up by each beat or frame.
Frame section:
t=if(above(t,1),0,t);
1 can be however much you want it to go up to. 0 Being wherever you want it to go back to when it gets to 1 or whatever you put in.
t=t+0.05;
0.05 is just an example, just stick in a number however much you want it to go up by each beat or frame.
Frame section:
t=if(above(t,1),0,t);
1 can be however much you want it to go up to. 0 Being wherever you want it to go back to when it gets to 1 or whatever you put in.
thanks
You could also use:
t=t+0.05;
t=t*below(t,1.05);
t=t+0.05;
t=t*below(t,1.05);
hmf, as long as everyone is giving their opinion, here is mine 😛
counter=if(above(counter,resetingpoint),0,counter+value)
That is the basic idea in it, you can use that in the beat or in the frame box.
As for making it seconds... well i have no clean and easy solution but i guess that this *might* work. (use in the frame section)
now=gettime(0) ; fps=1/(now-last) ; last=now ;
second=1/fps ;
Then just use the counter 🙂
counter=if(above(counter,resetingpoint),0,counter+second)
counter=if(above(counter,resetingpoint),0,counter+value)
That is the basic idea in it, you can use that in the beat or in the frame box.
As for making it seconds... well i have no clean and easy solution but i guess that this *might* work. (use in the frame section)
now=gettime(0) ; fps=1/(now-last) ; last=now ;
second=1/fps ;
Then just use the counter 🙂
counter=if(above(counter,resetingpoint),0,counter+second)
not quite correct, tug. and REALLY complicated (why use fps when you need seconds? 🙂)
last=now; // save time index of the last frame
now=gettime(0); // get new time index
seconds=now-last; // and calculate the difference
counter=if(above(counter,resettingpoint), // if counter>your defined maximum value then
counter-resettingpoint // subtract that maximum value from the counter
, // otherwise
counter // leave it unchanged
)+seconds // after the if, add the difference from above to it
Just thinking it my way 😛
value=value+1/fps , would be value=1 after 1 second i think 🙂
value=value+1/fps , would be value=1 after 1 second i think 🙂
value=value+seconds is also value=1 after 1 second 🙂
Yup i realize that now 😛
on a slightly related subject, can we either get a new function mod(var,mod) that supports floats or extend the var%mod operator to not cast integers?
i just got another idea that i actually think people could use and instead of posting a new thread i'll just stick it here: a contrast ape or even intergrated into avs that (obviously) increases the contrast of a preset using a slider, very simple and i would find useful.
Why not use an adjustable effectlist with a white clearscreen in it?
For one, it makes it too bright and i know this can be fixed with fast brightness but all that would slow your preset down. For some people that means a lot.
what the crap am i on about...
what the crap am i on about...
How about color modifier? Can't you use that? 🙂
If i knew how to, yes, but i don't so no.
But even if i could you would still have to agree that a contrast ape would save you a lot of time on writing code (due to the fact that there wouldn't be any) and make things much more simple.
But even if i could you would still have to agree that a contrast ape would save you a lot of time on writing code (due to the fact that there wouldn't be any) and make things much more simple.
Yeah i used to do that a lot too, thinking...
But everytime i said my thoughts out loud i was shot down for my stupid ideas 😔
And so will be most likely this too.
I don't know this for sure, but i think you can change the contrast and brightness just by multiplying or adding/subtracting from the red, green & blue values.
Example:
red=red*2 ;
green=green*2 ;
blue=blue*2
2x brightness
oh and you might turn off that "calculate every frame" box if your CMo doesn't calculate anything dynamicly.
But everytime i said my thoughts out loud i was shot down for my stupid ideas 😔
And so will be most likely this too.
I don't know this for sure, but i think you can change the contrast and brightness just by multiplying or adding/subtracting from the red, green & blue values.
Example:
red=red*2 ;
green=green*2 ;
blue=blue*2
2x brightness
oh and you might turn off that "calculate every frame" box if your CMo doesn't calculate anything dynamicly.
Yes, multiplying adjust the brightness.
And I think it is possible to do contrast in a colour modifier. I just tried to create one and it kinda worked.
And I think it is possible to do contrast in a colour modifier. I just tried to create one and it kinda worked.
with color modifiers, you can do anything you normally do with a gamma ramp. it's the same thing.
hope that helps you 🙂
color modifier (as i understand it) creates a so called "gamma ramp", which is basically 3 arrays (one for R, G and B)of bytes with indices ranging from 0 to 255. Let's call these arrays RGamma[0..255], GGamma[0..255] and BGamma[0..255]. In a color modifier you can write to these arrays by modifying 'red', 'green' and 'blue' in the 'level' part of the Color Modifier(they are in the range from 0 to 1 there)
The color modifier then splits every pixel into its red, green and blue components and looks into the red, green and blue Gamma Ramps respectively to get the new value for each channel.
hope that helps you 🙂
color modifier (as i understand it) creates a so called "gamma ramp", which is basically 3 arrays (one for R, G and B)of bytes with indices ranging from 0 to 255. Let's call these arrays RGamma[0..255], GGamma[0..255] and BGamma[0..255]. In a color modifier you can write to these arrays by modifying 'red', 'green' and 'blue' in the 'level' part of the Color Modifier(they are in the range from 0 to 1 there)
The color modifier then splits every pixel into its red, green and blue components and looks into the red, green and blue Gamma Ramps respectively to get the new value for each channel.
no that doesn't help me at all.
Just a quick question though, how old are all you people?
Just a quick question though, how old are all you people?
Now that's a hardly relevant question... "How old are you?" The heck you are trying to gain with that knowledge?
because i'm only 16, i don't know that much maths and stuff. I just wanted to know how old everyone here is so i can see where i'm at compared to everyone else
Well, intelligence isn't related to age as i've come to witness around here, but there is another thing called wisdom which only comes through experience 😉
Take for example Nic01, i think he just turned 15 and he knows about ten times more math than me and im 21, so knowing about math or something technical does not depend on age.
Take for example Nic01, i think he just turned 15 and he knows about ten times more math than me and im 21, so knowing about math or something technical does not depend on age.
well 10 points to Nic01