conworlds
annotate src/vr/opt.h @ 10:e3f0ca1d008a
added preliminary OpenHMD module
author | John Tsiombikas <nuclear@member.fsf.org> |
---|---|
date | Fri, 22 Aug 2014 20:11:15 +0300 |
parents | bd8202d6d28d |
children |
rev | line source |
---|---|
nuclear@8 | 1 #ifndef OPT_H_ |
nuclear@8 | 2 #define OPT_H_ |
nuclear@8 | 3 |
nuclear@8 | 4 enum opt_type { OTYPE_INT, OTYPE_FLOAT }; |
nuclear@8 | 5 |
nuclear@8 | 6 struct option { |
nuclear@8 | 7 enum opt_type type; |
nuclear@8 | 8 int ival; |
nuclear@8 | 9 float fval; |
nuclear@8 | 10 }; |
nuclear@8 | 11 |
nuclear@8 | 12 void *create_options(void); |
nuclear@8 | 13 void destroy_options(void *optdb); |
nuclear@8 | 14 |
nuclear@8 | 15 void set_option_int(void *optdb, const char *key, int val); |
nuclear@8 | 16 void set_option_float(void *optdb, const char *key, float val); |
nuclear@8 | 17 |
nuclear@8 | 18 int get_option_int(void *optdb, const char *key, int *val); |
nuclear@8 | 19 int get_option_float(void *optdb, const char *key, float *val); |
nuclear@8 | 20 |
nuclear@8 | 21 #endif /* OPT_H_ */ |