File: H5utils.h

package info (click to toggle)
paraview 4.0.1-1~bpo70%2B1
  • links: PTS, VCS
  • area: main
  • in suites: wheezy-backports
  • size: 526,572 kB
  • sloc: cpp: 2,284,430; ansic: 816,374; python: 239,936; xml: 70,162; tcl: 48,295; fortran: 39,116; yacc: 5,466; java: 3,518; perl: 3,107; lex: 1,620; sh: 1,555; makefile: 932; asm: 471; pascal: 228
file content (55 lines) | stat: -rw-r--r-- 2,392 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
// Define this symbol BEFORE including hdf5.h to indicate the HDF5 code
// in this file uses version 1.6 of the HDF5 API. This is harmless for
// versions of HDF5 before 1.8 and ensures correct compilation with
// version 1.8 and thereafter. When, and if, the HDF5 code in this file
// is explicitly upgraded to the 1.8 API, this symbol should be removed.
#define H5_USE_16_API
#include <hdf5.h>
#define MAXLENGTH 256

#define H5NIMROD_SUCCESS 0
#define H5NIMROD_ERR -1

struct _iter_op_data
{
  int stop_idx;
  int count;
  int type;
  char *name;
  size_t len;
  char *pattern;
};
int _transpose_3D (float *data, hsize_t * dims);

hid_t _normalize_h5_type (hid_t type);

herr_t _iteration_operator (hid_t group_id,        /*!< [in]  group id */
                            const char *member_name,        /*!< [in]  group name */
                            void *operator_data);        /*!< [in,out] data passed to the iterator */

int _get_num_groups_matching_pattern (hid_t group_id,
                                      const char *group_name,
                                      const hid_t type, char *const pattern);


int H5NIMROD_read_attrib (hid_t id, const char *attrib_name,
                          void *attrib_value);
int H5NIMROD_read_string_attrib (hid_t id, const char *attrib_name,
                                 char **attrib_value);
int H5NIMROD_read_dims (hid_t id, const char *dataset_name, int *ndims,
                        hsize_t * grid_dims);
int H5NIMROD_get_object_name (hid_t group_id, const char *group_name,
                              const hid_t type, const int idx, char *obj_name,
                              const int len_obj_name);
int H5NIMROD_get_num_objects_matching_pattern (hid_t group_id,
                                               const char *group_name,
                                               const hid_t type,
                                               char *const pattern);
int H5NIMROD_get_object_name (hid_t group_id, const char *group_name,
                              const hid_t type, const int idx, char *obj_name,
                              const int len_obj_name);

int H5NIMROD_read_float32_array (hid_t parent_id,
                                 const char *dataset_name,
                                 hsize_t * offset,
                                 int ndims, hsize_t * dims, float *array);