summaryrefslogtreecommitdiffstats
path: root/hl/examples/ex_image1.c
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2007-03-27 03:06:48 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2007-03-27 03:06:48 (GMT)
commitc64ac252cdd9fe40b96313e2435551f16428b9d6 (patch)
tree9ff6633ac3ee8fe9529620a0ecfc99bbbab451f8 /hl/examples/ex_image1.c
parentddf436469153cc5deb7cadfdb9a1b985c605774f (diff)
downloadhdf5-c64ac252cdd9fe40b96313e2435551f16428b9d6.zip
hdf5-c64ac252cdd9fe40b96313e2435551f16428b9d6.tar.gz
hdf5-c64ac252cdd9fe40b96313e2435551f16428b9d6.tar.bz2
[svn-r13549] Description:
Check in changes from Elena and I to get pgcc compiler working again. Primarily (all?) changes to move from using 'hsize_t' as array index to using something else ('size_t') mostly. Tested on: Linux/32 2.4 kagiso w/pgcc
Diffstat (limited to 'hl/examples/ex_image1.c')
-rw-r--r--hl/examples/ex_image1.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/hl/examples/ex_image1.c b/hl/examples/ex_image1.c
index 9b3c426..96bc7c7 100644
--- a/hl/examples/ex_image1.c
+++ b/hl/examples/ex_image1.c
@@ -16,8 +16,8 @@
#include "hdf5.h"
#include "hdf5_hl.h"
-#define WIDTH (hsize_t)400
-#define HEIGHT (hsize_t)200
+#define WIDTH 400
+#define HEIGHT 200
#define PAL_ENTRIES 9
unsigned char buf [ WIDTH*HEIGHT ];
@@ -26,7 +26,7 @@ int main( void )
hid_t file_id;
herr_t status;
hsize_t pal_dims[] = {PAL_ENTRIES,3};
- hsize_t i, j;
+ size_t i, j;
int n, space;
unsigned char pal[PAL_ENTRIES*3] = { /* create a palette with 9 colors */
0,0,168, /* dark blue */
@@ -56,7 +56,7 @@ int main( void )
file_id = H5Fcreate( "ex_image1.h5", H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT );
/* make the image */
- status = H5IMmake_image_8bit( file_id, "image1", WIDTH, HEIGHT, buf );
+ status = H5IMmake_image_8bit( file_id, "image1", (hsize_t)WIDTH, (hsize_t)HEIGHT, buf );
/* make a palette */
status = H5IMmake_palette( file_id, "pallete", pal_dims, pal );