Commit 57d0e96b authored by Uwe Schulzweida's avatar Uwe Schulzweida
Browse files

Renamed CHUNK_XXX to CDI_CHUNK_XXX.

parent ea0d9f63
......@@ -411,7 +411,7 @@ int cdfDefVar(stream_t *streamptr, int varID)
}
else if ( dimorder[id] == 2 && yid != UNDEFID )
{
if ( chunktype == CHUNK_LINES )
if ( chunktype == CDI_CHUNK_LINES )
chunks[ndims] = 1;
else
chunks[ndims] = ysize;
......@@ -517,7 +517,7 @@ int cdfDefVar(stream_t *streamptr, int varID)
#if defined (HAVE_NETCDF4)
if ( lchunk && (streamptr->filetype == FILETYPE_NC4 || streamptr->filetype == FILETYPE_NC4C) )
{
if ( chunktype == CHUNK_AUTO )
if ( chunktype == CDI_CHUNK_AUTO )
retval = nc_def_var_chunking(fileID, ncvarid, NC_CHUNKED, NULL);
else
retval = nc_def_var_chunking(fileID, ncvarid, NC_CHUNKED, chunks);
......
......@@ -120,9 +120,9 @@ extern "C" {
/* Chunks */
#define CHUNK_AUTO 1 /* use default chunk size */
#define CHUNK_GRID 2
#define CHUNK_LINES 3
#define CDI_CHUNK_AUTO 1 /* use default chunk size */
#define CDI_CHUNK_GRID 2
#define CDI_CHUNK_LINES 3
/* GRID types */
......
......@@ -28,7 +28,7 @@ int cdiDefaultModelID = CDI_UNDEFID;
int cdiDefaultTableID = CDI_UNDEFID;
//int cdiNcMissingValue = CDI_UNDEFID;
int cdiNcChunksizehint = CDI_UNDEFID;
int cdiChunkType = CHUNK_GRID;
int cdiChunkType = CDI_CHUNK_GRID;
int cdiSplitLtype105 = CDI_UNDEFID;
int cdiIgnoreAttCoordinates = FALSE;
......@@ -237,9 +237,9 @@ void cdiSetChunk(const char *chunkAlgo)
//size_t len = strlen(chunkAlgo);
int algo = -1;
if ( strcmp("auto", chunkAlgo) == 0 ) algo = CHUNK_AUTO;
else if ( strcmp("grid", chunkAlgo) == 0 ) algo = CHUNK_GRID;
else if ( strcmp("lines", chunkAlgo) == 0 ) algo = CHUNK_LINES;
if ( strcmp("auto", chunkAlgo) == 0 ) algo = CDI_CHUNK_AUTO;
else if ( strcmp("grid", chunkAlgo) == 0 ) algo = CDI_CHUNK_GRID;
else if ( strcmp("lines", chunkAlgo) == 0 ) algo = CDI_CHUNK_LINES;
/*
else if ( (pch = strstr(chunkAlgo,"x")) != 0 )
{
......
......@@ -1909,20 +1909,20 @@ void grid_set_chunktype(grid_t *grid, ncvar_t *ncvar)
if ( grid->type == GRID_UNSTRUCTURED )
{
if ( ncvar->chunks[ndims-1] == grid->size )
ncvar->chunktype = CHUNK_GRID;
ncvar->chunktype = CDI_CHUNK_GRID;
else
ncvar->chunktype = CHUNK_AUTO;
ncvar->chunktype = CDI_CHUNK_AUTO;
}
else
{
if ( grid->x.size > 1 && grid->y.size > 1 && ndims > 1 &&
grid->x.size == ncvar->chunks[ndims-1] &&
grid->y.size == ncvar->chunks[ndims-2] )
ncvar->chunktype = CHUNK_GRID;
ncvar->chunktype = CDI_CHUNK_GRID;
else if ( grid->x.size > 1 && grid->x.size == ncvar->chunks[ndims-1] )
ncvar->chunktype = CHUNK_LINES;
ncvar->chunktype = CDI_CHUNK_LINES;
else
ncvar->chunktype = CHUNK_AUTO;
ncvar->chunktype = CDI_CHUNK_AUTO;
}
}
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment