#
libsff

Home | Modules | Examples

# /home/pinky2/mattijs/OpenFOAM/OpenFOAM-1.0/applications/utilities/mesh/conversion/ccm24ToFoam/libccmio/libccmio/ccmiobuffer.h

Go to the documentation of this file.

    00001 #ifndef CCMIO_BUFFER_H
    00002 #define CCMIO_BUFFER_H
    00003
    00004 /*@@
    00005  *  Program: Star File Format Library  - $RCSfile: ccmiobuffer.h,v $
    00006  *  Author:  Geoff Prewett
    00007  *  Date:    July 31, 2003
    00008  *
    00009  *
    00010  *  Star File Format Library - Copyright (C) 2003 by adapco, Ltd.
    00011  *
    00012  *  This program is the property of adapco, Ltd. and contains
    00013  *  confidential and proprietary information.  The unauthorized use,
    00014  *  distribution, or duplication of this program is prohibited.
    00015  *  All rights reserved.
    00016  *
    00017  *  $Id: ccmiobuffer.h,v 1.2 2004/07/07 20:13:50 prewett Exp $
    00018  */
    00019
    00020 #ifdef __cplusplus
    00021 extern "C" {
    00022 #endif
    00023
    00024 #include <stdarg.h>
    00025 typedef char CCMIOBufferDataType;
    00026 struct _CCMIOBuffer {
    00027     long size;
    00028     long start;
    00029     CCMIOBufferDataType *buffer;
    00030     CCMIONode node;
    00031     int nDims;
    00032     int *dims;
    00033     unsigned int max;
    00034     int typeSize;
    00035     int isRead;
    00037     };
    00038
    00039 typedef struct _CCMIOBuffer* CCMIOBuffer;
    00040
    00041 /* \ingroup core */
    00042 #define kCCMIOInfinite          0
    00043 /* \ingroup core */
    00044 #define kCCMIODefaultBufferSize kCCMIOInfinite
    00045
    00046 /* \{
    00047    \name CCMIOBuffer
    00048    \brief Buffers reading and writing.
    00049    \ingroup core */
    00050
    00053 extern void CCMIOSetBufferSize( int n );
    00054
    00056 extern CCMIOError CCMIOCreateBuffer( CCMIOError *err, CCMIONode node,
    00057                                      CCMIOBufferType which, CCMIOBuffer *buff );
    00058
    00060 extern CCMIOError CCMIODestroyBuffer( CCMIOError *err, CCMIOBuffer buff );
    00061
    00073 extern CCMIOError CCMIOBufferReadDataPoint( CCMIOError *err, CCMIOBuffer buff,
    00074                                             void *data, ... );
    00075 extern CCMIOError CCMIOvBufferReadDataPoint( CCMIOError *err, CCMIOBuffer buff,
    00076                                              void *data, va_list args );
    00077
    00087 extern CCMIOError CCMIOBufferWriteNextDataPoint( CCMIOError *err,
    00088                                                  CCMIOBuffer buff,
    00089                                                  int n, void *data );
    00090
    00093 extern CCMIOError CCMIOBufferWriteDataPoint( CCMIOError *err, CCMIOBuffer buff,
    00094                                              void *data, ... );
    00095 extern CCMIOError CCMIOvBufferWriteDataPoint( CCMIOError *err, CCMIOBuffer buff,
    00096                                               void *data, va_list args );
    00098 extern CCMIOError CCMIOBufferGetNode( CCMIOError *err, CCMIOBuffer buff,
    00099                                       CCMIONode *node);
    00100 /*\}*/
    00101 #ifdef __cplusplus
    00102 }
    00103 #endif
    00104 #endif // CCMIO_BUFFER_H