aboutsummaryrefslogtreecommitdiff
path: root/iemlib1
diff options
context:
space:
mode:
authormusil <tmusil@users.sourceforge.net>2012-09-06 15:50:29 +0000
committermusil <tmusil@users.sourceforge.net>2012-09-06 15:50:29 +0000
commitf9f3f7fab4cb870ba675058f783af631dc80f152 (patch)
treea6050a76fbf1a3861a69d6f4a79e1f2072e05a83 /iemlib1
parent1c370c22ba52338507e351e7413dc49fe873f8f0 (diff)
64 bit array access compatible
svn path=/trunk/externals/iemlib/; revision=16191
Diffstat (limited to 'iemlib1')
-rw-r--r--iemlib1/src/iemlib.h15
1 files changed, 14 insertions, 1 deletions
diff --git a/iemlib1/src/iemlib.h b/iemlib1/src/iemlib.h
index 973bfeb..29c6276 100644
--- a/iemlib1/src/iemlib.h
+++ b/iemlib1/src/iemlib.h
@@ -1,7 +1,7 @@
/* For information on usage and redistribution, and for a DISCLAIMER OF ALL
* WARRANTIES, see the file, "LICENSE.txt," in this distribution.
-iemlib written by Thomas Musil, Copyright (c) IEM KUG Graz Austria 2000 - 2007 */
+iemlib written by Thomas Musil, Copyright (c) IEM KUG Graz Austria 2000 - 2011 */
#ifndef __IEMLIB_H__
#define __IEMLIB_H__
@@ -99,4 +99,17 @@ union tabfudge_f
#endif
+/* on 64bit systems we cannot use garray_getfloatarray... */
+#if((PD_MAJOR_VERSION)&&(PD_MINOR_VERSION > 40))
+# define iemarray_t t_word
+# define iemarray_getarray garray_getfloatwords
+# define iemarray_getfloat(pointer, index) (pointer[index].w_float)
+# define iemarray_setfloat(pointer, index, fvalue) (pointer[index].w_float = fvalue)
+#else
+# define iemarray_t t_float
+# define iemarray_getarray garray_getfloatarray
+# define iemarray_getfloat(pointer, index) (pointer[index])
+# define iemarray_setfloat(pointer, index, fvalue) (pointer[index] = fvalue)
+#endif
+
#endif