refactoring

This commit is contained in:
2008-10-01 15:43:55 +00:00
parent 828388c065
commit 14ef15cf83
45 changed files with 1218 additions and 1293 deletions
+10 -10
View File
@@ -59,7 +59,7 @@
\note
File is always opened in read/writer mode!
*/
h5_file *
h5_file_t *
H5OpenFile (
const char * filename, /*!< file name */
const MPI_Comm comm /*!< MPI communicator */
@@ -78,7 +78,7 @@ H5OpenFile (
*/
h5_err_t
H5CloseFile (
h5_file * fh /*!< file handle */
h5_file_t * fh /*!< file handle */
) {
SET_FNAME ( __func__ );
return h5_close_file ( fh );
@@ -97,9 +97,9 @@ H5CloseFile (
*/
h5_err_t
H5DefineStepNameFormat (
h5_file *f, /*!< Handle to file */
h5_file_t *f, /*!< Handle to file */
const char *name, /*!< Prefix */
const h5part_int64_t width /*!< Width of the number */
const h5_int64_t width /*!< Width of the number */
) {
SET_FNAME ( "H5PartDefineStepNameFormat" );
@@ -116,7 +116,7 @@ H5DefineStepNameFormat (
*/
h5_err_t
H5GetStepNameFormat (
h5_file *f, /*!< Handle to file */
h5_file_t *f, /*!< Handle to file */
char *name, /*!< OUT: Prefix */
const h5_size_t l_name, /*!< length of buffer name */
h5_size_t *width /*!< OUT: Width of the number */
@@ -135,7 +135,7 @@ H5GetStepNameFormat (
*/
h5_err_t
H5SetStep (
h5_file *f, /*!< [in] Handle to open file */
h5_file_t *f, /*!< [in] Handle to open file */
const h5_int64_t step /*!< [in] Step to set. */
) {
@@ -152,7 +152,7 @@ H5SetStep (
*/
h5_int64_t
H5GetStep (
h5_file *f /*!< Handle to open file */
h5_file_t *f /*!< Handle to open file */
) {
SET_FNAME ( __func__ );
@@ -168,7 +168,7 @@ H5GetStep (
*/
h5_err_t
H5StartTraverseSteps (
h5_file *f /*!< Handle to open file */
h5_file_t *f /*!< Handle to open file */
) {
SET_FNAME ( "H5FedStartTraverseSteps" );
@@ -185,10 +185,10 @@ H5StartTraverseSteps (
*/
h5_err_t
H5TraverseSteps (
h5_file *f /*!< Handle to open file */
h5_file_t * f /*!< Handle to open file */
) {
SET_FNAME ( "H5FedStartTraverseSteps" );
SET_FNAME ( __func__ );
return -1;
}
+9 -9
View File
@@ -16,7 +16,7 @@
#ifndef __H5_H
#define __H5_H
h5_file*
h5_file_t *
H5OpenFile (
const char * filename,
const MPI_Comm comm
@@ -24,19 +24,19 @@ H5OpenFile (
h5_err_t
H5CloseFile (
h5_file * fh
h5_file_t * fh
);
h5_err_t
H5DefineStepNameFormat (
h5_file *f,
h5_file_t *f,
const char *name,
const h5part_int64_t width
const h5_int64_t width
);
h5_err_t
H5GetStepNameFormat (
h5_file *f,
h5_file_t *f,
char *name,
const h5_size_t l_name,
h5_size_t *width
@@ -44,22 +44,22 @@ H5GetStepNameFormat (
h5_err_t
H5SetStep (
h5_file *f,
h5_file_t *f,
const h5_int64_t step
);
h5_int64_t
H5GetStep (
h5_file *f
h5_file_t *f
);
h5_err_t
H5StartTraverseSteps (
h5_file *f
h5_file_t *f
);
h5_err_t
H5TraverseSteps (
h5_file *f
h5_file_t *f
);
#endif
+177 -177
View File
@@ -86,7 +86,7 @@ static void
_normalize_partition (
struct H5BlockPartition *p /*!< IN/OUT: partition */
) {
h5part_int64_t x;
h5_int64_t x;
if ( p->i_start > p->i_end ) {
x = p->i_start;
@@ -115,7 +115,7 @@ _normalize_partition (
\return H5_SUCCESS or error code
*/
#ifdef PARALLEL_IO
static h5part_int64_t
static h5_int64_t
_allgather (
const h5_file *f /*!< IN: file handle */
) {
@@ -123,7 +123,7 @@ _allgather (
struct H5BlockPartition *layout = f->block->user_layout;
MPI_Datatype partition_m;
size_t n = sizeof (struct H5BlockPartition) / sizeof (h5part_int64_t);
size_t n = sizeof (struct H5BlockPartition) / sizeof (h5_int64_t);
MPI_Type_contiguous ( n, MPI_LONG_LONG, &partition_m );
MPI_Type_commit ( &partition_m );
@@ -134,9 +134,9 @@ _allgather (
return H5_SUCCESS;
}
#else
static h5part_int64_t
static h5_int64_t
_allgather (
const h5_file *f /*!< IN: file handle */
const h5_file_t *f /*!< IN: file handle */
) {
return H5_SUCCESS;
@@ -153,7 +153,7 @@ _allgather (
*/
static void
_get_dimension_sizes (
h5_file *f /*!< IN: file handle */
h5_file_t *f /*!< IN: file handle */
) {
int proc;
struct h5b_fdata *b = f->block;
@@ -201,7 +201,7 @@ _have_ghostzone (
\return volume
*/
static h5part_int64_t
static h5_int64_t
_volume_of_partition (
const struct H5BlockPartition *p /*!< IN: partition */
) {
@@ -223,17 +223,17 @@ _volume_of_partition (
\return volume
*/
static h5part_int64_t
static h5_int64_t
_volume_of_ghostzone (
const struct H5BlockPartition *p, /*!< IN: ptr to first partition */
const struct H5BlockPartition *q /*!< IN: ptr to second partition */
) {
h5part_int64_t dx = MIN ( p->i_end, q->i_end )
h5_int64_t dx = MIN ( p->i_end, q->i_end )
- MAX ( p->i_start, q->i_start ) + 1;
h5part_int64_t dy = MIN ( p->j_end, q->j_end )
h5_int64_t dy = MIN ( p->j_end, q->j_end )
- MAX ( p->j_start, q->j_start ) + 1;
h5part_int64_t dz = MIN ( p->k_end, q->k_end )
h5_int64_t dz = MIN ( p->k_end, q->k_end )
- MAX ( p->k_start, q->k_start ) + 1;
return dx * dy * dz;
@@ -250,7 +250,7 @@ _volume_of_ghostzone (
\return H5_SUCCESS or -1
*/
static h5part_int64_t
static h5_int64_t
_dissolve_X_ghostzone (
struct H5BlockPartition *p, /*!< IN/OUT: ptr to first partition */
struct H5BlockPartition *q /*!< IN/OUT: ptr to second partition */
@@ -278,7 +278,7 @@ _dissolve_X_ghostzone (
\return H5_SUCCESS or -1
*/
static h5part_int64_t
static h5_int64_t
_dissolve_Y_ghostzone (
struct H5BlockPartition *p, /*!< IN/OUT: ptr to first partition */
struct H5BlockPartition *q /*!< IN/OUT: ptr to second partition */
@@ -306,7 +306,7 @@ _dissolve_Y_ghostzone (
\return H5_SUCCESS or -1
*/
static h5part_int64_t
static h5_int64_t
_dissolve_Z_ghostzone (
struct H5BlockPartition *p, /*!< IN/OUT: ptr to first partition */
struct H5BlockPartition *q /*!< IN/OUT: ptr to second partition */
@@ -337,7 +337,7 @@ _dissolve_Z_ghostzone (
\return H5_SUCCESS or error code.
*/
static h5part_int64_t
static h5_int64_t
_dissolve_ghostzone (
struct H5BlockPartition *p, /*!< IN/OUT: ptr to first partition */
struct H5BlockPartition *q /*!< IN/OUT: ptr to second partition */
@@ -347,8 +347,8 @@ _dissolve_ghostzone (
struct H5BlockPartition q_;
struct H5BlockPartition p_best;
struct H5BlockPartition q_best;
h5part_int64_t vol;
h5part_int64_t max_vol = 0;
h5_int64_t vol;
h5_int64_t max_vol = 0;
p_ = *p;
q_ = *q;
@@ -416,9 +416,9 @@ _dissolve_ghostzone (
\return H5_SUCCESS or error code.
*/
static h5part_int64_t
static h5_int64_t
_dissolve_ghostzones (
h5_file *f /*!< IN: file handle */
h5_file_t *f /*!< IN: file handle */
) {
struct h5b_fdata *b = f->block;
@@ -431,7 +431,7 @@ _dissolve_ghostzones (
struct list *next;
struct H5BlockPartition *p;
struct H5BlockPartition *q;
h5part_int64_t vol;
h5_int64_t vol;
} *p_begin, *p_el, *p_max, *p_end, *p_save;
memcpy ( b->write_layout, b->user_layout,
@@ -528,9 +528,9 @@ _dissolve_ghostzones (
\internal
*/
h5part_int64_t
h5_int64_t
_release_hyperslab (
h5_file *f /*!< IN: file handle */
h5_file_t *f /*!< IN: file handle */
) {
herr_t herr;
@@ -562,15 +562,15 @@ _release_hyperslab (
\c H5PART_ERR_MPI<br>
\c H5PART_ERR_HDF5
*/
h5part_int64_t
h5_int64_t
H5BlockDefine3DFieldLayout(
h5_file *f, /*!< IN: File handle */
const h5part_int64_t i_start, /*!< OUT: start index of \c i */
const h5part_int64_t i_end, /*!< OUT: end index of \c i */
const h5part_int64_t j_start, /*!< OUT: start index of \c j */
const h5part_int64_t j_end, /*!< OUT: end index of \c j */
const h5part_int64_t k_start, /*!< OUT: start index of \c j */
const h5part_int64_t k_end /*!< OUT: end index of \c j */
h5_file_t *f, /*!< IN: File handle */
const h5_int64_t i_start, /*!< OUT: start index of \c i */
const h5_int64_t i_end, /*!< OUT: end index of \c i */
const h5_int64_t j_start, /*!< OUT: start index of \c j */
const h5_int64_t j_end, /*!< OUT: end index of \c j */
const h5_int64_t k_start, /*!< OUT: start index of \c j */
const h5_int64_t k_end /*!< OUT: end index of \c j */
) {
SET_FNAME ( "H5BlockDefine3DFieldLayout" );
@@ -586,7 +586,7 @@ H5BlockDefine3DFieldLayout(
_normalize_partition( p );
h5part_int64_t herr = _allgather ( f );
h5_int64_t herr = _allgather ( f );
if ( herr < 0 ) return HANDLE_MPI_ALLGATHER_ERR;
_get_dimension_sizes ( f );
@@ -611,16 +611,16 @@ H5BlockDefine3DFieldLayout(
\return \c H5_SUCCESS on success.<br>
\c H5PART_ERR_INVAL if proc is invalid.
*/
h5part_int64_t
h5_int64_t
H5Block3dGetPartitionOfProc (
h5_file *f, /*!< IN: File handle */
const h5part_int64_t proc, /*!< IN: Processor to get partition from */
h5part_int64_t *i_start, /*!< OUT: start index of \c i */
h5part_int64_t *i_end, /*!< OUT: end index of \c i */
h5part_int64_t *j_start, /*!< OUT: start index of \c j */
h5part_int64_t *j_end, /*!< OUT: end index of \c j */
h5part_int64_t *k_start, /*!< OUT: start index of \c k */
h5part_int64_t *k_end /*!< OUT: end index of \c k */
h5_file_t *f, /*!< IN: File handle */
const h5_int64_t proc, /*!< IN: Processor to get partition from */
h5_int64_t *i_start, /*!< OUT: start index of \c i */
h5_int64_t *i_end, /*!< OUT: end index of \c i */
h5_int64_t *j_start, /*!< OUT: start index of \c j */
h5_int64_t *j_end, /*!< OUT: end index of \c j */
h5_int64_t *k_start, /*!< OUT: start index of \c k */
h5_int64_t *k_end /*!< OUT: end index of \c k */
) {
SET_FNAME ( "H5Block3dGetProcOf" );
@@ -650,16 +650,16 @@ H5Block3dGetPartitionOfProc (
\return \c H5_SUCCESS on success.<br>
\c H5PART_ERR_INVAL if proc is invalid.
*/
h5part_int64_t
h5_int64_t
H5Block3dGetReducedPartitionOfProc (
h5_file *f, /*!< IN: File handle */
h5part_int64_t proc, /*!< IN: Processor to get partition from */
h5part_int64_t *i_start, /*!< OUT: start index of \c i */
h5part_int64_t *i_end, /*!< OUT: end index of \c i */
h5part_int64_t *j_start, /*!< OUT: start index of \c j */
h5part_int64_t *j_end, /*!< OUT: end index of \c j */
h5part_int64_t *k_start, /*!< OUT: start index of \c j */
h5part_int64_t *k_end /*!< OUT: end index of \c j */
h5_file_t *f, /*!< IN: File handle */
h5_int64_t proc, /*!< IN: Processor to get partition from */
h5_int64_t *i_start, /*!< OUT: start index of \c i */
h5_int64_t *i_end, /*!< OUT: end index of \c i */
h5_int64_t *j_start, /*!< OUT: start index of \c j */
h5_int64_t *j_end, /*!< OUT: end index of \c j */
h5_int64_t *k_start, /*!< OUT: start index of \c j */
h5_int64_t *k_end /*!< OUT: end index of \c j */
) {
SET_FNAME ( "H5Block3dGetProcOf" );
@@ -689,12 +689,12 @@ H5Block3dGetReducedPartitionOfProc (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
H5Block3dGetProcOf (
h5_file *f, /*!< IN: File handle */
h5part_int64_t i, /*!< IN: \c i coordinate */
h5part_int64_t j, /*!< IN: \c j coordinate */
h5part_int64_t k /*!< IN: \c k coordinate */
h5_file_t *f, /*!< IN: File handle */
h5_int64_t i, /*!< IN: \c i coordinate */
h5_int64_t j, /*!< IN: \c j coordinate */
h5_int64_t k /*!< IN: \c k coordinate */
) {
SET_FNAME ( "H5Block3dGetProcOf" );
@@ -707,7 +707,7 @@ H5Block3dGetProcOf (
if ( (layout->i_start <= i) && (i <= layout->i_end) &&
(layout->j_start <= j) && (j <= layout->j_end) &&
(layout->k_start <= k) && (k <= layout->k_end) )
return (h5part_int64_t)proc;
return (h5_int64_t)proc;
}
return -1;
@@ -722,9 +722,9 @@ H5Block3dGetProcOf (
\return \c H5_SUCCESS or error code
*/
static h5part_int64_t
static h5_int64_t
_open_block_group (
const h5_file *f /*!< IN: file handle */
const h5_file_t *f /*!< IN: file handle */
) {
struct h5b_fdata *b = f->block;
@@ -756,7 +756,7 @@ _open_block_group (
\internal
*/
static h5part_int64_t
static h5_int64_t
_have_object (
const hid_t id,
const char *name
@@ -771,15 +771,15 @@ _have_object (
\return \c H5_SUCCESS or error code
*/
static h5part_int64_t
static h5_int64_t
_open_field_group (
h5_file *f, /*!< IN: file handle */
h5_file_t *f, /*!< IN: file handle */
const char *name
) {
struct h5b_fdata *b = f->block;
h5part_int64_t h5err = _open_block_group ( f );
h5_int64_t h5err = _open_block_group ( f );
if ( h5err < 0 ) return h5err;
if ( ! _have_object ( b->blockgroup, name ) )
@@ -801,9 +801,9 @@ _open_field_group (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
_close_field_group (
h5_file *f /*!< IN: file handle */
h5_file_t *f /*!< IN: file handle */
) {
herr_t herr = H5Gclose ( f->block->field_group_id );
@@ -819,9 +819,9 @@ _close_field_group (
\return \c H5_SUCCESS or error code
*/
static h5part_int64_t
static h5_int64_t
_select_hyperslab_for_reading (
h5_file *f, /*!< IN: file handle */
h5_file_t *f, /*!< IN: file handle */
hid_t dataset
) {
@@ -839,7 +839,7 @@ _select_hyperslab_for_reading (
p->j_end - p->j_start + 1,
p->i_end - p->i_start + 1 };
h5part_int64_t herr = _release_hyperslab ( f );
h5_int64_t herr = _release_hyperslab ( f );
if ( herr < 0 ) return HANDLE_H5S_CLOSE_ERR;
b->diskshape = H5Dget_space ( dataset );
@@ -907,11 +907,11 @@ _select_hyperslab_for_reading (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
_read_data (
h5_file *f, /*!< IN: file handle */
h5_file_t *f, /*!< IN: file handle */
const char *name, /*!< IN: name of dataset to read */
h5part_float64_t *data /*!< OUT: ptr to read buffer */
h5_float64_t *data /*!< OUT: ptr to read buffer */
) {
struct h5b_fdata *b = f->block;
@@ -919,7 +919,7 @@ _read_data (
hid_t dataset_id = H5Dopen ( b->field_group_id, name, H5P_DEFAULT );
if ( dataset_id < 0 ) return HANDLE_H5D_OPEN_ERR ( name );
h5part_int64_t herr = _select_hyperslab_for_reading ( f, dataset_id );
h5_int64_t herr = _select_hyperslab_for_reading ( f, dataset_id );
if ( herr < 0 ) return herr;
herr = H5Dread (
@@ -948,18 +948,18 @@ _read_data (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
H5Block3dReadScalarField (
h5_file *f, /*!< IN: file handle */
h5_file_t *f, /*!< IN: file handle */
const char *name, /*!< IN: name of dataset to read */
h5part_float64_t *data /*!< OUT: ptr to read buffer */
h5_float64_t *data /*!< OUT: ptr to read buffer */
) {
SET_FNAME ( "H5Block3dReadScalarField" );
CHECK_TIMEGROUP ( f );
CHECK_LAYOUT ( f );
h5part_int64_t herr = _open_field_group ( f, name );
h5_int64_t herr = _open_field_group ( f, name );
if ( herr < 0 ) return herr;
herr = _read_data ( f, "0", data );
@@ -983,20 +983,20 @@ H5Block3dReadScalarField (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
H5Block3dRead3dVectorField (
h5_file *f, /*!< IN: file handle */
h5_file_t *f, /*!< IN: file handle */
const char *name, /*!< IN: name of dataset to read */
h5part_float64_t *x_data, /*!< OUT: ptr to read buffer X axis */
h5part_float64_t *y_data, /*!< OUT: ptr to read buffer Y axis */
h5part_float64_t *z_data /*!< OUT: ptr to read buffer Z axis */
h5_float64_t *x_data, /*!< OUT: ptr to read buffer X axis */
h5_float64_t *y_data, /*!< OUT: ptr to read buffer Y axis */
h5_float64_t *z_data /*!< OUT: ptr to read buffer Z axis */
) {
SET_FNAME ( "H5Block3dRead3dVectorField" );
CHECK_TIMEGROUP ( f );
CHECK_LAYOUT ( f );
h5part_int64_t herr = _open_field_group ( f, name );
h5_int64_t herr = _open_field_group ( f, name );
if ( herr < 0 ) return herr;
herr = _read_data ( f, "0", x_data );
@@ -1021,9 +1021,9 @@ H5Block3dRead3dVectorField (
\return \c H5_SUCCESS or error code
*/
static h5part_int64_t
static h5_int64_t
_select_hyperslab_for_writing (
h5_file *f /*!< IN: file handle */
h5_file_t *f /*!< IN: file handle */
) {
/*
@@ -1137,9 +1137,9 @@ _select_hyperslab_for_writing (
\return \c H5_SUCCESS or error code
*/
static h5part_int64_t
static h5_int64_t
_create_block_group (
const h5_file *f /*!< IN: file handle */
const h5_file_t *f /*!< IN: file handle */
) {
herr_t herr;
@@ -1166,13 +1166,13 @@ _create_block_group (
\return \c H5_SUCCESS or error code
*/
static h5part_int64_t
static h5_int64_t
_create_field_group (
h5_file *f, /*!< IN: file handle */
h5_file_t *f, /*!< IN: file handle */
const char *name /*!< IN: name of field group to create */
) {
h5part_int64_t h5err;
h5_int64_t h5err;
struct h5b_fdata *b = f->block;
@@ -1203,11 +1203,11 @@ _create_field_group (
\return \c H5_SUCCESS or error code
*/
static h5part_int64_t
static h5_int64_t
_write_field_data (
h5_file *f, /*!< IN: file handle */
h5_file_t *f, /*!< IN: file handle */
const char *name, /*!< IN: name of dataset to write */
const h5part_float64_t *data /*!< IN: data to write */
const h5_float64_t *data /*!< IN: data to write */
) {
struct h5b_fdata *b = f->block;
@@ -1234,11 +1234,11 @@ _write_field_data (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
H5Block3dWriteScalarField (
h5_file *f, /*!< IN: file handle */
h5_file_t *f, /*!< IN: file handle */
const char *name, /*!< IN: name of dataset to write */
const h5part_float64_t *data /*!< IN: scalar data to write */
const h5_float64_t *data /*!< IN: scalar data to write */
) {
SET_FNAME ( "H5Block3dWriteScalarField" );
@@ -1246,7 +1246,7 @@ H5Block3dWriteScalarField (
CHECK_TIMEGROUP ( f );
CHECK_LAYOUT ( f );
h5part_int64_t herr = _create_field_group ( f, name );
h5_int64_t herr = _create_field_group ( f, name );
if ( herr < 0 ) return herr;
herr = _write_field_data (
f,
@@ -1273,13 +1273,13 @@ H5Block3dWriteScalarField (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
H5Block3dWrite3dVectorField (
h5_file *f, /*!< IN: file handle */
h5_file_t *f, /*!< IN: file handle */
const char *name, /*!< IN: name of dataset to write */
const h5part_float64_t *x_data, /*!< IN: X axis data */
const h5part_float64_t *y_data, /*!< IN: Y axis data */
const h5part_float64_t *z_data /*!< IN: Z axis data */
const h5_float64_t *x_data, /*!< IN: X axis data */
const h5_float64_t *y_data, /*!< IN: Y axis data */
const h5_float64_t *z_data /*!< IN: Z axis data */
) {
SET_FNAME ( "H5Block3dWrite3dVectorField" );
@@ -1287,7 +1287,7 @@ H5Block3dWrite3dVectorField (
CHECK_TIMEGROUP ( f );
CHECK_LAYOUT ( f );
h5part_int64_t herr = _create_field_group ( f, name );
h5_int64_t herr = _create_field_group ( f, name );
if ( herr < 0 ) return herr;
herr = _write_field_data ( f, "0", x_data );
@@ -1312,9 +1312,9 @@ H5Block3dWrite3dVectorField (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
H5BlockGetNumFields (
h5_file *f /*!< IN: file handle */
h5_file_t *f /*!< IN: file handle */
) {
SET_FNAME ( "H5BlockGetNumFields" );
@@ -1333,19 +1333,19 @@ H5BlockGetNumFields (
\return \c H5_SUCCESS or error code
*/
static h5part_int64_t
static h5_int64_t
_get_field_info (
h5_file *f, /*!< IN: file handle */
h5_file_t *f, /*!< IN: file handle */
const char *field_name, /*!< IN: field name to get info about */
h5part_int64_t *grid_rank, /*!< OUT: rank of grid */
h5part_int64_t *grid_dims, /*!< OUT: dimensions of grid */
h5part_int64_t *field_dims /*!< OUT: rank of field (1 or 3) */
h5_int64_t *grid_rank, /*!< OUT: rank of grid */
h5_int64_t *grid_dims, /*!< OUT: dimensions of grid */
h5_int64_t *field_dims /*!< OUT: rank of field (1 or 3) */
) {
hsize_t dims[16];
h5part_int64_t i, j;
h5_int64_t i, j;
h5part_int64_t herr = _open_block_group ( f );
h5_int64_t herr = _open_block_group ( f );
if ( herr < 0 ) return herr;
hid_t group_id = H5Gopen ( f->block->blockgroup, field_name,
@@ -1363,7 +1363,7 @@ _get_field_info (
if ( *grid_rank < 0 ) return HANDLE_H5S_GET_SIMPLE_EXTENT_DIMS_ERR;
for ( i = 0, j = *grid_rank-1; i < *grid_rank; i++, j-- )
grid_dims[i] = (h5part_int64_t)dims[j];
grid_dims[i] = (h5_int64_t)dims[j];
*field_dims = h5_get_num_objects (
f->block->blockgroup,
@@ -1396,21 +1396,21 @@ _get_field_info (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
H5BlockGetFieldInfo (
h5_file *f, /*!< IN: file handle */
const h5part_int64_t idx, /*!< IN: index of field */
h5_file_t *f, /*!< IN: file handle */
const h5_int64_t idx, /*!< IN: index of field */
char *field_name, /*!< OUT: field name */
const h5part_int64_t len_field_name, /*!< IN: buffer size */
h5part_int64_t *grid_rank, /*!< OUT: grid rank */
h5part_int64_t *grid_dims, /*!< OUT: grid dimensions */
h5part_int64_t *field_dims /*!< OUT: field rank */
const h5_int64_t len_field_name, /*!< IN: buffer size */
h5_int64_t *grid_rank, /*!< OUT: grid rank */
h5_int64_t *grid_dims, /*!< OUT: grid dimensions */
h5_int64_t *field_dims /*!< OUT: field rank */
) {
SET_FNAME ( "H5BlockGetFieldInfo" );
CHECK_TIMEGROUP( f );
h5part_int64_t herr = h5_get_object_name (
h5_int64_t herr = h5_get_object_name (
f->step_gid,
H5BLOCK_GROUPNAME_BLOCK,
H5G_GROUP,
@@ -1430,13 +1430,13 @@ H5BlockGetFieldInfo (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
H5BlockGetFieldInfoByName (
h5_file *f, /*!< IN: file handle */
h5_file_t *f, /*!< IN: file handle */
const char *field_name, /*!< IN: field name */
h5part_int64_t *grid_rank, /*!< OUT: grid rank */
h5part_int64_t *grid_dims, /*!< OUT: grid dimensions */
h5part_int64_t *field_dims /*!< OUT: field rank */
h5_int64_t *grid_rank, /*!< OUT: grid rank */
h5_int64_t *grid_dims, /*!< OUT: grid dimensions */
h5_int64_t *field_dims /*!< OUT: field rank */
) {
SET_FNAME ( "H5BlockGetFieldInfo" );
@@ -1455,17 +1455,17 @@ H5BlockGetFieldInfoByName (
\return \c H5_SUCCESS or error code
*/
static h5part_int64_t
static h5_int64_t
_write_field_attrib (
h5_file *f, /*!< IN: file handle */
h5_file_t *f, /*!< IN: file handle */
const char *field_name, /*!< IN: field name */
const char *attrib_name, /*!< IN: attribute name */
const hid_t attrib_type, /*!< IN: attribute type */
const void *attrib_value, /*!< IN: attribute value */
const h5part_int64_t attrib_nelem /*!< IN: number of elements */
const h5_int64_t attrib_nelem /*!< IN: number of elements */
) {
h5part_int64_t herr = _open_field_group ( f, field_name );
h5_int64_t herr = _open_field_group ( f, field_name );
if ( herr < 0 ) return herr;
h5_write_attrib (
@@ -1490,14 +1490,14 @@ _write_field_attrib (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
H5BlockWriteFieldAttrib (
h5_file *f, /*!< IN: file handle */
h5_file_t *f, /*!< IN: file handle */
const char *field_name, /*!< IN: field name */
const char *attrib_name, /*!< IN: attribute name */
const h5part_int64_t attrib_type, /*!< IN: attribute type */
const h5_int64_t attrib_type, /*!< IN: attribute type */
const void *attrib_value, /*!< IN: attribute value */
const h5part_int64_t attrib_nelem /*!< IN: number of elements */
const h5_int64_t attrib_nelem /*!< IN: number of elements */
) {
SET_FNAME ( "H5BlockWriteFieldAttrib" );
@@ -1519,9 +1519,9 @@ H5BlockWriteFieldAttrib (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
H5BlockWriteFieldAttribString (
h5_file *f, /*!< IN: file handle */
h5_file_t *f, /*!< IN: file handle */
const char *field_name, /*!< IN: field name */
const char *attrib_name, /*!< IN: attribute name */
const char *attrib_value /*!< IN: attribute value */
@@ -1545,19 +1545,19 @@ H5BlockWriteFieldAttribString (
\return number of attributes or error code
*/
h5part_int64_t
h5_int64_t
H5BlockGetNumFieldAttribs (
h5_file *f, /*!< IN: file handle */
h5_file_t *f, /*!< IN: file handle */
const char *field_name /*<! IN: field name */
) {
SET_FNAME ( "H5BlockGetNumFieldAttribs" );
CHECK_TIMEGROUP( f );
h5part_int64_t herr = _open_field_group ( f, field_name );
h5_int64_t herr = _open_field_group ( f, field_name );
if ( herr < 0 ) return herr;
h5part_int64_t nattribs = H5Aget_num_attrs (
h5_int64_t nattribs = H5Aget_num_attrs (
f->block->field_group_id );
if ( nattribs < 0 ) HANDLE_H5A_GET_NUM_ATTRS_ERR;
@@ -1577,21 +1577,21 @@ H5BlockGetNumFieldAttribs (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
H5BlockGetFieldAttribInfo (
h5_file *f, /*!< IN: file handle */
h5_file_t *f, /*!< IN: file handle */
const char *field_name, /*!< IN: field name */
const h5part_int64_t attrib_idx, /*!< IN: attribute index */
const h5_int64_t attrib_idx, /*!< IN: attribute index */
char *attrib_name, /*!< OUT: attribute name */
const h5part_int64_t len_of_attrib_name,/*!< IN: buffer size */
h5part_int64_t *attrib_type, /*!< OUT: attribute type */
h5part_int64_t *attrib_nelem /*!< OUT: number of elements */
const h5_int64_t len_of_attrib_name,/*!< IN: buffer size */
h5_int64_t *attrib_type, /*!< OUT: attribute type */
h5_int64_t *attrib_nelem /*!< OUT: number of elements */
) {
SET_FNAME ( "H5BlockGetFieldAttribInfo" );
CHECK_TIMEGROUP( f );
h5part_int64_t herr = _open_field_group ( f, field_name );
h5_int64_t herr = _open_field_group ( f, field_name );
if ( herr < 0 ) return herr;
herr = h5_get_attrib_info (
@@ -1618,9 +1618,9 @@ H5BlockGetFieldAttribInfo (
\return \c H5_SUCCESS or error code
*/
static h5part_int64_t
static h5_int64_t
_read_field_attrib (
h5_file *f, /*!< IN: file handle */
h5_file_t *f, /*!< IN: file handle */
const char *field_name, /*!< IN: field name */
const char *attrib_name, /*!< IN: attribute name */
void *attrib_value /*!< OUT: value */
@@ -1628,7 +1628,7 @@ _read_field_attrib (
struct h5b_fdata *b = f->block;
h5part_int64_t herr = _open_field_group ( f, field_name );
h5_int64_t herr = _open_field_group ( f, field_name );
if ( herr < 0 ) return herr;
herr = h5_read_attrib (
@@ -1650,9 +1650,9 @@ _read_field_attrib (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
H5BlockReadFieldAttrib (
h5_file *f, /*!< IN: file handle */
h5_file_t *f, /*!< IN: file handle */
const char *field_name, /*!< IN: field name */
const char *attrib_name, /*!< IN: attribute name */
void *attrib_value /*!< OUT: value */
@@ -1676,21 +1676,21 @@ H5BlockReadFieldAttrib (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
H5Block3dGetFieldOrigin (
h5_file *f, /*!< IN: file handle */
h5_file_t *f, /*!< IN: file handle */
const char *field_name, /*!< IN: field name */
h5part_float64_t *x_origin, /*!< OUT: X origin */
h5part_float64_t *y_origin, /*!< OUT: Y origin */
h5part_float64_t *z_origin /*!< OUT: Z origin */
h5_float64_t *x_origin, /*!< OUT: X origin */
h5_float64_t *y_origin, /*!< OUT: Y origin */
h5_float64_t *z_origin /*!< OUT: Z origin */
) {
SET_FNAME ( "H5BlockSetFieldOrigin" );
CHECK_TIMEGROUP( f );
h5part_float64_t origin[3];
h5_float64_t origin[3];
h5part_int64_t herr = _read_field_attrib (
h5_int64_t herr = _read_field_attrib (
f,
field_name,
H5BLOCK_FIELD_ORIGIN_NAME,
@@ -1709,20 +1709,20 @@ H5Block3dGetFieldOrigin (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
H5Block3dSetFieldOrigin (
h5_file *f, /*!< IN: file handle */
h5_file_t *f, /*!< IN: file handle */
const char *field_name, /*!< IN: field name */
const h5part_float64_t x_origin, /*!< IN: X origin */
const h5part_float64_t y_origin, /*!< IN: Y origin */
const h5part_float64_t z_origin /*!< IN: Z origin */
const h5_float64_t x_origin, /*!< IN: X origin */
const h5_float64_t y_origin, /*!< IN: Y origin */
const h5_float64_t z_origin /*!< IN: Z origin */
) {
SET_FNAME ( "H5BlockSetFieldOrigin" );
CHECK_WRITABLE_MODE( f );
CHECK_TIMEGROUP( f );
h5part_float64_t origin[3] = { x_origin, y_origin, z_origin };
h5_float64_t origin[3] = { x_origin, y_origin, z_origin };
return _write_field_attrib (
f,
@@ -1740,21 +1740,21 @@ H5Block3dSetFieldOrigin (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
H5Block3dGetFieldSpacing (
h5_file *f, /*!< IN: file handle */
h5_file_t *f, /*!< IN: file handle */
const char *field_name, /*!< IN: field name */
h5part_float64_t *x_spacing, /*!< OUT: X spacing */
h5part_float64_t *y_spacing, /*!< OUT: Y spacing */
h5part_float64_t *z_spacing /*!< OUT: Z spacing */
h5_float64_t *x_spacing, /*!< OUT: X spacing */
h5_float64_t *y_spacing, /*!< OUT: Y spacing */
h5_float64_t *z_spacing /*!< OUT: Z spacing */
) {
SET_FNAME ( "H5BlockGetFieldSpacing" );
CHECK_TIMEGROUP( f );
h5part_float64_t spacing[3];
h5_float64_t spacing[3];
h5part_int64_t herr = _read_field_attrib (
h5_int64_t herr = _read_field_attrib (
f,
field_name,
H5BLOCK_FIELD_SPACING_NAME,
@@ -1773,20 +1773,20 @@ H5Block3dGetFieldSpacing (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
H5Block3dSetFieldSpacing (
h5_file *f, /*!< IN: file handle */
h5_file_t *f, /*!< IN: file handle */
const char *field_name, /*!< IN: field name */
const h5part_float64_t x_spacing, /*!< IN: X spacing */
const h5part_float64_t y_spacing, /*!< IN: Y spacing */
const h5part_float64_t z_spacing /*!< IN: Z spacing */
const h5_float64_t x_spacing, /*!< IN: X spacing */
const h5_float64_t y_spacing, /*!< IN: Y spacing */
const h5_float64_t z_spacing /*!< IN: Z spacing */
) {
SET_FNAME ( "H5BlockSetFieldSpacing" );
CHECK_WRITABLE_MODE( f );
CHECK_TIMEGROUP( f );
h5part_float64_t spacing[3] = { x_spacing, y_spacing, z_spacing };
h5_float64_t spacing[3] = { x_spacing, y_spacing, z_spacing };
return _write_field_attrib (
f,
@@ -1806,9 +1806,9 @@ H5Block3dSetFieldSpacing (
\return \c H5_SUCCESS if field data is available otherwise \c
H5PART_ERR_NOENTRY.
*/
h5part_int64_t
h5_int64_t
H5BlockHasFieldData (
h5_file *f /*!< IN: file handle */
h5_file_t *f /*!< IN: file handle */
) {
SET_FNAME ( "H5BlockHasFieldData" );
+99 -99
View File
@@ -10,190 +10,190 @@ extern "C" {
*/
h5part_int64_t
h5_int64_t
H5BlockDefine3DFieldLayout (
h5_file *f,
const h5part_int64_t i_start,
const h5part_int64_t i_end,
const h5part_int64_t j_start,
const h5part_int64_t j_end,
const h5part_int64_t k_start,
const h5part_int64_t k_end
h5_file_t *f,
const h5_int64_t i_start,
const h5_int64_t i_end,
const h5_int64_t j_start,
const h5_int64_t j_end,
const h5_int64_t k_start,
const h5_int64_t k_end
);
h5part_int64_t
h5_int64_t
H5Block3dGetPartitionOfProc (
h5_file *f,
const h5part_int64_t proc,
h5part_int64_t *i_start,
h5part_int64_t *i_end,
h5part_int64_t *j_start,
h5part_int64_t *j_end,
h5part_int64_t *k_start,
h5part_int64_t *k_end
h5_file_t *f,
const h5_int64_t proc,
h5_int64_t *i_start,
h5_int64_t *i_end,
h5_int64_t *j_start,
h5_int64_t *j_end,
h5_int64_t *k_start,
h5_int64_t *k_end
);
h5part_int64_t
h5_int64_t
H5Block3dGetReducedPartitionOfProc (
h5_file *f,
h5part_int64_t proc,
h5part_int64_t *i_start,
h5part_int64_t *i_end,
h5part_int64_t *j_start,
h5part_int64_t *j_end,
h5part_int64_t *k_start,
h5part_int64_t *k_end
h5_file_t *f,
h5_int64_t proc,
h5_int64_t *i_start,
h5_int64_t *i_end,
h5_int64_t *j_start,
h5_int64_t *j_end,
h5_int64_t *k_start,
h5_int64_t *k_end
);
h5part_int64_t
h5_int64_t
H5Block3dGetProcOf (
h5_file *f,
h5part_int64_t i,
h5part_int64_t j,
h5part_int64_t k
h5_file_t *f,
h5_int64_t i,
h5_int64_t j,
h5_int64_t k
);
h5part_int64_t
h5_int64_t
H5Block3dWriteScalarField (
h5_file *f,
h5_file_t *f,
const char *name,
const h5part_float64_t *data
const h5_float64_t *data
);
h5part_int64_t
h5_int64_t
H5Block3dReadScalarField (
h5_file *f,
h5_file_t *f,
const char *name,
h5part_float64_t *data
h5_float64_t *data
);
h5part_int64_t
h5_int64_t
H5BlockGetNumFields (
h5_file *f
h5_file_t *f
);
h5part_int64_t
h5_int64_t
H5BlockGetFieldInfo (
h5_file *f,
const h5part_int64_t idx,
h5_file_t *f,
const h5_int64_t idx,
char *name,
const h5part_int64_t len_name,
h5part_int64_t *grid_rank,
h5part_int64_t *grid_dims,
h5part_int64_t *field_dims
const h5_int64_t len_name,
h5_int64_t *grid_rank,
h5_int64_t *grid_dims,
h5_int64_t *field_dims
);
h5part_int64_t
h5_int64_t
H5BlockGetFieldInfoByName (
h5_file *f,
h5_file_t *f,
const char *field_name,
h5part_int64_t *grid_rank,
h5part_int64_t *grid_dims,
h5part_int64_t *field_dims
h5_int64_t *grid_rank,
h5_int64_t *grid_dims,
h5_int64_t *field_dims
);
h5part_int64_t
h5_int64_t
H5Block3dGetFieldOrigin (
h5_file *f,
h5_file_t *f,
const char *field_name,
h5part_float64_t *x_origin,
h5part_float64_t *y_origin,
h5part_float64_t *z_origin
h5_float64_t *x_origin,
h5_float64_t *y_origin,
h5_float64_t *z_origin
);
h5part_int64_t
h5_int64_t
H5Block3dSetFieldOrigin (
h5_file *f,
h5_file_t *f,
const char *field_name,
const h5part_float64_t x_origin,
const h5part_float64_t y_origin,
const h5part_float64_t z_origin
const h5_float64_t x_origin,
const h5_float64_t y_origin,
const h5_float64_t z_origin
);
h5part_int64_t
h5_int64_t
H5Block3dGetFieldSpacing (
h5_file *f,
h5_file_t *f,
const char *field_name,
h5part_float64_t *x_spacing,
h5part_float64_t *y_spacing,
h5part_float64_t *z_spacing
h5_float64_t *x_spacing,
h5_float64_t *y_spacing,
h5_float64_t *z_spacing
);
h5part_int64_t
h5_int64_t
H5Block3dSetFieldSpacing (
h5_file *f,
h5_file_t *f,
const char *field_name,
const h5part_float64_t x_spacing,
const h5part_float64_t y_spacing,
const h5part_float64_t z_spacing
const h5_float64_t x_spacing,
const h5_float64_t y_spacing,
const h5_float64_t z_spacing
);
h5part_int64_t
h5_int64_t
H5Block3dWrite3dVectorField (
h5_file *f,
h5_file_t *f,
const char *name,
const h5part_float64_t *xval,
const h5part_float64_t *yval,
const h5part_float64_t *zval
const h5_float64_t *xval,
const h5_float64_t *yval,
const h5_float64_t *zval
);
h5part_int64_t
h5_int64_t
H5Block3dRead3dVectorField (
h5_file *f,
h5_file_t *f,
const char *name,
h5part_float64_t *xval,
h5part_float64_t *yval,
h5part_float64_t *zval
h5_float64_t *xval,
h5_float64_t *yval,
h5_float64_t *zval
);
h5part_int64_t
h5_int64_t
H5BlockWriteFieldAttrib (
h5_file *f,
h5_file_t *f,
const char *field_name,
const char *attrib_name,
const h5part_int64_t attrib_type,
const h5_int64_t attrib_type,
const void *attrib_value,
const h5part_int64_t attrib_nelem
const h5_int64_t attrib_nelem
);
h5part_int64_t
h5_int64_t
H5BlockWriteFieldAttribString (
h5_file *f,
h5_file_t *f,
const char *field_name,
const char *attrib_name,
const char *attrib_value
);
h5part_int64_t
h5_int64_t
H5BlockGetNumFieldAttribs (
h5_file *f,
h5_file_t *f,
const char *field_name
);
h5part_int64_t
h5_int64_t
H5BlockGetFieldAttribInfo (
h5_file *f,
h5_file_t *f,
const char *field_name,
const h5part_int64_t attrib_idx,
const h5_int64_t attrib_idx,
char *attrib_name,
const h5part_int64_t len_of_attrib_name,
h5part_int64_t *attrib_type,
h5part_int64_t *attrib_nelem
const h5_int64_t len_of_attrib_name,
h5_int64_t *attrib_type,
h5_int64_t *attrib_nelem
);
h5part_int64_t
h5_int64_t
H5BlockReadFieldAttrib (
h5_file *f,
h5_file_t *f,
const char *field_name,
const char *attrib_name,
void *attrib_value
);
h5part_int64_t
h5_int64_t
H5BlockHasFieldData (
h5_file *f
h5_file_t *f
);
+3 -3
View File
@@ -21,7 +21,7 @@
h5_err_t
H5FedOpenMesh (
h5_file * f,
h5_file_t * f,
const h5_id_t id,
const h5_oid_t type
) {
@@ -31,7 +31,7 @@ H5FedOpenMesh (
h5_id_t
H5FedAddMesh (
h5_file * f,
h5_file_t * f,
const h5_oid_t type
) {
SET_FNAME ( __func__ );
@@ -40,7 +40,7 @@ H5FedAddMesh (
h5_err_t
H5FedSetLevel (
h5_file * f,
h5_file_t * f,
const h5_id_t id
) {
SET_FNAME ( __func__ );
+29 -29
View File
@@ -27,52 +27,52 @@
h5_size_t
H5FedGetNumMeshes (
h5_file * f,
h5_file_t * f,
const h5_oid_t type
);
h5_err_t
H5FedOpenMesh (
h5_file * f,
h5_file_t * f,
const h5_id_t id,
const h5_oid_t type
);
h5_id_t
H5FedAddMesh (
h5_file * f,
h5_file_t * f,
const h5_oid_t type
);
h5_size_t
H5FedGetNumLevels (
h5_file * f
h5_file_t * f
);
h5_err_t
H5FedSetLevel (
h5_file * f,
h5_file_t * f,
const h5_id_t id
);
h5_id_t
H5FedGetLevel (
h5_file * f
h5_file_t * f
);
h5_id_t
H5FedAddLevel (
h5_file * f
h5_file_t * f
);
h5_err_t
H5FedAddNumVertices (
h5_file * f,
h5_file_t * f,
const h5_size_t num
);
h5_err_t
H5FedAddNumEntities (
h5_file * f,
h5_file_t * f,
const h5_size_t num
);
@@ -80,58 +80,58 @@ H5FedAddNumEntities (
h5_size_t
H5GetNumNodes (
h5_file * f
h5_file_t * f
);
/****** VERTEX statistics routines *******************************************/
h5_size_t
H5FedGetNumVertices (
h5_file * f
h5_file_t * f
);
h5_size_t
H5FedGetNumVerticesTotal(
h5_file * f
h5_file_t * f
);
h5_size_t
H5FedGetNumVerticesCnode (
h5_file * f,
h5_file_t * f,
const h5_id_t cnode
);
/****** TRIANGLE statistics routines *****************************************/
h5_size_t
H5FedGetNumTriangles (
h5_file * f
h5_file_t * f
);
h5_size_t
H5FedGetNumTrianglesTotal (
h5_file * f
h5_file_t * f
);
h5_size_t
H5FedGetNumTrianglesCnode (
h5_file * f,
h5_file_t * f,
const h5_id_t cnode
);
/****** TETRAHEDRON statistics routines **************************************/
h5_size_t
H5FedGetNumTetrahedra (
h5_file * f
h5_file_t * f
);
h5_size_t
H5FedGetNumTetrahedraTotal (
h5_file * f
h5_file_t * f
);
h5_size_t
H5FedGetNumTetrahedraCnode (
h5_file * f,
h5_file_t * f,
const h5_id_t cnode
);
@@ -141,19 +141,19 @@ H5FedGetNumTetrahedraCnode (
/* vertices */
h5_id_t
H5FedStoreVertex (
h5_file * f,
h5_file_t * f,
const h5_id_t id,
const h5_float64_t P[3]
);
h5_err_t
H5FedStartTraverseVertices (
h5_file * f
h5_file_t * f
);
h5_id_t
H5FedTraverseVertices (
h5_file * f,
h5_file_t * f,
h5_id_t * const id,
h5_float64_t P[3]
);
@@ -161,12 +161,12 @@ H5FedTraverseVertices (
h5_size_t
H5FedGetNumTriangles (
h5_file * f
h5_file_t * f
);
h5_id_t
H5FedStoreTriangle (
h5_file * f,
h5_file_t * f,
const h5_id_t id,
const h5_id_t parent_id,
h5_id_t vertex_ids[3]
@@ -174,12 +174,12 @@ H5FedStoreTriangle (
h5_err_t
H5FedStartTraverseTriangles (
h5_file * f
h5_file_t * f
);
h5_id_t
H5FedTraverseTriangles (
h5_file * f,
h5_file_t * f,
h5_id_t * const id,
h5_id_t * const parent_id,
h5_id_t vertex_ids[3]
@@ -188,7 +188,7 @@ H5FedTraverseTriangles (
/* tetrahedra */
h5_id_t
H5FedStoreTetrahedron (
h5_file * f,
h5_file_t * f,
const h5_id_t id,
const h5_id_t parent_id,
const h5_id_t vertex_ids[4]
@@ -196,12 +196,12 @@ H5FedStoreTetrahedron (
h5_err_t
H5FedStartTraverseTetrahedra (
h5_file * f
h5_file_t * f
);
h5_id_t
H5FedTraverseTetrahedra (
h5_file * f,
h5_file_t * f,
h5_id_t * const id,
h5_id_t * const parent_id,
h5_id_t vertex_ids[4]
+16 -16
View File
@@ -31,7 +31,7 @@
\return NULL-pointer on error.
*/
h5_id_t * H5FedGetEdgesUAdjacentToVertex (
h5_file * fh, /*!< file handle */
h5_file_t * fh, /*!< file handle */
const h5_id_t level, /*!< mesh level to query */
const h5_id_t vertex_id, /*!< global vertex id */
h5_size_t * const num_adj_edges /*!< OUT: size of returned vector */
@@ -51,7 +51,7 @@ h5_id_t * H5FedGetEdgesUAdjacentToVertex (
\return NULL-pointer on error.
*/
h5_id_t * H5FedGetTrianglesUAdjacentToVertex (
h5_file * fh, /*!< file handle */
h5_file_t * fh, /*!< file handle */
const h5_id_t level, /*!< mesh level to query */
const h5_id_t vertex_id, /*!< global vertex id */
h5_size_t * const num_adj_triangles
@@ -72,7 +72,7 @@ h5_id_t * H5FedGetTrianglesUAdjacentToVertex (
\return NULL-pointer on error.
*/
h5_id_t * H5FedGetTetrahedrasUAdjacentToVertex (
h5_file * fh, /*!< file handle */
h5_file_t * fh, /*!< file handle */
const h5_id_t level, /*!< mesh level to query */
const h5_id_t vertex_id, /*!< global vertex id */
h5_size_t * const num_adj_tetrahedra
@@ -93,7 +93,7 @@ h5_id_t * H5FedGetTetrahedrasUAdjacentToVertex (
\return NULL-pointer on error.
*/
h5_id_t * H5FedGetTrianglesUAdjacentToEdge (
h5_file * fh, /*!< file handle */
h5_file_t * fh, /*!< file handle */
const h5_id_t level, /*!< mesh level to query */
const h5_id_t edge_id, /*!< global edge id */
h5_size_t * const num_adj_triangles
@@ -114,7 +114,7 @@ h5_id_t * H5FedGetTrianglesUAdjacentToEdge (
\return NULL-pointer on error.
*/
h5_id_t * H5FedGetTetrahedraUAdjacentToEdge (
h5_file * fh, /*!< file handle */
h5_file_t * fh, /*!< file handle */
const h5_id_t level, /*!< mesh level to query */
const h5_id_t edge_id, /*!< global edge id */
h5_size_t * const num_adj_tets /*!< OUT: size of returned vector */
@@ -140,9 +140,9 @@ h5_id_t * H5FedGetTetrahedraUAdjacentToEdge (
\return NULL-pointer on error.
*/
h5_id_t * H5FedGetTetrahedraUAdjacentToTriangle (
h5_file * fh, /*!< file handle */
const h5_int_t level, /*!< mesh level to query */
const h5_int_t triangle_id, /*!< global triangle id */
h5_file_t * fh, /*!< file handle */
const h5_id_t level, /*!< mesh level to query */
const h5_id_t triangle_id, /*!< global triangle id */
h5_size_t * const num_adj_tets /*!< OUT: size of returned vector */
) {
return NULL;
@@ -160,9 +160,9 @@ h5_id_t * H5FedGetTetrahedraUAdjacentToTriangle (
\return NULL-pointer on error.
*/
h5_id_t * H5FedGetVerticesDAdjacentToEdge (
h5_file * fh, /*!< file handle */
const h5_int_t level, /*!< mesh level to query */
const h5_int_t edge_id, /*!< global edge id */
h5_file_t * fh, /*!< file handle */
const h5_id_t level, /*!< mesh level to query */
const h5_id_t edge_id, /*!< global edge id */
h5_size_t * const num_adj_vertices
/*!< OUT: size of returned vector */
) {
@@ -179,7 +179,7 @@ h5_id_t * H5FedGetVerticesDAdjacentToEdge (
\return NULL-pointer on error.
*/
h5_id_t * H5FedGetEdjesDAdjacentToTriangle (
h5_file * fh, /*!< file handle */
h5_file_t * fh, /*!< file handle */
const h5_id_t level, /*!< mesh level to query */
const h5_id_t triangle_id, /*!< global triangle id */
h5_size_t * const num_adj_triangles
@@ -198,7 +198,7 @@ h5_id_t * H5FedGetEdjesDAdjacentToTriangle (
\return NULL-pointer on error.
*/
h5_id_t * H5FedGetVerticesDAdjacentToTriangle (
h5_file * fh, /*!< file handle */
h5_file_t * fh, /*!< file handle */
const h5_id_t level, /*!< mesh level to query */
const h5_id_t triangle_id, /*!< global triangle id */
h5_size_t * const num_adj_vertices
@@ -217,7 +217,7 @@ h5_id_t * H5FedGetVerticesDAdjacentToTriangle (
\return NULL-pointer on error.
*/
h5_id_t * H5FedGetTrianglesDAdjacentToTetrahedron (
h5_file * fh, /*!< file handle */
h5_file_t * fh, /*!< file handle */
const h5_id_t level, /*!< mesh level to query */
const h5_id_t tet_id, /*!< global tetrahedron id */
h5_size_t * const num_adj_triangles
@@ -236,7 +236,7 @@ h5_id_t * H5FedGetTrianglesDAdjacentToTetrahedron (
\return NULL-pointer on error.
*/
h5_id_t * H5FedGetEdjesDAdjacentToTetrahedron (
h5_file * fh, /*!< file handle */
h5_file_t * fh, /*!< file handle */
const h5_id_t level, /*!< mesh level to query */
const h5_id_t tet_id, /*!< global tetrahedron id */
h5_size_t * const num_adj_edges /*!< OUT: size of returned vector */
@@ -254,7 +254,7 @@ h5_id_t * H5FedGetEdjesDAdjacentToTetrahedron (
\return NULL-pointer on error.
*/
h5_id_t * H5FedGetVerticesDAdjacentToTetrahedron (
h5_file * fh, /*!< file handle */
h5_file_t * fh, /*!< file handle */
const h5_id_t level, /*!< mesh level to query */
const h5_id_t tet_id, /*!< global tetrahedron id */
h5_size_t * const num_adj_vertices
+9 -9
View File
@@ -21,7 +21,7 @@
h5_err_t
H5FedAddBoundary (
h5_file * const f
h5_file_t * const f
) {
SET_FNAME ( __func__ );
return h5t_open_boundary ( f, -1 );
@@ -29,7 +29,7 @@ H5FedAddBoundary (
h5_err_t
H5FedOpenBoundary (
h5_file * const f,
h5_file_t * const f,
const h5_id_t boundary_id
) {
SET_FNAME ( __func__ );
@@ -38,7 +38,7 @@ H5FedOpenBoundary (
h5_err_t
H5FedCloseBoundary (
h5_file * const f
h5_file_t * const f
) {
SET_FNAME ( __func__ );
return h5t_close_boundary ( f );
@@ -46,7 +46,7 @@ H5FedCloseBoundary (
h5_err_t
H5FedAddNumBoundaryfaces (
h5_file * const f,
h5_file_t * const f,
const h5_id_t num_boundaryfaces
) {
SET_FNAME ( __func__ );
@@ -55,7 +55,7 @@ H5FedAddNumBoundaryfaces (
h5_err_t
H5FedStoreBoundaryface (
h5_file *f,
h5_file_t *f,
h5_id_t *global_vids
) {
SET_FNAME ( __func__ );
@@ -64,7 +64,7 @@ H5FedStoreBoundaryface (
h5_err_t
H5FedStoreBoundaryfaceGlobalID (
h5_file *f,
h5_file_t *f,
h5_id_t global_fid
) {
SET_FNAME ( __func__ );
@@ -73,7 +73,7 @@ H5FedStoreBoundaryfaceGlobalID (
h5_err_t
H5FedStoreBoundaryfaceLocalID (
h5_file *f,
h5_file_t *f,
h5_id_t local_fid
) {
SET_FNAME ( __func__ );
@@ -82,7 +82,7 @@ H5FedStoreBoundaryfaceLocalID (
h5_err_t
H5FedStartTraverseBoundaryfaces (
h5_file * const f
h5_file_t * const f
) {
SET_FNAME ( __func__ );
return h5t_start_traverse_boundary_faces( f );
@@ -90,7 +90,7 @@ H5FedStartTraverseBoundaryfaces (
h5_id_t
H5FedTraverseBoundaryfaces (
h5_file * const f,
h5_file_t * const f,
h5_id_t * const id, /*!< OUT: global face id */
h5_id_t * const parent_id, /*!< OUT: parent id if level
\c >0 else \c -1 */
+9 -9
View File
@@ -3,53 +3,53 @@
h5_err_t
H5FedAddBoundary (
h5_file * const f
h5_file_t * const f
);
h5_err_t
H5FedOpenBoundary (
h5_file * const f,
h5_file_t * const f,
const h5_id_t boundary_id
);
h5_err_t
H5FedCloseBoundary (
h5_file *f
h5_file_t *f
);
h5_err_t
H5FedAddNumBoundaryfaces (
h5_file * const f,
h5_file_t * const f,
const h5_id_t num_boundaryfaces
);
h5_err_t
H5FedStoreBoundaryface (
h5_file *f,
h5_file_t *f,
h5_id_t *global_vids
);
h5_err_t
H5FedStoreBoundaryfaceGlobalID (
h5_file *f,
h5_file_t *f,
h5_id_t global_fid
);
h5_err_t
H5FedStoreBoundaryfaceLocalID (
h5_file *f,
h5_file_t *f,
h5_id_t local_fid
);
h5_err_t
H5FedStartTraverseBoundaryfaces (
h5_file * const f
h5_file_t * const f
);
h5_id_t
H5FedTraverseBoundaryfaces (
h5_file * const f,
h5_file_t * const f,
h5_id_t * const id,
h5_id_t * const parent_id,
h5_id_t vertex_ids[3]
+61 -48
View File
@@ -30,10 +30,11 @@
\return value \c >=0 on success
\return \c -1 on error
*/
h5_int_t H5FedStoreDoFVertexFloat (
h5_file * fh, /*!< file handle */
h5_err_t
H5FedStoreDoFVertexFloat (
h5_file_t * fh, /*!< file handle */
const h5_id_t vertex_id, /*!< global vertex id */
const h5_float_t * const dof, /*!< DoF n-tuple */
const h5_float64_t * const dof, /*!< DoF n-tuple */
const h5_size_t dof_size /*!< number of \c h5_float
value in \c dof */
) {
@@ -50,10 +51,11 @@ h5_int_t H5FedStoreDoFVertexFloat (
\return value \c >=0 on success
\return \c -1 on error
*/
h5_int_t H5FedStoreDoFVertexComplex (
h5_file * fh, /*!< file handle */
h5_err_t
H5FedStoreDoFVertexComplex (
h5_file_t * fh, /*!< file handle */
const h5_id_t vertex_id, /*!< global vertex id */
const h5_complex * const dof, /*!< DoF n-tuple */
const h5_complex_t * const dof, /*!< DoF n-tuple */
const h5_size_t dof_size /*!< number of \c h5_complex
values in \c dof */
) {
@@ -70,8 +72,9 @@ h5_int_t H5FedStoreDoFVertexComplex (
\return Pointer to n-tuple of type \c h5_float.
\return NULL-pointer on error.
*/
h5_float_t * H5FedGetDoFVertexFloat (
h5_file * fh, /*!< file handle */
h5_float64_t *
H5FedGetDoFVertexFloat (
h5_file_t * fh, /*!< file handle */
const h5_id_t vertex_id, /*!< global vertex id */
h5_size_t * const dof_size /*!< OUT: number of \c h5_float
values in returned n-tuple */
@@ -89,8 +92,8 @@ h5_float_t * H5FedGetDoFVertexFloat (
\return Pointer to n-tuple of type \c h5_float.
\return NULL-pointer on error.
*/
h5_complex * H5FedGetDoFVertexComplex (
h5_file * fh, /*!< file handle */
h5_complex_t * H5FedGetDoFVertexComplex (
h5_file_t * fh, /*!< file handle */
const h5_id_t vertex_id, /*!< global vertex id */
h5_size_t * const dof_size /*!< OUT: number of \c h5_float
values in returned n-tuple */
@@ -111,7 +114,7 @@ h5_complex * H5FedGetDoFVertexComplex (
Do we need this function????
*/
h5_size_t H5FedGetNumDoFVertexFloat (
h5_file * fh, /*!< file handle */
h5_file_t * fh, /*!< file handle */
const h5_id_t vertex_id /*!< global vertex id */
) {
return -1;
@@ -130,7 +133,7 @@ h5_size_t H5FedGetNumDoFVertexFloat (
Do we need this function????
*/
h5_size_t H5FedGetNumDoFVertexComplex (
h5_file * fh, /*!< file handle */
h5_file_t * fh, /*!< file handle */
const h5_size_t vertex_id /*!< global vertex id */
) {
return -1;
@@ -148,10 +151,11 @@ h5_size_t H5FedGetNumDoFVertexComplex (
\return something \c >=0 on success
\return \c -1 on error
*/
h5_int_t H5FedStoreDoFEdgeFloat (
h5_file * fh, /*!< file handle */
h5_err_t
H5FedStoreDoFEdgeFloat (
h5_file_t * fh, /*!< file handle */
const h5_id_t edge_id, /*!< global edge id */
const h5_float_t * const dof, /*!< DoF n-tuple */
const h5_float64_t * const dof, /*!< DoF n-tuple */
const h5_size_t dof_size /*!< number of \c h5_float
value in \c dof */
) {
@@ -168,10 +172,11 @@ h5_int_t H5FedStoreDoFEdgeFloat (
\return something \c >=0 on success
\return \c -1 on error
*/
h5_int_t H5FedStoreDoFEdgeComplex (
h5_file * fh, /*!< file handle */
h5_err_t
H5FedStoreDoFEdgeComplex (
h5_file_t * fh, /*!< file handle */
const h5_id_t edge_id, /*!< global edge id */
const h5_complex * const dof, /*!< DoF n-tuple */
const h5_complex_t * const dof, /*!< DoF n-tuple */
const h5_size_t dof_size /*!< number of \c h5_complex
value in \c dof */
) {
@@ -188,8 +193,9 @@ h5_int_t H5FedStoreDoFEdgeComplex (
\return Pointer to n-tuple of type \c h5_float.
\return NULL-pointer on error.
*/
h5_float_t * H5FedGetDoFEdgeFloat (
h5_file * fh, /*!< file handle */
h5_float64_t *
H5FedGetDoFEdgeFloat (
h5_file_t * fh, /*!< file handle */
const h5_id_t edge_id, /*!< global edge id */
h5_size_t * const dof_size /*!< OUT: number of \c h5_float
values in returned n-tuple */
@@ -207,8 +213,8 @@ h5_float_t * H5FedGetDoFEdgeFloat (
\return Pointer to n-tuple of type \c h5_float.
\return NULL-pointer on error.
*/
h5_complex* H5FedGetDoFEdgeComplex (
h5_file * fh, /*!< file handle */
h5_complex_t* H5FedGetDoFEdgeComplex (
h5_file_t * fh, /*!< file handle */
const h5_id_t edge_id, /*!< global edge id */
h5_size_t * const dof_size /*!< OUT: number of \c h5_float
values in returned n-tuple */
@@ -229,7 +235,7 @@ h5_complex* H5FedGetDoFEdgeComplex (
Do we need this function????
*/
h5_size_t H5FedGetNumDoFEdgeFloat (
h5_file * fh, /*!< file handle */
h5_file_t * fh, /*!< file handle */
const h5_id_t edge_id /*!< global edge id */
) {
return -1;
@@ -245,7 +251,7 @@ h5_size_t H5FedGetNumDoFEdgeFloat (
\return \c -1 if edge doesn't exist.
*/
h5_size_t H5FedGetNumDoFEdgeComplex (
h5_file * fh, /*!< file handle */
h5_file_t * fh, /*!< file handle */
const h5_id_t edge_id /*!< global edge id */
) {
return -1;
@@ -264,10 +270,11 @@ h5_size_t H5FedGetNumDoFEdgeComplex (
\return value \c >=0 on success
\return \c -1 on error
*/
h5_int_t H5FedStoreDoFTriangleFloat (
h5_file * fh, /*!< file handle */
h5_err_t
H5FedStoreDoFTriangleFloat (
h5_file_t * fh, /*!< file handle */
const h5_id_t triangle_id, /*!< global triangle id */
const h5_float_t * const dof, /*!< DoF vector */
const h5_float64_t * const dof, /*!< DoF vector */
const h5_size_t dof_size /*!< number of \c h5_float_t
values in \c dof */
) {
@@ -284,10 +291,11 @@ h5_int_t H5FedStoreDoFTriangleFloat (
\return value \c >=0 on success
\return \c -1 on error
*/
h5_int_t H5FedStoreDoFTriangleComplex (
h5_file * fh, /*!< file handle */
h5_err_t
H5FedStoreDoFTriangleComplex (
h5_file_t * fh, /*!< file handle */
const h5_id_t triangle_id, /*!< global triangle id */
const h5_complex * const dof, /*!< DoF vector */
const h5_complex_t * const dof, /*!< DoF vector */
const h5_size_t dof_size /*!< number of \c h5_complex
values in \c dof */
) {
@@ -304,8 +312,9 @@ h5_int_t H5FedStoreDoFTriangleComplex (
\return Pointer to n-tuple of type \c h5_float.
\return NULL-pointer on error.
*/
h5_float_t * H5FedGetDoFTriangleFloat (
h5_file* fh, /*!< file handle */
h5_float64_t *
H5FedGetDoFTriangleFloat (
h5_file_t * f, /*!< file handle */
const h5_id_t triangle_id, /*!< global triangle id */
h5_size_t * const dof_size /*!< OUT: number of \c h5_float
values in returned n-tuple */
@@ -323,8 +332,8 @@ h5_float_t * H5FedGetDoFTriangleFloat (
\return Pointer to n-tuple of type \c h5_float.
\return NULL-pointer on error.
*/
h5_complex * H5FedGetDoFTriangleComplex (
h5_file * fh, /*!< file handle */
h5_complex_t * H5FedGetDoFTriangleComplex (
h5_file_t * fh, /*!< file handle */
const h5_id_t triangle_id, /*!< global triangle id */
h5_size_t * const dof_size /*!< OUT: number of \c h5_float
values in returned n-tuple */
@@ -345,7 +354,7 @@ h5_complex * H5FedGetDoFTriangleComplex (
Do we need this function????
*/
h5_size_t H5FedGetNumDoFTriangleFloat (
h5_file * fh, /*!< file handle */
h5_file_t * fh, /*!< file handle */
const h5_id_t triangle_id /*!< global triangle id */
) {
return -1;
@@ -364,7 +373,7 @@ h5_size_t H5FedGetNumDoFTriangleFloat (
Do we need this function????
*/
h5_size_t H5FedGetNumDoFTriangleComplex (
h5_file * fh, /*!< file handle */
h5_file_t * fh, /*!< file handle */
const h5_id_t triangle_id /*!< global triangle id */
) {
return -1;
@@ -383,10 +392,11 @@ h5_size_t H5FedGetNumDoFTriangleComplex (
\return value \c >=0 on success
\return \c -1 on error
*/
h5_int_t H5FedStoreDoFTetrahedronFloat (
h5_file * fh, /*!< file handle */
h5_err_t
H5FedStoreDoFTetrahedronFloat (
h5_file_t * fh, /*!< file handle */
const h5_id_t tet_id, /*!< global tetrahedron id */
const h5_float_t * const dof, /*!< DoF vector */
const h5_float64_t * const dof, /*!< DoF vector */
const h5_size_t dof_size /*!< number of \c h5_float
value in \c dof */
) {
@@ -403,10 +413,11 @@ h5_int_t H5FedStoreDoFTetrahedronFloat (
\return value \c >=0 on success
\return \c -1 on error
*/
h5_int_t H5FedStoreDoFTetrahedronComplex (
h5_file * fh, /*!< file handle */
h5_err_t
H5FedStoreDoFTetrahedronComplex (
h5_file_t * fh, /*!< file handle */
const h5_id_t tet_id, /*!< global tetrahedron id */
const h5_complex * const dof, /*!< DoF vector */
const h5_complex_t * const dof, /*!< DoF vector */
const h5_size_t dof_size /*!< number of \c h5_complex
value in \c dof */
) {
@@ -423,8 +434,9 @@ h5_int_t H5FedStoreDoFTetrahedronComplex (
\return Pointer to n-tuple of type \c h5_float.
\return NULL-pointer on error.
*/
h5_float_t * H5FedGetDoFTetrahedronFloat (
h5_file * fh, /*!< file handle */
h5_float64_t *
H5FedGetDoFTetrahedronFloat (
h5_file_t * fh, /*!< file handle */
const h5_id_t tet_id, /*!< global tetrahedron id */
h5_size_t * const dof_size /*!< OUT: number of \c h5_float
values in returned n-tuple */
@@ -442,8 +454,9 @@ h5_float_t * H5FedGetDoFTetrahedronFloat (
\return Pointer to n-tuple of type \c h5_complex
\return NULL-pointer on error.
*/
h5_complex * H5FedGetDoFTetrahedronComplex (
h5_file * fh, /*!< file handle */
h5_complex_t *
H5FedGetDoFTetrahedronComplex (
h5_file_t * fh, /*!< file handle */
const h5_id_t tet_id, /*!< global tetrahedron id */
h5_size_t * const dof_size /*!< OUT: number of \c h5_complex
values in returned n-tuple */
@@ -464,7 +477,7 @@ h5_complex * H5FedGetDoFTetrahedronComplex (
Do we need this function????
*/
h5_size_t H5FedGetNumDoFTetrahedronFloat (
h5_file * fh, /*!< file handle */
h5_file_t * fh, /*!< file handle */
const h5_id_t tet_id /*!< global tetrahedron id */
) {
return -1;
@@ -480,7 +493,7 @@ h5_size_t H5FedGetNumDoFTetrahedronFloat (
\retuen \c -1 if tetrahedron doesn't exist.
*/
h5_size_t H5FedGetNumDoFTetrahedronComplex (
h5_file * fh, /*!< file handle */
h5_file_t * fh, /*!< file handle */
const h5_id_t tet_id /*!< global tetrahedron id */
) {
return -1;
+13 -13
View File
@@ -24,7 +24,7 @@
h5_size_t
H5FedGetNumMeshes (
h5_file * f, /*!< file handle */
h5_file_t * f, /*!< file handle */
const h5_oid_t type
) {
SET_FNAME ( __func__ );
@@ -41,7 +41,7 @@ H5FedGetNumMeshes (
*/
h5_size_t
H5FedGetNumLevels (
h5_file * fh /*!< file handle */
h5_file_t * fh /*!< file handle */
) {
SET_FNAME ( __func__ );
return h5t_get_num_levels ( fh );
@@ -49,7 +49,7 @@ H5FedGetNumLevels (
h5_id_t
H5FedGetLevel (
h5_file * fh /*!< file handle */
h5_file_t * fh /*!< file handle */
) {
SET_FNAME ( __func__ );
return h5t_get_level ( fh );
@@ -57,7 +57,7 @@ H5FedGetLevel (
h5_size_t
H5FedGetNumVertices (
h5_file * fh /*!< file handle */
h5_file_t * fh /*!< file handle */
) {
SET_FNAME ( __func__ );
return h5t_get_num_vertices_on_level ( fh );
@@ -74,7 +74,7 @@ H5FedGetNumVertices (
*/
h5_size_t
H5FedGetNumVerticesTotal(
h5_file * fh /*!< file handle */
h5_file_t * fh /*!< file handle */
) {
SET_FNAME ( __func__ );
return h5t_get_num_vertices_on_level ( fh );
@@ -90,7 +90,7 @@ H5FedGetNumVerticesTotal(
q \return \c -1 on error.
*/
h5_size_t H5FedGetNumVerticesCnode (
h5_file * fh, /*!< file handle */
h5_file_t * fh, /*!< file handle */
const h5_id_t cnode /*!< compute node */
) {
return -1;
@@ -100,7 +100,7 @@ h5_size_t H5FedGetNumVerticesCnode (
h5_size_t
H5FedGetNumTriangles (
h5_file * fh /*!< file handle */
h5_file_t * fh /*!< file handle */
) {
return h5t_get_num_entities_on_level ( fh );
}
@@ -116,7 +116,7 @@ H5FedGetNumTriangles (
*/
h5_size_t
H5FedGetNumTrianglesTotal (
h5_file * fh /*!< file handle */
h5_file_t * fh /*!< file handle */
) {
return h5t_get_num_entities_on_level ( fh );
}
@@ -133,7 +133,7 @@ H5FedGetNumTrianglesTotal (
*/
h5_size_t
H5FedGetNumTrianglesCnode (
h5_file * fh, /*!< file handle */
h5_file_t * fh, /*!< file handle */
const h5_id_t cnode /*!< compute node to query */
) {
return -1;
@@ -152,7 +152,7 @@ H5FedGetNumTrianglesCnode (
*/
h5_size_t
H5FedGetNumTetrahedraTotal(
h5_file * fh /*!< file handle */
h5_file_t * fh /*!< file handle */
) {
SET_FNAME ( __func__ );
return h5t_get_num_entities_on_level ( fh );
@@ -168,7 +168,7 @@ H5FedGetNumTetrahedraTotal(
\return \c -1 on error.
*/
h5_size_t H5FedGetNumTetrahedraCnode (
h5_file * fh, /*!< file handle */
h5_file_t * fh, /*!< file handle */
const h5_id_t level /*!< mesh level to query */
) {
return -1;
@@ -188,7 +188,7 @@ h5_size_t H5FedGetNumTetrahedraCnode (
\return \c -1 on error.
*/
h5_size_t H5FedGetNumBoundaryTrianglesTotal (
h5_file * fh, /*!< file handle */
h5_file_t * fh, /*!< file handle */
const h5_id_t level /*!< mesh level to query */
) {
return -1;
@@ -204,7 +204,7 @@ h5_size_t H5FedGetNumBoundaryTrianglesTotal (
\return \c -1 on error.
*/
h5_size_t H5FedGetNumBoundaryTrianglesCnode (
h5_file * fh, /*!< file handle */
h5_file_t * fh, /*!< file handle */
const h5_id_t level, /*!< mesh level to query */
const h5_id_t cnode /*!< compute node */
) {
+2 -2
View File
@@ -24,7 +24,7 @@
h5_id_t
H5FedMapTet2GlobalID (
h5_file *f,
h5_file_t *f,
h5_id_t * const global_vids
) {
SET_FNAME ( __func__ );
@@ -34,7 +34,7 @@ H5FedMapTet2GlobalID (
h5_id_t
H5FedMapTriangle2GlobalID (
h5_file *f,
h5_file_t *f,
h5_id_t * const global_vids
) {
SET_FNAME ( __func__ );
+2 -2
View File
@@ -21,13 +21,13 @@
h5_id_t
H5FedMapTet2GlobalID (
h5_file * const f,
h5_file_t * const f,
h5_id_t * const global_vids
);
h5_id_t
H5FedMapTriangle2GlobalID (
h5_file * const f,
h5_file_t * const f,
h5_id_t * const global_vids
);
+6 -6
View File
@@ -21,7 +21,7 @@
h5_err_t
H5FedStartTraverseVertices (
h5_file * f /*!< file handle */
h5_file_t * f /*!< file handle */
) {
SET_FNAME ( __func__ );
return h5t_start_traverse_vertices ( f );
@@ -38,7 +38,7 @@ H5FedStartTraverseVertices (
*/
h5_id_t
H5FedTraverseVertices (
h5_file * f, /*!< file handle */
h5_file_t * f, /*!< file handle */
h5_id_t * const id, /*!< OUT: global id */
h5_float64_t P[3] /*!< OUT: coordinates */
) {
@@ -50,7 +50,7 @@ H5FedTraverseVertices (
h5_err_t
H5FedStartTraverseTriangles (
h5_file * f /*!< file handle */
h5_file_t * f /*!< file handle */
) {
SET_FNAME ( __func__ );
return h5t_start_traverse_triangles ( f );
@@ -58,7 +58,7 @@ H5FedStartTraverseTriangles (
h5_id_t
H5FedTraverseTriangles (
h5_file * f, /*!< file handle */
h5_file_t * f, /*!< file handle */
h5_id_t * const id, /*!< OUT: global tetrahedron id */
h5_id_t * const parent_id, /*!< OUT: parent id if level
\c >0 else \c -1 */
@@ -71,7 +71,7 @@ H5FedTraverseTriangles (
h5_err_t
H5FedStartTraverseTetrahedra (
h5_file * f /*!< file handle */
h5_file_t * f /*!< file handle */
) {
SET_FNAME ( __func__ );
return h5t_start_traverse_tets ( f );
@@ -90,7 +90,7 @@ H5FedStartTraverseTetrahedra (
*/
h5_id_t
H5FedTraverseTetrahedra (
h5_file * f, /*!< file handle */
h5_file_t * f, /*!< file handle */
h5_id_t * const id, /*!< OUT: global tetrahedron id */
h5_id_t * const parent_id, /*!< OUT: parent id if level
\c >0 else \c -1 */
+8 -8
View File
@@ -37,7 +37,7 @@
h5_id_t
H5FedAddLevel (
h5_file * f /*!< file handle */
h5_file_t * f /*!< file handle */
) {
SET_FNAME ( __func__ );
return h5t_add_level ( f );
@@ -61,7 +61,7 @@ H5FedAddLevel (
*/
h5_err_t
H5FedAddNumVertices (
h5_file * f, /*!< file handle */
h5_file_t * f, /*!< file handle */
const h5_size_t num /*!< number of additional vertices */
) {
@@ -86,7 +86,7 @@ H5FedAddNumVertices (
*/
h5_id_t
H5FedStoreVertex (
h5_file * f, /*!< file handle */
h5_file_t * f, /*!< file handle */
const h5_id_t id, /*!< global vertex id or -1 */
const h5_float64_t P[3] /*!< coordinates */
) {
@@ -104,7 +104,7 @@ H5FedStoreVertex (
h5_err_t
H5FedAddNumTets (
h5_file * f, /*!< file handle */
h5_file_t * f, /*!< file handle */
const h5_size_t num /*!< number of additional
tets on current level */
) {
@@ -114,7 +114,7 @@ H5FedAddNumTets (
h5_err_t
H5FedAddNumTriangles (
h5_file * f, /*!< file handle */
h5_file_t * f, /*!< file handle */
const h5_size_t num /*!< number of additional
triangle on current level */
) {
@@ -138,7 +138,7 @@ H5FedAddNumTriangles (
*/
h5_id_t
H5FedStoreTetrahedron (
h5_file * f, /*!< file handle */
h5_file_t * f, /*!< file handle */
const h5_id_t id, /*!< global tetrahedron id */
const h5_id_t parent_id, /*!< global parent id
if level \c >0 else \c -1 */
@@ -155,7 +155,7 @@ H5FedStoreTetrahedron (
h5_id_t
H5FedRefineTetrahedron (
h5_file * f, /*!< file handle */
h5_file_t * f, /*!< file handle */
const h5_id_t id /*!< global tetrahedron id */
) {
SET_FNAME ( __func__ );
@@ -164,7 +164,7 @@ H5FedRefineTetrahedron (
h5_id_t
H5FedStoreTriangle (
h5_file * f, /*!< file handle */
h5_file_t * f, /*!< file handle */
const h5_id_t id, /*!< global tetrahedron id */
const h5_id_t parent_id, /*!< global parent id
if level \c >0 else \c -1 */
+111 -111
View File
@@ -123,7 +123,7 @@ Last modified on April 19, 2007.
\return File handle or \c NULL
*/
h5_file*
h5_file_t *
H5PartOpenFileParallel (
const char *filename, /*!< [in] The name of the data file to open. */
unsigned flags, /*!< [in] The access mode for the file. */
@@ -153,7 +153,7 @@ H5PartOpenFileParallel (
\return File handle or \c NULL
*/
h5_file*
h5_file_t *
H5PartOpenFile (
const char *filename, /*!< [in] The name of the data file to open. */
unsigned flags /*!< [in] The access mode for the file. */
@@ -173,9 +173,9 @@ H5PartOpenFile (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
H5PartCloseFile (
h5_file *f /*!< [in] filehandle of the file to close */
h5_file_t *f /*!< [in] filehandle of the file to close */
) {
SET_FNAME ( "H5PartCloseFile" );
@@ -185,11 +185,11 @@ H5PartCloseFile (
/*============== File Writing Functions ==================== */
h5part_int64_t
h5_int64_t
H5PartDefineStepName (
h5_file *f,
h5_file_t *f,
const char *name,
const h5part_int64_t width
const h5_int64_t width
) {
SET_FNAME ( "H5PartDefineStepName" );
@@ -210,10 +210,10 @@ H5PartDefineStepName (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
H5PartSetNumParticles (
h5_file *f, /*!< [in] Handle to open file */
h5part_int64_t nparticles /*!< [in] Number of particles */
h5_file_t *f, /*!< [in] Handle to open file */
h5_int64_t nparticles /*!< [in] Number of particles */
) {
SET_FNAME ( "H5PartSetNumParticles" );
@@ -247,11 +247,11 @@ H5PartSetNumParticles (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
H5PartWriteDataFloat64 (
h5_file *f, /*!< [in] Handle to open file */
h5_file_t *f, /*!< [in] Handle to open file */
const char *name, /*!< [in] Name to associate array with */
const h5part_float64_t *array /*!< [in] Array to commit to disk */
const h5_float64_t *array /*!< [in] Array to commit to disk */
) {
SET_FNAME ( "H5PartWriteDataFloat64" );
@@ -285,11 +285,11 @@ H5PartWriteDataFloat64 (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
H5PartWriteDataInt64 (
h5_file *f, /*!< [in] Handle to open file */
h5_file_t *f, /*!< [in] Handle to open file */
const char *name, /*!< [in] Name to associate array with */
const h5part_int64_t *array /*!< [in] Array to commit to disk */
const h5_int64_t *array /*!< [in] Array to commit to disk */
) {
SET_FNAME ( "H5PartOpenWriteDataInt64" );
@@ -318,9 +318,9 @@ H5PartWriteDataInt64 (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
H5PartWriteFileAttribString (
h5_file *f, /*!< [in] Handle to open file */
h5_file_t *f, /*!< [in] Handle to open file */
const char *attrib_name,/*!< [in] Name of attribute to create */
const char *attrib_value/*!< [in] Value of attribute */
) {
@@ -353,9 +353,9 @@ H5PartWriteFileAttribString (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
H5PartWriteStepAttribString (
h5_file *f, /*!< [in] Handle to open file */
h5_file_t *f, /*!< [in] Handle to open file */
const char *attrib_name,/*!< [in] Name of attribute to create */
const char *attrib_value/*!< [in] Value of attribute */
) {
@@ -392,13 +392,13 @@ H5PartWriteStepAttribString (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
H5PartWriteStepAttrib (
h5_file *f, /*!< [in] Handle to open file */
h5_file_t *f, /*!< [in] Handle to open file */
const char *attrib_name, /*!< [in] Name of attribute */
const h5part_int64_t attrib_type,/*!< [in] Type of value. */
const h5_int64_t attrib_type,/*!< [in] Type of value. */
const void *attrib_value, /*!< [in] Value of attribute */
const h5part_int64_t attrib_nelem/*!< [in] Number of elements */
const h5_int64_t attrib_nelem/*!< [in] Number of elements */
){
SET_FNAME ( "H5PartWriteStepAttrib" );
@@ -433,13 +433,13 @@ H5PartWriteStepAttrib (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
H5PartWriteFileAttrib (
h5_file *f, /*!< [in] Handle to open file */
h5_file_t *f, /*!< [in] Handle to open file */
const char *attrib_name, /*!< [in] Name of attribute */
const h5part_int64_t attrib_type,/*!< [in] Type of value. */
const h5_int64_t attrib_type,/*!< [in] Type of value. */
const void *attrib_value, /*!< [in] Value of attribute */
const h5part_int64_t attrib_nelem/*!< [in] Number of elements */
const h5_int64_t attrib_nelem/*!< [in] Number of elements */
) {
SET_FNAME ( "H5PartWriteFileAttrib" );
@@ -462,9 +462,9 @@ H5PartWriteFileAttrib (
\return Number of attributes bound to current time step or error code.
*/
h5part_int64_t
h5_int64_t
H5PartGetNumStepAttribs (
h5_file *f /*!< [in] Handle to open file */
h5_file_t *f /*!< [in] Handle to open file */
) {
SET_FNAME ( "H5PartGetNumStepAttribs" );
@@ -482,9 +482,9 @@ H5PartGetNumStepAttribs (
\return Number of attributes bound to file \c f or error code.
*/
h5part_int64_t
h5_int64_t
H5PartGetNumFileAttribs (
h5_file *f /*!< [in] Handle to open file */
h5_file_t *f /*!< [in] Handle to open file */
) {
SET_FNAME ( "H5PartGetNumFileAttribs" );
@@ -509,16 +509,16 @@ H5PartGetNumFileAttribs (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
H5PartGetStepAttribInfo (
h5_file *f, /*!< [in] Handle to open file */
const h5part_int64_t attrib_idx,/*!< [in] Index of attribute to
h5_file_t *f, /*!< [in] Handle to open file */
const h5_int64_t attrib_idx,/*!< [in] Index of attribute to
get infos about */
char *attrib_name, /*!< [out] Name of attribute */
const h5part_int64_t len_of_attrib_name,
const h5_int64_t len_of_attrib_name,
/*!< [in] length of buffer \c name */
h5part_int64_t *attrib_type, /*!< [out] Type of value. */
h5part_int64_t *attrib_nelem /*!< [out] Number of elements */
h5_int64_t *attrib_type, /*!< [out] Type of value. */
h5_int64_t *attrib_nelem /*!< [out] Number of elements */
) {
SET_FNAME ( "H5PartGetStepAttribInfo" );
@@ -549,16 +549,16 @@ H5PartGetStepAttribInfo (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
H5PartGetFileAttribInfo (
h5_file *f, /*!< [in] Handle to open file */
const h5part_int64_t attrib_idx,/*!< [in] Index of attribute to get
h5_file_t *f, /*!< [in] Handle to open file */
const h5_int64_t attrib_idx,/*!< [in] Index of attribute to get
infos about */
char *attrib_name, /*!< [out] Name of attribute */
const h5part_int64_t len_of_attrib_name,
const h5_int64_t len_of_attrib_name,
/*!< [in] length of buffer \c name */
h5part_int64_t *attrib_type, /*!< [out] Type of value. */
h5part_int64_t *attrib_nelem /*!< [out] Number of elements */
h5_int64_t *attrib_type, /*!< [out] Type of value. */
h5_int64_t *attrib_nelem /*!< [out] Number of elements */
) {
SET_FNAME ( "H5PartGetFileAttribInfo" );
@@ -582,9 +582,9 @@ H5PartGetFileAttribInfo (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
H5PartReadStepAttrib (
h5_file *f, /*!< [in] Handle to open file */
h5_file_t *f, /*!< [in] Handle to open file */
const char *attrib_name, /*!< [in] Name of attribute to read */
void *attrib_value /*!< [out] Value of attribute */
) {
@@ -604,9 +604,9 @@ H5PartReadStepAttrib (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
H5PartReadFileAttrib (
h5_file *f,
h5_file_t *f,
const char *attrib_name,
void *attrib_value
) {
@@ -648,10 +648,10 @@ H5PartReadFileAttrib (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
H5PartSetStep (
h5_file *f, /*!< [in] Handle to open file */
const h5part_int64_t step /*!< [in] Time-step to set. */
h5_file_t *f, /*!< [in] Handle to open file */
const h5_int64_t step /*!< [in] Time-step to set. */
) {
SET_FNAME ( "H5PartSetStep" );
@@ -675,10 +675,10 @@ H5PartSetStep (
\return true or false
*/
h5part_int64_t
h5_int64_t
H5PartHasStep (
h5_file *f, /*!< [in] Handle to open file */
h5part_int64_t step /*!< [in] Step number to query */
h5_file_t *f, /*!< [in] Handle to open file */
h5_int64_t step /*!< [in] Step number to query */
) {
SET_FNAME ( "H5PartHasStep" );
@@ -700,9 +700,9 @@ H5PartHasStep (
\return number of time-steps or error code
*/
h5part_int64_t
h5_int64_t
H5PartGetNumSteps (
h5_file *f /*!< [in] Handle to open file */
h5_file_t *f /*!< [in] Handle to open file */
) {
SET_FNAME ( "H5PartGetNumSteps" );
@@ -725,9 +725,9 @@ H5PartGetNumSteps (
\return number of datasets in current step or error code
*/
h5part_int64_t
h5_int64_t
H5PartGetNumDatasets (
h5_file *f /*!< [in] Handle to open file */
h5_file_t *f /*!< [in] Handle to open file */
) {
SET_FNAME ( "H5PartGetNumDatasets" );
@@ -748,12 +748,12 @@ H5PartGetNumDatasets (
\result \c H5_SUCCESS
*/
h5part_int64_t
h5_int64_t
H5PartGetDatasetName (
h5_file *f, /*!< [in] Handle to open file */
const h5part_int64_t idx, /*!< [in] Index of the dataset */
h5_file_t *f, /*!< [in] Handle to open file */
const h5_int64_t idx, /*!< [in] Index of the dataset */
char *name, /*!< [out] Name of dataset */
const h5part_int64_t len_of_name/*!< [in] Size of buffer \c name */
const h5_int64_t len_of_name/*!< [in] Size of buffer \c name */
) {
SET_FNAME ( "H5PartGetDatasetName" );
@@ -780,15 +780,15 @@ H5PartGetDatasetName (
\return \c H5_SUCCESS
*/
h5part_int64_t
h5_int64_t
H5PartGetDatasetInfo (
h5_file *f, /*!< [in] Handle to open file */
const h5part_int64_t idx,/*!< [in] Index of the dataset */
h5_file_t *f, /*!< [in] Handle to open file */
const h5_int64_t idx,/*!< [in] Index of the dataset */
char *dataset_name, /*!< [out] Name of dataset */
const h5part_int64_t len_dataset_name,
const h5_int64_t len_dataset_name,
/*!< [in] Size of buffer \c dataset_name */
h5part_int64_t *type, /*!< [out] Type of data in dataset */
h5part_int64_t *nelem /*!< [out] Number of elements. */
h5_int64_t *type, /*!< [out] Type of data in dataset */
h5_int64_t *nelem /*!< [out] Number of elements. */
) {
SET_FNAME ( "H5PartGetDatasetInfo" );
@@ -810,9 +810,9 @@ H5PartGetDatasetInfo (
\return number of particles in current step or an error
code.
*/
h5part_int64_t
h5_int64_t
H5PartGetNumParticles (
h5_file *f /*!< [in] Handle to open file */
h5_file_t *f /*!< [in] Handle to open file */
) {
SET_FNAME ( "H5PartGetNumParticles" );
@@ -821,7 +821,7 @@ H5PartGetNumParticles (
return h5_get_errno();
if ( f->step_gid < 0 ) {
h5part_int64_t herr = h5_set_step ( f, 0 );
h5_int64_t herr = h5_set_step ( f, 0 );
if ( herr < 0 ) return herr;
}
@@ -831,9 +831,9 @@ H5PartGetNumParticles (
/*!
\ingroup h5part_read
*/
h5part_int64_t
h5_int64_t
H5PartResetView (
h5_file *f /*!< [in] Handle to open file */
h5_file_t *f /*!< [in] Handle to open file */
) {
SET_FNAME ( "H5PartResetView" );
@@ -848,9 +848,9 @@ H5PartResetView (
/*!
\ingroup h5part_read
*/
h5part_int64_t
h5_int64_t
H5PartHasView (
h5_file *f /*!< [in] Handle to open file */
h5_file_t *f /*!< [in] Handle to open file */
) {
SET_FNAME ( __func__ );
@@ -880,11 +880,11 @@ H5PartHasView (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
H5PartSetView (
h5_file *f, /*!< [in] Handle to open file */
const h5part_int64_t start, /*!< [in] Start particle */
const h5part_int64_t end /*!< [in] End particle */
h5_file_t *f, /*!< [in] Handle to open file */
const h5_int64_t start, /*!< [in] Start particle */
const h5_int64_t end /*!< [in] End particle */
) {
SET_FNAME ( "H5PartSetView" );
@@ -893,7 +893,7 @@ H5PartSetView (
CHECK_READONLY_MODE ( f );
if ( f->step_gid < 0 ) {
h5part_int64_t herr = h5_set_step ( f, 0 );
h5_int64_t herr = h5_set_step ( f, 0 );
if ( herr < 0 ) return herr;
}
@@ -910,11 +910,11 @@ H5PartSetView (
\return the number of elements in the view
*/
h5part_int64_t
h5_int64_t
H5PartGetView (
h5_file *f, /*!< [in] Handle to open file */
h5part_int64_t *start, /*!< [out] Start particle */
h5part_int64_t *end /*!< [out] End particle */
h5_file_t *f, /*!< [in] Handle to open file */
h5_int64_t *start, /*!< [out] Start particle */
h5_int64_t *end /*!< [out] End particle */
) {
SET_FNAME ( "H5PartGetView" );
@@ -922,7 +922,7 @@ H5PartGetView (
CHECK_FILEHANDLE( f );
if ( f->step_gid < 0 ) {
h5part_int64_t herr = h5_set_step ( f, 0 );
h5_int64_t herr = h5_set_step ( f, 0 );
if ( herr < 0 ) return herr;
}
return H5U_get_view( f, start, end );
@@ -945,14 +945,14 @@ H5PartGetView (
the last (NumParticles % f->nprocs) particles are not handled!
*/
h5part_int64_t
h5_int64_t
H5PartSetCanonicalView (
h5_file *f /*!< [in] Handle to open file */
h5_file_t *f /*!< [in] Handle to open file */
) {
SET_FNAME ( "H5PartSetCanonicalView" );
h5part_int64_t herr;
h5_int64_t herr;
CHECK_FILEHANDLE( f );
CHECK_READONLY_MODE ( f )
@@ -977,11 +977,11 @@ H5PartSetCanonicalView (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
H5PartReadDataFloat64 (
h5_file *f, /*!< [in] Handle to open file */
h5_file_t *f, /*!< [in] Handle to open file */
const char *name, /*!< [in] Name to associate dataset with */
h5part_float64_t *array /*!< [out] Array of data */
h5_float64_t *array /*!< [out] Array of data */
) {
SET_FNAME ( "H5PartReadDataFloat64" );
@@ -1003,11 +1003,11 @@ H5PartReadDataFloat64 (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
H5PartReadDataInt64 (
h5_file *f, /*!< [in] Handle to open file */
h5_file_t *f, /*!< [in] Handle to open file */
const char *name, /*!< [in] Name to associate dataset with */
h5part_int64_t *array /*!< [out] Array of data */
h5_int64_t *array /*!< [out] Array of data */
) {
SET_FNAME ( "H5PartReadDataInt64" );
@@ -1031,21 +1031,21 @@ H5PartReadDataInt64 (
\return \c H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
H5PartReadParticleStep (
h5_file *f, /*!< [in] Handle to open file */
h5part_int64_t step, /*!< [in] Step to read */
h5part_float64_t *x, /*!< [out] Buffer for dataset named "x" */
h5part_float64_t *y, /*!< [out] Buffer for dataset named "y" */
h5part_float64_t *z, /*!< [out] Buffer for dataset named "z" */
h5part_float64_t *px, /*!< [out] Buffer for dataset named "px" */
h5part_float64_t *py, /*!< [out] Buffer for dataset named "py" */
h5part_float64_t *pz, /*!< [out] Buffer for dataset named "pz" */
h5part_int64_t *id /*!< [out] Buffer for dataset named "id" */
h5_file_t *f, /*!< [in] Handle to open file */
h5_int64_t step, /*!< [in] Step to read */
h5_float64_t *x, /*!< [out] Buffer for dataset named "x" */
h5_float64_t *y, /*!< [out] Buffer for dataset named "y" */
h5_float64_t *z, /*!< [out] Buffer for dataset named "z" */
h5_float64_t *px, /*!< [out] Buffer for dataset named "px" */
h5_float64_t *py, /*!< [out] Buffer for dataset named "py" */
h5_float64_t *pz, /*!< [out] Buffer for dataset named "pz" */
h5_int64_t *id /*!< [out] Buffer for dataset named "id" */
) {
SET_FNAME ( "H5PartReadParticleStep" );
h5part_int64_t herr;
h5_int64_t herr;
CHECK_FILEHANDLE( f );
@@ -1085,9 +1085,9 @@ H5PartReadParticleStep (
\return \c H5_SUCCESS
*/
h5part_int64_t
h5_int64_t
H5PartSetVerbosityLevel (
const h5part_int64_t level
const h5_int64_t level
) {
return h5_set_debuglevel ( level );
@@ -1100,9 +1100,9 @@ H5PartSetVerbosityLevel (
\return \c H5_SUCCESS
*/
h5part_int64_t
h5_int64_t
H5PartSetErrorHandler (
h5part_error_handler handler
h5_error_handler handler
) {
return h5_set_errorhandler( handler );
@@ -1115,7 +1115,7 @@ H5PartSetErrorHandler (
\return Pointer to error handler.
*/
h5part_error_handler
h5_error_handler
H5PartGetErrorHandler (
void
) {
@@ -1129,7 +1129,7 @@ H5PartGetErrorHandler (
\return error code
*/
h5part_int64_t
h5_int64_t
H5PartGetErrno (
void
) {
+113 -113
View File
@@ -28,12 +28,12 @@ extern "C" {
#define H5PART_WRITE H5_O_WRONLY
#define H5PART_APPEND H5_O_APPEND
#define H5PART_INT64 ((h5part_int64_t)H5T_NATIVE_INT64)
#define H5PART_FLOAT64 ((h5part_int64_t)H5T_NATIVE_DOUBLE)
#define H5PART_CHAR ((h5part_int64_t)H5T_NATIVE_CHAR)
#define H5PART_INT64 ((h5_int64_t)H5T_NATIVE_INT64)
#define H5PART_FLOAT64 ((h5_int64_t)H5T_NATIVE_DOUBLE)
#define H5PART_CHAR ((h5_int64_t)H5T_NATIVE_CHAR)
/*========== File Opening/Closing ===============*/
h5_file*
h5_file_t *
H5PartOpenFile(
const char *filename,
const unsigned flags
@@ -42,7 +42,7 @@ H5PartOpenFile(
#define H5PartOpenFileSerial(x,y) H5PartOpenFile(x,y)
#ifdef PARALLEL_IO
h5_file*
h5_file_t *
H5PartOpenFileParallel (
const char *filename,
const unsigned flags,
@@ -51,141 +51,141 @@ H5PartOpenFileParallel (
#endif
h5part_int64_t
h5_int64_t
H5PartCloseFile (
h5_file *f
h5_file_t *f
);
/*============== File Writing Functions ==================== */
h5part_int64_t
h5_int64_t
H5PartDefineStepName (
h5_file *f,
h5_file_t *f,
const char *name,
const h5part_int64_t width
const h5_int64_t width
);
h5part_int64_t
h5_int64_t
H5PartSetNumParticles (
h5_file *f,
const h5part_int64_t nparticles
h5_file_t *f,
const h5_int64_t nparticles
);
h5part_int64_t
h5_int64_t
H5PartWriteDataFloat64 (
h5_file *f,
h5_file_t *f,
const char *name,
const h5part_float64_t *array
const h5_float64_t *array
);
h5part_int64_t
h5_int64_t
H5PartWriteDataInt64 (
h5_file *f,
h5_file_t *f,
const char *name,
const h5part_int64_t *array
const h5_int64_t *array
);
/*================== File Reading Routines =================*/
h5part_int64_t
h5_int64_t
H5PartSetStep (
h5_file *f,
const h5part_int64_t step
h5_file_t *f,
const h5_int64_t step
);
h5part_int64_t
h5_int64_t
H5PartHasStep (
h5_file *f,
const h5part_int64_t step
h5_file_t *f,
const h5_int64_t step
);
h5part_int64_t
h5_int64_t
H5PartGetNumSteps (
h5_file *f
h5_file_t *f
);
h5part_int64_t
h5_int64_t
H5PartGetNumDatasets (
h5_file *f
h5_file_t *f
);
h5part_int64_t
h5_int64_t
H5PartGetDatasetName (
h5_file *f,
const h5part_int64_t idx,
h5_file_t *f,
const h5_int64_t idx,
char *name,
const h5part_int64_t maxlen
const h5_int64_t maxlen
);
h5part_int64_t
h5_int64_t
H5PartGetDatasetInfo (
h5_file *f,
const h5part_int64_t idx,
h5_file_t *f,
const h5_int64_t idx,
char *name,
const h5part_int64_t maxlen,
h5part_int64_t *type,
h5part_int64_t *nelem);
const h5_int64_t maxlen,
h5_int64_t *type,
h5_int64_t *nelem);
h5part_int64_t
h5_int64_t
H5PartGetNumParticles (
h5_file *f
h5_file_t *f
);
h5part_int64_t
h5_int64_t
H5PartSetView (
h5_file *f,
const h5part_int64_t start,
const h5part_int64_t end
h5_file_t *f,
const h5_int64_t start,
const h5_int64_t end
);
h5part_int64_t
h5_int64_t
H5PartGetView (
h5_file *f,
h5part_int64_t *start,
h5part_int64_t *end
h5_file_t *f,
h5_int64_t *start,
h5_int64_t *end
);
h5part_int64_t
h5_int64_t
H5PartHasView (
h5_file *f
h5_file_t *f
);
h5part_int64_t
h5_int64_t
H5PartResetView (
h5_file *f
h5_file_t *f
);
h5part_int64_t
h5_int64_t
H5PartSetCanonicalView (
h5_file *f
h5_file_t *f
);
h5part_int64_t
h5_int64_t
H5PartReadDataFloat64(
h5_file *f,
h5_file_t *f,
const char *name,
h5part_float64_t *array
h5_float64_t *array
);
h5part_int64_t
h5_int64_t
H5PartReadDataInt64 (
h5_file *f,
h5_file_t *f,
const char *name,
h5part_int64_t *array
h5_int64_t *array
);
h5part_int64_t
h5_int64_t
H5PartReadParticleStep (
h5_file *f,
const h5part_int64_t step,
h5part_float64_t *x, /* particle positions */
h5part_float64_t *y,
h5part_float64_t *z,
h5part_float64_t *px, /* particle momenta */
h5part_float64_t *py,
h5part_float64_t *pz,
h5part_int64_t *id /* and phase */
h5_file_t *f,
const h5_int64_t step,
h5_float64_t *x, /* particle positions */
h5_float64_t *y,
h5_float64_t *z,
h5_float64_t *px, /* particle momenta */
h5_float64_t *py,
h5_float64_t *pz,
h5_int64_t *id /* and phase */
);
/**********==============Attributes Interface============***************/
@@ -196,114 +196,114 @@ H5PartReadParticleStep (
attributes that are bound to a particular data array, but this could
easily be done if required.
*/
h5part_int64_t
h5_int64_t
H5PartWriteStepAttrib (
h5_file *f,
h5_file_t *f,
const char *attrib_name,
const h5part_int64_t attrib_type,
const h5_int64_t attrib_type,
const void *attrib_value,
const h5part_int64_t attrib_nelem
const h5_int64_t attrib_nelem
);
h5part_int64_t
h5_int64_t
H5PartWriteFileAttrib (
h5_file *f,
h5_file_t *f,
const char *attrib_name,
const h5part_int64_t attrib_type,
const h5_int64_t attrib_type,
const void *attrib_value,
const h5part_int64_t attrib_nelem
const h5_int64_t attrib_nelem
);
h5part_int64_t
h5_int64_t
H5PartWriteFileAttribString (
h5_file *f,
h5_file_t *f,
const char *name,
const char *attrib
);
h5part_int64_t
h5_int64_t
H5PartWriteStepAttribString (
h5_file *f,
h5_file_t *f,
const char *name,
const char *attrib
);
h5part_int64_t
h5_int64_t
H5PartGetNumStepAttribs ( /* for current filestep */
h5_file *f
h5_file_t *f
);
h5part_int64_t
h5_int64_t
H5PartGetNumFileAttribs (
h5_file *f
h5_file_t *f
);
h5part_int64_t
h5_int64_t
H5PartGetStepAttribInfo (
h5_file *f,
const h5part_int64_t attrib_idx,
h5_file_t *f,
const h5_int64_t attrib_idx,
char *attrib_name,
const h5part_int64_t len_of_attrib_name,
h5part_int64_t *attrib_type,
h5part_int64_t *attrib_nelem
const h5_int64_t len_of_attrib_name,
h5_int64_t *attrib_type,
h5_int64_t *attrib_nelem
);
h5part_int64_t
h5_int64_t
H5PartGetFileAttribInfo (
h5_file *f,
const h5part_int64_t idx,
h5_file_t *f,
const h5_int64_t idx,
char *name,
const h5part_int64_t maxnamelen,
h5part_int64_t *type,
h5part_int64_t *nelem
const h5_int64_t maxnamelen,
h5_int64_t *type,
h5_int64_t *nelem
);
h5part_int64_t
h5_int64_t
H5PartReadStepAttrib (
h5_file *f,
h5_file_t *f,
const char *name,
void *data
);
h5part_int64_t
h5_int64_t
H5PartReadFileAttrib (
h5_file *f,
h5_file_t *f,
const char *name,
void *data
);
h5part_int64_t
h5_int64_t
H5PartSetVerbosityLevel (
const h5part_int64_t level
const h5_int64_t level
);
h5part_int64_t
h5_int64_t
H5PartSetErrorHandler (
const h5part_error_handler handler
const h5_error_handler handler
);
h5part_int64_t
h5_int64_t
H5PartGetErrno (
void
);
h5part_error_handler
h5_error_handler
H5PartGetErrorHandler (
void
);
h5part_int64_t
h5_int64_t
H5PartReportErrorHandler (
const char *funcname,
const h5part_int64_t eno,
const h5_int64_t eno,
const char *fmt,
...
);
h5part_int64_t
h5_int64_t
H5PartAbortErrorHandler (
const char *funcname,
const h5part_int64_t eno,
const h5_int64_t eno,
const char *fmt,
...
);
+3 -3
View File
@@ -33,7 +33,7 @@
*/
h5_size_t
H5GetNumNodes (
h5_file * f /*!< file handle */
h5_file_t * f /*!< file handle */
) {
SET_FNAME ( __func__ );
return (h5_size_t)fh->nprocs;
@@ -48,7 +48,7 @@ H5GetNumNodes (
*/
h5_id_t
H5GetNumSteps (
h5_file * fh /*!< file handle */
h5_file_t * fh /*!< file handle */
) {
SET_FNAME ( __func__ );
return h5_get_num_steps( fh );
@@ -63,7 +63,7 @@ H5GetNumSteps (
*/
h5_err_t
H5HasStep (
h5_file *f, /*!< [in] Handle to open file */
h5_file_t *f, /*!< [in] Handle to open file */
h5part_int64_t step /*!< [in] Step number to query */
) {
+2
View File
@@ -53,6 +53,7 @@ include_HEADERS = \
h5_qsort_private.h \
h5_readwrite.h \
h5_readwrite_private.h \
h5_syscall_private.h \
h5_types.h \
h5b_errorhandling_private.h \
h5t_boundaries.h \
@@ -80,6 +81,7 @@ libH5_core_a_SOURCES = \
h5_qsort.c \
h5_qsort_r.c \
h5_readwrite.c \
h5_syscall.c \
h5t_boundaries.c \
h5t_errorhandling.c \
h5t_map.c \
+10 -10
View File
@@ -11,7 +11,7 @@
#include "H5Part.h"
#include "H5Block.h"
h5part_int64_t
h5_int64_t
h5_read_attrib (
hid_t id,
const char *attrib_name,
@@ -54,7 +54,7 @@ h5_read_attrib (
return H5_SUCCESS;
}
h5part_int64_t
h5_int64_t
h5_write_attrib (
hid_t id,
const char *attrib_name,
@@ -91,14 +91,14 @@ h5_write_attrib (
return H5_SUCCESS;
}
h5part_int64_t
h5_int64_t
h5_get_attrib_info (
hid_t id,
const h5part_int64_t attrib_idx,
const h5_int64_t attrib_idx,
char *attrib_name,
const h5part_int64_t len_attrib_name,
h5part_int64_t *attrib_type,
h5part_int64_t *attrib_nelem
const h5_int64_t len_attrib_name,
h5_int64_t *attrib_type,
h5_int64_t *attrib_nelem
) {
herr_t herr;
@@ -142,9 +142,9 @@ h5_get_attrib_info (
return H5_SUCCESS;
}
h5part_int64_t
h5_int64_t
h5_get_num_attribs (
h5_file *f,
h5_file_t *f,
hid_t id
) {
@@ -153,5 +153,5 @@ h5_get_num_attribs (
int nattribs = H5Aget_num_attrs ( id );
if ( nattribs < 0 ) HANDLE_H5A_GET_NUM_ATTRS_ERR;
return (h5part_int64_t) nattribs;
return (h5_int64_t) nattribs;
}
+9 -9
View File
@@ -1,14 +1,14 @@
#ifndef __ATTRIBS_H
#define __ATTRIBS_H
h5part_int64_t
h5_int64_t
h5_read_attrib (
hid_t id,
const char *attrib_name,
void *attrib_value
);
h5part_int64_t
h5_int64_t
h5_write_attrib (
hid_t id,
const char *attrib_name,
@@ -17,19 +17,19 @@ h5_write_attrib (
const hsize_t attrib_nelem
);
h5part_int64_t
h5_int64_t
h5_get_attrib_info (
hid_t id,
const h5part_int64_t attrib_idx,
const h5_int64_t attrib_idx,
char *attrib_name,
const h5part_int64_t len_attrib_name,
h5part_int64_t *attrib_type,
h5part_int64_t *attrib_nelem
const h5_int64_t len_attrib_name,
h5_int64_t *attrib_type,
h5_int64_t *attrib_nelem
);
h5part_int64_t
h5_int64_t
h5_get_num_attribs (
h5_file *f,
h5_file_t *f,
hid_t id
);
+33 -19
View File
@@ -1,8 +1,11 @@
#ifndef __H5_PRIVATE_H
#define __H5_PRIVATE_H
#include "h5t_types_private.h"
#include "h5_errorhandling_private.h"
#include "h5_qsort_private.h"
#include "h5_syscall_private.h"
#include "h5b_errorhandling_private.h"
#include "h5t_boundaries_private.h"
#include "h5t_map_private.h"
@@ -23,8 +26,19 @@
#define _h5t_build_triangle_id( idx, entity_id ) \
( (idx << (sizeof(entity_id)*8 - 3)) | (entity_id & H5_TET_MASK))
#define TRY(func,exception) if ( func < 0 ) goto exception;
#if __SIZEOF_POINTER__ == 4
#define TRY(func) if ( (int32_t)(func) == (int32_t)(-1) ) return H5_ERR;
#define TRY2(func,exception) if ( (int32_t)(func) == (int32_t)(-1) ) goto exception;
#elif __SIZEOF_POINTER__ == 8
#define TRY(func) \
if ( (int64_t)(func) == (int64_t)(-1) ) \
return H5_ERR;
#define TRY2(func,exception) \
if ( (int64_t)(func) == (int64_t)(-1) ) \
goto exception;
#else
#error "Unknown pointer size!"
#endif
/*!
@@ -45,15 +59,15 @@ struct _iter_op_data {
char *pattern;
};
h5part_int64_t
h5_int64_t
h5_set_step (
h5_file *f,
const h5part_int64_t step
h5_file_t *f,
const h5_int64_t step
);
h5part_int64_t
h5_int64_t
h5_get_num_particles (
h5_file *f
h5_file_t *f
);
herr_t
@@ -72,14 +86,14 @@ h5_normalize_h5_type (
hid_t type
);
h5part_int64_t
h5_int64_t
h5_read_attrib (
hid_t id,
const char *attrib_name,
void *attrib_value
);
h5part_int64_t
h5_int64_t
h5_write_attrib (
hid_t id,
const char *attrib_name,
@@ -88,24 +102,24 @@ h5_write_attrib (
const hsize_t attrib_nelem
);
h5part_int64_t
h5_int64_t
h5_get_attrib_info (
hid_t id,
const h5part_int64_t attrib_idx,
const h5_int64_t attrib_idx,
char *attrib_name,
const h5part_int64_t len_attrib_name,
h5part_int64_t *attrib_type,
h5part_int64_t *attrib_nelem
const h5_int64_t len_attrib_name,
h5_int64_t *attrib_type,
h5_int64_t *attrib_nelem
);
h5part_int64_t
h5_int64_t
h5_get_num_objects (
hid_t group_id,
const char *group_name,
const hid_t type
);
h5part_int64_t
h5_int64_t
h5_get_num_objects_matching_pattern (
hid_t group_id,
const char *group_name,
@@ -113,14 +127,14 @@ h5_get_num_objects_matching_pattern (
char * const pattern
);
h5part_int64_t
h5_int64_t
_H5Part_get_object_name (
hid_t group_id,
const char *group_name,
const hid_t type,
const h5part_int64_t idx,
const h5_int64_t idx,
char *obj_name,
const h5part_int64_t len_obj_name
const h5_int64_t len_obj_name
);
+2 -2
View File
@@ -46,10 +46,10 @@ h5_get_debuglevel (
h5_err_t
h5_set_errorhandler (
h5part_error_handler handler
h5_error_handler handler
);
h5part_error_handler
h5_error_handler
h5_get_errorhandler (
void
);
+1 -1
View File
@@ -5,7 +5,7 @@
hid_t
_h5_open_group (
h5_file * f,
h5_file_t * f,
const hid_t parent_gid,
const char * const grpname
) {
+1 -1
View File
@@ -3,7 +3,7 @@
hid_t
_h5_open_group (
h5_file *f,
h5_file_t *f,
const hid_t parent_gid,
const char * const grpname
);
+2 -2
View File
@@ -1,5 +1,5 @@
#ifndef __MAPS_H
#define __MAPS_H
#ifndef __H5_MAPS_H
#define __H5_MAPS_H
h5_err_t
_h5_alloc_smap (
+23 -23
View File
@@ -19,9 +19,9 @@
\return H5_SUCCESS or error code
*/
h5part_int64_t
h5_int64_t
h5_check_filehandle (
const h5_file *f /*!< filehandle to check validity of */
const h5_file_t *f /*!< filehandle to check validity of */
) {
if ( f == NULL )
@@ -46,7 +46,7 @@ _h5_error_handler ( hid_t estack_id, void* unused ) {
return 0;
}
static h5part_int64_t
static h5_int64_t
_init ( void ) {
static int __init = 0;
@@ -68,9 +68,9 @@ _init ( void ) {
\return H5_SUCCESS or error code
*/
static h5part_int64_t
static h5_int64_t
_h5u_open_file (
h5_file *f /*!< IN: file handle */
h5_file_t *f /*!< IN: file handle */
) {
f->shape = 0;
f->diskshape = H5S_ALL;
@@ -78,7 +78,7 @@ _h5u_open_file (
f->viewstart = -1;
f->viewend = -1;
f->pnparticles =
(h5part_int64_t*) malloc (f->nprocs * sizeof (h5part_int64_t));
(h5_int64_t*) malloc (f->nprocs * sizeof (h5_int64_t));
if (f->pnparticles == NULL) {
return HANDLE_H5_NOMEM_ERR;
}
@@ -94,9 +94,9 @@ _h5u_open_file (
\return H5_SUCCESS or error code
*/
static h5part_int64_t
static h5_int64_t
_h5b_open_file (
h5_file *f /*!< IN: file handle */
h5_file_t *f /*!< IN: file handle */
) {
struct h5b_fdata *b;
@@ -131,7 +131,7 @@ _h5b_open_file (
}
h5_file*
h5_file_t *
h5_open_file (
const char *filename, /*!< [in] The name of the data file to open. */
unsigned flags, /*!< [in] The access mode for the file. */
@@ -145,14 +145,14 @@ h5_open_file (
return NULL;
}
h5_set_errno ( H5_SUCCESS );
h5_file *f = NULL;
h5_file_t *f = NULL;
f = (h5_file*) malloc( sizeof (h5_file) );
f = (h5_file_t*) malloc( sizeof (h5_file_t) );
if( f == NULL ) {
HANDLE_H5_NOMEM_ERR;
goto error_cleanup;
}
memset (f, 0, sizeof (h5_file));
memset (f, 0, sizeof (h5_file_t));
f->prefix_step_name = strdup ( H5PART_GROUPNAME_STEP );
if( f->prefix_step_name == NULL ) {
@@ -297,9 +297,9 @@ h5_open_file (
\return H5_SUCCESS or error code
*/
static h5part_int64_t
static h5_int64_t
_h5u_close_file (
h5_file *f /*!< IN: file handle */
h5_file_t *f /*!< IN: file handle */
) {
herr_t herr;
h5_set_errno ( H5_SUCCESS );
@@ -334,9 +334,9 @@ _h5u_close_file (
\return H5_SUCCESS or error code
*/
static h5part_int64_t
static h5_int64_t
_h5b_close_file (
h5_file *f /*!< IN: file handle */
h5_file_t *f /*!< IN: file handle */
) {
herr_t herr;
@@ -368,9 +368,9 @@ _h5b_close_file (
return H5_SUCCESS;
}
h5part_int64_t
h5_int64_t
h5_close_file (
h5_file *f
h5_file_t *f
) {
herr_t r = 0;
h5_set_errno ( H5_SUCCESS );
@@ -423,9 +423,9 @@ h5_close_file (
h5_int64_t
h5_define_stepname_fmt (
h5_file *f,
h5_file_t *f,
const char *name,
const h5part_int64_t width
const h5_int64_t width
) {
f->prefix_step_name = strdup ( name );
if( f->prefix_step_name == NULL ) {
@@ -438,7 +438,7 @@ h5_define_stepname_fmt (
h5_err_t
h5_get_stepname_fmt (
h5_file * f,
h5_file_t * f,
char *name,
const h5_size_t l_name,
h5_size_t *width
@@ -448,7 +448,7 @@ h5_get_stepname_fmt (
h5_int64_t
h5_get_step (
h5_file * f
h5_file_t * f
) {
return -1;
}
@@ -456,7 +456,7 @@ h5_get_step (
h5_int64_t
h5_has_step (
h5_file * f,
h5_file_t * f,
h5_int64_t step
) {
char name[128];
+12 -12
View File
@@ -1,33 +1,33 @@
#ifndef __H5_OPENCLOSE_H
#define __H5_OPENCLOSE_H
h5_file*
h5_file_t *
h5_open_file (
const char *filename,
unsigned flags,
MPI_Comm comm
);
h5part_int64_t
h5_int64_t
h5_check_filehandle (
const h5_file *f
const h5_file_t *f
);
h5part_int64_t
h5_int64_t
h5_close_file (
h5_file *f
h5_file_t *f
);
h5part_int64_t
h5_int64_t
h5_define_stepname_fmt (
h5_file *f,
h5_file_t *f,
const char *name,
const h5part_int64_t width
const h5_int64_t width
);
h5_err_t
h5_get_stepname_fmt (
h5_file *f,
h5_file_t *f,
char *name,
const h5_size_t l_name,
h5_size_t *width
@@ -35,18 +35,18 @@ h5_get_stepname_fmt (
h5_err_t
_h5_close_step (
h5_file *f
h5_file_t *f
);
h5_int64_t
h5_has_step (
h5_file * f,
h5_file_t * f,
h5_int64_t step
);
h5_int64_t
h5_get_step (
h5_file *f
h5_file_t *f
);
#endif
+26 -26
View File
@@ -9,9 +9,9 @@
#include "h5_core.h"
#include "h5_core_private.h"
h5part_int64_t
h5_int64_t
h5_write_data (
h5_file *f, /*!< IN: Handle to open file */
h5_file_t *f, /*!< IN: Handle to open file */
const char *name, /*!< IN: Name to associate array with */
const void *array, /*!< IN: Array to commit to disk */
const hid_t type, /*!< IN: Type of data */
@@ -54,7 +54,7 @@ h5_write_data (
h5_err_t
h5_write_dataset (
h5_file * const f, /*!< IN: Handle to open file */
h5_file_t * const f, /*!< IN: Handle to open file */
const hid_t group_id,
const char dataset_name[],/*!< IN: Name to associate data with */
const hid_t type_id, /*!< IN: Type of data */
@@ -125,12 +125,12 @@ h5_write_dataset (
h5_err_t
h5_read_dataset2 (
h5_file * const f,
h5_file_t * const f,
hid_t group_id,
const char dataset_name[],
hid_t type_id,
hid_t (*set_memspace)(h5_file*,hid_t),
hid_t (*set_diskspace)(h5_file*,hid_t),
hid_t (*set_memspace)(h5_file_t*,hid_t),
hid_t (*set_diskspace)(h5_file_t*,hid_t),
void * const data ) {
hid_t dataset_id = H5Dopen ( group_id, dataset_name, H5P_DEFAULT );
@@ -164,7 +164,7 @@ h5_read_dataset2 (
h5_err_t
h5_read_dataset (
h5_file *f,
h5_file_t *f,
hid_t group_id,
const char dataset_name[],
hid_t type_id,
@@ -192,7 +192,7 @@ h5_read_dataset (
h5_err_t
_h5_read_dataset (
h5_file * const f,
h5_file_t * const f,
hid_t dataset_id,
hid_t type_id,
hid_t memspace_id,
@@ -258,7 +258,7 @@ h5_iteration_operator (
Get number of object of type \c type in HDF5 group \c group_id.
*/
h5part_int64_t
h5_int64_t
h5_get_num_objects (
hid_t group_id,
const char *group_name,
@@ -279,7 +279,7 @@ h5_get_num_objects (
If pattern is NULL, count all objects of given type.
*/
h5part_int64_t
h5_int64_t
h5_get_num_objects_matching_pattern (
hid_t group_id,
const char *group_name,
@@ -287,7 +287,7 @@ h5_get_num_objects_matching_pattern (
char * const pattern
) {
h5part_int64_t herr;
h5_int64_t herr;
int idx = 0;
struct _iter_op_data data;
@@ -307,14 +307,14 @@ h5_get_num_objects_matching_pattern (
Iterator for \c H5Giterate().
*/
h5part_int64_t
h5_int64_t
h5_get_object_name (
hid_t group_id,
const char *group_name,
const hid_t type,
const h5part_int64_t idx,
const h5_int64_t idx,
char *obj_name,
const h5part_int64_t len_obj_name
const h5_int64_t len_obj_name
) {
herr_t herr;
@@ -330,7 +330,7 @@ h5_get_object_name (
herr = H5Giterate ( group_id, group_name, &iterator_idx,
h5_iteration_operator,
&data );
if ( herr < 0 ) return (h5part_int64_t)herr;
if ( herr < 0 ) return (h5_int64_t)herr;
if ( herr == 0 ) HANDLE_H5_NOENTRY_ERR( group_name,
type, idx );
@@ -340,7 +340,7 @@ h5_get_object_name (
h5_int64_t
_create_step (
h5_file * f
h5_file_t * f
) {
h5_print_debug (
"Proc[%d]: Create step #%lld for file %lld",
@@ -358,7 +358,7 @@ _create_step (
h5_int64_t
_open_step (
h5_file * f
h5_file_t * f
) {
h5_print_info (
"Proc[%d]: Open step #%lld for file %lld",
@@ -375,7 +375,7 @@ _open_step (
static h5_err_t
_init_step (
h5_file * f
h5_file_t * f
) {
h5_err_t h5err = _h5t_init_step ( f );
if ( h5err < 0 ) return h5err;
@@ -385,7 +385,7 @@ _init_step (
h5_err_t
_h5_close_step (
h5_file * f
h5_file_t * f
) {
if ( f->step_gid < 0 ) return H5_SUCCESS;
@@ -403,7 +403,7 @@ _h5_close_step (
h5_int64_t
_set_step (
h5_file * f,
h5_file_t * f,
const h5_int64_t step_idx /*!< [in] Step to set. */
) {
f->step_idx = step_idx;
@@ -435,7 +435,7 @@ _set_step (
h5_int64_t
h5_set_step (
h5_file *f, /*!< [in] Handle to open file */
h5_file_t *f, /*!< [in] Handle to open file */
const h5_int64_t step_idx /*!< [in] Step to set. */
) {
@@ -481,7 +481,7 @@ h5_normalize_h5_type (
}
h5part_int64_t
h5_int64_t
h5_get_dataset_type(
hid_t group_id,
const char *dataset_name
@@ -492,7 +492,7 @@ h5_get_dataset_type(
hid_t hdf5_type = H5Dget_type ( dataset_id );
if ( hdf5_type < 0 ) HANDLE_H5D_GET_TYPE_ERR;
h5part_int64_t type = (h5part_int64_t) h5_normalize_h5_type ( hdf5_type );
h5_int64_t type = (h5_int64_t) h5_normalize_h5_type ( hdf5_type );
herr_t herr = H5Tclose(hdf5_type);
if ( herr < 0 ) HANDLE_H5T_CLOSE_ERR;
@@ -503,10 +503,10 @@ h5_get_dataset_type(
return type;
}
h5part_int64_t
h5_int64_t
h5_has_index (
h5_file *f, /*!< [in] Handle to open file */
h5part_int64_t step /*!< [in] Step number to query */
h5_file_t *f, /*!< [in] Handle to open file */
h5_int64_t step /*!< [in] Step number to query */
) {
char name[128];
sprintf ( name,
+15 -15
View File
@@ -1,9 +1,9 @@
#ifndef __READWRITE_H
#define __READWRITE_H
h5part_int64_t
h5_int64_t
h5_write_data (
h5_file *f,
h5_file_t *f,
const char *name,
const void *array,
const hid_t type,
@@ -15,7 +15,7 @@ h5_write_data (
h5_err_t
h5_write_dataset (
h5_file * const f,
h5_file_t * const f,
const hid_t group_id,
const char dataset_name[],
const hid_t type_id,
@@ -25,14 +25,14 @@ h5_write_dataset (
) ;
h5part_int64_t
h5_int64_t
h5_get_num_objects (
hid_t group_id,
const char *group_name,
const hid_t type
);
h5part_int64_t
h5_int64_t
h5_get_num_objects_matching_pattern (
hid_t group_id,
const char *group_name,
@@ -40,20 +40,20 @@ h5_get_num_objects_matching_pattern (
char * const pattern
);
h5part_int64_t
h5_int64_t
h5_get_object_name (
hid_t group_id,
const char *group_name,
const hid_t type,
const h5part_int64_t idx,
const h5_int64_t idx,
char *obj_name,
const h5part_int64_t len_obj_name
const h5_int64_t len_obj_name
);
h5part_int64_t
h5_int64_t
h5_set_step (
h5_file *f, /*!< [in] Handle to open file */
const h5part_int64_t step /*!< [in] Time-step to set. */
h5_file_t *f, /*!< [in] Handle to open file */
const h5_int64_t step /*!< [in] Time-step to set. */
);
hid_t
@@ -61,16 +61,16 @@ h5_normalize_h5_type (
hid_t type
);
h5part_int64_t
h5_int64_t
h5_get_dataset_type(
hid_t group_id,
const char *dataset_name
);
h5part_int64_t
h5_int64_t
h5_has_index (
h5_file *f, /*!< [in] Handle to open file */
h5part_int64_t step /*!< [in] Step number to query */
h5_file_t *f, /*!< [in] Handle to open file */
h5_int64_t step /*!< [in] Step number to query */
);
#endif
+1 -1
View File
@@ -3,7 +3,7 @@
h5_err_t
_h5_read_dataset (
h5_file * const f,
h5_file_t * const f,
hid_t dataset_id,
hid_t type_id,
hid_t memspace_id,
+46 -184
View File
@@ -8,6 +8,7 @@
#include <fcntl.h>
#define H5_SUCCESS 0
#define H5_ERR -1
#define H5_ERR_BADF -9
#define H5_ERR_NOMEM -12
#define H5_ERR_INVAL -22
@@ -37,76 +38,16 @@ typedef __int64 int64_t;
typedef int64_t h5_int64_t;
typedef int32_t h5_int32_t;
typedef h5_int64_t h5_int_t;
typedef h5_int64_t h5part_int64_t;
typedef int32_t h5_id_t;
typedef int32_t h5_size_t; /* size in number of elements */
typedef int32_t h5_err_t;
typedef double h5_float64_t;
typedef h5_float64_t h5_float_t;
typedef h5_float64_t h5part_float64_t;
struct h5_complex {
h5_float64_t r,i;
};
typedef struct h5_complex h5_complex;
enum h5_oid { /* enum with number of vertices(!) */
H5_OID_VERTEX = 1,
H5_OID_EDGE = 2,
H5_OID_TRIANGLE = 3,
H5_OID_TETRAHEDRON = 4
};
typedef enum h5_oid h5_oid_t;
#define H5_MAX_VERTICES_PER_ENTITY H5_OID_TETRAHEDRON
struct h5_vertex { /* 32Byte */
h5_id_t id;
h5_id_t unused; /* for right alignment */
h5_float64_t P[3];
};
typedef struct h5_vertex h5_vertex;
typedef struct h5_vertex h5_vertex_t;
struct h5_edge { /* 16Bytes */
h5_id_t id;
h5_id_t parent_id;
h5_id_t refined_on_evel; /* = 0 if not refined*/
h5_id_t unused; /* for right alignment */
h5_id_t vertex_ids[2];
};
typedef struct h5_edge h5_edge;
typedef struct h5_edge h5_edge_t;
struct h5_triangle { /*24Bytes*/
h5_id_t id;
h5_id_t parent_id;
h5_id_t vertex_ids[3];
h5_id_t refined_on_level;
};
typedef struct h5_triangle h5_triangle;
typedef struct h5_triangle h5_triangle_t;
struct h5_tetrahedron { /* 24Bytes */
h5_id_t id;
h5_id_t parent_id;
h5_id_t refined_on_level;
h5_id_t unused; /* for right alignment */
h5_id_t vertex_ids[4];
};
typedef struct h5_tetrahedron h5_tetrahedron;
typedef struct h5_tetrahedron h5_tetrahedron_t;
struct h5_ltriangle {
h5_id_t vertex_ids[3]; /* local(!) vertex ids */
};
struct h5_ltetrahedron {
h5_id_t vertex_ids[4]; /* local(!) vertex ids */
};
typedef struct h5_complex h5_complex_t;
typedef h5_err_t (*h5_error_handler)( const char*, const h5_err_t, const char*,...)
@@ -121,8 +62,6 @@ typedef h5_err_t (*h5_verror_handler)(
const char*,
va_list ap );
typedef h5_error_handler h5part_error_handler;
#ifndef PARALLEL_IO
typedef unsigned long MPI_Comm;
#endif
@@ -130,8 +69,8 @@ typedef unsigned long MPI_Comm;
struct h5u_fdata {
hsize_t nparticles; /* -> u.nparticles */
h5part_int64_t viewstart; /* -1 if no view is available: A "view" looks */
h5part_int64_t viewend; /* at a subset of the data. */
h5_int64_t viewstart; /* -1 if no view is available: A "view" looks */
h5_int64_t viewend; /* at a subset of the data. */
/**
the number of particles in each processor.
@@ -141,7 +80,7 @@ struct h5u_fdata {
So they can be used to compute the offset of
the view for each processor
*/
h5part_int64_t *pnparticles;
h5_int64_t *pnparticles;
hid_t shape;
hid_t diskshape;
@@ -149,19 +88,19 @@ struct h5u_fdata {
};
struct H5BlockPartition {
h5part_int64_t i_start;
h5part_int64_t i_end;
h5part_int64_t j_start;
h5part_int64_t j_end;
h5part_int64_t k_start;
h5part_int64_t k_end;
h5_int64_t i_start;
h5_int64_t i_end;
h5_int64_t j_start;
h5_int64_t j_end;
h5_int64_t k_start;
h5_int64_t k_end;
};
struct h5b_fdata {
h5part_int64_t step_idx;
h5part_int64_t i_max;
h5part_int64_t j_max;
h5part_int64_t k_max;
h5_int64_t step_idx;
h5_int64_t i_max;
h5_int64_t j_max;
h5_int64_t k_max;
struct H5BlockPartition *user_layout;
struct H5BlockPartition *write_layout;
int have_layout;
@@ -173,107 +112,6 @@ struct h5b_fdata {
hid_t field_group_id;
};
union entities {
struct h5_tetrahedron *tets;
struct h5_triangle *tris;
void *data;
};
union lentities {
struct h5_ltetrahedron *tets;
struct h5_ltriangle *tris;
void *data;
};
struct smap {
h5_size_t size; /* allocated space in number of items */
h5_size_t num_items; /* stored items */
h5_id_t *items;
};
struct idmap {
h5_size_t size; /* allocated space in number of items */
h5_size_t num_items; /* stored items */
struct {
h5_id_t global_id;
h5_id_t local_id;
} *items;
};
struct boundary {
char name[16];
char label[256];
h5_id_t id; /* name of boundary as integer */
h5_id_t changed; /* true if boundary is new or
has been changed */
h5_id_t gid; /* hdf5 grp id boundary */
h5_id_t *faces;
h5_id_t *lfaces;
h5_size_t *num_faces; /* addit. num of faces per level */
h5_size_t *num_faces_on_level; /* real num of faces per level */
h5_id_t last_accessed_face;
};
typedef struct boundary boundary_t;
struct h5t_fdata {
/*** book-keeping ***/
char mesh_name[16];
char mesh_label[256];
enum h5_oid mesh_type;
h5_id_t cur_mesh;
h5_id_t mesh_changed; /* true if mesh is new or has been changed */
h5_id_t num_meshes;
hid_t entity_tid; /* HDF5 type id: tet, triangle ... */
h5_id_t cur_level;
h5_id_t new_level; /* idx of the first new level or -1 */
h5_size_t num_levels;
/*** vertices ***/
h5_vertex *vertices;
h5_size_t *num_vertices;
struct idmap map_vertex_g2l;/* map global id to local id */
struct smap sorted_lvertices;
h5_id_t last_retrieved_vertex_id;
h5_id_t last_stored_vertex_id;
/*** Entities ***/
union entities entities;
union lentities lentities; /* local vertex id's of entities */
h5_size_t *num_entities;
h5_size_t *num_entities_on_level;
struct idmap map_entity_g2l;/* map global id to local id */
/* array with geometrically sorted local entitiy ids
[0]: 0,1,2,3 sorted
[1]: 1,0,2,3 sorted */
struct smap sorted_lentities[H5_MAX_VERTICES_PER_ENTITY];
h5_id_t last_retrieved_entity_id;
h5_id_t last_stored_entity_id;
/*** Boundary Meshes ***/
h5_id_t num_boundaries; /* number of boundaries */
h5_id_t boundaries_gid; /* hdf5 grp id container group */
boundary_t boundary;
/*** HDF5 objects ***/
hid_t topo_gid; /* grp id of mesh in current level */
hid_t meshes_gid;
hid_t mesh_gid;
/*** type ids' for compound types ***/
hid_t float64_3tuple_tid; /* 3-tuple of 64-bit float */
hid_t int32_2tuple_tid; /* 2-tuple of 32-bit int */
hid_t int32_3tuple_tid; /* 3-tuple of 32-bit int */
hid_t int32_4tuple_tid; /* 4-tuple of 32-bit int */
hid_t vertex_tid; /* vertex structure */
hid_t triangle_tid; /* triangle structure */
hid_t tet_tid; /* tetrahedron structure */
};
/**
\struct h5_file
@@ -317,8 +155,8 @@ struct h5_file {
hsize_t nparticles; /* -> u.nparticles */
h5part_int64_t viewstart; /* -1 if no view is available: A "view" looks */
h5part_int64_t viewend; /* at a subset of the data. */
h5_int64_t viewstart; /* -1 if no view is available: A "view" looks */
h5_int64_t viewend; /* at a subset of the data. */
/**
the number of particles in each processor.
@@ -328,7 +166,7 @@ struct h5_file {
So they can be used to compute the offset of
the view for each processor
*/
h5part_int64_t *pnparticles;
h5_int64_t *pnparticles;
hid_t shape;
hid_t diskshape;
@@ -336,12 +174,36 @@ struct h5_file {
/* END unstructured */
struct h5u_fdata u;
struct h5u_fdata *u;
struct h5b_fdata *block;
struct h5t_fdata t;
struct h5t_fdata *t;
};
typedef struct h5_file h5_file;
typedef struct h5_file h5_file_t;
typedef struct h5_file H5PartFile;
struct smap {
h5_size_t size; /* allocated space in number of items */
h5_size_t num_items; /* stored items */
h5_id_t *items;
};
struct idmap {
h5_size_t size; /* allocated space in number of items */
h5_size_t num_items; /* stored items */
struct {
h5_id_t global_id;
h5_id_t local_id;
} *items;
};
enum h5_oid { /* enum with number of vertices(!) */
H5_OID_VERTEX = 1,
H5_OID_EDGE = 2,
H5_OID_TRIANGLE = 3,
H5_OID_TETRAHEDRON = 4
};
typedef enum h5_oid h5_oid_t;
#define H5_MAX_VERTICES_PER_ENTITY H5_OID_TETRAHEDRON
#endif
+38 -47
View File
@@ -5,44 +5,40 @@
static h5_err_t
_open_boundaries_group (
h5_file * const f
h5_file_t * const f
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
if ( t->cur_mesh < 0 )
return _h5t_error_undef_mesh ( f );
TRY( (t->boundaries_gid = _h5_open_group (
f, t->mesh_gid, H5T_BOUNDARYMESH_GRPNAME )), error_exit );
TRY( t->boundaries_gid = _h5_open_group (
f, t->mesh_gid, H5T_BOUNDARYMESH_GRPNAME ) );
return H5_SUCCESS;
error_exit:
return h5_get_errno();
}
static h5_err_t
_open_boundary_group (
h5_file * const f
h5_file_t * const f
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
boundary_t *boundary = &t->boundary;
if ( t->cur_mesh < 0 )
return _h5t_error_undef_mesh ( f );
if ( t->boundaries_gid < 0 ) {
TRY( _open_boundaries_group ( f ), error_exit );
TRY( _open_boundaries_group ( f ) );
}
boundary->gid = _h5_open_group (
f, t->boundaries_gid, boundary->name );
return H5_SUCCESS;
error_exit:
return h5_get_errno();
}
h5_id_t
h5t_get_num_boundaries (
h5_file * const f
h5_file_t * const f
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
if ( t->cur_mesh < 0 )
return _h5t_error_undef_mesh ( f );
@@ -58,14 +54,14 @@ h5t_get_num_boundaries (
h5_err_t
h5t_set_boundary_label (
h5_file * const f,
h5_file_t * const f,
const char * const bname
) {
return -1;
}
h5_err_t
h5t_get_boundary_label (
h5_file * const f,
h5_file_t * const f,
char * const boundary_name,
const size_t size
) {
@@ -74,16 +70,16 @@ h5t_get_boundary_label (
h5_err_t
h5t_open_boundary (
h5_file * const f,
h5_file_t * const f,
const h5_id_t boundary_id
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
boundary_t *boundary = &t->boundary;
TRY( h5t_close_boundary ( f ), error_exit );
TRY( h5t_close_boundary ( f ) );
if ( t->num_boundaries < 0 ) {
TRY( h5t_get_num_boundaries ( f ), error_exit );
TRY( h5t_get_num_boundaries ( f ) );
}
if ( (boundary_id < -1) || (boundary_id >= t->num_boundaries) ) {
return HANDLE_H5_OUT_OF_RANGE_ERR( "boundary", boundary_id );
@@ -96,16 +92,14 @@ h5t_open_boundary (
}
snprintf ( boundary->name, sizeof (boundary->name),
"%d", boundary->id );
TRY( _open_boundary_group ( f ), error_exit );
TRY( _open_boundary_group ( f ) );
return H5_SUCCESS;
error_exit:
return h5_get_errno();
}
h5_err_t
h5t_open_boundary_with_label (
h5_file * const f,
h5_file_t * const f,
const char * const boundary_label
) {
return -1;
@@ -113,9 +107,9 @@ h5t_open_boundary_with_label (
h5_err_t
_h5t_read_boundaryfaces (
h5_file * const f
h5_file_t * const f
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
boundary_t *boundary = &t->boundary;
const char * const dataset_name = "Faces";
@@ -155,9 +149,9 @@ _h5t_read_boundaryfaces (
h5_err_t
_h5t_write_boundary (
h5_file * const f
h5_file_t * const f
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
boundary_t *boundary = &t->boundary;
hsize_t maxdim = H5S_UNLIMITED;
@@ -175,9 +169,9 @@ _h5t_write_boundary (
h5_err_t
h5t_close_boundary (
h5_file * const f
h5_file_t * const f
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
boundary_t *boundary = &t->boundary;
if ( boundary->changed ) {
@@ -191,23 +185,21 @@ h5t_close_boundary (
bzero ( boundary, sizeof(*boundary) );
TRY( _h5_close_group( boundary->gid ), exception);
TRY( _h5_close_group( boundary->gid ) );
boundary->id = -1;
boundary->gid = -1;
boundary->last_accessed_face = -1;
return H5_SUCCESS;
exception:
return h5_get_errno();
}
h5_err_t
h5t_add_num_boundaryfaces (
h5_file * const f,
h5_file_t * const f,
const h5_id_t num_faces
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
boundary_t *boundary = &t->boundary;
boundary->num_faces = realloc (
@@ -248,17 +240,17 @@ h5t_add_num_boundaryfaces (
*/
h5_id_t
h5t_get_num_boundaryfaces (
h5_file * const f
h5_file_t * const f
) {
return -1;
}
h5_id_t
h5t_store_boundaryface (
h5_file * const f,
h5_file_t * const f,
h5_id_t * const global_vids
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
if ( t->vertices == NULL ) {
h5_err_t h5err = _h5t_read_mesh ( f );
@@ -283,10 +275,10 @@ h5t_store_boundaryface (
h5_id_t
h5t_store_boundaryface_global_id (
h5_file * const f,
h5_file_t * const f,
const h5_id_t global_fid
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
switch ( t->mesh_type ) {
case H5_OID_TETRAHEDRON: {
@@ -302,10 +294,10 @@ h5t_store_boundaryface_global_id (
h5_id_t
h5t_store_boundaryface_local_id (
h5_file * const f,
h5_file_t * const f,
const h5_id_t local_fid
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
boundary_t *boundary = &t->boundary;
if ( boundary->num_faces == NULL )
@@ -336,22 +328,21 @@ h5t_store_boundaryface_local_id (
h5_err_t
h5t_start_traverse_boundary_faces (
h5_file * const f
h5_file_t * const f
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
boundary_t *boundary = &t->boundary;
if ( boundary->faces == NULL ) {
TRY( _h5t_read_boundaryfaces ( f ), error_exit );
TRY( _h5t_read_boundaryfaces ( f ) );
}
boundary->last_accessed_face = -1;
error_exit:
return h5_get_errno();
return H5_SUCCESS;
}
h5_id_t
h5t_traverse_boundary_faces (
h5_file * const f,
h5_file_t * const f,
h5_id_t * const global_id,
h5_id_t * const parent_id,
h5_id_t vertex_ids[]
+9 -9
View File
@@ -3,52 +3,52 @@
h5_err_t
h5t_open_boundary (
h5_file * const f,
h5_file_t * const f,
const h5_id_t boundary_id
);
h5_err_t
h5t_close_boundary (
h5_file * const f
h5_file_t * const f
);
h5_err_t
h5t_add_num_boundaryfaces (
h5_file * const f,
h5_file_t * const f,
const h5_id_t num
);
h5_id_t
h5t_get_num_boundaryfaces (
h5_file * const f
h5_file_t * const f
);
h5_id_t
h5t_store_boundaryface (
h5_file * const f,
h5_file_t * const f,
h5_id_t * const vertices
);
h5_id_t
h5t_store_boundaryface_global_id (
h5_file * const f,
h5_file_t * const f,
const h5_id_t global_fid
);
h5_id_t
h5t_store_boundaryface_local_id (
h5_file * const f,
h5_file_t * const f,
const h5_id_t local_fid
);
h5_err_t
h5t_start_traverse_boundary_faces (
h5_file * const f
h5_file_t * const f
);
h5_id_t
h5t_traverse_boundary_faces (
h5_file * const f,
h5_file_t * const f,
h5_id_t * const global_id,
h5_id_t * const parent_id,
h5_id_t vertex_ids[]
+5 -5
View File
@@ -19,10 +19,10 @@ const char * H5_OID_NAMES[] = {
h5_err_t
_h5t_handle_get_global_entity_id_err (
h5_file *f,
h5_file_t *f,
const h5_id_t * const global_vids
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
switch ( t->mesh_type ) {
case H5_OID_TETRAHEDRON:
return _h5t_error_global_tet_id_nexist ( global_vids );
@@ -35,10 +35,10 @@ _h5t_handle_get_global_entity_id_err (
h5_err_t
_h5t_handle_get_local_entity_id_err (
h5_file *f,
h5_file_t *f,
const h5_id_t * const local_vids
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
switch ( t->mesh_type ) {
case H5_OID_TETRAHEDRON:
return _h5t_error_local_tet_id_nexist ( local_vids );
@@ -53,7 +53,7 @@ h5_err_t
_h5t_error_illegal_object_type (
h5_file_t * const f,
h5_oid_t oid ) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
switch ( t->mesh_type ) {
case H5_OID_TETRAHEDRON:
return h5_error_internal( __FILE__, __func__, __LINE__ );
+2 -2
View File
@@ -4,13 +4,13 @@
h5_err_t
_h5t_handle_get_global_entity_id_err (
h5_file *f,
h5_file_t *f,
const h5_id_t * const global_vids
);
h5_err_t
_h5t_handle_get_local_entity_id_err (
h5_file *f,
h5_file_t *f,
const h5_id_t * const local_vids
);
+48 -48
View File
@@ -25,13 +25,13 @@ _qsort_cmp_vertices (
const void* _local_vid1,
const void* _local_vid2
) {
h5_file *f = (h5_file*)_f;
h5_file_t *f = (h5_file_t*)_f;
h5_id_t local_vid1 = *(h5_id_t*)_local_vid1;
h5_id_t local_vid2 = *(h5_id_t*)_local_vid2;
return _cmp_vertices (
f->t.vertices[local_vid1].P,
f->t.vertices[local_vid2].P );
f->t->vertices[local_vid1].P,
f->t->vertices[local_vid2].P );
}
@@ -43,7 +43,7 @@ _h5t_sort_vertices (
h5_file_t * const f
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
h5_id_t num_vertices = t->num_vertices[t->num_levels-1];
h5_id_t i;
@@ -70,11 +70,11 @@ _h5t_sort_vertices (
static h5_id_t
_get_local_vertex_id_of_entity (
h5_file * f,
h5_file_t * f,
int ith_vertex,
h5_id_t local_eid
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
h5_id_t local_vid = -1;
h5_id_t global_vid = -1;
@@ -117,11 +117,11 @@ _get_local_vertex_id_of_entity (
*/
static h5_float64_t*
_get_vertex_of_entity (
h5_file * f,
h5_file_t * f,
int ith_vertex,
h5_id_t local_entity_id
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
h5_id_t local_vid = _get_local_vertex_id_of_entity (
f, ith_vertex, local_entity_id );
@@ -137,11 +137,11 @@ _get_vertex_of_entity (
*/
static int
_vcmp_entities (
h5_file *f,
h5_file_t *f,
h5_id_t *e1,
h5_id_t *e2
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
int i;
for ( i = 0; i < t->mesh_type; i++ ) {
@@ -159,11 +159,11 @@ _vcmp_entities (
*/
static int
_cmp_entities (
h5_file * f,
h5_file_t * f,
h5_id_t local_eid1,
h5_id_t local_eid2
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
int i;
for ( i = 0; i < t->mesh_type; i++ ) {
int r = _cmp_vertices (
@@ -177,11 +177,11 @@ _cmp_entities (
static int
_cmp_entities1 (
h5_file * f,
h5_file_t * f,
h5_id_t local_eid1,
h5_id_t local_eid2
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
int imap[] = { 1, 0, 2, 3 };
int i;
for ( i = 0; i < t->mesh_type; i++ ) {
@@ -224,10 +224,10 @@ _qsort_cmp_entities1 (
*/
h5_err_t
_h5t_sort_entities (
h5_file *f
h5_file_t *f
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
h5_size_t num_entities = h5t_get_num_entities ( f );
if ( num_entities < 0 ) return num_entities;
@@ -264,11 +264,11 @@ _h5t_sort_entities (
*/
h5_err_t
_h5t_sort_local_vertex_ids (
h5_file * const f,
h5_file_t * const f,
h5_id_t * const local_vids, /* IN/OUT: local vertex ids */
const h5_size_t size /* size of array */
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
h5_size_t i;
for ( i = 1; i < size; ++i ) {
@@ -289,7 +289,7 @@ _h5t_sort_local_vertex_ids (
h5_err_t
_h5t_sort_global_vertex_ids (
h5_file * const f,
h5_file_t * const f,
h5_id_t * const global_vids, /* IN/OUT: global vertex ids */
const h5_size_t size /* size of array */
) {
@@ -321,10 +321,10 @@ _h5t_sort_global_vertex_ids (
*/
static h5_id_t
_search_entity (
h5_file *f,
h5_file_t *f,
h5_id_t * const local_vids /* local vertex ids */
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
_h5t_sort_local_vertex_ids ( f, local_vids, t->mesh_type );
@@ -352,10 +352,10 @@ _search_entity (
*/
h5_id_t
h5t_get_local_entity_id (
h5_file *f,
h5_file_t *f,
h5_id_t * const local_vids /* IN/OUT: local vertex id's */
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
h5_id_t local_eid = _search_entity ( f, local_vids );
if ( local_eid < 0 ) {
@@ -370,10 +370,10 @@ h5t_get_local_entity_id (
*/
h5_id_t
h5t_map_global_vertex_id2local (
h5_file *f,
h5_file_t *f,
const h5_id_t global_id
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
h5_id_t local_id = _h5_search_idmap ( &t->map_vertex_g2l, global_id );
if ( local_id < 0 )
@@ -383,10 +383,10 @@ h5t_map_global_vertex_id2local (
h5_id_t
h5t_map_local_vertex_id2global (
h5_file *f,
h5_file_t *f,
const h5_id_t local_vid
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
if ( local_vid < 0 || local_vid > t->num_vertices[t->num_levels-1] )
return HANDLE_H5_OUT_OF_RANGE_ERR ( "vertex", local_vid );
@@ -395,7 +395,7 @@ h5t_map_local_vertex_id2global (
h5_err_t
h5t_map_global_vertex_ids2local (
h5_file *f,
h5_file_t *f,
const h5_id_t * const global_vids,
const h5_id_t size,
h5_id_t * const local_vids
@@ -417,10 +417,10 @@ h5t_map_global_vertex_ids2local (
*/
h5_id_t
h5t_map_local_entity_id2global (
h5_file *f,
h5_file_t *f,
const h5_id_t local_eid
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
switch ( t->mesh_type ) {
case H5_OID_TETRAHEDRON:
@@ -441,10 +441,10 @@ h5t_map_local_entity_id2global (
*/
h5_id_t
h5t_get_global_entity_id (
h5_file *f,
h5_file_t *f,
const h5_id_t * const global_vids /* global vertex id's */
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
h5_id_t local_vids[H5_MAX_VERTICES_PER_ENTITY];
if ( t->vertices == NULL ) {
@@ -469,11 +469,11 @@ h5t_get_global_entity_id (
static int
_search_ith_vertex_in_entity (
h5_file * const f,
h5_file_t * const f,
const int i,
h5_id_t local_vid
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
register h5_id_t low = 0;
register h5_id_t high = t->sorted_lentities[i].num_items - 1;
@@ -499,12 +499,12 @@ _search_ith_vertex_in_entity (
static h5_id_t
_tetm_contain_triangle (
h5_file *f,
h5_file_t *f,
const h5_id_t * const local_vids,
int i,
h5_id_t local_eid
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
h5_id_t *local_vids_of_entity = t->lentities.tets[local_eid].vertex_ids;
if ( i == 0 &&
@@ -533,10 +533,10 @@ _tetm_contain_triangle (
*/
h5_id_t
_tetm_search_triangle (
h5_file *f,
h5_file_t *f,
h5_id_t * const local_vids
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
_h5t_sort_local_vertex_ids ( f, local_vids, 3 );
@@ -596,10 +596,10 @@ _tetm_search_triangle (
*/
h5_id_t
h5t_get_global_triangle_id (
h5_file * const f,
h5_file_t * const f,
h5_id_t * const global_vids
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
if ( t->vertices == NULL ) {
h5_err_t h5err = _h5t_read_mesh ( f );
@@ -629,10 +629,10 @@ h5t_get_global_triangle_id (
*/
h5_id_t
h5t_get_local_triangle_id (
h5_file * const f,
h5_file_t * const f,
h5_id_t * const local_vids
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
switch ( t->mesh_type ) {
case H5_OID_TETRAHEDRON: {
@@ -653,10 +653,10 @@ h5t_get_local_triangle_id (
h5_id_t
h5t_map_global_entity_id2local (
h5_file * const f,
h5_file_t * const f,
const h5_id_t global_eid
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
h5_id_t local_eid = _h5_search_idmap ( &t->map_entity_g2l, global_eid );
if ( local_eid < 0 )
return _h5t_error_global_id_nexist ( "entity", global_eid );
@@ -670,10 +670,10 @@ h5t_map_global_entity_id2local (
*/
h5_id_t
h5t_map_global_triangle_id2local (
h5_file * const f,
h5_file_t * const f,
const h5_id_t global_tri_id
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
switch ( t->mesh_type ) {
case H5_OID_TETRAHEDRON: {
h5_id_t global_tet_id = global_tri_id & H5_TET_MASK;
@@ -698,10 +698,10 @@ h5t_map_global_triangle_id2local (
*/
h5_id_t
h5t_map_local_triangle_id2global (
h5_file * const f,
h5_file_t * const f,
const h5_id_t local_tri_id
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
switch ( t->mesh_type ) {
case H5_OID_TETRAHEDRON: {
h5_id_t local_tet_id = local_tri_id & H5_TET_MASK;
+11 -11
View File
@@ -3,13 +3,13 @@
h5_id_t
h5t_map_global_vertex_id2local (
h5_file *f,
h5_file_t *f,
h5_id_t global_vid
);
h5_err_t
h5t_map_global_vertex_ids2local (
h5_file *f,
h5_file_t *f,
const h5_id_t * const global_vids,
const h5_id_t size,
h5_id_t * const local_vids
@@ -17,55 +17,55 @@ h5t_map_global_vertex_ids2local (
h5_id_t
h5t_map_local_vertex_id2global (
h5_file *f,
h5_file_t *f,
h5_id_t local_vid
);
h5_id_t
h5t_map_local_entity_id2global (
h5_file *f,
h5_file_t *f,
h5_id_t local_eid
);
h5_id_t
h5t_map_global_entity_id2local (
h5_file * const f,
h5_file_t * const f,
const h5_id_t global_eid
);
h5_id_t
h5t_map_local_triangle_id2global (
h5_file * const f,
h5_file_t * const f,
const h5_id_t local_tid
);
h5_id_t
h5t_map_global_triangle_id2local (
h5_file * const f,
h5_file_t * const f,
const h5_id_t global_tid
);
h5_id_t
h5t_get_local_entity_id (
h5_file *f,
h5_file_t *f,
h5_id_t * const local_vids
);
h5_id_t
h5t_get_global_entity_id (
h5_file *f,
h5_file_t *f,
const h5_id_t * const global_vids
);
h5_id_t
h5t_get_local_triangle_id (
h5_file * const f,
h5_file_t * const f,
h5_id_t * const local_vids
);
h5_id_t
h5t_get_global_triangle_id (
h5_file * const f,
h5_file_t * const f,
h5_id_t * const global_vids
);
+28 -30
View File
@@ -15,9 +15,9 @@
*/
static h5_err_t
_create_array_types (
h5_file * f
h5_file_t * f
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
hsize_t dims[1] = { 3 };
hid_t hid = H5Tarray_create ( H5T_NATIVE_DOUBLE, 1, dims );
@@ -52,9 +52,9 @@ _create_array_types (
static h5_err_t
_create_vertex_type (
h5_file * f
h5_file_t * f
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
hid_t hid = H5Tcreate ( H5T_COMPOUND, sizeof(struct h5_vertex) );
if ( hid < 0 ) {
@@ -94,9 +94,9 @@ _create_vertex_type (
static h5_err_t
_create_triangle_type (
h5_file * f
h5_file_t * f
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
hid_t hid = H5Tcreate ( H5T_COMPOUND, sizeof(struct h5_triangle) );
if ( hid < 0 ) {
@@ -145,9 +145,9 @@ _create_triangle_type (
static h5_err_t
_create_tet_type (
h5_file * f
h5_file_t * f
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
hid_t hid = H5Tcreate ( H5T_COMPOUND, sizeof(struct h5_tetrahedron) );
if ( hid < 0 ) {
@@ -203,11 +203,11 @@ _create_tet_type (
return H5_SUCCESS;
}
h5_err_t
_h5t_init_fdata (
h5_file * f
static h5_err_t
_init_fdata (
h5_file_t * f
) {
struct h5t_fdata * t = &f->t;
struct h5t_fdata * t = f->t;
memset ( t->mesh_name, 0, sizeof ( t->mesh_name ) );
t->num_meshes = -1;
@@ -238,16 +238,14 @@ _h5t_init_fdata (
*/
h5_err_t
_h5t_open_file (
h5_file * f /*!< IN: file handle */
h5_file_t * f /*!< IN: file handle */
) {
h5_err_t h5err = H5_SUCCESS;;
if (( h5err = _h5t_init_fdata ( f )) < 0 ) return h5err;
if (( h5err = _create_array_types ( f )) < 0 ) return h5err;
if (( h5err = _create_vertex_type ( f )) < 0 ) return h5err;
if (( h5err = _create_triangle_type ( f )) < 0 ) return h5err;
if (( h5err = _create_tet_type ( f )) < 0 ) return h5err;
TRY( f->t = _h5_alloc ( NULL, sizeof(*f->t) ) );
TRY( _init_fdata ( f ) );
TRY( _create_array_types ( f ) );
TRY( _create_vertex_type ( f ) );
TRY( _create_triangle_type ( f ) );
TRY( _create_tet_type ( f ) );
return H5_SUCCESS;
}
@@ -264,7 +262,7 @@ _h5t_open_file (
*/
h5_err_t
_h5t_close_file (
h5_file *f /*!< IN: file handle */
h5_file_t *f /*!< IN: file handle */
) {
h5_err_t h5err = H5_SUCCESS;
@@ -289,7 +287,7 @@ _h5t_init_step (
*/
h5_err_t
_h5t_close_step (
h5_file * f
h5_file_t * f
) {
return H5_SUCCESS;
@@ -300,7 +298,7 @@ h5_err_t
_h5t_open_topo_group (
h5_file_t * const f
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
t->topo_gid = _h5_open_group ( f, f->root_gid, H5T_CONTAINER_GRPNAME );
return t->topo_gid;
@@ -310,7 +308,7 @@ h5_err_t
_h5t_open_meshes_group (
h5_file_t * const f
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
if ( t->topo_gid < 0 ) {
h5_err_t h5err = _h5t_open_topo_group ( f );
@@ -333,7 +331,7 @@ h5_err_t
_h5t_open_mesh_group (
h5_file_t * const f
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
if ( t->meshes_gid < 0 ) {
h5_err_t h5err = _h5t_open_meshes_group ( f );
@@ -352,7 +350,7 @@ h5t_open_mesh (
h5_id_t id,
const h5_oid_t type
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
h5_err_t h5err = _h5t_close_mesh ( f );
if ( h5err < 0 ) return h5err;
@@ -411,7 +409,7 @@ static h5_err_t
_release_memory (
h5_file_t * const f
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
if ( t->num_vertices ) {
free ( t->num_vertices );
@@ -470,7 +468,7 @@ _h5t_close_mesh (
h5err = h5t_close_boundary ( f );
if ( h5err < 0 ) return h5err;
if (( h5err = _h5t_init_fdata ( f )) < 0 ) return h5err;
if (( h5err = _init_fdata ( f )) < 0 ) return h5err;
return h5err;
}
@@ -480,7 +478,7 @@ h5t_open_level (
h5_file_t * const f,
const h5_id_t id
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
if ( (id < 0) || (id >= t->num_levels) )
return HANDLE_H5_OUT_OF_RANGE_ERR ( "Level", id );
+60 -60
View File
@@ -12,7 +12,7 @@
h5_err_t
_h5t_write_obj (
h5_file * f,
h5_file_t * f,
const hid_t group_id,
const hsize_t current_dims,
const hsize_t max_dims,
@@ -36,9 +36,9 @@ _h5t_write_obj (
static h5_err_t
_write_vertices (
h5_file * f
h5_file_t * f
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
h5_err_t h5err;
if ( t->num_vertices <= 0 ) return H5_SUCCESS; /* ???? */
@@ -72,9 +72,9 @@ _write_vertices (
static h5_err_t
_write_entities (
h5_file * f
h5_file_t * f
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
h5_err_t h5err;
if ( t->num_entities <= 0 ) return H5_SUCCESS;
@@ -120,9 +120,9 @@ _write_entities (
h5_err_t
_h5t_write_mesh (
h5_file * f
h5_file_t * f
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
h5_err_t h5err;
if ( ! t->mesh_changed ) return 0;
@@ -138,10 +138,10 @@ _h5t_write_mesh (
h5_size_t
h5t_get_num_meshes (
h5_file * f,
h5_file_t * f,
const enum h5_oid type
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
if ( t->topo_gid < 0 ) {
h5_err_t h5err = _h5t_open_topo_group ( f );
@@ -150,12 +150,12 @@ h5t_get_num_meshes (
switch ( type ) {
case H5_OID_TETRAHEDRON:
return (h5_size_t)h5_get_num_objects (
f->t.topo_gid,
t->topo_gid,
"TetMeshes",
H5G_GROUP );
case H5_OID_TRIANGLE:
return (h5_size_t)h5_get_num_objects (
f->t.topo_gid,
t->topo_gid,
"TriangleMeshes",
H5G_GROUP );
default:
@@ -167,9 +167,9 @@ h5t_get_num_meshes (
*/
h5_size_t
h5t_get_num_levels (
h5_file * f
h5_file_t * f
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
h5_err_t h5err;
if ( t->num_levels >= 0 ) return t->num_levels;
@@ -200,9 +200,9 @@ h5t_get_num_levels (
h5_id_t
h5t_get_level (
h5_file * f
h5_file_t * f
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
return t->cur_level;
}
@@ -211,12 +211,12 @@ h5t_get_level (
*/
static h5_err_t
_read_dataset (
h5_file * f,
h5_file_t * f,
hid_t group_id,
const char dataset_name[],
hid_t type_id,
hid_t (*open_mem_space)(h5_file*,hid_t),
hid_t (*open_file_space)(h5_file*,hid_t),
hid_t (*open_mem_space)(h5_file_t*,hid_t),
hid_t (*open_file_space)(h5_file_t*,hid_t),
void * const data ) {
hid_t dataset_id = H5Dopen ( group_id, dataset_name, H5P_DEFAULT );
@@ -254,7 +254,7 @@ _read_dataset (
static hid_t
_open_mem_space_vertices (
h5_file * f,
h5_file_t * f,
hid_t dataset_id
) {
return H5S_ALL;
@@ -262,7 +262,7 @@ _open_mem_space_vertices (
static hid_t
_open_file_space_vertices (
h5_file * f,
h5_file_t * f,
hid_t dataset_id
) {
return H5S_ALL;
@@ -270,7 +270,7 @@ _open_file_space_vertices (
static hid_t
_open_space_all (
h5_file * f,
h5_file_t * f,
hid_t dataset_id
) {
return H5S_ALL;
@@ -278,10 +278,10 @@ _open_space_all (
static h5_err_t
_read_num_vertices (
h5_file * f
h5_file_t * f
) {
h5_err_t h5err;
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
if ( t->mesh_gid < 0 ) {
h5err = _h5t_open_mesh_group ( f );
@@ -307,10 +307,10 @@ _read_num_vertices (
h5_err_t
_h5t_read_vertices (
h5_file * f
h5_file_t * f
) {
h5_err_t h5err;
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
if ( t->mesh_gid < 0 ) {
h5err = _h5t_open_mesh_group ( f );
@@ -350,9 +350,9 @@ _h5t_read_vertices (
h5_size_t
h5t_get_num_vertices_on_level (
h5_file * f
h5_file_t * f
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
if ( t->cur_mesh < 0 ) {
return _h5t_error_undef_mesh ( f );
@@ -369,9 +369,9 @@ h5t_get_num_vertices_on_level (
h5_err_t
h5t_start_traverse_vertices (
h5_file * f
h5_file_t * f
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
t->last_retrieved_vertex_id = -1;
return H5_SUCCESS;
@@ -379,11 +379,11 @@ h5t_start_traverse_vertices (
h5_id_t
h5t_traverse_vertices (
h5_file * f, /*!< file handle */
h5_file_t * f, /*!< file handle */
h5_id_t * const id, /*!< OUT: global vertex id */
h5_float64_t P[3] /*!< OUT: coordinates */
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
if ( t->vertices == NULL ) {
h5_err_t h5err = _h5t_read_vertices ( f );
@@ -393,7 +393,7 @@ h5t_traverse_vertices (
h5_debug ( "Traversing done!" );
return 0;
}
h5_vertex *vertex = &t->vertices[++t->last_retrieved_vertex_id];
h5_vertex_t *vertex = &t->vertices[++t->last_retrieved_vertex_id];
*id = vertex->id;
memcpy ( P, &vertex->P, sizeof ( vertex->P ) );
@@ -403,12 +403,12 @@ h5t_traverse_vertices (
static h5_err_t
_read_num_entities (
h5_file * f
h5_file_t * f
) {
h5_err_t h5err;
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
if ( t->mesh_gid < 0 ) {
h5err = _h5t_open_mesh_group ( f );
@@ -434,11 +434,11 @@ _read_num_entities (
static h5_err_t
_read_num_entities_on_level (
h5_file * f
h5_file_t * f
) {
h5_err_t h5err;
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
if ( t->cur_level < 0 )
return _h5t_error_undef_level( f );
@@ -467,7 +467,7 @@ _read_num_entities_on_level (
static hid_t
_open_mem_space_entities (
h5_file * f,
h5_file_t * f,
hid_t dataset_id
) {
return H5S_ALL;
@@ -475,7 +475,7 @@ _open_mem_space_entities (
static hid_t
_open_file_space_entities (
h5_file * f,
h5_file_t * f,
hid_t dataset_id
) {
return H5S_ALL;
@@ -483,10 +483,10 @@ _open_file_space_entities (
h5_err_t
_h5t_read_entities (
h5_file * f
h5_file_t * f
) {
h5_err_t h5err;
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
if ( t->mesh_gid < 0 ) {
h5err = _h5t_open_mesh_group ( f );
@@ -547,9 +547,9 @@ _h5t_read_entities (
h5_size_t
h5t_get_num_entities_on_level (
h5_file * f
h5_file_t * f
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
if ( t->cur_mesh < 0 ) {
return _h5t_error_undef_mesh ( f );
@@ -566,9 +566,9 @@ h5t_get_num_entities_on_level (
h5_size_t
h5t_get_num_entities (
h5_file * f
h5_file_t * f
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
if ( t->cur_mesh < 0 ) {
return _h5t_error_undef_mesh ( f );
@@ -582,9 +582,9 @@ h5t_get_num_entities (
h5_err_t
h5t_start_traverse_tets (
h5_file * f
h5_file_t * f
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
switch ( t->mesh_type ) {
case H5_OID_TRIANGLE: {
@@ -601,13 +601,13 @@ h5t_start_traverse_tets (
h5_id_t
_traverse_tets (
h5_file * f,
h5_file_t * f,
h5_id_t * const id, /*!< OUT: global tetrahedron id */
h5_id_t * const parent_id, /*!< OUT: global parent id
if level \c >0 else \c -1 */
h5_id_t ids[4] /*!< OUT: tuple with vertex id's */
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
if ( t->entities.data == NULL ) {
h5_err_t h5err = _h5t_read_entities ( f );
@@ -617,7 +617,7 @@ _traverse_tets (
h5_debug ( "Traversing done!" );
return 0;
}
h5_tetrahedron *tet = &t->entities.tets[++t->last_retrieved_entity_id];
h5_tetrahedron_t *tet = &t->entities.tets[++t->last_retrieved_entity_id];
while ( (tet->refined_on_level != -1) &&
(tet->refined_on_level <= t->cur_level) ){
@@ -637,13 +637,13 @@ _traverse_tets (
h5_id_t
h5t_traverse_tets (
h5_file * f,
h5_file_t * f,
h5_id_t * const id, /*!< OUT: global tetrahedron id */
h5_id_t * const parent_id, /*!< OUT: global parent id
if level \c >0 else \c -1 */
h5_id_t ids[4] /*!< OUT: tuple with vertex id's */
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
switch ( t->mesh_type ) {
case H5_OID_TRIANGLE: {
@@ -660,9 +660,9 @@ h5t_traverse_tets (
h5_err_t
h5t_start_traverse_triangles (
h5_file * f
h5_file_t * f
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
switch ( t->mesh_type ) {
case H5_OID_TRIANGLE: {
@@ -680,13 +680,13 @@ h5t_start_traverse_triangles (
static h5_id_t
_traverse_triangles (
h5_file * f,
h5_file_t * f,
h5_id_t * const id, /*!< OUT: global triangle id */
h5_id_t * const parent_id, /*!< OUT: global parent id
if level \c >0 else \c -1 */
h5_id_t ids[3] /*!< OUT: tuple with vertex id's */
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
if ( t->entities.data == NULL ) {
h5_err_t h5err = _h5t_read_entities ( f );
@@ -696,7 +696,7 @@ _traverse_triangles (
h5_debug ( "Traversing done!" );
return 0;
}
h5_triangle *tri = &t->entities.tris[++t->last_retrieved_entity_id];
h5_triangle_t *tri = &t->entities.tris[++t->last_retrieved_entity_id];
while ( (tri->refined_on_level != -1) &&
(tri->refined_on_level <= t->cur_level) ){
@@ -716,14 +716,14 @@ _traverse_triangles (
h5_id_t
h5t_traverse_triangles (
h5_file * f,
h5_file_t * f,
h5_id_t * const id, /*!< OUT: global triangle id */
h5_id_t * const parent_id, /*!< OUT: global parent id
if level \c >0 else \c -1 */
h5_id_t ids[3] /*!< OUT: tuple with vertex id's */
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
switch ( t->mesh_type ) {
case H5_OID_TRIANGLE: {
@@ -739,9 +739,9 @@ h5t_traverse_triangles (
h5_err_t
_h5t_read_mesh (
h5_file *f
h5_file_t *f
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
if ( t->vertices == NULL ) {
h5_err_t h5err = _h5t_read_vertices ( f );
+21 -21
View File
@@ -3,83 +3,83 @@
h5_err_t
_h5t_write_mesh (
h5_file * f
h5_file_t * f
);
h5_size_t
h5t_get_num_meshes (
h5_file * f,
h5_file_t * f,
const enum h5_oid type
);
h5_id_t
h5t_add_mesh (
h5_file * f
h5_file_t * f
);
h5_size_t
h5t_get_num_levels (
h5_file * f
h5_file_t * f
);
h5_id_t
h5t_get_level (
h5_file * f
h5_file_t * f
);
h5_err_t
_h5t_read_vertices (
h5_file * f
h5_file_t * f
);
h5_size_t
h5t_get_num_vertices_on_level (
h5_file * f
h5_file_t * f
);
h5_err_t
h5t_start_traverse_vertices (
h5_file * f
h5_file_t * f
);
h5_id_t
h5t_traverse_vertices (
h5_file * f,
h5_file_t * f,
h5_id_t * const id,
h5_float64_t P[3]
);
h5_size_t
h5t_add_num_tets (
h5_file * f,
h5_file_t * f,
const h5_size_t num
) ;
h5_size_t
h5t_add_num_triangles (
h5_file * f,
h5_file_t * f,
const h5_size_t num
) ;
h5_size_t
h5t_add_num_entities (
h5_file * f,
h5_file_t * f,
const h5_size_t num
) ;
h5_size_t
h5t_get_num_entities (
h5_file * f
h5_file_t * f
);
h5_size_t
h5t_get_num_entities_on_level (
h5_file * f
h5_file_t * f
);
h5_id_t
h5t_store_tet (
h5_file * f,
h5_file_t * f,
const h5_id_t id,
const h5_id_t parent_id,
const h5_id_t vertex_ids[4]
@@ -87,7 +87,7 @@ h5t_store_tet (
h5_id_t
h5t_store_triangle (
h5_file * f,
h5_file_t * f,
const h5_id_t id,
const h5_id_t parent_id,
const h5_id_t vertex_ids[3]
@@ -95,17 +95,17 @@ h5t_store_triangle (
h5_err_t
_h5t_read_entities (
h5_file * f
h5_file_t * f
);
h5_err_t
h5t_start_traverse_tets (
h5_file * f
h5_file_t * f
);
h5_id_t
h5t_traverse_tets (
h5_file * f,
h5_file_t * f,
h5_id_t * const id,
h5_id_t * const parent_id,
h5_id_t vertex_ids[4]
@@ -114,12 +114,12 @@ h5t_traverse_tets (
h5_err_t
h5t_start_traverse_triangles (
h5_file * f
h5_file_t * f
);
h5_id_t
h5t_traverse_triangles (
h5_file * f,
h5_file_t * f,
h5_id_t * const id,
h5_id_t * const parent_id,
h5_id_t vertex_ids[3]
+2 -2
View File
@@ -3,7 +3,7 @@
h5_err_t
_h5t_write_obj (
h5_file * f,
h5_file_t * f,
const hid_t gid,
const hsize_t current_dims,
const hsize_t max_dims,
@@ -14,7 +14,7 @@ _h5t_write_obj (
h5_err_t
_h5t_read_mesh (
h5_file *f
h5_file_t *f
);
#endif
+77 -32
View File
@@ -7,13 +7,14 @@
#include <hdf5.h>
#include "h5_core/h5_core.h"
#include "h5t_types_private.h"
#include "h5_core/h5_core_private.h"
h5_id_t
h5t_add_level (
h5_file_t * const f
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
if ( f->mode == H5_O_RDONLY ) {
return H5_ERR_INVAL;
@@ -49,7 +50,7 @@ _h5t_alloc_num_vertices (
h5_file_t * const f,
const h5_size_t num_vertices
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
ssize_t num_bytes = num_vertices*sizeof ( t->vertices[0] );
h5_debug ( "Allocating %ld bytes.", num_bytes );
@@ -58,13 +59,10 @@ _h5t_alloc_num_vertices (
return HANDLE_H5_NOMEM_ERR;
}
TRY( _h5_alloc_idmap (&t->map_vertex_g2l, num_vertices ), error_exit );
TRY( _h5_alloc_smap (&t->sorted_lvertices, num_vertices ), error_exit );
TRY( _h5_alloc_idmap (&t->map_vertex_g2l, num_vertices ) );
TRY( _h5_alloc_smap (&t->sorted_lvertices, num_vertices ) );
return H5_SUCCESS;
error_exit:
return h5_get_errno();
}
h5_err_t
@@ -72,7 +70,7 @@ _h5t_add_num_vertices (
h5_file_t * const f,
const h5_size_t num
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
if ( t->cur_level < 0 ) {
return _h5t_error_undef_level( f );
@@ -90,7 +88,7 @@ h5t_store_vertex (
const h5_id_t global_id, /*!< global vertex id or -1 */
const h5_float64_t P[3] /*!< coordinates */
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
/*
more than allocated
@@ -119,7 +117,7 @@ h5t_store_vertex (
}
h5_id_t local_id = ++t->last_stored_vertex_id;
h5_vertex *vertex = &t->vertices[local_id];
h5_vertex_t *vertex = &t->vertices[local_id];
vertex->id = global_id;
memcpy ( &vertex->P, P, sizeof ( vertex->P ) );
@@ -134,7 +132,7 @@ _h5t_alloc_num_entities (
const size_t cur_num_entities,
const size_t new_num_entities
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
size_t sizeof_entity = 0;
size_t sizeof_lentity = 0;
@@ -175,17 +173,15 @@ h5_add_num_tets (
h5_file_t * const f,
const h5_size_t num
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
if ( t->mesh_type != H5_OID_TETRAHEDRON ) {
_h5t_error_illegal_object_type ( f, H5_OID_TETRAHEDRON );
}
TRY( _h5t_add_num_vertices ( f, num+3 ), error_exit );
TRY( _h5t_add_num_entities ( f, num ), error_exit );
TRY( _h5t_add_num_vertices ( f, num+3 ) );
TRY( _h5t_add_num_entities ( f, num ) );
return H5_SUCCESS;
error_exit:
return h5_get_errno();
}
h5_err_t
@@ -193,16 +189,14 @@ h5_add_num_triangles (
h5_file_t * const f,
const h5_size_t num
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
if ( t->mesh_type != H5_OID_TRIANGLE ) {
_h5t_error_illegal_object_type ( f, H5_OID_TRIANGLE );
}
TRY( _h5t_add_num_vertices ( f, num+2 ), error_exit );
TRY( _h5t_add_num_entities ( f, num ), error_exit );
TRY( _h5t_add_num_vertices ( f, num+2 ) );
TRY( _h5t_add_num_entities ( f, num ) );
return H5_SUCCESS;
error_exit:
return h5_get_errno();
}
h5_err_t
@@ -210,7 +204,7 @@ _h5t_add_num_entities (
h5_file_t * const f,
const h5_size_t num
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
size_t cur_num_entities = t->cur_level > 0 ?
t->num_entities[t->cur_level-1] : 0;
@@ -233,7 +227,7 @@ h5t_store_tet (
const h5_id_t vertex_ids[4] /*!< tuple with vertex id's */
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
/*
more than allocated
@@ -277,7 +271,7 @@ h5t_store_tet (
}
h5_id_t local_id = ++t->last_stored_entity_id;
h5_tetrahedron *tet = &t->entities.tets[local_id];
h5_tetrahedron_t *tet = &t->entities.tets[local_id];
tet->id = global_id;
tet->parent_id = parent_id;
tet->refined_on_level = -1;
@@ -310,7 +304,7 @@ h5t_store_triangle (
const h5_id_t vertex_ids[3] /*!< tuple with vertex id's */
) {
struct h5t_fdata *t = &f->t;
struct h5t_fdata *t = f->t;
/*
more than allocated
@@ -354,7 +348,7 @@ h5t_store_triangle (
}
h5_id_t local_id = ++t->last_stored_entity_id;
h5_triangle *tri = &t->entities.tris[local_id];
h5_triangle_t *tri = &t->entities.tris[local_id];
tri->id = global_id;
tri->parent_id = parent_id;
tri->refined_on_level = -1;
@@ -374,6 +368,26 @@ h5t_store_triangle (
return local_id;
}
/*!
Refine edge. Store vertex, if new.
\return local id of vertex
*/
h5_err_t
_h5t_bisect_edge (
h5_file_t * const f,
h5_id_t local_vid0,
h5_id_t local_vid1
) {
struct h5t_fdata *t = f->t;
h5_float64_t *P0 = t->vertices[local_vid0].P;
h5_float64_t *P1 = t->vertices[local_vid1].P;
return H5_SUCCESS;
}
/*!
Refine tetrahedron \c global_tid
@@ -384,14 +398,45 @@ h5t_refine_tet (
h5_file_t * const f,
const h5_id_t global_tid
) {
struct h5t_fdata *t = f->t;
h5_id_t local_vids[6];
h5_id_t local_tid;
TRY( local_tid = h5t_map_global_entity_id2local( f, global_tid ) );
local_vids[0] = _h5t_bisect_edge(
f,
t->lentities.tets[local_tid].vertex_ids[0],
t->lentities.tets[local_tid].vertex_ids[1] );
local_vids[1] = _h5t_bisect_edge(
f,
t->lentities.tets[local_tid].vertex_ids[0],
t->lentities.tets[local_tid].vertex_ids[2] );
local_vids[2] = _h5t_bisect_edge(
f,
t->lentities.tets[local_tid].vertex_ids[0],
t->lentities.tets[local_tid].vertex_ids[3] );
local_vids[3] = _h5t_bisect_edge(
f,
t->lentities.tets[local_tid].vertex_ids[1],
t->lentities.tets[local_tid].vertex_ids[2] );
local_vids[4] = _h5t_bisect_edge(
f,
t->lentities.tets[local_tid].vertex_ids[1],
t->lentities.tets[local_tid].vertex_ids[3] );
local_vids[5] = _h5t_bisect_edge(
f,
t->lentities.tets[local_tid].vertex_ids[2],
t->lentities.tets[local_tid].vertex_ids[3] );
/*
get local id of tet
compute vertices
add new vertices
add new tets
*/
error_exit:
return h5_get_errno();
#if 0
h5t_store_tet (
f,
-1,
global_id,
#endif
return H5_SUCCESS;
}
+44 -44
View File
@@ -11,14 +11,14 @@
h5_int64_t
h5u_has_view (
h5_file *f
h5_file_t *f
) {
return ( f->viewstart >= 0 ) && ( f->viewend >= 0 );
}
static hid_t
_get_diskshape_for_reading (
h5_file *f,
h5_file_t *f,
hid_t dataset
) {
@@ -65,7 +65,7 @@ _get_diskshape_for_reading (
static hid_t
_get_memshape_for_reading (
h5_file *f,
h5_file_t *f,
hid_t dataset
) {
@@ -81,12 +81,12 @@ _get_memshape_for_reading (
}
}
h5part_int64_t
h5_int64_t
H5U_get_num_elems (
h5_file *f /*!< [in] Handle to open file */
h5_file_t *f /*!< [in] Handle to open file */
) {
h5part_int64_t herr;
h5_int64_t herr;
hid_t space_id;
hid_t dataset_id;
char dataset_name[128];
@@ -112,7 +112,7 @@ H5U_get_num_elems (
return HANDLE_H5D_OPEN_ERR ( dataset_name );
space_id = _get_diskshape_for_reading ( f, dataset_id );
if ( space_id < 0 ) return (h5part_int64_t)space_id;
if ( space_id < 0 ) return (h5_int64_t)space_id;
if ( h5u_has_view ( f ) ) {
nparticles = H5Sget_select_npoints ( space_id );
@@ -130,12 +130,12 @@ H5U_get_num_elems (
herr = H5Dclose ( dataset_id );
if ( herr < 0 ) return HANDLE_H5D_CLOSE_ERR;
return (h5part_int64_t) nparticles;
return (h5_int64_t) nparticles;
}
h5part_int64_t
h5_int64_t
H5U_read_elems (
h5_file *f, /*!< [in] Handle to open file */
h5_file_t *f, /*!< [in] Handle to open file */
const char *name, /*!< [in] Name to associate dataset with */
void *array, /*!< [out] Array of data */
const hid_t type
@@ -147,17 +147,17 @@ H5U_read_elems (
hid_t memspace_id;
if ( f->step_gid < 0 ) {
h5part_int64_t h5err = h5_set_step ( f, f->step_idx );
h5_int64_t h5err = h5_set_step ( f, f->step_idx );
if ( h5err < 0 ) return h5err;
}
dataset_id = H5Dopen ( f->step_gid, name, H5P_DEFAULT );
if ( dataset_id < 0 ) return HANDLE_H5D_OPEN_ERR ( name );
space_id = _get_diskshape_for_reading ( f, dataset_id );
if ( space_id < 0 ) return (h5part_int64_t)space_id;
if ( space_id < 0 ) return (h5_int64_t)space_id;
memspace_id = _get_memshape_for_reading ( f, dataset_id );
if ( memspace_id < 0 ) return (h5part_int64_t)memspace_id;
if ( memspace_id < 0 ) return (h5_int64_t)memspace_id;
herr = H5Dread (
dataset_id,
@@ -185,10 +185,10 @@ H5U_read_elems (
return H5_SUCCESS;
}
h5part_int64_t
h5_int64_t
H5U_set_num_elements (
h5_file *f, /*!< [in] Handle to open file */
h5part_int64_t nparticles /*!< [in] Number of particles */
h5_file_t *f, /*!< [in] Handle to open file */
h5_int64_t nparticles /*!< [in] Number of particles */
) {
CHECK_FILEHANDLE( f );
@@ -311,9 +311,9 @@ H5U_set_num_elements (
return H5_SUCCESS;
}
h5part_int64_t
h5_int64_t
H5U_write_data (
h5_file *f, /*!< IN: Handle to open file */
h5_file_t *f, /*!< IN: Handle to open file */
const char *name, /*!< IN: Name to associate array with */
const void *array, /*!< IN: Array to commit to disk */
const hid_t type /*!< IN: Type of data */
@@ -334,9 +334,9 @@ H5U_write_data (
f->diskshape );
}
h5part_int64_t
h5_int64_t
H5U_reset_view (
h5_file *f
h5_file_t *f
) {
herr_t herr = 0;
@@ -362,13 +362,13 @@ H5U_reset_view (
return H5_SUCCESS;
}
h5part_int64_t
h5_int64_t
H5U_set_view (
h5_file *f, /*!< [in] Handle to open file */
h5part_int64_t start, /*!< [in] Start particle */
h5part_int64_t end /*!< [in] End particle */
h5_file_t *f, /*!< [in] Handle to open file */
h5_int64_t start, /*!< [in] Start particle */
h5_int64_t end /*!< [in] End particle */
) {
h5part_int64_t herr = 0;
h5_int64_t herr = 0;
hsize_t total;
hsize_t stride = 1;
hsize_t dmax = H5S_UNLIMITED;
@@ -439,15 +439,15 @@ H5U_set_view (
return H5_SUCCESS;
}
h5part_int64_t
h5_int64_t
H5U_get_view (
h5_file *f,
h5part_int64_t *start,
h5part_int64_t *end
h5_file_t *f,
h5_int64_t *start,
h5_int64_t *end
) {
h5part_int64_t viewstart = 0;
h5part_int64_t viewend = 0;
h5_int64_t viewstart = 0;
h5_int64_t viewend = 0;
if ( f->viewstart >= 0 )
viewstart = f->viewstart;
@@ -467,17 +467,17 @@ H5U_get_view (
return viewend - viewstart;
}
h5part_int64_t
h5_int64_t
H5U_set_canonical_view (
h5_file *f
h5_file_t *f
) {
h5part_int64_t herr = H5U_reset_view ( f );
h5_int64_t herr = H5U_reset_view ( f );
if ( herr < 0 ) return HANDLE_H5_SET_VIEW_ERR( herr, -1, -1 );
#ifdef PARALLEL_IO
h5part_int64_t start = 0;
h5part_int64_t end = 0;
h5part_int64_t n = 0;
h5_int64_t start = 0;
h5_int64_t end = 0;
h5_int64_t n = 0;
int i = 0;
n = H5U_get_num_elems ( f );
@@ -516,18 +516,18 @@ H5U_set_canonical_view (
/*!
Get information about dataset in current index given by its index
*/
h5part_int64_t
h5_int64_t
H5U_get_dataset_info (
h5_file *f, /*!< [in] Handle to open file */
const h5part_int64_t idx,/*!< [in] Index of the dataset */
h5_file_t *f, /*!< [in] Handle to open file */
const h5_int64_t idx,/*!< [in] Index of the dataset */
char *dataset_name, /*!< [out] Name of dataset */
const h5part_int64_t len_dataset_name,
const h5_int64_t len_dataset_name,
/*!< [in] Size of buffer \c dataset_name */
h5part_int64_t *type, /*!< [out] Type of data in dataset */
h5part_int64_t *nelem /*!< [out] Number of elements. */
h5_int64_t *type, /*!< [out] Type of data in dataset */
h5_int64_t *nelem /*!< [out] Number of elements. */
) {
h5part_int64_t herr = h5_get_object_name (
h5_int64_t herr = h5_get_object_name (
f->file,
f->step_name,
H5G_DATASET,
+10 -10
View File
@@ -3,12 +3,12 @@
h5_int64_t
H5U_get_num_elems (
h5_file *f
h5_file_t *f
);
h5_int64_t
H5U_read_elems (
h5_file *f,
h5_file_t *f,
const char *name,
void *array,
const hid_t type
@@ -16,13 +16,13 @@ H5U_read_elems (
h5_int64_t
H5U_set_num_elements (
h5_file *f,
h5_file_t *f,
h5_int64_t nparticles
);
h5_int64_t
H5U_write_data (
h5_file *f,
h5_file_t *f,
const char *name,
const void *array,
const hid_t type
@@ -30,36 +30,36 @@ H5U_write_data (
h5_int64_t
h5u_has_view (
h5_file *f
h5_file_t *f
);
h5_int64_t
H5U_reset_view (
h5_file *f
h5_file_t *f
);
h5_int64_t
H5U_set_view (
h5_file *f,
h5_file_t *f,
h5_int64_t start,
h5_int64_t end
);
h5_int64_t
H5U_get_view (
h5_file *f,
h5_file_t *f,
h5_int64_t *start,
h5_int64_t *end
);
h5_int64_t
H5U_set_canonical_view (
h5_file *f
h5_file_t *f
);
h5_int64_t
H5U_get_dataset_info (
h5_file *f,
h5_file_t *f,
const h5_int64_t idx,
char *dataset_name,
const h5_int64_t len_dataset_name,