diff options
Diffstat (limited to 'dive.h')
-rw-r--r-- | dive.h | 17 |
1 files changed, 10 insertions, 7 deletions
@@ -155,12 +155,6 @@ typedef struct { const char *description; /* "integrated", "belt", "ankle" */ } weightsystem_t; -extern bool cylinder_nodata(cylinder_t *cyl); -extern bool cylinder_none(void *_data); -extern bool weightsystem_none(void *_data); -extern bool no_weightsystems(weightsystem_t *ws); -extern bool weightsystems_equal(weightsystem_t *ws1, weightsystem_t *ws2); - extern int get_pressure_units(unsigned int mb, const char **units); extern double get_depth_units(unsigned int mm, int *frac, const char **units); extern double get_volume_units(unsigned int ml, int *frac, const char **units); @@ -227,7 +221,7 @@ static inline double psi_to_bar(double psi) return psi / 14.5037738; } -static inline unsigned long psi_to_mbar(double psi) +static inline long psi_to_mbar(double psi) { return psi_to_bar(psi)*1000 + 0.5; } @@ -244,6 +238,7 @@ static inline double bar_to_atm(double bar) /* Volume in mliter of a cylinder at pressure 'p' */ extern int gas_volume(cylinder_t *cyl, pressure_t p); +extern int wet_volume(double cuft, pressure_t p); static inline int mbar_to_PSI(int mbar) { @@ -743,6 +738,14 @@ struct tank_info { int cuft, ml, psi, bar; }; +extern bool cylinder_nodata(cylinder_t *cyl); +extern bool cylinder_none(void *_data); +extern bool weightsystem_none(void *_data); +extern bool no_weightsystems(weightsystem_t *ws); +extern bool weightsystems_equal(weightsystem_t *ws1, weightsystem_t *ws2); +extern void remove_cylinder(struct dive *dive, int idx); +extern void remove_weightsystem(struct dive *dive, int idx); + #ifdef __cplusplus } #endif |