aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorschnetter <schnetter@38c3d835-c875-442e-b0fe-21c19ce1d001>2005-01-29 18:07:22 +0000
committerschnetter <schnetter@38c3d835-c875-442e-b0fe-21c19ce1d001>2005-01-29 18:07:22 +0000
commit6d71eaefe8b6e91e5568b8c99acba0d35380aeb1 (patch)
treed05908ea69f822b28d5817e4770763f952cf7027
parent4580d1dc57096fb7a99d0c93351a61c3025dd24e (diff)
Use CCTK_BYTE instead of CCTK_CHAR.
Add support for CCTK_INT1. CCTK_BYTE as UCHAR instead of CHAR. git-svn-id: http://svn.cactuscode.org/arrangements/CactusPUGHIO/IOPanda/trunk@76 38c3d835-c875-442e-b0fe-21c19ce1d001
-rw-r--r--src/Output.c7
-rw-r--r--src/Write.c2
2 files changed, 7 insertions, 2 deletions
diff --git a/src/Output.c b/src/Output.c
index 2b3bc75..d04cf49 100644
--- a/src/Output.c
+++ b/src/Output.c
@@ -484,7 +484,7 @@ static int DumpVar (const cGH *GH, const ioRequest *request, const char *alias)
switch (request->hdatatype)
{
- case CCTK_VARIABLE_CHAR: ainfo.esize_ = CHAR; break;
+ case CCTK_VARIABLE_BYTE: ainfo.esize_ = UCHAR; break;
case CCTK_VARIABLE_INT:
#ifdef CCTK_INTEGER_PRECISION_8
@@ -493,6 +493,8 @@ static int DumpVar (const cGH *GH, const ioRequest *request, const char *alias)
ainfo.esize_ = INT32; break;
#elif CCTK_INTEGER_PRECISION_2
ainfo.esize_ = INT16; break;
+#elif CCTK_INTEGER_PRECISION_1
+ ainfo.esize_ = INT8; break;
#endif
case CCTK_VARIABLE_REAL:
@@ -502,6 +504,9 @@ static int DumpVar (const cGH *GH, const ioRequest *request, const char *alias)
ainfo.esize_ = FLOAT64; break;
#endif
+#ifdef CCTK_INT1
+ case CCTK_VARIABLE_INT1: ainfo.esize_ = INT8; break;
+#endif
#ifdef CCTK_INT2
case CCTK_VARIABLE_INT2: ainfo.esize_ = INT16; break;
#endif
diff --git a/src/Write.c b/src/Write.c
index 9900d96..2566377 100644
--- a/src/Write.c
+++ b/src/Write.c
@@ -153,7 +153,7 @@ void IOPanda_getDumpData (const cGH *GH, int vindex, int timelevel,
but that way produces much more efficient code */
l = 0;
switch (CCTK_VarTypeI (vindex)) {
- case CCTK_VARIABLE_CHAR:
+ case CCTK_VARIABLE_BYTE:
char_ptr = (CCTK_BYTE *) *outme;
for (k = start [2]; k <= end [2]; k += ioUtilGH->downsample [2])
for (j = start [1]; j <= end [1]; j += ioUtilGH->downsample [1])