Missed a file

master
Peter Nelson 2010-01-20 10:44:24 +00:00
parent 2d4ffb346b
commit d250b9044a
1 changed files with 16 additions and 0 deletions

16
control.h 100644
View File

@ -0,0 +1,16 @@
struct control_t
{
float value;
float step;
};
static inline void control_setstep(struct control_t *control, float value, uint32_t samples)
{
control->step = (value - control->value) / samples;
}
static inline void control_tick(struct control_t *control)
{
control->value += control->step;
}