67 #define chk(x) checkHDFerr(x,__FILE__,__LINE__)
70 fprintf(stderr,
"HDF I/O Error in (%s:%d)\n",
83 chk(DFSDsetdims(1,&timeLen));
84 chk(DFSDsetNT(dataType));
85 chk(DFSDputdata(filename, 1, &timeLen, &time));
93 for (i[2]=0; i[2]<dim[2]; i[2]++)
94 for (i[1]=0; i[1]<dim[1]; i[1]++)
95 for (i[0]=0; i[0]<dim[0]; i[0]++)
97 int c_i=dim[
i], f_i=dim[
i];
105 dSize[0]=dim[2]; dSize[1]=dim[1]; dSize[2]=dim[0];
106 chk(DFSDsetdims(3,dSize));
107 chk(DFSDsetNT(dataType));
108 chk(DFSDadddata(filename, 3, dSize, x));
109 chk(DFSDadddata(filename, 3, dSize, y));
110 chk(DFSDadddata(filename, 3, dSize, z));
113 delete[]
x;
delete[]
y;
delete[]
z;
void int int REAL REAL * y
static int checkHDFerr(int errCode, const char *fName, int lineNo)
void int int int REAL REAL REAL const char * fName
void int int int REAL REAL REAL * z
unsigned long time()
Get the value of a system timer with a millisecond precision.
const char * write_hdf(const blockDim &dim, const vector3d *locs, const char *filename)