libpsys

view src/pstrack.h @ 15:5678915dc2c7

probably done with the psys loader
author John Tsiombikas <nuclear@mutantstargoat.com>
date Mon, 10 Sep 2012 21:57:49 +0300
parents 613d2bf3ea1f
children
line source
1 #ifndef PSTRACK_H_
2 #define PSTRACK_H_
4 #include <vmath/vmath.h>
5 #include <anim/anim.h>
7 struct psys_track {
8 struct anm_track trk;
10 anm_time_t cache_tm;
11 float cache_val;
12 };
14 struct psys_track3 {
15 struct anm_track x, y, z;
17 anm_time_t cache_tm;
18 vec3_t cache_vec;
19 };
21 int psys_init_track(struct psys_track *track);
22 void psys_destroy_track(struct psys_track *track);
24 int psys_init_track3(struct psys_track3 *track);
25 void psys_destroy_track3(struct psys_track3 *track);
27 void psys_eval_track(struct psys_track *track, anm_time_t tm);
28 void psys_set_value(struct psys_track *track, anm_time_t tm, float v);
29 float psys_get_value(struct psys_track *track, anm_time_t tm);
30 float psys_get_cur_value(struct psys_track *track);
32 void psys_eval_track3(struct psys_track3 *track, anm_time_t tm);
33 void psys_set_value3(struct psys_track3 *track, anm_time_t tm, vec3_t v);
34 vec3_t psys_get_value3(struct psys_track3 *track, anm_time_t tm);
35 vec3_t psys_get_cur_value3(struct psys_track3 *track);
37 #endif /* PSTRACK_H_ */