diff options
author | Quincey Koziol <koziol@hdfgroup.org> | 1998-02-25 18:48:33 (GMT) |
---|---|---|
committer | Quincey Koziol <koziol@hdfgroup.org> | 1998-02-25 18:48:33 (GMT) |
commit | faa3f5739e0b52d84d119791b6859fe610b76d37 (patch) | |
tree | 6c1849a3516a7bf19a4f33af1868bb55e536c3d3 /examples/h5_chunk_read.c | |
parent | 1f96b24ba70e33d1c87dd5773d3ef18d1f46a3c5 (diff) | |
download | hdf5-faa3f5739e0b52d84d119791b6859fe610b76d37.zip hdf5-faa3f5739e0b52d84d119791b6859fe610b76d37.tar.gz hdf5-faa3f5739e0b52d84d119791b6859fe610b76d37.tar.bz2 |
[svn-r296] Switched prefix for dataspaces from H5P to H5S
Diffstat (limited to 'examples/h5_chunk_read.c')
-rw-r--r-- | examples/h5_chunk_read.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/examples/h5_chunk_read.c b/examples/h5_chunk_read.c index 3460d9d..916383b 100644 --- a/examples/h5_chunk_read.c +++ b/examples/h5_chunk_read.c @@ -48,8 +48,8 @@ dataset = H5Dopen(file, DATASETNAME); */ filespace = H5Dget_space(dataset); /* Get filespace handle first. */ -rank = H5Pget_ndims(filespace); -status_n = H5Pget_dims(filespace, dims); +rank = H5Sget_ndims(filespace); +status_n = H5Sget_dims(filespace, dims); printf("dataset rank %d, dimensions %d x %d \n", rank, dims[0], dims[1]); /* @@ -73,7 +73,7 @@ printf("chunk rank %d, dimensions %d x %d \n", rank_chunk, /* * Define the memory space to read dataset. */ -memspace = H5Pcreate_simple(RANK,dims,NULL); +memspace = H5Screate_simple(RANK,dims,NULL); /* * Read dataset back and display. @@ -110,7 +110,7 @@ for (j = 0; j < dims[0]; j++) { * and read it into column array. */ col_dims[0] = 10; -memspace = H5Pcreate_simple(RANKC, col_dims, NULL); +memspace = H5Screate_simple(RANKC, col_dims, NULL); /* * Define the column (hyperslab) to read. @@ -119,7 +119,7 @@ offset[0] = 0; offset[1] = 2; count[0] = 10; count[1] = 1; -status = H5Pset_hyperslab(filespace, offset, count, NULL); +status = H5Sset_hyperslab(filespace, offset, count, NULL); status = H5Dread(dataset, H5T_NATIVE_INT, memspace, filespace, H5C_DEFAULT, column); printf("\n"); @@ -146,7 +146,7 @@ for (i = 0; i < 10; i++) { /* * Define the memory space to read a chunk. */ -memspace = H5Pcreate_simple(rank_chunk,chunk_dims,NULL); +memspace = H5Screate_simple(rank_chunk,chunk_dims,NULL); /* * Define chunk in the file (hyperslab) to read. @@ -155,7 +155,7 @@ offset[0] = 2; offset[1] = 0; count[0] = chunk_dims[0]; count[1] = chunk_dims[1]; -status = H5Pset_hyperslab(filespace, offset, count, NULL); +status = H5Sset_hyperslab(filespace, offset, count, NULL); /* * Read chunk back and display. @@ -179,8 +179,8 @@ for (j = 0; j < chunk_dims[0]; j++) { */ H5Cclose(cparms); H5Dclose(dataset); -H5Pclose(filespace); -H5Pclose(memspace); +H5Sclose(filespace); +H5Sclose(memspace); H5Fclose(file); } |