diff options
Diffstat (limited to 'src/IOJpeg.h')
-rw-r--r-- | src/IOJpeg.h | 56 |
1 files changed, 56 insertions, 0 deletions
diff --git a/src/IOJpeg.h b/src/IOJpeg.h new file mode 100644 index 0000000..75355e2 --- /dev/null +++ b/src/IOJpeg.h @@ -0,0 +1,56 @@ +#ifdef __cplusplus +extern "C" { +#endif + +#define SLABSKEL_MAXDIM 4 + +#include "StoreNamedData.h" + +/* structure holding information on the output geometry */ +typedef struct IOJpegGeo +{ + int vdim; /* dimension of the gridvariable (dynamic) */ + int sdim; /* dimension of the slab (dynamic) */ + int direction[SLABSKEL_MAXDIM]; /* direction of slab (by parameter) */ + int slab_start[SLABSKEL_MAXDIM];/* global start index (by parameter) */ + int length[SLABSKEL_MAXDIM]; /* requested index slab length (by parameter) */ + int actlen[SLABSKEL_MAXDIM]; /* actual index slab length (by PUGHSlab)*/ + int downs[SLABSKEL_MAXDIM]; /* downsampling (by parameter) */ +} IOJpegGeo_t; + + +/* IOJpeg GH extension structure */ +typedef struct IOJpegGH { + + /* how often to output */ + int out2D_every; + + /* flags indicating output for var [i] */ + char *do_out2D; + + /* directories in which to output */ + char *outdir2D; + + /* the last iteration output */ + int *out2D_last; + + /* geometry information (downsampling, zooming, etc.) */ + IOJpegGeo_t **out_geo; + + /* database for names of output files that were already created */ + pNamedData *fileList_2D; + + +} IOJpegGH; + +/* function prototypes */ +int IOJpeg_Write3D (cGH *GH, int index, const char *alias); +int IOJpeg_Write2D (cGH *GH, int index, const char *alias); +int IOJpeg_Write1D (cGH *GH, int index, const char *alias); + +int IOJpeg_DumpVar (cGH *GH, int index, int timelevel, IOJpegGeo_t *geo, FILE *fid); + + +#ifdef __cplusplus +} // extern "C" +#endif |