Get a scalar value from a GSD file gsdGet0x
t | type | Fortran | GSD |
b | char | byte | byte |
l | char | logical1 | logical |
w | short | integer2 | word |
i | int | integer4 | integer |
r | float | real4 | real |
d | double | real8 | double |
c | char[17] | character16 | char |
This routine will convert between numeric types (all but GSD type char). That is to say, the calling
routine can request, say, an integer value by calling gsdGet0i
, even if the item in the GSD file has a
different numeric type, say real. C casting rules are applied, which may differ from Fortran truncation
rules. No test for conversion errors is performed.
gsdGet0c
value should be declared with length 17
at least. The returned string is null-terminated in value[16]. [1:] Failure to read the item value.
[2:] Numbered item cannot be found.
[3:] Item is not scalar.
[0:] Otherwise.