Last change
on this file since 27 was
19,
checked in by dkearney, 19 years ago
|
initial submission of the Rappture Core components and language bindings
|
File size:
1.5 KB
|
Line | |
---|
1 | |
---|
2 | |
---|
3 | #ifdef __cplusplus |
---|
4 | extern "C" { |
---|
5 | #endif |
---|
6 | |
---|
7 | typedef struct RpUnits RpUnits; |
---|
8 | |
---|
9 | // unit definition functions |
---|
10 | RpUnits* defineUnit(const char* unitSymbol, RpUnits* basis); |
---|
11 | |
---|
12 | // conversion definition functions |
---|
13 | RpUnits* defineConv( RpUnits* fromUnit, |
---|
14 | RpUnits* toUnit, |
---|
15 | double (*convForwFxnPtr)(double), |
---|
16 | double (*convBackFxnPtr)(double) ); |
---|
17 | |
---|
18 | // unit attribute access functions |
---|
19 | const char* getUnits(RpUnits* unit); |
---|
20 | |
---|
21 | const char* getUnitsName(RpUnits* unit); |
---|
22 | |
---|
23 | double getExponent(RpUnits* unit); |
---|
24 | |
---|
25 | RpUnits* getBasis(RpUnits* unit); |
---|
26 | |
---|
27 | RpUnits* find(const char* unitSymbol); |
---|
28 | |
---|
29 | int makeMetric(RpUnits* basis); |
---|
30 | |
---|
31 | // convert functions |
---|
32 | const char* convert_str( RpUnits* fromUnits, |
---|
33 | RpUnits* toUnits, |
---|
34 | double val, |
---|
35 | int showUnits ); |
---|
36 | |
---|
37 | const char* convert_str_result( RpUnits* fromUnits, |
---|
38 | RpUnits* toUnits, |
---|
39 | double val, |
---|
40 | int showUnits, |
---|
41 | int* result ); |
---|
42 | |
---|
43 | double convert_double(RpUnits* fromUnits, RpUnits* toUnits, double val); |
---|
44 | |
---|
45 | double convert_double_result( RpUnits* fromUnits, |
---|
46 | RpUnits* toUnits, |
---|
47 | double val, |
---|
48 | int* result ); |
---|
49 | |
---|
50 | |
---|
51 | #ifdef __cplusplus |
---|
52 | } |
---|
53 | #endif |
---|
Note: See
TracBrowser
for help on using the repository browser.