Main Page | Modules | Alphabetical List | Data Structures | File List | Data Fields | Globals

imaallo.c File Reference

#include "idima.h"
#include "idima-private.h"
#include "iderr.h"
#include "idprint.h"
#include <stdlib.h>

Go to the source code of this file.

Functions

void _IdFreeLinesOfPlane (void **pi, int n)
void _IdFreePlanesOfBloc (void ***, int, int)
int _IdAllocLinesOfPlane (void *piv, int sx, int sy, int si)
void ** _IdAllocPlan (int sx, int sy, int si)
void _IdFreePlan (void **pi, int n)
void *** _IdAllocBloc (int sx, int sy, int sz, int si)
void _IdFreeBloc (void ***pi, int nbp, int nbl)
void _IdImaFree (PPIMAGE *pi)
 Free dynamically allocated PPIMAGE "object".

PPIMAGE IdImaAlloc (int sx, int sy, int ty)
 Dynamic allocation of PPIMAGE "object".

PPIMAGE IdImaClone (PPIMAGE sim)
 Cloning (by using dynamic allocation) of PPIMAGE "object" IdImaClone is an alias of IdImaAllocLikeImage.

PPIMAGE IdImaAllocLikeImage (void *sim)
 Allocate a new PPIMAGE of same dimensions (width and height) and same type of the incoming argument.


Function Documentation

void*** _IdAllocBloc int  sx,
int  sy,
int  sz,
int  si
 

Definition at line 154 of file imaallo.c.

References IdErrPrintf().

int _IdAllocLinesOfPlane void *  piv,
int  sx,
int  sy,
int  si
 

Definition at line 70 of file imaallo.c.

References _IdFreeLinesOfPlane(), and IdErrPrintf().

Referenced by _IdAllocPlan(), and IdImaAlloc().

void** _IdAllocPlan int  sx,
int  sy,
int  si
 

Definition at line 101 of file imaallo.c.

References _IdAllocLinesOfPlane(), and IdErrPrintf().

void _IdFreeBloc void ***  pi,
int  nbp,
int  nbl
 

Definition at line 175 of file imaallo.c.

References _IdFreePlanesOfBloc().

void _IdFreeLinesOfPlane void **  pi,
int  n
 

Referenced by _IdAllocLinesOfPlane(), _IdFreePlan(), and _IdFreePlanesOfBloc().

void _IdFreePlan void **  pi,
int  n
 

Definition at line 117 of file imaallo.c.

References _IdFreeLinesOfPlane().

void _IdFreePlanesOfBloc void ***  ,
int  ,
int 
 

Definition at line 143 of file imaallo.c.

References _IdFreeLinesOfPlane().

Referenced by _IdFreeBloc().

void _IdImaFree PPIMAGE pi  ) 
 

Free dynamically allocated PPIMAGE "object".

Parameters:
pi Pointer to PPIMAGE to free.

Definition at line 188 of file imaallo.c.

References _IdImaPrivate.

Referenced by IdImaFree().

PPIMAGE IdImaAlloc int  sx,
int  sy,
int  ty
 

Dynamic allocation of PPIMAGE "object".

Warning:
It is the callers responsability to check the pointer returned by IdImaAlloc.
Parameters:
sx Width (horizontal dimension) of the image to be allocated
sy Height (vertical dimension) of the image to be allocated
ty Ido type of the image e.g. IMA_UCHAR, IMA_FLOAT, IMA_RGB...
Returns:
(PPIMAGE)0 on failure. Pointer (casted to PPIMAGE) of newly allocated image on success.

Definition at line 221 of file imaallo.c.

References PRIVATE_IMAGE::_fichier, _IdAllocLinesOfPlane(), PRIVATE_IMAGE::_message, PRIVATE_IMAGE::DimX, PRIVATE_IMAGE::DimY, IDERR_ALLOC_MEM, IDERR_WRONG_TYPE, IdErrno, IdErrPrintf(), IdImaFree, IDO_TYPE, IdSizeOfType, IMA, IMA_BIT, IMA_UCHAR, PPIMAGE, PRIVATE_IMAGE::subObject, PRIVATE_IMAGE::Type, PRIVATE_IMAGE::UsedNbX, and PRIVATE_IMAGE::UsedNbY.

Referenced by _IdImaCreImagetteClear(), DisplayObject2D(), DisplayVol(), GetBrainPhysicalValues(), GetkSpaceImage2DFromExperience(), IdCntFillPolygonXXX(), IdCntSurfacePoly(), IdDcmReadFileIntoVectorFromDcmHdr(), IdImaAllocLikeImage(), IdImaCheckSizeAlloc(), IdImaCheckSizeAllocType(), IdImaCheckTypeAlloc(), IdImaCheckTypeAllocSize(), IdImaCreImagette(), IdImaFill(), IdImaMakeImagetteXYHoriz(), IdImaMakeImagetteXYVertic(), IdImaRecad16To16IgnoreUpper(), IdImaRecad16To8(), IdImaRecad16To8IgnoreUpper(), IdImaRecadTo8ABS(), IdImaRecadTo8DCT(), IdImaRecadTo8LOG(), IdImaScotchImages(), IdImaSignalToImage(), SetObjectFieldDefault2D(), and WriteVolRecUchar().

PPIMAGE IdImaAllocLikeImage void *  sim  ) 
 

Allocate a new PPIMAGE of same dimensions (width and height) and same type of the incoming argument.

Warning:
It is the callers responsability to check the pointer return by IdImaClone.
Parameters:
sim Source IMage to be cloned
Returns:
(PPIMAGE)0 on failure. Pointer (casted to PPIMAGE) of newly allocated image on success.

Definition at line 290 of file imaallo.c.

References IdErrPrintf(), IdImaAlloc(), IdImaDimX(), IdImaDimY(), IdImaType(), and PPIMAGE.

Referenced by IdCntFillExtPolygon(), IdCntFillPolygon(), IdImaCheckTypeSizeAlloc(), IdImaClone(), and IdImaFillContour().

PPIMAGE IdImaClone PPIMAGE  sim  ) 
 

Cloning (by using dynamic allocation) of PPIMAGE "object" IdImaClone is an alias of IdImaAllocLikeImage.

Warning:
It is the callers responsability to check the pointer return by IdImaClone.
Parameters:
sim Source IMage to be cloned
Returns:
(PPIMAGE)0 on failure. Pointer (casted to PPIMAGE) of newly allocated image on success.

Definition at line 275 of file imaallo.c.

References IdImaAllocLikeImage(), and PPIMAGE.


Generated on Wed Oct 19 09:28:36 2005 for SIMRI3D by doxygen 1.3.7