Woolz Image Processing  Version 1.7.0
WlzAllocation

Files

file  WlzAssign.c
 Woolz objects domains and values maintain a linkcount, which records it's usage by other objects, domains or values. To increment a linkcount the appropriate assignment function should be used.
 
file  WlzBuildObj.c
 Functions to allow spatial domain objects with values to be built incrementally.
 
file  WlzConstruct3D.c
 Functions to construct 3D domain objects from 2D domain objects.
 
file  WlzCopy.c
 Functions to make 'deep' copies of objects.
 
file  WlzFreeSpace.c
 Functions for freeing objects and their components.
 
file  WlzMakeCompound.c
 Makes compound objects.
 
file  WlzMakeIntervalValues.c
 Makes an interval values table.
 
file  WlzMakeStructs.c
 Functions for allocating woolz structures.
 
file  WlzTiledValues.c
 Functions construct and convert tiled objects.
 

Functions

WlzObjectWlzAssignObject (WlzObject *obj, WlzErrorNum *dstErr)
 Assign an object (increment it's linkcount) by first checking for NULL, then the value of linkcount, before incrementing the linkcount. If used concientiously, assignment should avoid memory errors. More...
 
WlzDomain WlzAssignDomain (WlzDomain domain, WlzErrorNum *dstErr)
 Assign a domain by incrementing it's linkcount. More...
 
WlzValues WlzAssignValues (WlzValues values, WlzErrorNum *dstErr)
 Assign a values by incrementing it's linkcount. More...
 
WlzProperty WlzAssignProperty (WlzProperty property, WlzErrorNum *dstErr)
 Assign a property by incrementing it's linkcount. More...
 
WlzAffineTransformWlzAssignAffineTransform (WlzAffineTransform *trans, WlzErrorNum *dstErr)
 Assign an affine transform by incrementing it's linkcount. More...
 
WlzTransform WlzAssignTransform (WlzTransform t, WlzErrorNum *dstErr)
 Assign a transform by incrementing it's linkcount. More...
 
WlzThreeDViewStructWlzAssign3DViewStruct (WlzThreeDViewStruct *viewStr, WlzErrorNum *dstErr)
 Assign an woolz 3D view structure by incrementing it's linkcount. More...
 
WlzBoundListWlzAssignBoundList (WlzBoundList *blist, WlzErrorNum *dstErr)
 Assign a boundary list by incrementing it's linkcount. More...
 
WlzPolygonDomainWlzAssignPolygonDomain (WlzPolygonDomain *poly, WlzErrorNum *dstErr)
 Assign a polygon domain by incrementing it's linkcount. More...
 
WlzGMModelWlzAssignGMModel (WlzGMModel *model, WlzErrorNum *dstErr)
 Assign a geometric model by incrementing it's linkcount. More...
 
int WlzUnlink (int *linkcount, WlzErrorNum *dstErr)
 Unlink an object, domain or values by decrementing and testing it's linkcount. More...
 
WlzObjectWlzBuildObj3U (WlzObject *cObj, WlzIVertex3 og, WlzIVertex2 sz, int bufSz, WlzUByte *buf, WlzErrorNum *dstErr)
 Wrapper for WlzBuildObj3() with WlzUByte values. More...
 
WlzObjectWlzBuildObj3S (WlzObject *cObj, WlzIVertex3 og, WlzIVertex2 sz, int bufSz, short *buf, WlzErrorNum *dstErr)
 Wrapper for WlzBuildObj3() with short values. More...
 
WlzObjectWlzBuildObj3I (WlzObject *cObj, WlzIVertex3 og, WlzIVertex2 sz, int bufSz, int *buf, WlzErrorNum *dstErr)
 Wrapper for WlzBuildObj3() with int values. More...
 
WlzObjectWlzBuildObj3F (WlzObject *cObj, WlzIVertex3 og, WlzIVertex2 sz, int bufSz, float *buf, WlzErrorNum *dstErr)
 Wrapper for WlzBuildObj3() with float values. More...
 
WlzObjectWlzBuildObj3D (WlzObject *cObj, WlzIVertex3 og, WlzIVertex2 sz, int bufSz, double *buf, WlzErrorNum *dstErr)
 Wrapper for WlzBuildObj3() with double values. More...
 
WlzObjectWlzBuildObj3R (WlzObject *cObj, WlzIVertex3 og, WlzIVertex2 sz, int bufSz, WlzUInt *buf, WlzErrorNum *dstErr)
 Wrapper for WlzBuildObj3() with RGBA values. More...
 
WlzObjectWlzBuildObj3B (WlzObject *cObj, WlzIVertex3 og, WlzIVertex2 sz, WlzGreyType gType, int bufSz, char *buf, WlzErrorNum *dstErr)
 Wrapper for WlzBuildObj3() with buffer passed as bytes. More...
 
WlzObjectWlzBuildObj3 (WlzObject *cObj, WlzIVertex3 og, WlzIVertex2 sz, WlzGreyType gType, int bufSz, WlzGreyP bufP, WlzErrorNum *dstErr)
 Creates a new or adds to an existing 3D spatial domain object using a rectangular buffer of values to a single plane of the given current object (which may be NULL or empty if the object is to be created). The returned object will share domains and values of planes other than the given plane with the current object. More...
 
WlzObjectWlzConstruct3DObjFromFile (int nFileStr, char **fileStr, int plane1, float xSz, float ySz, float zSz, WlzErrorNum *dstErr)
 Constructs a 3D domain object from 2D domain objects read from the given files. Each file is read in turn and added to the 3D object. An empty plane can be specified by setting the file string to NULL. Either all or none of the 2D objects must have values. When the 2D objects have values then the background value of the first 2D object is set to be the background value of the 3D object. More...
 
WlzObjectWlzConstruct3DObjFromObj (int nObjs, WlzObject **objs, int plane1, float xSz, float ySz, float zSz, WlzErrorNum *dstErr)
 Constructs a 3D domain object from 2D domain objects. Each 2D object is assigned in turn to the 3D object no domains or values are copied. An empty can be specified by setting the 2D object to NULL. Either all or none of the 2D objects must have values. When the 2D objects have values then the background value of the first 2D object is set to be the background value of the 3D object. More...
 
WlzObjectWlzCopyObject (WlzObject *inObj, WlzErrorNum *dstErr)
 Copies a Woolz object together with it's domain, values and properties and then returns the copy. More...
 
WlzDomain WlzCopyDomain (WlzObjectType inObjType, WlzDomain inDom, WlzErrorNum *dstErr)
 Copies the given objects domain. More...
 
WlzValues WlzCopyValues (WlzObjectType inObjType, WlzValues inVal, WlzDomain inDom, WlzErrorNum *dstErr)
 Copies the given values. More...
 
WlzPropertyListWlzCopyPropertyList (WlzPropertyList *gList, WlzErrorNum *dstErr)
 Copies the given property list. More...
 
WlzIndexedValuesWlzCopyIndexedValues (WlzIndexedValues *inV, WlzErrorNum *dstErr)
 Copies the given indexed values. More...
 
WlzErrorNum WlzCopyObjectGreyValues (WlzObject *dObj, WlzObject *sObj)
 Copies the grey values of the source object to the destination object, overwriting the values of the destination object. More...
 
WlzErrorNum WlzFreeObj (WlzObject *obj)
 Free space allocated to a woolz object. More...
 
WlzErrorNum WlzFreeIntervalDomain (WlzIntervalDomain *idom)
 Free an interval domain - convenience link to WlzFreeDomain() More...
 
WlzErrorNum WlzFreeHistogramDomain (WlzHistogramDomain *hist)
 Free a histogram domain. More...
 
WlzErrorNum WlzFreeDomain (WlzDomain domain)
 Free a domain structure of any type. All domain structures must have a type and linkcount. Most also have a freeptr by which, if set, all the space allocated can be freed, however there are some special cases. More...
 
WlzErrorNum WlzFreePlaneDomain (WlzPlaneDomain *planedm)
 Free a planedomain. More...
 
WlzErrorNum WlzFreeValueTb (WlzRagRValues *vdmn)
 Convenience routine to free a ragged rect valuetable. More...
 
WlzErrorNum WlzFreeValues (WlzValues values)
 Free a values structure, currently only WlzRagRValues and WlzRectValues DO NOT call this function with any other values structure types! More...
 
WlzErrorNum WlzFreeVoxelValueTb (WlzVoxelValues *voxtab)
 Free a voxel value table. More...
 
WlzErrorNum WlzFreePolyDmn (WlzPolygonDomain *poly)
 Free a polygon domain. More...
 
WlzErrorNum WlzFreeBoundList (WlzBoundList *b)
 Recursively free a boundary list. More...
 
WlzErrorNum WlzFree3DWarpTrans (Wlz3DWarpTrans *obj)
 Free a 3D warp transform. More...
 
WlzErrorNum WlzFreeContour (WlzContour *ctr)
 Free's a WlzContour data structure. More...
 
WlzErrorNum WlzFreeIndexedValues (WlzIndexedValues *ixv)
 Frees an indexed valuetable. More...
 
WlzErrorNum WlzFreePointValues (WlzPointValues *pv)
 Frees a points valuetable. More...
 
WlzLBTDomain2DWlzMakeLBTDomain2D (WlzObjectType type, int l1, int ll, int k1, int kl, WlzErrorNum *dstErr)
 Creates a linear binary tree domain without creating any nodes, leaving the nodes pointer NULL. Only the type, bounding box and depth are set. The depth \(d\) is set such that

\[ 2^d >= \max(k_l - k_1, l_l - l_1) + 1 \]

where \(k_1\), \(k_l\), \(l_1\) and \(l_l\) are the first column, last column, first line and last line respectively. More...

 
WlzLBTDomain3DWlzMakeLBTDomain3D (WlzObjectType type, int p1, int pl, int l1, int ll, int k1, int kl, WlzErrorNum *dstErr)
 Creates a linear binary tree domain without creating any nodes, leaving the nodes pointer NULL. Only the type, bounding box and depth are set. The depth \(d\) is set such that

\[ 2^d >= \max(p_l - p_1, k_l - k_1, l_l - l_1) + 1 \]

where \(k_1\), \(k_l\), \(l_1\) and \(l_l\) are the first column, last column, first line and last line respectively. More...

 
WlzErrorNum WlzFreeLBTDomain3D (WlzLBTDomain3D *lDom)
 Frees the given 3D linear binary tree domain. More...
 
WlzErrorNum WlzFreeLBTDomain2D (WlzLBTDomain2D *lDom)
 Frees the given 2D linear binary tree domain. More...
 
WlzCompoundArrayWlzMakeCompoundArray (WlzObjectType type, int mode, int n, WlzObject **ol, WlzObjectType otype, WlzErrorNum *dstErr)
 Makes a new Woolz compound array object. More...
 
WlzIntervalValuesWlzMakeIntervalValues (WlzObjectType type, WlzObject *obj, WlzPixelV bckgrnd, WlzErrorNum *dstErr)
 Make in interval values table to match the input object The table will have linkcount set to zero. More...
 
WlzIntervalDomainWlzMakeIntervalDomain (WlzObjectType type, int l1, int ll, int k1, int kl, WlzErrorNum *dstErr)
 Allocate space for an interval domain structure. If the type is WLZ_INTERVALDOMAIN_INTVL then allocate space for the interval line array and set the pointer. More...
 
WlzPlaneDomainWlzMakePlaneDomain (WlzObjectType type, int p1, int pl, int l1, int ll, int k1, int kl, WlzErrorNum *dstErr)
 Allocate space for a plane domain and the domain pointers. More...
 
WlzObjectWlzNewObjectValues (WlzObject *sObj, WlzObjectType tType, WlzPixelV bgdV, int setFG, WlzPixelV fgdV, WlzErrorNum *dstErr)
 Creaes a new object with the domain of the given object and a new values. More...
 
WlzVoxelValuesWlzNewValuesVox (WlzObject *sObj, WlzObjectType gTType, WlzPixelV bgdV, WlzErrorNum *dstErr)
 From the domain of the given source object a new voxel value table is created with the given grey type and background value. More...
 
WlzObjectWlzMakeMain (WlzObjectType type, WlzDomain domain, WlzValues values, WlzPropertyList *plist, WlzObject *assoc, WlzErrorNum *dstErr)
 Make a top-level woolz object assigning domain, values and other pointers as required . The type is checked. The domain is not checked for NULL although this should only apply to the WLZ_EMPTY_OBJ. More...
 
WlzRagRValuesWlzMakeValueTb (WlzObjectType type, int l1, int ll, int k1, WlzPixelV backgrnd, WlzObject *orig, WlzErrorNum *dstErr)
 Allocate and initialise space for a ragged-rectangle value table only. More...
 
WlzVoxelValuesWlzMakeVoxelValueTb (WlzObjectType type, int p1, int pl, WlzPixelV backgrnd, WlzObject *orig, WlzErrorNum *dstErr)
 Allocate space for a voxel table. More...
 
WlzRectValuesWlzMakeRectValueTb (WlzObjectType type, int line1, int lastln, int kol1, int width, WlzPixelV backgrnd, int *values, WlzErrorNum *dstErr)
 Make rectangular value table attaching values if set. Note the values pointer is just copied and will not be freed when the object is freed unless the freeptr is set using AlcFreePointerPush(). More...
 
WlzErrorNum WlzMakeInterval (int line, WlzIntervalDomain *idom, int nints, WlzInterval *intptr)
 Attach and interval pointer to a an interval domain in the appropriate place and set the number of intervals on the line. Note this procedure makes no checks on the arguments because it is often used in deeply nested loops. More...
 
WlzErrorNum WlzMakeValueLine (WlzRagRValues *vtb, int line, int k1, int kl, int *greyptr)
 Attach the grey values for a valueline within a ragged- rectangle value table. Not this procedure does not check the input arguments because it is often at the core of nested loops. More...
 
WlzPointValuesWlzNewPointValues (WlzObject *obj, int rank, int *dim, WlzGreyType vType, WlzErrorNum *dstErr)
 Makes a new point value table which covers the points of the given object. More...
 
WlzPointValuesWlzMakePointValues (size_t nP, int rank, int *dim, WlzGreyType vType, WlzErrorNum *dstErr)
 Makes a new point value table with space for the requested number of points. More...
 
WlzPolygonDomainWlzMakePolygonDomain (WlzObjectType type, int n, WlzIVertex2 *vertices, int maxv, int copy, WlzErrorNum *dstErr)
 Make a polygon domain, allocating space and copying as required: More...
 
WlzBoundListWlzMakeBoundList (WlzObjectType type, int wrap, WlzPolygonDomain *poly, WlzErrorNum *dstErr)
 Allocate space and initialise a boundlist structure. More...
 
WlzIVertex2WlzMakeIVertex (int nverts, WlzErrorNum *dstErr)
 Make an integer vertex array. More...
 
WlzObjectWlzMakeRect (int line1, int lastln, int kol1, int lastkl, WlzGreyType pixeltype, int *grey_values, WlzPixelV backgrnd, WlzPropertyList *plist, WlzObject *assoc_obj, WlzErrorNum *dstErr)
 Make a top-level rectangular object, setting values if non-NULL, uses WlzMakeRectValueTb() to assign values which by default will not be freed when the object is freed. The freeptr needs to be explicitly set by the calling procedure. This is a convenience procedure calling WlzMakeIntervalDomain() then WlzMakeRectValueTb() then WlzMakeMain(). More...
 
WlzObjectWlzNewObjectValueTable (WlzObject *gObj, WlzPixelV bgdV, WlzErrorNum *dstErr)
 Creates a new Woolz object using the given object's domain and a new value table, but uses the grey values of the given object's value table. More...
 
WlzObjectWlzMakeCuboid (int plane1, int lastpl, int line1, int lastln, int kol1, int lastkl, WlzGreyType pixType, WlzPixelV bgdV, WlzPropertyList *plist, WlzObject *assocObj, WlzErrorNum *dstErr)
 Creates a 3D domain object with values, for which the domain is a cuboid and the values are of the given type and initialized to have value zero. More...
 
WlzHistogramDomainWlzMakeHistogramDomain (WlzObjectType type, int maxBins, WlzErrorNum *dstErr)
 Allocates space for a histogram domain with the space for the given maximum number of bins of the appropriate type. More...
 
WlzObjectWlzMakeEmpty (WlzErrorNum *dstErr)
 Convenience procedure to make a top-level empty object. More...
 
WlzObjectWlzMakeHistogram (WlzObjectType type, int maxBins, WlzErrorNum *dstErr)
 Convenience procedure to make a top-level object with a histogram domain. More...
 
WlzObjectWlzNewGrey (WlzObject *iobj, WlzErrorNum *dstErr)
 Make a top-level object with the same domain as iobj (pointer copied and linkcount incremented) and new valuetable with values copied from iobj. If iobj has no valuetable then the returned object will have no value- table. This allows a copy of a 2D grey-value object. More...
 
WlzRagRValuesWlzNewValueTb (WlzObject *obj, WlzObjectType type, WlzPixelV backgrnd, WlzErrorNum *dstErr)
 Create a value table of required type with the same size and shape as the domain of obj. This must be of type WLZ_2D_DOMAINOBJ. More...
 
WlzIntervalDomainWlzNewIDomain (WlzObjectType outDomType, WlzIntervalDomain *inDom, WlzErrorNum *dstErr)
 Make a copy of an intervaldomain. More...
 
WlzContourWlzMakeContour (WlzErrorNum *dstErr)
 Makes a new contour data structure. More...
 
WlzIndexedValuesWlzMakeIndexedValues (WlzObject *obj, int rank, int *dim, WlzGreyType vType, WlzValueAttach attach, WlzErrorNum *dstErr)
 Makes a new indexed value table. More...
 
WlzErrorNum WlzExtendIndexedValues (WlzIndexedValues *ixv, size_t n)
 Extends the given indexed value table. This is just a wrapper for AlcVectorExtend(). More...
 
WlzTiledValuesWlzMakeTiledValues (int dim, int vRank, WlzErrorNum *dstErr)
 Allocates a new tiled value table, but without allocating any indices or tiles. More...
 
WlzErrorNum WlzFreeTiledValues (WlzTiledValues *tVal)
 Frees a tiled value table. More...
 
WlzTiledValuesWlzNewTiledValues (WlzTiledValues *gVal, WlzPixelV bgdV, WlzErrorNum *dstErr)
 Creates a new tiled values table which shares both the grey value tiles and indexing with the given tiled values. This is done by using the original_table field. More...
 
WlzObjectWlzMakeTiledValuesFromObj (WlzObject *gObj, size_t tileSz, int copyValues, WlzGreyType gType, unsigned int vRank, unsigned int *vDim, WlzPixelV bgdV, WlzErrorNum *dstErr)
 Creates a tiled object from the given object. More...
 
WlzErrorNum WlzMakeTiledValuesTiles (WlzTiledValues *tVal)
 Allocates tiles without a memory mapped file for the tiles values and sets background value within the tiles. More...
 
WlzTiledValueBufferWlzMakeTiledValueBuffer (WlzTiledValues *tVal, WlzErrorNum *dstErr)
 Makes a new tiled values buffer for the given tiled values table. More...
 
void WlzFreeTiledValueBuffer (WlzTiledValueBuffer *tBuf)
 Frees the given tiled values buffer including it's line buffer. More...
 
WlzObjectWlzMakeTiledValuesObj2D (WlzObject *gObj, size_t tileSz, int setTiles, WlzGreyType gType, unsigned int vRank, unsigned int *vDim, WlzPixelV bgdV, WlzErrorNum *dstErr)
 Creates a 2D domain object which has the same domain as the given 2D domain object but a tiled value table. More...
 
WlzObjectWlzMakeTiledValuesObj3D (WlzObject *gObj, size_t tileSz, int setTiles, WlzGreyType gType, unsigned int vRank, unsigned int *vDim, WlzPixelV bgdV, WlzErrorNum *dstErr)
 Creates a 3D domain object which has the same domain as the given 3D domain object but a tiled value table. More...
 

Detailed Description

Function Documentation

WlzObject* WlzAssignObject ( WlzObject obj,
WlzErrorNum dstErr 
)

Assign an object (increment it's linkcount) by first checking for NULL, then the value of linkcount, before incrementing the linkcount. If used concientiously, assignment should avoid memory errors.

Returns
Given object with incremented linkcount or NULL on error.
Parameters
objGiven object.
dstErrDestination error pointer, may be NULL.

References _WlzObject::linkcount, WLZ_ERR_LINKCOUNT_DATA, WLZ_ERR_NONE, and WLZ_ERR_OBJECT_NULL.

Referenced by main(), Wlz3DSectionOcc(), Wlz3DSectionSegmentObject(), Wlz3DViewTransformBitmap(), WlzBoundaryDomain(), WlzBoundaryToPolyObjArray(), WlzCannyDeriche(), WlzCMeshDispToField(), WlzCMeshFromObj2D(), WlzCMeshFromObj3D(), WlzCMeshIntersectDom2D5(), WlzCMeshStrainTensorAtPts(), WlzCMeshTransformManyObjAsIdx(), WlzConComThreshold(), WlzContourGrdObj2D(), WlzCopyValues(), WlzDGTensorFeatures(), WlzDilation(), WlzDistanceTransform(), WlzDomainFill3D(), WlzDomainNearby(), WlzDrawDomainObj(), WlzEffReadObjAm(), WlzEffReadObjAnl(), WlzEffReadObjNifti(), WlzEffReadObjTiff(), WlzEffWriteObjAm(), WlzEffWriteObjNifti(), WlzEffWriteObjStack(), WlzErosion(), WlzGauss2(), WlzGetMaskedSectionFromObject(), WlzGetPatchTree(), WlzGetProjectionFromObject(), WlzGreyIncValuesInDomain(), WlzGreyMask(), WlzGreyModGradient(), WlzGreySetValue(), WlzGreyTemplate(), WlzImageArithmetic(), WlzImageBlendObjToBufRGBA(), WlzIndexObjFromCompound(), WlzIndexObjToCompound(), WlzInit3DViewStruct(), WlzInteriority(), WlzInteriorityN(), WlzLabel(), WlzLabel3D(), WlzLaplacian(), WlzLBTTestOutputNodesVtk(), WlzMakeCompoundArray(), WlzMakeMain(), WlzMakePatchTree(), WlzMakeTiledValuesObj2D(), WlzMakeTiledValuesObj3D(), WlzMeshFromObjBox(), WlzNMSuppress(), WlzObjToConvexHull(), WlzOffsetDist(), WlzPatchTreeToObject(), WlzPointsFromDomObj(), WlzPolyToObj(), WlzProj3DToSection(), WlzProjectObjToPlane(), WlzRankFilter(), WlzRasterLineSetItv2D(), WlzReadObj(), WlzRegCCorObjs(), WlzRegConCalcRCC(), WlzRegisterPatchTreeBF(), WlzRGBAMultiThreshold(), WlzRGBAToCompound(), WlzRGBChanRatio(), WlzRsvFilterBuffer(), WlzScalarFeatures2D(), WlzSepFilter(), WlzSepTrans(), WlzSobel(), WlzSplitObj(), WlzStructDilation(), WlzStructErosion(), WlzThinToPoints(), WlzThreshold(), WlzValuesFromCoords(), WlzVerticesBuildTree(), and WlzXORDom().

WlzValues WlzAssignValues ( WlzValues  values,
WlzErrorNum dstErr 
)

Assign a values by incrementing it's linkcount.

Returns
Given values with incremented linkcount or NULL on error.
Parameters
valuesGiven values.
dstErrDestination error pointer, may be NULL.

References _WlzValues::core, _WlzCoreValues::linkcount, WLZ_ERR_LINKCOUNT_DATA, WLZ_ERR_NONE, and WLZ_ERR_VALUES_NULL.

Referenced by Wlz3DViewTransformObj(), WlzAffineTransformGMShell(), WlzBasisFnInvertMakeCMeshTr2D(), WlzBasisFnInvertMakeCMeshTr3D(), WlzBasisFnMakeCMeshTr2D(), WlzBasisFnMakeCMeshTr3D(), WlzBuildObj3(), WlzCbThreshold(), WlzClassValCon4(), WlzClipObjToBox3D(), WlzCMeshCompSurfMap(), WlzCMeshProduct(), WlzCMeshTransformFromObj(), WlzCMeshTransformInvert(), WlzCMeshTransformManyObjAsIdx(), WlzCMeshTransformObj(), WlzCompoundToRGBA(), WlzConstruct3DObjFromFile(), WlzConstruct3DObjFromObj(), WlzConvertPix(), WlzCopyScaleCMeshValue(), WlzCopyValues(), WlzCutObjToValBox3D(), WlzDiffDomain3d(), WlzDistanceTransform(), WlzDomainFill3D(), WlzEffReadObjTiff(), WlzFillBlankPlanes(), WlzFromArray1D(), WlzFromArray3D(), WlzGetMaskedSectionFromObject(), WlzGetProjectionFromObject(), WlzGetSubSectionFromObject(), WlzGreyMask(), WlzGreyMeanDifference(), WlzGreyTemplate(), WlzGreyTransfer(), WlzIndexToRGBA(), WlzIntersect3d(), WlzIntersectN(), WlzIntRescaleObj(), WlzLabel3D(), WlzLBTMakeNodeIndexObj2D(), WlzLBTMakeNodeIndexObj3D(), WlzMakeCuboid(), WlzMakeMain(), WlzNewObjectValueTable(), WlzNewTiledValues(), WlzNewValuesVox(), WlzReadMeshTransform3D(), WlzReadObj(), WlzRGBAToCompound(), WlzRGBAToModulus(), WlzRGBChanRatio(), WlzRsvFilterBuffer(), WlzScalarBinaryOp2(), WlzScalarFn(), WlzScalarMulAdd(), WlzShiftValues(), WlzThreshold(), WlzTransposeObj(), WlzUnion3d(), WlzUnionN(), and WlzValuesFromCoords().

WlzProperty WlzAssignProperty ( WlzProperty  property,
WlzErrorNum dstErr 
)

Assign a property by incrementing it's linkcount.

Returns
Given property with incremented linkcount or the core property set to NULL on error.
Parameters
propertyGiven property.
dstErrDestination error pointer, may be NULL.

References _WlzProperty::core, _WlzCoreProperty::linkcount, WLZ_ERR_LINKCOUNT_DATA, WLZ_ERR_NONE, and WLZ_ERR_PROPERTY_NULL.

Referenced by WlzCopyPropertyList(), and WlzReadObj().

WlzAffineTransform* WlzAssignAffineTransform ( WlzAffineTransform trans,
WlzErrorNum dstErr 
)

Assign an affine transform by incrementing it's linkcount.

Returns
Given affine transform with incremented linkcount or NULL on error.
Parameters
transGiven affine transform.
dstErrDestination error pointer, may be NULL.

References _WlzAffineTransform::linkcount, WLZ_ERR_LINKCOUNT_DATA, WLZ_ERR_NONE, and WLZ_ERR_OBJECT_NULL.

Referenced by WlzMake3DViewStruct(), WlzMake3DViewStructCopy(), WlzMatchICPCtr(), WlzMatchICPWeightMatches(), and WlzRegICPVerticesWSD2D().

WlzTransform WlzAssignTransform ( WlzTransform  t,
WlzErrorNum dstErr 
)

Assign a transform by incrementing it's linkcount.

Returns
Given transform with incremented linkcount or NULL on error.
Parameters
tGiven transform.
dstErrDestination error pointer, may be NULL.

References _WlzTransform::core, _WlzCoreTransform::linkcount, WLZ_ERR_LINKCOUNT_DATA, and WLZ_ERR_NONE.

WlzThreeDViewStruct* WlzAssign3DViewStruct ( WlzThreeDViewStruct viewStr,
WlzErrorNum dstErr 
)

Assign an woolz 3D view structure by incrementing it's linkcount.

Returns
Given 3D view structure with incremented linkcount or NULL on error.
Parameters
viewStrGiven 3D view structure.
dstErrDestination error pointer, may be NULL.

References _WlzThreeDViewStruct::linkcount, WLZ_ERR_LINKCOUNT_DATA, WLZ_ERR_NONE, and WLZ_ERR_OBJECT_NULL.

WlzBoundList* WlzAssignBoundList ( WlzBoundList blist,
WlzErrorNum dstErr 
)

Assign a boundary list by incrementing it's linkcount.

Returns
Given boundary list with incremented linkcount or NULL on error.
Parameters
blistGiven boundary list.
dstErrDestination error pointer, may be NULL.

References _WlzBoundList::linkcount, WLZ_ERR_LINKCOUNT_DATA, WLZ_ERR_NONE, and WLZ_ERR_OBJECT_NULL.

Referenced by WlzBoundDecimate(), WlzBoundSmooth(), WlzConvertBoundType(), WlzReadObj(), and WlzTransposeObj().

WlzPolygonDomain* WlzAssignPolygonDomain ( WlzPolygonDomain poly,
WlzErrorNum dstErr 
)

Assign a polygon domain by incrementing it's linkcount.

Returns
Given polygon domain with incremented linkcount or NULL on error.
Parameters
polyGiven boundary list.
dstErrDestination error pointer, may be NULL.

References _WlzPolygonDomain::linkcount, WLZ_ERR_LINKCOUNT_DATA, WLZ_ERR_NONE, and WLZ_ERR_OBJECT_NULL.

Referenced by WlzBoundDecimate(), WlzBoundSmooth(), WlzBoundVtxCount(), WlzCMeshTransformManyObjAsIdx(), WlzConvertBoundType(), WlzMakeBoundList(), WlzMeshTransformVerify(), WlzObjToBoundary(), and WlzReadObj().

WlzGMModel* WlzAssignGMModel ( WlzGMModel model,
WlzErrorNum dstErr 
)
int WlzUnlink ( int *  linkcount,
WlzErrorNum dstErr 
)
WlzObject* WlzBuildObj3U ( WlzObject cObj,
WlzIVertex3  og,
WlzIVertex2  sz,
int  bufSz,
WlzUByte buf,
WlzErrorNum dstErr 
)

Wrapper for WlzBuildObj3() with WlzUByte values.

Returns
New Woolz object.
Parameters
cObjGiven current object.
ogOrigin of rectangular buffer.
szBuffer size (note 2D).
bufSzNumber of values in the buffer (ie sz.vtX * sz.vtY).
bufGiven buffer of values.
dstErrDestination error pointer, may be NULL.

References _WlzGreyP::ubp, WLZ_GREY_UBYTE, and WlzBuildObj3().

WlzObject* WlzBuildObj3S ( WlzObject cObj,
WlzIVertex3  og,
WlzIVertex2  sz,
int  bufSz,
short *  buf,
WlzErrorNum dstErr 
)

Wrapper for WlzBuildObj3() with short values.

Returns
New Woolz object.
Parameters
cObjGiven current object.
ogOrigin of rectangular buffer.
szBuffer size (note 2D).
bufSzNumber of values in the buffer (ie sz.vtX * sz.vtY).
bufGiven buffer of values.
dstErrDestination error pointer, may be NULL.

References _WlzGreyP::shp, WLZ_GREY_SHORT, and WlzBuildObj3().

WlzObject* WlzBuildObj3I ( WlzObject cObj,
WlzIVertex3  og,
WlzIVertex2  sz,
int  bufSz,
int *  buf,
WlzErrorNum dstErr 
)

Wrapper for WlzBuildObj3() with int values.

Returns
New Woolz object.
Parameters
cObjGiven current object.
ogOrigin of rectangular buffer.
szBuffer size (note 2D).
bufSzNumber of values in the buffer (ie sz.vtX * sz.vtY).
bufGiven buffer of values.
dstErrDestination error pointer, may be NULL.

References _WlzGreyP::inp, WLZ_GREY_INT, and WlzBuildObj3().

WlzObject* WlzBuildObj3F ( WlzObject cObj,
WlzIVertex3  og,
WlzIVertex2  sz,
int  bufSz,
float *  buf,
WlzErrorNum dstErr 
)

Wrapper for WlzBuildObj3() with float values.

Returns
New Woolz object.
Parameters
cObjGiven current object.
ogOrigin of rectangular buffer.
szBuffer size (note 2D).
bufSzNumber of values in the buffer (ie sz.vtX * sz.vtY).
bufGiven buffer of values.
dstErrDestination error pointer, may be NULL.

References _WlzGreyP::flp, WLZ_GREY_FLOAT, and WlzBuildObj3().

WlzObject* WlzBuildObj3D ( WlzObject cObj,
WlzIVertex3  og,
WlzIVertex2  sz,
int  bufSz,
double *  buf,
WlzErrorNum dstErr 
)

Wrapper for WlzBuildObj3() with double values.

Returns
New Woolz object.
Parameters
cObjGiven current object.
ogOrigin of rectangular buffer.
szBuffer size (note 2D).
bufSzNumber of values in the buffer (ie sz.vtX * sz.vtY).
bufGiven buffer of values.
dstErrDestination error pointer, may be NULL.

References _WlzGreyP::dbp, WLZ_GREY_DOUBLE, and WlzBuildObj3().

WlzObject* WlzBuildObj3R ( WlzObject cObj,
WlzIVertex3  og,
WlzIVertex2  sz,
int  bufSz,
WlzUInt buf,
WlzErrorNum dstErr 
)

Wrapper for WlzBuildObj3() with RGBA values.

Returns
New Woolz object.
Parameters
cObjGiven current object.
ogOrigin of rectangular buffer.
szBuffer size (note 2D).
bufSzNumber of values in the buffer (ie sz.vtX * sz.vtY).
bufGiven buffer of values.
dstErrDestination error pointer, may be NULL.

References _WlzGreyP::rgbp, WLZ_GREY_RGBA, and WlzBuildObj3().

WlzObject* WlzBuildObj3B ( WlzObject cObj,
WlzIVertex3  og,
WlzIVertex2  sz,
WlzGreyType  gType,
int  bufSz,
char *  buf,
WlzErrorNum dstErr 
)

Wrapper for WlzBuildObj3() with buffer passed as bytes.

Returns
New Woolz object.
Parameters
cObjGiven current object.
ogOrigin of rectangular buffer.
szBuffer size (note 2D).
gTypeThe grey type.
bufSzNumber of values in the buffer (ie sz.vtX * sz.vtY * sizeof(<gType>))).
bufGiven buffer of values.
dstErrDestination error pointer, may be NULL.

References _WlzGreyP::ubp, WLZ_ERR_GREY_TYPE, WLZ_ERR_NONE, WlzBuildObj3(), and WlzGreySize().

WlzObject* WlzBuildObj3 ( WlzObject cObj,
WlzIVertex3  og,
WlzIVertex2  sz,
WlzGreyType  gType,
int  bufSz,
WlzGreyP  bufP,
WlzErrorNum dstErr 
)

Creates a new or adds to an existing 3D spatial domain object using a rectangular buffer of values to a single plane of the given current object (which may be NULL or empty if the object is to be created). The returned object will share domains and values of planes other than the given plane with the current object.

Returns
New Woolz object.
Parameters
cObjGiven current object.
ogOrigin of rectangular buffer.
szBuffer size (note 2D).
gTypeGrey type which must be consistent with the current object (if it is valid) and the buffer of values.
bufSzNumber of values in the buffer (ie sz.vtX * sz.vtY).
bufPGiven buffer of values.
dstErrDestination error pointer, may be NULL.

References ALG_MAX, ALG_MIN, _WlzValues::core, _WlzDomain::core, _WlzObject::domain, _WlzPlaneDomain::domains, _WlzDomain::i, _WlzGreyP::inp, _WlzGreyV::inv, _WlzIntervalDomain::kol1, _WlzPlaneDomain::kol1, _WlzPlaneDomain::lastkl, _WlzIntervalDomain::lastln, _WlzPlaneDomain::lastln, _WlzPlaneDomain::lastpl, _WlzIntervalDomain::line1, _WlzPlaneDomain::line1, _WlzDomain::p, _WlzPlaneDomain::plane1, _WlzValues::r, _WlzPixelV::type, _WlzObject::type, _WlzPixelV::v, _WlzValues::v, _WlzObject::values, _WlzVoxelValues::values, _WlzValues::vox, _WlzPlaneDomain::voxel_size, _WlzIVertex2::vtX, _WlzIVertex3::vtX, _WlzIVertex2::vtY, _WlzIVertex3::vtY, _WlzIVertex3::vtZ, WLZ_2D_DOMAINOBJ, WLZ_3D_DOMAINOBJ, WLZ_EMPTY_OBJ, WLZ_ERR_DOMAIN_NULL, WLZ_ERR_GREY_TYPE, WLZ_ERR_NONE, WLZ_ERR_OBJECT_TYPE, WLZ_ERR_VALUES_NULL, WLZ_GREY_ERROR, WLZ_GREY_INT, WLZ_GREY_TAB_RAGR, WLZ_GREY_TAB_RECT, WLZ_INTERVALDOMAIN_RECT, WLZ_PLANEDOMAIN_DOMAIN, WLZ_VOXELVALUETABLE_GREY, WlzAssignDomain(), WlzAssignValues(), WlzCopyObject(), WlzFreeObj(), WlzGetBackground(), WlzGreyTransfer(), WlzGreyTypeFromObj(), WlzGreyValueTableType(), WlzMakeIntervalDomain(), WlzMakeMain(), WlzMakePlaneDomain(), WlzMakeRectValueTb(), WlzMakeVoxelValueTb(), WlzNewValueTb(), WlzUnion2(), _WlzIBox3::xMax, _WlzIBox3::xMin, _WlzIBox3::yMax, _WlzIBox3::yMin, _WlzIBox3::zMax, and _WlzIBox3::zMin.

Referenced by WlzBuildObj3B(), WlzBuildObj3D(), WlzBuildObj3F(), WlzBuildObj3I(), WlzBuildObj3R(), WlzBuildObj3S(), and WlzBuildObj3U().

WlzObject* WlzConstruct3DObjFromFile ( int  nFileStr,
char **  fileStr,
int  plane1,
float  xSz,
float  ySz,
float  zSz,
WlzErrorNum dstErr 
)

Constructs a 3D domain object from 2D domain objects read from the given files. Each file is read in turn and added to the 3D object. An empty plane can be specified by setting the file string to NULL. Either all or none of the 2D objects must have values. When the 2D objects have values then the background value of the first 2D object is set to be the background value of the 3D object.

Returns
New 3D object.
Parameters
nFileStrNumber of file strings.
fileStrFile strings.
plane1The plane coordinate of the first 2D object.
xSzColumn voxel size.
ySzLine voxel size.
zSzPlane voxel size.
dstErrDestination error pointer, may be NULL.

References _WlzValues::core, _WlzDomain::core, _WlzObject::domain, _WlzPlaneDomain::domains, _WlzDomain::p, _WlzObject::type, _WlzObject::values, _WlzVoxelValues::values, _WlzValues::vox, _WlzPlaneDomain::voxel_size, WLZ_2D_DOMAINOBJ, WLZ_3D_DOMAINOBJ, WLZ_EMPTY_OBJ, WLZ_ERR_DOMAIN_NULL, WLZ_ERR_NONE, WLZ_ERR_OBJECT_TYPE, WLZ_ERR_PARAM_NULL, WLZ_ERR_READ_EOF, WLZ_ERR_VALUES_NULL, WLZ_PLANEDOMAIN_DOMAIN, WLZ_VOXELVALUETABLE_GREY, WlzAssignDomain(), WlzAssignValues(), WlzFreeDomain(), WlzFreeObj(), WlzFreeValues(), WlzGetBackground(), WlzMakeMain(), WlzMakePlaneDomain(), WlzMakeVoxelValueTb(), WlzReadObj(), and WlzStandardPlaneDomain().

WlzObject* WlzConstruct3DObjFromObj ( int  nObjs,
WlzObject **  objs,
int  plane1,
float  xSz,
float  ySz,
float  zSz,
WlzErrorNum dstErr 
)

Constructs a 3D domain object from 2D domain objects. Each 2D object is assigned in turn to the 3D object no domains or values are copied. An empty can be specified by setting the 2D object to NULL. Either all or none of the 2D objects must have values. When the 2D objects have values then the background value of the first 2D object is set to be the background value of the 3D object.

Returns
New 3D object.
Parameters
nObjsNumber of objects.
objsThe 2D objects, the first of which MUST not be NULL.
plane1The plane coordinate of the first 2D object.
xSzColumn voxel size.
ySzLine voxel size.
zSzPlane voxel size.
dstErrDestination error pointer, may be NULL.

References _WlzValues::core, _WlzDomain::core, _WlzObject::domain, _WlzPlaneDomain::domains, _WlzDomain::p, _WlzObject::type, _WlzObject::values, _WlzVoxelValues::values, _WlzValues::vox, _WlzPlaneDomain::voxel_size, WLZ_2D_DOMAINOBJ, WLZ_3D_DOMAINOBJ, WLZ_EMPTY_OBJ, WLZ_ERR_DOMAIN_NULL, WLZ_ERR_NONE, WLZ_ERR_OBJECT_NULL, WLZ_ERR_OBJECT_TYPE, WLZ_ERR_PARAM_NULL, WLZ_ERR_VALUES_NULL, WLZ_PLANEDOMAIN_DOMAIN, WLZ_VOXELVALUETABLE_GREY, WlzAssignDomain(), WlzAssignValues(), WlzFreeDomain(), WlzFreeValues(), WlzGetBackground(), WlzMakeMain(), WlzMakePlaneDomain(), WlzMakeVoxelValueTb(), and WlzStandardPlaneDomain().

WlzObject* WlzCopyObject ( WlzObject inObj,
WlzErrorNum dstErr 
)

Copies a Woolz object together with it's domain, values and properties and then returns the copy.

Returns
Copy of given object.
Parameters
inObjThe given object.
dstErrDestination error pointer, may be NULL.

References AlcVectorFree(), _WlzIndexedValues::attach, _WlzDomain::cm2, _WlzValues::core, _WlzDomain::core, _WlzIndexedValues::dim, _WlzObject::domain, _WlzCMeshP::m2, _WlzObject::plist, _WlzIndexedValues::rank, _WlzObject::type, _WlzCoreValues::type, _WlzObject::values, _WlzIndexedValues::values, _WlzIndexedValues::vType, WLZ_2D_DOMAINOBJ, WLZ_2D_POLYGON, WLZ_3D_DOMAINOBJ, WLZ_3D_POLYGON, WLZ_3D_VIEW_STRUCT, WLZ_3D_WARP_TRANS, WLZ_AFFINE_TRANS, WLZ_BOUNDLIST, WLZ_CMESH_2D, WLZ_CMESH_2D5, WLZ_CMESH_3D, WLZ_COMPOUND_ARR_1, WLZ_COMPOUND_ARR_2, WLZ_COMPOUND_LIST_1, WLZ_COMPOUND_LIST_2, WLZ_CONTOUR, WLZ_CONV_HULL, WLZ_CONVOLVE_FLOAT, WLZ_CONVOLVE_INT, WLZ_EMPTY_OBJ, WLZ_ERR_NONE, WLZ_ERR_OBJECT_NULL, WLZ_ERR_OBJECT_TYPE, WLZ_ERR_VALUES_TYPE, WLZ_FMATCHOBJ, WLZ_HISTOGRAM, WLZ_INDEXED_VALUES, WLZ_LUT, WLZ_PROPERTY_OBJ, WLZ_RECTANGLE, WLZ_TEXT, WLZ_TRANS_OBJ, WLZ_WARP_TRANS, WlzCMeshCopy(), WlzCopyDomain(), WlzCopyPropertyList(), WlzCopyValues(), WlzFreeDomain(), WlzFreePropertyList(), WlzFreeValues(), WlzIndexedValueSize(), WlzMakeEmpty(), WlzMakeIndexedValues(), WlzMakeMain(), and _WlzValues::x.

Referenced by Wlz2DContains(), WlzBuildObj3(), WlzCompThreshold(), WlzCopyValues(), WlzDrawDomainObj(), WlzGreyScale(), WlzGreyShift(), WlzGreyTransfer(), WlzGreyValueMixing_s(), WlzHistogramFindPeaks(), WlzHistogramFitPeaks(), WlzRegCCorObjs(), WlzRsvFilterBuffer(), and WlzTransformProduct().

WlzDomain WlzCopyDomain ( WlzObjectType  inObjType,
WlzDomain  inDom,
WlzErrorNum dstErr 
)

Copies the given objects domain.

Returns
Copied domain, NULL on error.
Parameters
inObjTypeType of given domain's parent object.
inDomDomain to be copied.
dstErrDestination error pointer, may be NULL.

References _WlzDomain::b, _WlzLUTDomain::bin1, _WlzHistogramDomain::binSize, _WlzHistogramDomain::binValues, _WlzDomain::cm2, _WlzDomain::cm2d5, _WlzDomain::cm3, _WlzDomain::core, _WlzDomain::ctr, _WlzDomain::cvh2, _WlzDomain::cvh3, _WlzPlaneDomain::domains, _WlzBoundList::down, _WlzDomain::hist, _WlzDomain::i, _WlzPlaneDomain::kol1, _WlzLUTDomain::lastbin, _WlzPlaneDomain::lastkl, _WlzPlaneDomain::lastln, _WlzPlaneDomain::lastpl, _WlzPlaneDomain::line1, _WlzDomain::lut, _WlzHistogramDomain::maxBins, _WlzPolygonDomain::maxvertices, _WlzContour::model, _WlzHistogramDomain::nBins, _WlzBoundList::next, _WlzPolygonDomain::nvertices, _WlzHistogramDomain::origin, _WlzDomain::p, _WlzPlaneDomain::plane1, _WlzDomain::poly, _WlzBoundList::poly, _WlzDomain::t, _WlzCoreDomain::type, _WlzIntervalDomain::type, _WlzPlaneDomain::type, _WlzPolygonDomain::type, _WlzBoundList::type, _WlzHistogramDomain::type, _WlzPlaneDomain::voxel_size, _WlzDomain::vs3d, _WlzPolygonDomain::vtx, _WlzConvHullDomain2::vtxType, _WlzConvHullDomain3::vtxType, WLZ_2D_DOMAINOBJ, WLZ_2D_POLYGON, WLZ_3D_DOMAINOBJ, WLZ_3D_POLYGON, WLZ_3D_VIEW_STRUCT, WLZ_3D_WARP_TRANS, WLZ_AFFINE_TRANS, WLZ_BOUNDLIST, WLZ_CMESH_2D, WLZ_CMESH_2D5, WLZ_CMESH_3D, WLZ_COMPOUND_ARR_1, WLZ_COMPOUND_ARR_2, WLZ_COMPOUND_LIST_1, WLZ_COMPOUND_LIST_2, WLZ_CONTOUR, WLZ_CONV_HULL, WLZ_CONVHULL_DOMAIN_2D, WLZ_CONVHULL_DOMAIN_3D, WLZ_CONVOLVE_FLOAT, WLZ_CONVOLVE_INT, WLZ_EMPTY_OBJ, WLZ_ERR_DOMAIN_NULL, WLZ_ERR_DOMAIN_TYPE, WLZ_ERR_NONE, WLZ_ERR_OBJECT_TYPE, WLZ_ERR_UNIMPLEMENTED, WLZ_FMATCHOBJ, WLZ_GREY_DOUBLE, WLZ_GREY_INT, WLZ_HISTOGRAM, WLZ_HISTOGRAMDOMAIN_INT, WLZ_LUT, WLZ_PROPERTY_OBJ, WLZ_RECTANGLE, WLZ_TEXT, WLZ_TRANS_OBJ, WLZ_WARP_TRANS, WlzAffineTransformCopy(), WlzAssignDomain(), WlzAssignGMModel(), WlzCMeshCopy2D(), WlzCMeshCopy2D5(), WlzCMeshCopy3D(), WlzConvexHullCopy2(), WlzConvexHullCopy3(), WlzFreeBoundList(), WlzFreeDomain(), WlzFreePolyDmn(), WlzGMModelCopy(), WlzMake3DViewStructCopy(), WlzMakeBoundList(), WlzMakeContour(), WlzMakeHistogramDomain(), WlzMakeLUTDomain(), WlzMakePlaneDomain(), WlzMakePolygonDomain(), WlzNewIDomain(), WlzValueCopyGreyToGrey(), and _WlzBoundList::wrap.

Referenced by WlzCopyObject(), WlzDiffDomain3d(), and WlzUnion3d().

WlzValues WlzCopyValues ( WlzObjectType  inObjType,
WlzValues  inVal,
WlzDomain  inDom,
WlzErrorNum dstErr 
)

Copies the given values.

Returns
Copied values, NULL on error.
Parameters
inObjTypeType of given values parent object.
inValValues to be copied.
inDomDomain over which values are defined (parent object's domain).
dstErrDestination error pointer, may be NULL.

References AlcVectorItemGet(), _WlzIndexedValues::attach, _WlzVoxelValues::bckgrnd, _WlzDomain::cm2, _WlzDomain::cm2d5, _WlzDomain::cm3, _WlzValues::core, _WlzDomain::core, _WlzIndexedValues::dim, _WlzPlaneDomain::domains, _WlzCMeshEntP::e2, _WlzCMeshEntP::e2d5, _WlzCMeshEntP::e3, _WlzCMeshRes::elm, _WlzCMeshNod2D::idx, _WlzCMeshNod3D::idx, _WlzCMeshElm2D::idx, _WlzCMeshElm3D::idx, _WlzVoxelValues::lastpl, _WlzCoreValues::linkcount, _WlzValues::lut, _WlzCMeshEntRes::maxEnt, _WlzCMeshEntP::n2, _WlzCMeshEntP::n2d5, _WlzCMeshEntP::n3, _WlzCMeshRes::nod, _WlzValues::obj, _WlzDomain::p, _WlzVoxelValues::plane1, _WlzIndexedValues::rank, _WlzCMesh2D::res, _WlzCMesh2D5::res, _WlzCMesh3D::res, _WlzCoreDomain::type, _WlzCoreValues::type, _WlzVoxelValues::type, _WlzCMeshEntP::v, _WlzObject::values, _WlzVoxelValues::values, _WlzCMeshEntRes::vec, _WlzValues::vox, _WlzIndexedValues::vType, WLZ_2D_DOMAINOBJ, WLZ_2D_POLYGON, WLZ_3D_DOMAINOBJ, WLZ_3D_POLYGON, WLZ_3D_WARP_TRANS, WLZ_AFFINE_TRANS, WLZ_BOUNDLIST, WLZ_CMESH_2D, WLZ_CMESH_2D5, WLZ_CMESH_3D, WLZ_COMPOUND_ARR_1, WLZ_COMPOUND_ARR_2, WLZ_COMPOUND_LIST_1, WLZ_COMPOUND_LIST_2, WLZ_CONTOUR, WLZ_CONV_HULL, WLZ_CONVOLVE_FLOAT, WLZ_CONVOLVE_INT, WLZ_EMPTY_OBJ, WLZ_ERR_DOMAIN_NULL, WLZ_ERR_DOMAIN_TYPE, WLZ_ERR_NONE, WLZ_ERR_OBJECT_TYPE, WLZ_ERR_VALUES_NULL, WLZ_ERR_VALUES_TYPE, WLZ_FMATCHOBJ, WLZ_HISTOGRAM, WLZ_INDEXED_VALUES, WLZ_LUT, WLZ_PLANEDOMAIN_DOMAIN, WLZ_PROPERTY_OBJ, WLZ_RECTANGLE, WLZ_TEXT, WLZ_TRANS_OBJ, WLZ_VALUE_ATTACH_ELM, WLZ_VALUE_ATTACH_NOD, WLZ_VOXELVALUETABLE_GREY, WLZ_WARP_TRANS, WlzAssignObject(), WlzAssignValues(), WlzCopyObject(), WlzFreeObj(), WlzFreeValues(), WlzGreySize(), WlzGreyTableIsTiled(), WlzIndexedValueGet(), WlzMakeIndexedValues(), WlzMakeMain(), WlzMakeVoxelValueTb(), WlzNewGrey(), and _WlzValues::x.

Referenced by WlzCMeshExpValues(), WlzCopyObject(), WlzGreyModGradient(), WlzRsvFilterObj(), and WlzUnion3d().

WlzPropertyList* WlzCopyPropertyList ( WlzPropertyList gList,
WlzErrorNum dstErr 
)

Copies the given property list.

Returns
Copied property list.
    A new property list is created with a zero link count
    and a linked list for the properties. Each property of
    given list is then copied and assigned to the new list.
    The order of the properties in the new list is the same
    as that in the given list, although a property that
    occurs more than once in the given list will have many
    copies created.
Parameters
gListGiven property list.
dstErrDestination error pointer, may be NULL.

References ALC_ER_NONE, AlcDLPListEntryAppend(), _WlzEMAPProperty::anatomyUID, _WlzEMAPProperty::comment, _WlzProperty::core, _WlzProperty::emap, _WlzEMAPProperty::emapType, _AlcDLPItem::entry, _WlzEMAPProperty::fileName, _WlzProperty::greyV, _AlcDLPList::head, _WlzPropertyList::list, _WlzEMAPProperty::modelName, _WlzEMAPProperty::modelUID, _WlzNameProperty::name, _WlzGreyProperty::name, _WlzProperty::name, _AlcDLPItem::next, _WlzProperty::simple, _WlzEMAPProperty::stage, _WlzEMAPProperty::subStage, _WlzEMAPProperty::targetUID, _WlzEMAPProperty::targetVersion, _WlzCoreProperty::type, _WlzGreyProperty::value, _WlzEMAPProperty::version, WLZ_ERR_MEM_ALLOC, WLZ_ERR_NONE, WLZ_ERR_PROPERTY_NULL, WLZ_ERR_PROPERTY_TYPE, WLZ_PROPERTY_EMAP, WLZ_PROPERTY_GREY, WLZ_PROPERTY_NAME, WLZ_PROPERTY_SIMPLE, WlzAssignProperty(), WlzFreePropertyList(), WlzFreePropertyListEntry(), WlzMakeEMAPProperty(), WlzMakeGreyProperty(), WlzMakeNameProperty(), and WlzMakePropertyList().

Referenced by WlzCopyObject().

WlzErrorNum WlzCopyObjectGreyValues ( WlzObject dObj,
WlzObject sObj 
)

Copies the grey values of the source object to the destination object, overwriting the values of the destination object.

Returns
Woolz error code.
Parameters
dObjDestination object.
sObjSource object.

References ALG_MAX, ALG_MIN, _WlzValues::core, _WlzDomain::core, _WlzObject::domain, _WlzPlaneDomain::domains, _WlzGreyValueWSpace::gPtr, _WlzGreyValueWSpace::gType, _WlzDomain::i, _WlzInterval::ileft, _WlzInterval::iright, _WlzIntervalDomain::lastln, _WlzPlaneDomain::lastpl, _WlzIntervalWSpace::lftpos, _WlzIntervalDomain::line1, _WlzIntervalWSpace::linpos, _WlzLUTValues::maxVal, _WlzDomain::p, _WlzGreyWSpace::pixeltype, _WlzPlaneDomain::plane1, _WlzIntervalWSpace::rgtpos, _WlzValues::t, _WlzObject::type, _WlzCoreValues::type, _WlzLUTValues::type, _WlzGreyWSpace::u_grintptr, _WlzLUTValues::val, _WlzObject::values, _WlzVoxelValues::values, _WlzGreyValueWSpace::values, _WlzValues::vox, _WlzTiledValues::vpe, _WlzLUTValues::vType, WLZ_2D_DOMAINOBJ, WLZ_3D_DOMAINOBJ, WLZ_ERR_DOMAIN_NULL, WLZ_ERR_EOO, WLZ_ERR_NONE, WLZ_ERR_OBJECT_NULL, WLZ_ERR_OBJECT_TYPE, WLZ_ERR_VALUES_NULL, WLZ_ERR_VALUES_TYPE, WLZ_GREY_TAB_TILED, WLZ_LUT, WLZ_NULL, WLZ_RASTERDIR_ILIC, WLZ_VOXELVALUETABLE_GREY, WlzFreeObj(), WlzGreyTableIsTiled(), WlzGreyTableTypeToTableType(), WlzGreyValueFreeWSp(), WlzGreyValueGet(), WlzGreyValueMakeWSp(), WlzInitGreyScan(), WlzInitRasterScan(), WlzIWSpIntersection(), WlzMakeLUTValues(), WlzMakeMain(), WlzNextGreyInterval(), WlzNextInterval(), and WlzValueCopyGreyToGrey().

Referenced by WlzMakeTiledValuesObj2D(), and WlzMakeTiledValuesObj3D().

WlzErrorNum WlzFreeObj ( WlzObject obj)

Free space allocated to a woolz object.

Returns
Error number, values: WLZ_ERR_NONE, WLZ_ERR_MEM_FREE
Parameters
objObject to be freed.
Source:
WlzFreeSpace.c

References AlcFree(), _WlzObject::assoc, _WlzDomain::b, _WlzDomain::cm2, _WlzDomain::cm2d5, _WlzDomain::cm3, _WlzValues::core, _WlzDomain::core, _WlzDomain::ctr, _WlzDomain::cvh2, _WlzDomain::cvh3, _WlzObject::domain, _WlzDomain::hist, _WlzDomain::i, _WlzObject::linkcount, _WlzIntervalDomain::linkcount, _WlzPlaneDomain::linkcount, _WlzCoreValues::linkcount, _WlzCompoundArray::n, _WlzCompoundArray::o, _WlzValues::obj, _WlzDomain::p, _WlzObject::plist, _WlzDomain::poly, _WlzValues::pts, _WlzDomain::pts, _WlzDomain::r, _WlzValues::t, _WlzDomain::t, _WlzObject::type, _WlzCoreDomain::type, _WlzCoreValues::type, _WlzValues::v, _WlzObject::values, _WlzValues::vox, WLZ_2D_DOMAINOBJ, WLZ_2D_POLYGON, WLZ_3D_DOMAINOBJ, WLZ_AFFINE_TRANS, WLZ_BOUNDLIST, WLZ_CMESH_2D, WLZ_CMESH_2D5, WLZ_CMESH_3D, WLZ_COMPOUND_ARR_1, WLZ_COMPOUND_ARR_2, WLZ_CONTOUR, WLZ_CONV_HULL, WLZ_CONVHULL_DOMAIN_2D, WLZ_CONVHULL_DOMAIN_3D, WLZ_DBG, WLZ_DBG_ALLOC, WLZ_DBG_LVL_1, WLZ_DBG_LVL_FN, WLZ_EMPTY_OBJ, WLZ_ERR_DOMAIN_TYPE, WLZ_ERR_MEM_FREE, WLZ_ERR_NONE, WLZ_ERR_OBJECT_TYPE, WLZ_GREY_TAB_TILED, WLZ_HISTOGRAM, WLZ_LUT, WLZ_POINTS, WLZ_PROPERTY_OBJ, WLZ_RECTANGLE, WLZ_TRANS_OBJ, WlzCMeshFree2D(), WlzCMeshFree2D5(), WlzCMeshFree3D(), WlzFreeAffineTransform(), WlzFreeBoundList(), WlzFreeContour(), WlzFreeConvexHullDomain2(), WlzFreeConvexHullDomain3(), WlzFreeDomain(), WlzFreeIndexedValues(), WlzFreeLUTValues(), WlzFreePlaneDomain(), WlzFreePointValues(), WlzFreePolyDmn(), WlzFreePropertyList(), WlzFreeTiledValues(), WlzFreeValueTb(), WlzFreeVoxelValueTb(), WlzGreyTableIsTiled(), WlzUnlink(), and _WlzValues::x.

Referenced by DumbRegMatch(), main(), Wlz2DContains(), Wlz3DSectionOcc(), Wlz3DSectionSegmentObject(), Wlz3DViewTransformBitmap(), Wlz3DViewTransformObj(), WlzAffineTransformGMShell(), WlzAffineTransformObjCb(), WlzAutoCor(), WlzBasisFnInvertMakeCMeshTr2D(), WlzBasisFnInvertMakeCMeshTr3D(), WlzBasisFnMakeCMeshTr2D(), WlzBasisFnMakeCMeshTr3D(), WlzBoundaryDomain(), WlzBoundaryToObj(), WlzBoundTo8Bound(), WlzBoundToObj(), WlzBuildObj3(), WlzCannyDeriche(), WlzCbThreshold(), WlzCCorS2D(), WlzCentrality(), WlzCentreOfMassVtx3D(), WlzClipObjToBox2D(), WlzClipObjToBox3D(), WlzCMeshCompSurfMap(), WlzCMeshCompSurfMapToDomain(), WlzCMeshComputeCurvatures(), WlzCMeshComputeCurvaturesFromNodNorm(), WlzCMeshComputeNormalsElm(), WlzCMeshComputeNormalsIxv2D5(), WlzCMeshComputeNormalsNod(), WlzCMeshCurvToImage(), WlzCMeshDispToField(), WlzCMeshDistance2D(), WlzCMeshDistance3D(), WlzCMeshExpansion(), WlzCMeshExpValues(), WlzCMeshFlatten2D5(), WlzCMeshFromObj2D(), WlzCMeshFromObj3D(), WlzCMeshIntersectDom2D5(), WlzCMeshSetDispFromField(), WlzCMeshStrainTensor(), WlzCMeshStrainTensorAtPts(), WlzCMeshToDomObj(), WlzCMeshToDomObjValues(), WlzCMeshTransformFromObj(), WlzCMeshTransformInvert(), WlzCMeshTransformManyObjAsIdx(), WlzCMeshValueTransfer(), WlzCompDispIncGrey(), WlzCompoundArrayToScalar(), WlzCompoundToRGBA(), WlzCompThreshold(), WlzConComThreshold(), WlzConstruct3DObjFromFile(), WlzContourFromPoints(), WlzContourGrdObj2D(), WlzContourRBFBndObj3D(), WlzConvertPix(), WlzConvertVtx(), WlzConvexHullVtxD3ToI3(), WlzCopyObjectGreyValues(), WlzCopyScaleCMeshValue(), WlzCopyValues(), WlzCutObjToValBox2D(), WlzCutObjToValBox3D(), WlzDbgObjWrite(), WlzDGTensorFeatures(), WlzDGTensorPDFeature(), WlzDGTensorSDFeature(), WlzDiffDomain(), WlzDiffDomain3d(), WlzDilation(), WlzDistanceTransform(), WlzDomainFill(), WlzDomainFill3D(), WlzDomainNearby(), WlzDomainOccupancy(), WlzDrawDomainObj(), WlzEffReadObjAm(), WlzEffReadObjAnl(), WlzEffReadObjIPL(), WlzEffReadObjJpeg(), WlzEffReadObjNifti(), WlzEffReadObjObj(), WlzEffReadObjPly2(), WlzEffReadObjSlc(), WlzEffReadObjSMesh(), WlzEffReadObjStl(), WlzEffReadObjTiff(), WlzEffWriteObjAm(), WlzEffWriteObjAnl(), WlzEffWriteObjBmp2D(), WlzEffWriteObjJpeg(), WlzEffWriteObjNifti(), WlzEffWriteObjNrrd(), WlzEffWriteObjPnm2D(), WlzEffWriteObjStack(), WlzEffWriteObjTiff(), WlzEffWriteObjTxt(), WlzEffWritePointsVtkFieldValues(), WlzErosion(), WlzExplode3D(), WlzFillBlankPlanes(), WlzFilterNObjValues(), WlzFourierTransformObj(), WlzFree3DViewStruct(), WlzFreePatchTree(), WlzFreeTransform(), WlzFromArray1D(), WlzFromArray2D(), WlzFromArray3D(), WlzGauss2(), WlzGaussFilter(), WlzGaussNoise(), WlzGeometryTrackUpAndDown_s(), WlzGetMaskedSectionFromObject(), WlzGetPatchTree(), WlzGetPatchTreeToDepth(), WlzGetProjectionFromObject(), WlzGreyIncValuesInDomain(), WlzGreyMask(), WlzGreyMeanDifference(), WlzGreyModGradient(), WlzGreyScale(), WlzGreySetHilbertRankValues(), WlzGreySetIncValues(), WlzGreySetRange(), WlzGreySetRangeLut(), WlzGreySetValue(), WlzGreyShift(), WlzGreyStats(), WlzGreyTemplate(), WlzGreyTransfer(), WlzHasIntersection(), WlzHistogramFindPeaks(), WlzHistogramFitPeaks(), WlzHistogramMapValues(), WlzHistogramMatchObj(), WlzHistogramObj(), WlzHyThreshold(), WlzImageArithmetic(), WlzImageBlendObjToBufRGBA(), WlzIndexObjFromCompound(), WlzIndexObjToCompound(), WlzIndexToRGBA(), WlzInit3DViewStruct(), WlzInteriority(), WlzInteriorityN(), WlzIntersect3d(), WlzIntersectN(), WlzIntRescaleObj(), WlzIterate(), WlzIterateWSpFree(), WlzLabel(), WlzLabel3D(), WlzLaplacian(), WlzLBTDomain2DFromIDomain(), WlzLBTDomain3DFromPDomain(), WlzLBTMakeNodeIndexObj2D(), WlzLBTMakeNodeIndexObj3D(), WlzLBTTestOutputNodesVtk(), WlzLUTGreyTransformNew(), WlzLUTTransformObj(), WlzMakeCuboidObject(), WlzMakeMarkers(), WlzMakeSphereObject(), WlzMakeStdStructElement(), WlzMakeTiledValuesObj2D(), WlzMakeTiledValuesObj3D(), WlzMarkerLattice(), WlzMatchICPWeightMatches(), WlzMeshAffineProduct(), WlzMeshFromObjBox(), WlzMeshTransformVerify(), WlzNewGrey(), WlzNewObjectValues(), WlzNewValuesVox(), WlzNMSuppress(), WlzNObjGreyStats(), WlzObjectFacts(), WlzObjToBoundary(), WlzObjToConvexHull(), WlzOffsetDist(), WlzPatchTreeToObject(), WlzPointsFromDomObj(), WlzPointsToDomObj(), WlzPolarSample(), WlzPolygonToObj(), WlzPolyToObj(), WlzProj3DToSection(), WlzProjectObjToPlane(), WlzRankFilter(), WlzRasterLineSetItv2D(), WlzReadMeshTransform3D(), WlzReadObj(), WlzRegCCorObjs(), WlzRegConCalcRCC(), WlzRegICPObjsGrd(), WlzRegICPVerticesWSD2D(), WlzRegisterPatchTreeBF(), WlzRGBAGreyScale(), WlzRGBAGreyStats(), WlzRGBAImageArithmetic(), WlzRGBAModGradient(), WlzRGBAMultiThreshold(), WlzRGBAScalarBinaryOp(), WlzRGBAToCompound(), WlzRGBAToModulus(), WlzRGBChanRatio(), WlzRsvFilterBuffer(), WlzRsvFilterObj(), WlzSampleObj(), WlzSampleObjPoint3D(), WlzScalarBinaryOp(), WlzScalarBinaryOp2(), WlzScalarFeatures2D(), WlzScalarFn(), WlzScalarMulAdd(), WlzSepFilter(), WlzSepTrans(), WlzSetBackground(), WlzShadeCorrectBFDF(), WlzSkeleton3D(), WlzSobel(), WlzSplitMontageObj(), WlzSplitObj(), WlzStructDilation(), WlzStructErosion(), WlzTensorGetComponent(), WlzTensorSmooth(), WlzThinToPoints(), WlzThreshold(), WlzToArray1D(), WlzToArray2D(), WlzToArray3D(), WlzTransposeObj(), WlzUnion3d(), WlzUnionN(), WlzValuesFromCoords(), WlzVerifyObject(), WlzVerticesBuildTree(), WlzVerticesFromObj3I(), WlzVerticesFromObjBnd2I(), WlzVerticesFromObjBnd3I(), WlzVolume(), WlzWindow(), and WlzXORDom().

WlzErrorNum WlzFreeHistogramDomain ( WlzHistogramDomain hist)

Free a histogram domain.

Returns
Error number, values: from WlzFreeDomain().
Parameters
histHistogram domain to be freed.
Source:
WlzFreeSpace.c

References _WlzDomain::hist, and WlzFreeDomain().

Referenced by WlzBasisFnFree(), and WlzReadObj().

WlzErrorNum WlzFreeDomain ( WlzDomain  domain)

Free a domain structure of any type. All domain structures must have a type and linkcount. Most also have a freeptr by which, if set, all the space allocated can be freed, however there are some special cases.

Returns
Woolz error code.
Parameters
domainDomain to be freed.

References ALC_ER_NONE, AlcFree(), AlcFreeStackFree(), _WlzDomain::cm2, _WlzDomain::cm3, _WlzDomain::core, _WlzCoreDomain::freeptr, _WlzCoreDomain::linkcount, _WlzCoreDomain::type, _WlzDomain::vs3d, WLZ_3D_VIEW_STRUCT, WLZ_CMESH_2D, WLZ_CMESH_3D, WLZ_ERR_MEM_FREE, WLZ_ERR_NONE, WlzCMeshFree2D(), WlzCMeshFree3D(), WlzFree3DViewStruct(), and WlzUnlink().

Referenced by WlzAffineTransformObjCb(), WlzAffineTransformPoints(), WlzBasisFnTransformObj(), WlzCMeshStrainTensorAtPts(), WlzCMeshToDomObjValues(), WlzCMeshTransformFromObj(), WlzCMeshTransformManyObjAsIdx(), WlzCMeshTransformObj(), WlzConstruct3DObjFromFile(), WlzConstruct3DObjFromObj(), WlzCopyDomain(), WlzCopyObject(), WlzDGTensorFeatures(), WlzDilation(), WlzEffReadObjTiff(), WlzErosion(), WlzErosion4(), WlzFreeHistogramDomain(), WlzFreeIntervalDomain(), WlzFreeLBTDomain2D(), WlzFreeLBTDomain3D(), WlzFreeObj(), WlzFreePlaneDomain(), WlzFromArray1D(), WlzFromArray3D(), WlzGetProjectionFromObject(), WlzMakeCuboid(), WlzMakeLUTObject(), WlzMakeQuadrilateral(), WlzMakeRect(), WlzMakeSinglePixelObject(), WlzMakeTiledValuesObj2D(), WlzMakeTiledValuesObj3D(), WlzMeshAffineProduct(), WlzPolyToObj(), WlzReadMeshTransform3D(), WlzReadObj(), WlzSampleObjPoint2D(), WlzSampleObjPoint3D(), WlzShiftDomain(), WlzShiftObject(), WlzSkeleton3D(), WlzStructDilation(), WlzStructErosion(), and WlzThinToPoints().

WlzErrorNum WlzFreeValueTb ( WlzRagRValues vdmn)

Convenience routine to free a ragged rect valuetable.

Returns
Error number, values: WLZ_ERR_NONE and from WlzFreeValues().
Parameters
vdmnValue domain to be freed.
Source:
WlzFreeSpace.c

References _WlzValues::v, WLZ_ERR_NONE, and WlzFreeValues().

Referenced by WlzCMeshToDomObjValues(), WlzFreeObj(), WlzIndexObjFromCompound(), WlzLBTMakeNodeIndexObj2D(), WlzLBTMakeNodeIndexObj3D(), WlzLUTTransformObj(), WlzMakeTiledValuesObj2D(), WlzNewValueTb(), WlzReadObj(), WlzScalarMulAdd(), WlzShadeCorrectBFDF(), and WlzStandardPlaneDomain().

WlzErrorNum WlzFreeBoundList ( WlzBoundList b)

Recursively free a boundary list.

Returns
Error number, values: WLZ_ERR_NONE and from WlzUnlink().
Parameters
bBoundary list structure to be freed (note this will call WlzFreeBoundList recursively).
Source:
WlzFreeSpace.c

References AlcFree(), _WlzBoundList::down, _WlzBoundList::linkcount, _WlzBoundList::next, _WlzBoundList::poly, WLZ_ERR_NONE, WlzFreePolyDmn(), and WlzUnlink().

Referenced by WlzAffineTransformIsTranslate(), WlzBasisFnTransformBoundList(), WlzBoundDecimate(), WlzBoundSmooth(), WlzConvertBoundType(), WlzCopyDomain(), WlzDomainFill(), WlzDomainFill3D(), WlzFreeObj(), WlzFreePlaneDomain(), WlzReadObj(), WlzShiftDomain(), and WlzTransposeObj().

WlzErrorNum WlzFree3DWarpTrans ( Wlz3DWarpTrans obj)

Free a 3D warp transform.

Returns
Error number, values: WLZ_ERR_NONE and from WlzFreePlaneDomain().
Parameters
obj3D warp transform object to be freed.
Source:
WlzFreeSpace.c

References AlcFree(), _Wlz3DWarpTrans::intptdoms, _Wlz3DWarpTrans::pdom, WLZ_ERR_NONE, WLZ_ERR_OBJECT_NULL, and WlzFreePlaneDomain().

Referenced by WlzReadObj().

WlzLBTDomain2D* WlzMakeLBTDomain2D ( WlzObjectType  type,
int  l1,
int  ll,
int  k1,
int  kl,
WlzErrorNum dstErr 
)

Creates a linear binary tree domain without creating any nodes, leaving the nodes pointer NULL. Only the type, bounding box and depth are set. The depth \(d\) is set such that

\[ 2^d >= \max(k_l - k_1, l_l - l_1) + 1 \]

where \(k_1\), \(k_l\), \(l_1\) and \(l_l\) are the first column, last column, first line and last line respectively.

Returns
New 2D linear binary tree domain.
Parameters
typeType of domain, which must be WLZ_LBTDOMAIN_2D.
l1First line.
lllast line.
k1First column.
klLast column.
dstErrDestination error pointer, may be NULL.

References AlcCalloc(), AlgBitNextPowerOfTwo(), _WlzLBTDomain2D::depth, _WlzLBTDomain2D::kol1, _WlzLBTDomain2D::lastkl, _WlzLBTDomain2D::lastln, _WlzLBTDomain2D::line1, _WlzLBTDomain2D::type, WLZ_ERR_MEM_ALLOC, WLZ_ERR_NONE, WLZ_ERR_PARAM_DATA, WLZ_LBTDOMAIN_2D, and WLZ_MAX.

Referenced by WlzLBTDomain2DFromIDomain().

WlzLBTDomain3D* WlzMakeLBTDomain3D ( WlzObjectType  type,
int  p1,
int  pl,
int  l1,
int  ll,
int  k1,
int  kl,
WlzErrorNum dstErr 
)

Creates a linear binary tree domain without creating any nodes, leaving the nodes pointer NULL. Only the type, bounding box and depth are set. The depth \(d\) is set such that

\[ 2^d >= \max(p_l - p_1, k_l - k_1, l_l - l_1) + 1 \]

where \(k_1\), \(k_l\), \(l_1\) and \(l_l\) are the first column, last column, first line and last line respectively.

Returns
New 3D linear binary tree domain.
Parameters
typeType of domain, which must be WLZ_LBTDOMAIN_3D.
p1First plane.
plLast plane.
l1First line.
llLast line.
k1First column.
klLast column.
dstErrDestination error pointer, may be NULL.

References AlcCalloc(), AlgBitNextPowerOfTwo(), _WlzLBTDomain3D::depth, _WlzLBTDomain3D::kol1, _WlzLBTDomain3D::lastkl, _WlzLBTDomain3D::lastln, _WlzLBTDomain3D::lastpl, _WlzLBTDomain3D::line1, _WlzLBTDomain3D::plane1, _WlzLBTDomain3D::type, WLZ_ERR_MEM_ALLOC, WLZ_ERR_NONE, WLZ_ERR_PARAM_DATA, WLZ_LBTDOMAIN_3D, and WLZ_MAX.

Referenced by WlzLBTDomain3DFromPDomain().

WlzErrorNum WlzFreeLBTDomain3D ( WlzLBTDomain3D lDom)

Frees the given 3D linear binary tree domain.

Returns
Woolz error code.
Parameters
lDomGiven LBT domain.

References _WlzDomain::l3, WLZ_ERR_NONE, and WlzFreeDomain().

Referenced by WlzCMeshFromObj3D().

WlzErrorNum WlzFreeLBTDomain2D ( WlzLBTDomain2D lDom)

Frees the given 2D linear binary tree domain.

Returns
Woolz error code.
Parameters
lDomGiven LBT domain.

References _WlzDomain::l2, WLZ_ERR_NONE, and WlzFreeDomain().

Referenced by WlzCMeshFromObj2D(), and WlzLBTTestOutputNodesVtk().

WlzCompoundArray* WlzMakeCompoundArray ( WlzObjectType  type,
int  mode,
int  n,
WlzObject **  ol,
WlzObjectType  otype,
WlzErrorNum dstErr 
)

Makes a new Woolz compound array object.

Returns
New Woolz compound array object.
Parameters
typeType of compound array which should be either WLZ_COMPOUND_ARR_1 or WLZ_COMPOUND_ARR_2.
modeAction to be performed, which may have the values:
  • 1: Allocate an empty array with space for n objects.
  • 2: Array members are given in the input object list, the list linked.
  • 3: Array members are given in the input object list, objects assigned.
nNumber of objects.
olInput object list.
otypeWoolz object type if objects are type checked.
dstErrDestination pointer for error number, may be NULL.

References AlcCalloc(), _WlzCompoundArray::linkcount, _WlzCompoundArray::n, _WlzCompoundArray::o, _WlzCompoundArray::otype, _WlzCompoundArray::type, WLZ_COMPOUND_ARR_1, WLZ_COMPOUND_ARR_2, WLZ_ERR_MEM_ALLOC, WLZ_ERR_NONE, WLZ_ERR_OBJECT_TYPE, WLZ_ERR_PARAM_DATA, and WlzAssignObject().

Referenced by WlzCMeshDispToField(), WlzCompDispIncGrey(), WlzCompoundToRGBA(), WlzDGTensorFeatures(), WlzEffReadObjAnl(), WlzEffReadObjTiff(), WlzEffWriteObjAm(), WlzEffWriteObjNifti(), WlzFourierTransformObj(), WlzGreyModGradient(), WlzIndexObjToCompound(), WlzLabel3D(), WlzReadObj(), WlzRGBAGreyScale(), WlzRGBAImageArithmetic(), WlzRGBAToCompound(), WlzScalarMulAdd(), WlzSepFilter(), WlzSepTrans(), WlzShadeCorrectBFDF(), and WlzValuesFromCoords().

WlzIntervalValues* WlzMakeIntervalValues ( WlzObjectType  type,
WlzObject obj,
WlzPixelV  bckgrnd,
WlzErrorNum dstErr 
)

Make in interval values table to match the input object The table will have linkcount set to zero.

Returns
New interval values table.
Parameters
typeRequired table type.
objInput object.
bckgrndValues table background value.
dstErrError return.
Constraints
The woolz object type must resolve to WLZ_GREY_TAB_INTL using WlzGreyTableTypeToTableType()or an error will be reported and NULL returned. For historical reasons the type encodes the table type as well as the grey-value type.
Source:
WlzMakeIntervalValues.c

References AlcCalloc(), AlcFreeStackPush(), _WlzIntervalValues::bckgrnd, _WlzIntervalWSpace::colrmn, _WlzValues::core, _WlzDomain::core, _WlzGreyP::dbp, _WlzObject::domain, _WlzGreyP::flp, _WlzIntervalValues::freeptr, _WlzValues::i, _WlzDomain::i, _WlzGreyP::inp, _WlzIntervalDomain::kol1, _WlzIntervalValues::kol1, _WlzIntervalDomain::lastkl, _WlzIntervalDomain::lastln, _WlzIntervalValues::lastln, _WlzIntervalWSpace::lftpos, _WlzIntervalDomain::line1, _WlzIntervalValues::line1, _WlzIntervalValues::linkcount, _WlzValueIntervalLine::nintvs, _WlzIntervalWSpace::nwlpos, _WlzIntervalValues::original_table, _WlzGreyP::rgbp, _WlzIntervalWSpace::rgtpos, _WlzGreyP::shp, _WlzObject::type, _WlzIntervalValues::type, _WlzGreyP::ubp, _WlzValueLine::values, _WlzIntervalValues::vil, _WlzValueLine::vkol1, _WlzValueLine::vlastkl, _WlzValueIntervalLine::vtbint, _WlzIntervalValues::width, WLZ_2D_DOMAINOBJ, WLZ_EMPTY_OBJ, WLZ_ERR_DOMAIN_NULL, WLZ_ERR_DOMAIN_TYPE, WLZ_ERR_EOO, WLZ_ERR_GREY_TYPE, WLZ_ERR_MEM_ALLOC, WLZ_ERR_NONE, WLZ_ERR_OBJECT_NULL, WLZ_GREY_DOUBLE, WLZ_GREY_FLOAT, WLZ_GREY_INT, WLZ_GREY_RGBA, WLZ_GREY_SHORT, WLZ_GREY_UBYTE, WLZ_RASTERDIR_ILIC, WlzArea(), WlzFreeValues(), WlzGreyTableTypeToGreyType(), WlzGreyTableTypeToTableType(), WlzInitRasterScan(), WlzIntervalCount(), and WlzNextInterval().

Referenced by WlzDomainFill3D(), and WlzNewValueTb().

WlzIntervalDomain* WlzMakeIntervalDomain ( WlzObjectType  type,
int  l1,
int  ll,
int  k1,
int  kl,
WlzErrorNum dstErr 
)

Allocate space for an interval domain structure. If the type is WLZ_INTERVALDOMAIN_INTVL then allocate space for the interval line array and set the pointer.

Returns
Pointer to allocated interval domain.
Parameters
typeRequired interval domain type.
l1First line
llLast line.
k1First column
klLast column
dstErrerror return values: WLZ_ERR_NONE, WLZ_ERR_PARAM_DATA, WLZ_ERR_MEM_ALLOC
Source:
WlzMakeStructs.c

References AlcCalloc(), AlcMalloc(), _WlzIntervalDomain::freeptr, _WlzIntervalDomain::intvlines, _WlzIntervalDomain::kol1, _WlzIntervalDomain::lastkl, _WlzIntervalDomain::lastln, _WlzIntervalDomain::line1, _WlzIntervalDomain::linkcount, _WlzIntervalDomain::type, WLZ_ERR_MEM_ALLOC, WLZ_ERR_NONE, WLZ_ERR_PARAM_DATA, WLZ_INTERVALDOMAIN_INTVL, and WLZ_INTERVALDOMAIN_RECT.

Referenced by Wlz3DSectionSegmentObject(), Wlz3DViewTransformObj(), WlzBuildObj3(), WlzCbThreshold(), WlzClipObjToBox2D(), WlzCMeshToDomObjValues(), WlzCMeshTransformManyObjAsIdx(), WlzConvexHullVtxD3ToI3(), WlzDiffDomain(), WlzDilation(), WlzErosion(), WlzErosion4(), WlzFillBlankPlanes(), WlzFromArray2D(), WlzFromArray3D(), WlzGetMaskedSectionFromObject(), WlzGetProjectionFromObject(), WlzGetSubSectionFromObject(), WlzIDomainFromPItv2D(), WlzIntersectN(), WlzIntRescaleObj(), WlzLabel(), WlzMakeCircleObject(), WlzMakeCuboid(), WlzMakeQuadrilateral(), WlzMakeRect(), WlzMakeRectangleObject(), WlzMakeSpecialStructElement(), WlzNewIDomain(), WlzPDomainFromPItv3D(), WlzPolyToObj(), WlzReadObj(), WlzSampleObj(), WlzSampleObjPoint2D(), WlzSkeleton3D(), WlzStructDilation(), WlzStructErosion(), WlzThreshold(), WlzTransposeObj(), and WlzUnionN().

WlzPlaneDomain* WlzMakePlaneDomain ( WlzObjectType  type,
int  p1,
int  pl,
int  l1,
int  ll,
int  k1,
int  kl,
WlzErrorNum dstErr 
)

Allocate space for a plane domain and the domain pointers.

Returns
POinter to the allocated planedomain.
Parameters
typePlaneDomain type.
p1First plane
plLast plane.
l1First line.
llLast line.
k1First column.
klLast column.
dstErrerror return values: WLZ_ERR_NONE, WLZ_ERR_MEM_ALLOC, WLZ_ERR_PARAM_DATA.
Source:
WlzMakeStructs.c

References AlcCalloc(), AlcFree(), AlcMalloc(), _WlzPlaneDomain::domains, _WlzPlaneDomain::freeptr, _WlzPlaneDomain::kol1, _WlzPlaneDomain::lastkl, _WlzPlaneDomain::lastln, _WlzPlaneDomain::lastpl, _WlzPlaneDomain::line1, _WlzPlaneDomain::linkcount, _WlzPlaneDomain::plane1, _WlzPlaneDomain::type, _WlzPlaneDomain::voxel_size, WLZ_ERR_MEM_ALLOC, WLZ_ERR_NONE, WLZ_ERR_PARAM_DATA, WLZ_PLANEDOMAIN_AFFINE, WLZ_PLANEDOMAIN_BOUNDLIST, WLZ_PLANEDOMAIN_DOMAIN, WLZ_PLANEDOMAIN_HISTOGRAM, WLZ_PLANEDOMAIN_POLYGON, and WLZ_PLANEDOMAIN_WARP.

Referenced by Wlz3DSectionSegmentObject(), Wlz3DViewTransformObj(), WlzAffineTransformGMShell(), WlzBoundaryToObj(), WlzBuildObj3(), WlzCbThreshold(), WlzClipObjToBox3D(), WlzCMeshTransformManyObjAsIdx(), WlzCompoundToRGBA(), WlzConstruct3DObjFromFile(), WlzConstruct3DObjFromObj(), WlzConvertPix(), WlzConvertVtx(), WlzConvexHullVtxD3ToI3(), WlzCopyDomain(), WlzCutObjToValBox3D(), WlzDiffDomain3d(), WlzDilation(), WlzDomainFill3D(), WlzEffReadObjTiff(), WlzErosion(), WlzFromArray3D(), WlzGreyTemplate(), WlzIndexToRGBA(), WlzIntersect3d(), WlzIntRescaleObj(), WlzLabel3D(), WlzMakeCuboid(), WlzMakeCuboidObject(), WlzMakeSpecialStructElement(), WlzMakeSphereObject(), WlzObjToBoundary(), WlzPDomainFromPItv3D(), WlzPolygonToObj(), WlzReadObj(), WlzRGBAToModulus(), WlzSampleObjPoint3D(), WlzShiftDomain(), WlzStructDilation(), WlzStructErosion(), WlzThreshold(), WlzTransposeObj(), and WlzUnion3d().

WlzObject* WlzNewObjectValues ( WlzObject sObj,
WlzObjectType  tType,
WlzPixelV  bgdV,
int  setFG,
WlzPixelV  fgdV,
WlzErrorNum dstErr 
)

Creaes a new object with the domain of the given object and a new values.

Returns
New object or NULL on error.
    This function conveniently wraps up WlzNewValueTb(),
    WlzNewValuesVox(), WlzMakeMain() and WlzGreySetValue().
Parameters
sObjGiven object.
tTypeGrey table type.
bgdVBackground value.
setFGSet forground value if non zero.
fgdVForeground value to be set.
dstErrDestinaition error pointer, may be NULL.

References _WlzDomain::core, _WlzObject::domain, _WlzObject::type, _WlzValues::v, _WlzValues::vox, WLZ_2D_DOMAINOBJ, WLZ_3D_DOMAINOBJ, WLZ_ERR_DOMAIN_NULL, WLZ_ERR_NONE, WLZ_ERR_OBJECT_NULL, WLZ_ERR_OBJECT_TYPE, WlzFreeObj(), WlzGreySetValue(), WlzMakeMain(), WlzNewValuesVox(), and WlzNewValueTb().

Referenced by WlzDomainOccupancy(), WlzEffWriteObjNrrd(), WlzInteriority(), WlzNObjGreyStats(), WlzSepFilter(), WlzSetBackGroundNewObj(), and WlzTensorGetComponent().

WlzObject* WlzMakeMain ( WlzObjectType  type,
WlzDomain  domain,
WlzValues  values,
WlzPropertyList plist,
WlzObject assoc,
WlzErrorNum dstErr 
)

Make a top-level woolz object assigning domain, values and other pointers as required . The type is checked. The domain is not checked for NULL although this should only apply to the WLZ_EMPTY_OBJ.

Returns
Pointer to object structure.
Parameters
typeObject type.
domainDomain to be assigned using WlzAssignDomain()
valuesValues to be attached using WlzAssignValues()
plistProperty list attached using WlzAssignPropertyList()
assocAssociated Object attached using WlzAssignObject().
dstErrerror return values: WLZ_ERR_NONE, WLZ_ERR_MEM_ALLOC, WLZ_ERR_PARAM_DATA snd error values from WlzAssign procedures.
Source:
WlzMakeStructs.c

References AlcFree(), AlcMalloc(), _WlzObject::assoc, _WlzValues::core, _WlzDomain::core, _WlzObject::domain, _WlzObject::linkcount, _WlzCoreDomain::linkcount, _WlzCoreValues::linkcount, _WlzObject::plist, _WlzObject::type, _WlzObject::values, WLZ_2D_DOMAINOBJ, WLZ_2D_POLYGON, WLZ_3D_DOMAINOBJ, WLZ_3D_POLYGON, WLZ_3D_VIEW_STRUCT, WLZ_3D_WARP_TRANS, WLZ_AFFINE_TRANS, WLZ_BOUNDLIST, WLZ_CMESH_2D, WLZ_CMESH_2D5, WLZ_CMESH_3D, WLZ_CMESH_TRANS, WLZ_CONTOUR, WLZ_CONV_HULL, WLZ_DBG, WLZ_DBG_ALLOC, WLZ_DBG_LVL_1, WLZ_EMPTY_OBJ, WLZ_ERR_MEM_ALLOC, WLZ_ERR_NONE, WLZ_ERR_PARAM_DATA, WLZ_HISTOGRAM, WLZ_LUT, WLZ_MESH_TRANS, WLZ_POINTS, WLZ_PROPERTY_OBJ, WLZ_RECTANGLE, WLZ_TRANS_OBJ, WLZ_WARP_TRANS, WlzAssignDomain(), WlzAssignObject(), WlzAssignPropertyList(), and WlzAssignValues().

Referenced by Wlz3DSectionSegmentObject(), Wlz3DViewTransformObj(), WlzAffineTransformGMShell(), WlzAffineTransformObjCb(), WlzBasisFnInvertMakeCMeshTr2D(), WlzBasisFnInvertMakeCMeshTr3D(), WlzBasisFnMakeCMeshTr2D(), WlzBasisFnMakeCMeshTr3D(), WlzBasisFnTransformObj(), WlzBoundaryToObj(), WlzBoundaryToPolyObjArray(), WlzBoundTo8Bound(), WlzBuildObj3(), WlzCannyDeriche(), WlzCbThreshold(), WlzCentreOfMassVtx3D(), WlzClipObjToBox2D(), WlzClipObjToBox3D(), WlzCMeshCompSurfMap(), WlzCMeshComputeCurvaturesFromNodNorm(), WlzCMeshComputeNormalsElm(), WlzCMeshComputeNormalsIxv2D5(), WlzCMeshComputeNormalsNod(), WlzCMeshCurvToImage(), WlzCMeshDispToField(), WlzCMeshDistance2D(), WlzCMeshDistance3D(), WlzCMeshExpansion(), WlzCMeshExpValues(), WlzCMeshExtract2D(), WlzCMeshFlatten2D5(), WlzCMeshIntersect(), WlzCMeshIntersectDom2D5(), WlzCMeshMeshMeshProduct(), WlzCMeshSetDispFromField(), WlzCMeshStrainTensorAtPts(), WlzCMeshToContour(), WlzCMeshToDomObjValues(), WlzCMeshTransformFromObj(), WlzCMeshTransformInvert(), WlzCMeshTransformManyObjAsIdx(), WlzCMeshTransformObj(), WlzCMeshValueTransfer(), WlzCompDispIncGrey(), WlzCompoundArrayToScalar(), WlzCompoundToRGBA(), WlzConComThreshold(), WlzConstruct3DObjFromFile(), WlzConstruct3DObjFromObj(), WlzContourFromPoints(), WlzContourGrdObj2D(), WlzContourRBFBndObj3D(), WlzConvertPix(), WlzConvertVtx(), WlzConvexHullVtxD3ToI3(), WlzCopyObject(), WlzCopyObjectGreyValues(), WlzCopyScaleCMeshValue(), WlzCopyValues(), WlzCutObjToValBox3D(), WlzDGTensorPDFeature(), WlzDGTensorSDFeature(), WlzDiffDomain(), WlzDiffDomain3d(), WlzDilation(), WlzDistanceTransform(), WlzDomainFill(), WlzDomainFill3D(), WlzEffReadObjEMT(), WlzEffReadObjMesh(), WlzEffReadObjNifti(), WlzEffReadObjNodeEle(), WlzEffReadObjObj(), WlzEffReadObjPly2(), WlzEffReadObjSMesh(), WlzEffReadObjStl(), WlzEffReadObjTiff(), WlzEffReadObjVMesh(), WlzEffWriteObjAm(), WlzEffWriteObjAnl(), WlzEffWriteObjStack(), WlzEffWriteObjTiff(), WlzEffWritePointsVtkFieldValues(), WlzErosion(), WlzErosion4(), WlzExplode3D(), WlzFillBlankPlanes(), WlzFilterNObjValues(), WlzFromArray1D(), WlzFromArray2D(), WlzFromArray3D(), WlzGaussNoise(), WlzGetMaskedSectionFromObject(), WlzGetProjectionFromObject(), WlzGetSectionFromObject(), WlzGetSubSectionFromObject(), WlzGreyIncValuesInDomain(), WlzGreyMask(), WlzGreyMeanDifference(), WlzGreyModGradient(), WlzGreySetHilbertRankValues(), WlzGreySetIncValues(), WlzGreySetRange(), WlzGreySetRangeLut(), WlzGreySetValue(), WlzGreyStats(), WlzGreyTemplate(), WlzGreyTransfer(), WlzHasIntersection(), WlzHistogramMapValues(), WlzHistogramMatchObj(), WlzHistogramObj(), WlzHyThreshold(), WlzImageArithmetic(), WlzIndexObjFromCompound(), WlzIndexObjToCompound(), WlzIndexToRGBA(), WlzIntersect3d(), WlzIntersectN(), WlzIntRescaleObj(), WlzIterate(), WlzLabel(), WlzLabel3D(), WlzLBTDomain2DFromIDomain(), WlzLBTDomain3DFromPDomain(), WlzLBTMakeNodeIndexObj2D(), WlzLBTMakeNodeIndexObj3D(), WlzLBTTestOutputNodesVtk(), WlzLUTTransformObj(), WlzMakeCircleObject(), WlzMakeCuboid(), WlzMakeCuboidObject(), WlzMakeEmpty(), WlzMakeHistogram(), WlzMakeLUTObject(), WlzMakeQuadrilateral(), WlzMakeRect(), WlzMakeRectangleObject(), WlzMakeSinglePixelObject(), WlzMakeSphereObject(), WlzMakeTiledValuesObj2D(), WlzMakeTiledValuesObj3D(), WlzMarkerLattice(), WlzMatchICPWeightMatches(), WlzMeshAffineProduct(), WlzNewGrey(), WlzNewObjectValues(), WlzNewObjectValueTable(), WlzNewValuesVox(), WlzNMSuppress(), WlzNObjGreyStats(), WlzObjectFacts(), WlzObjToBoundary(), WlzObjToConvexHull(), WlzObjToConvexPolygon(), WlzPatchTreeToObject(), WlzPointsFromDomObj(), WlzPolygonToObj(), WlzPolyTo8Polygon(), WlzPolyToObj(), WlzProjectObjToPlane(), WlzRankFilter(), WlzReadMeshTransform3D(), WlzReadObj(), WlzRegConCalcRCC(), WlzRegICPObjsGrd(), WlzRGBAModGradient(), WlzRGBAMultiThreshold(), WlzRGBAToChannel(), WlzRGBAToCompound(), WlzRGBAToModulus(), WlzRGBChanRatio(), WlzRsvFilterBuffer(), WlzRsvFilterObj(), WlzSampleObj(), WlzSampleObjPoint2D(), WlzSampleObjPoint3D(), WlzScalarBinaryOp(), WlzScalarBinaryOp2(), WlzScalarFn(), WlzScalarMulAdd(), WlzSepFilter(), WlzSepTrans(), WlzSetBackground(), WlzShadeCorrectBFDF(), WlzShiftObject(), WlzSkeleton3D(), WlzStructDilation(), WlzStructErosion(), WlzThinToPoints(), WlzThreshold(), WlzToArray1D(), WlzToArray3D(), WlzTransposeObj(), WlzUnion3d(), WlzUnionN(), WlzValuesFromCoords(), WlzVerifyObject(), WlzVerticesFromObj3I(), and WlzVolume().

WlzRagRValues* WlzMakeValueTb ( WlzObjectType  type,
int  l1,
int  ll,
int  k1,
WlzPixelV  backgrnd,
WlzObject orig,
WlzErrorNum dstErr 
)

Allocate and initialise space for a ragged-rectangle value table only.

Returns
Pointer to a ragged rectangle values table.
Parameters
typeValues structure type. Must be a correct type as given by WlzGreyValueTableType() with table_type = WLZ_GREY_TAB_RAGR.
l1First line.
llLast line.
k1First column.
backgrndBackground pixel value
origOriginal object holding the grey-value data.
dstErrError return values: WLZ_ERR_NONE, WLZ_ERR_PARAM_DATA, WLZ_ERR_LINE_DATA, WLZ_ERR_MEM_ALLOC
Source:
WlzMakeStructs.c

References AlcCalloc(), AlcFree(), _WlzRagRValues::bckgrnd, _WlzValues::core, _WlzRagRValues::freeptr, _WlzRagRValues::kol1, _WlzRagRValues::lastln, _WlzRagRValues::line1, _WlzRagRValues::linkcount, _WlzRagRValues::original_table, _WlzRagRValues::type, _WlzRagRValues::vtblines, _WlzRagRValues::width, WLZ_ERR_LINE_DATA, WLZ_ERR_MEM_ALLOC, WLZ_ERR_NONE, WLZ_ERR_PARAM_DATA, WLZ_GREY_DOUBLE, WLZ_GREY_FLOAT, WLZ_GREY_INT, WLZ_GREY_RGBA, WLZ_GREY_SHORT, WLZ_GREY_TAB_INTL, WLZ_GREY_TAB_RAGR, WLZ_GREY_TAB_RECT, WLZ_GREY_UBYTE, WlzGreyTableTypeToGreyType(), WlzGreyTableTypeToTableType(), and WlzValueConvertPixel().

Referenced by WlzNewObjectValueTable(), WlzNewValueTb(), WlzReadObj(), and WlzShiftValues().

WlzVoxelValues* WlzMakeVoxelValueTb ( WlzObjectType  type,
int  p1,
int  pl,
WlzPixelV  backgrnd,
WlzObject orig,
WlzErrorNum dstErr 
)
WlzRectValues* WlzMakeRectValueTb ( WlzObjectType  type,
int  line1,
int  lastln,
int  kol1,
int  width,
WlzPixelV  backgrnd,
int *  values,
WlzErrorNum dstErr 
)

Make rectangular value table attaching values if set. Note the values pointer is just copied and will not be freed when the object is freed unless the freeptr is set using AlcFreePointerPush().

Returns
Pointer to a rectangular value table.
Parameters
typeValue table type. Must be a valid table type e.g. as returned by WlzGreyValueTableType() with table_type = WLZ_GREY_TAB_RECT.
line1First line
lastlnLast line.
kol1First column
widthWidth
backgrndBackground pixel value.
valuesPointer to array of pixel values.
dstErrError return values: WLZ_ERR_NONE, WLZ_ERR_PARAM_DATA, WLZ_ERR_MEM_ALLOC
Source:
WlzMakeStructs.c

References AlcFree(), AlcMalloc(), _WlzRectValues::bckgrnd, _WlzValues::core, _WlzRectValues::freeptr, _WlzGreyP::inp, _WlzRectValues::kol1, _WlzRectValues::lastln, _WlzRectValues::line1, _WlzRectValues::linkcount, _WlzRectValues::original_table, _WlzRectValues::type, _WlzRectValues::values, _WlzRectValues::width, WLZ_ERR_MEM_ALLOC, WLZ_ERR_NONE, WLZ_ERR_PARAM_DATA, WLZ_GREY_DOUBLE, WLZ_GREY_FLOAT, WLZ_GREY_INT, WLZ_GREY_RGBA, WLZ_GREY_SHORT, WLZ_GREY_TAB_INTL, WLZ_GREY_TAB_RAGR, WLZ_GREY_TAB_RECT, WLZ_GREY_UBYTE, WlzGreyTableTypeToGreyType(), WlzGreyTableTypeToTableType(), and WlzValueConvertPixel().

Referenced by WlzBuildObj3(), WlzFromArray1D(), WlzFromArray3D(), WlzMakeCuboid(), WlzMakeRect(), WlzNewObjectValueTable(), WlzNewValueTb(), WlzReadObj(), WlzSampleObjPoint2D(), WlzShiftValues(), and WlzTransposeObj().

WlzErrorNum WlzMakeInterval ( int  line,
WlzIntervalDomain idom,
int  nints,
WlzInterval intptr 
)

Attach and interval pointer to a an interval domain in the appropriate place and set the number of intervals on the line. Note this procedure makes no checks on the arguments because it is often used in deeply nested loops.

Returns
Woolz error, values: WLZ_ERR_NONE
Parameters
lineLine on which the interval array is to be attached.
idomPointer to the interval domain to hold the intervals.
nintsNumber of intervals in the array.
intptrPointer to the set of intervals.
Source:
WlzMakeStructs.c

References _WlzIntervalDomain::intvlines, _WlzIntervalLine::intvs, _WlzIntervalDomain::line1, _WlzIntervalLine::nintvs, and WLZ_ERR_NONE.

Referenced by Wlz3DSectionSegmentObject(), Wlz3DViewTransformObj(), WlzCbThreshold(), WlzClipObjToBox2D(), WlzConvexHullVtxD3ToI3(), WlzDiffDomain(), WlzDilation(), WlzErosion(), WlzErosion4(), WlzIntersectN(), WlzIntRescaleObj(), WlzLabel(), WlzMakeCircleObject(), WlzMakeQuadrilateral(), WlzNewIDomain(), WlzPolyToObj(), WlzReadObj(), WlzSampleObj(), WlzSampleObjPoint2D(), WlzSkStrip4(), WlzStructDilation(), WlzStructErosion(), WlzThreshold(), and WlzUnionN().

WlzErrorNum WlzMakeValueLine ( WlzRagRValues vtb,
int  line,
int  k1,
int  kl,
int *  greyptr 
)

Attach the grey values for a valueline within a ragged- rectangle value table. Not this procedure does not check the input arguments because it is often at the core of nested loops.

Returns
Woolz error, values: WLZ_ERR_NONE.
Parameters
vtbPointer to a ragged rectangle value table.
lineLine for the values to be set.
k1First column of grey interval.
klLast column of grey interval.
greyptrGrey values pointer cast type int *.
Source:
WlzMakeStructs.c

References _WlzGreyP::inp, _WlzRagRValues::kol1, _WlzRagRValues::line1, _WlzValueLine::values, _WlzValueLine::vkol1, _WlzValueLine::vlastkl, _WlzRagRValues::vtblines, and WLZ_ERR_NONE.

Referenced by WlzNewValueTb(), and WlzReadObj().

WlzPointValues* WlzNewPointValues ( WlzObject obj,
int  rank,
int *  dim,
WlzGreyType  vType,
WlzErrorNum dstErr 
)

Makes a new point value table which covers the points of the given object.

Returns
New point value table or NULL on error.
Parameters
objGiven object, the domain of which is used to determine the value allocation. This must have type WLZ_POINTS.
rankThe rank of the individual values.
dimThe dimensions of individual indexed values.
vTypeThe type of the data in the individual values.
dstErrDestination error pointer, may be NULL.

References _WlzDomain::core, _WlzObject::domain, _WlzPoints::nPoints, _WlzDomain::pts, _WlzObject::type, WLZ_ERR_DOMAIN_NULL, WLZ_ERR_NONE, WLZ_ERR_OBJECT_NULL, WLZ_ERR_OBJECT_TYPE, WLZ_POINTS, and WlzMakePointValues().

WlzPointValues* WlzMakePointValues ( size_t  nP,
int  rank,
int *  dim,
WlzGreyType  vType,
WlzErrorNum dstErr 
)

Makes a new point value table with space for the requested number of points.

Returns
New point value table or NULL on error.
Parameters
nPNumber of points to allocate space for.
rankThe rank of the individual values.
dimThe dimensions of individual indexed values.
vTypeThe type of the data in the individual values.
dstErrDestination error pointer, may be NULL.

References AlcCalloc(), AlcMalloc(), _WlzPointValues::dim, _WlzPointValues::maxPoints, _WlzPointValues::pSz, _WlzPointValues::rank, _WlzPointValues::type, _WlzGreyP::v, _WlzPointValues::values, _WlzPointValues::vType, WLZ_ERR_GREY_TYPE, WLZ_ERR_MEM_ALLOC, WLZ_ERR_NONE, WLZ_ERR_PARAM_DATA, WLZ_GREY_BIT, WLZ_POINT_VALUES, WlzFreePointValues(), and WlzGreySize().

Referenced by WlzCMeshStrainTensorAtPts(), WlzCMeshTransformObj(), WlzDGTensorPDFeature(), WlzEffWritePointsVtkFieldValues(), WlzNewPointValues(), WlzPointValuesFromDomObj(), and WlzReadMeshTransform3D().

WlzPolygonDomain* WlzMakePolygonDomain ( WlzObjectType  type,
int  n,
WlzIVertex2 vertices,
int  maxv,
int  copy,
WlzErrorNum dstErr 
)

Make a polygon domain, allocating space and copying as required:

  • vertices != NULL, copy=0 - just plant the pointer
  • vertices != NULL, copy=1 - allocate space and copy
  • vertices == NULL, copy=0 - no vertex space allocated
    probably an error!!
  • vertices == NULL, copy=1 - allocate space for maxv vertices
Returns
Pointer to the initialised structure.
Parameters
typeone of WLZ_POLYGON_INT, WLZ_POLYGON_FLOAT, WLZ_POLYGON_DOUBLE
nnumber of vertices if vertices!=NULL.
verticesvertices to be set, see type for value options.
maxvsize of array if vertices!=NULL else number of vertices for which space it to be allocated.
copycopy flag see description for values.
dstErrError return, values: WLZ_ERR_NONE, WLZ_ERR_PARAM_DATA, WLZ_ERR_MEM_ALLOC.
Source:
WlzMakeStructs.c

References AlcCalloc(), _WlzPolygonDomain::linkcount, _WlzPolygonDomain::maxvertices, _WlzPolygonDomain::nvertices, _WlzPolygonDomain::type, _WlzPolygonDomain::vtx, WLZ_ERR_MEM_ALLOC, WLZ_ERR_NONE, WLZ_ERR_PARAM_DATA, WLZ_POLYGON_DOUBLE, WLZ_POLYGON_FLOAT, and WLZ_POLYGON_INT.

Referenced by WlzAffineTransformIsTranslate(), WlzBasisFnTransformPoly2(), WlzCMeshTransformManyObjAsIdx(), WlzConvertPolyType(), WlzCopyDomain(), WlzDomainFill3D(), WlzMeshTransformVerify(), WlzObjToBoundary(), WlzObjToConvexPolygon(), WlzPolyDecimate(), WlzPolyEquispace(), WlzPolyReverse(), WlzPolyTo8Polygon(), WlzReadObj(), WlzShiftDomain(), and WlzTransposeObj().

WlzBoundList* WlzMakeBoundList ( WlzObjectType  type,
int  wrap,
WlzPolygonDomain poly,
WlzErrorNum dstErr 
)

Allocate space and initialise a boundlist structure.

Returns
Pointer to a BoundList structure.
Parameters
typeBoundList type, one of: WLZ_BOUNDLIST_PIECE or WLZ_BOUNDLIST_HOLE.
wrapnumber of vertices by which the polygon is "wrapped" ie number of vertices overlapping at the beginning and end.
polypolygon for this boundary structure
dstErrError return, values: WLZ_ERR_NONE, WLZ_ERR_PARAM_DATA, WLZ_ERR_MEM_ALLOC.
Source:
WlzMakeStructs.c

References AlcFree(), AlcMalloc(), _WlzBoundList::down, _WlzBoundList::freeptr, _WlzBoundList::linkcount, _WlzBoundList::next, _WlzBoundList::poly, _WlzBoundList::type, _WlzBoundList::up, WLZ_BOUNDLIST_HOLE, WLZ_BOUNDLIST_PIECE, WLZ_ERR_MEM_ALLOC, WLZ_ERR_NONE, WLZ_ERR_PARAM_DATA, WlzAssignPolygonDomain(), and _WlzBoundList::wrap.

Referenced by WlzBoundDecimate(), WlzBoundSmooth(), WlzBoundTo8Bound(), WlzConvertBoundType(), WlzCopyDomain(), WlzDomainFill3D(), WlzObjToBoundary(), WlzReadObj(), WlzShiftDomain(), and WlzTransposeObj().

WlzIVertex2* WlzMakeIVertex ( int  nverts,
WlzErrorNum dstErr 
)

Make an integer vertex array.

Returns
Pointer to the array of vertex structures.
Parameters
nvertsNumber of vertices.
dstErrError return, values: WLZ_ERR_NONE, WLZ_ERR_MEM_ALLOC.
Source:
WlzMakeStructs.c

References AlcMalloc(), WLZ_ERR_MEM_ALLOC, and WLZ_ERR_NONE.

WlzObject* WlzMakeRect ( int  line1,
int  lastln,
int  kol1,
int  lastkl,
WlzGreyType  pixeltype,
int *  grey_values,
WlzPixelV  backgrnd,
WlzPropertyList plist,
WlzObject assoc_obj,
WlzErrorNum dstErr 
)

Make a top-level rectangular object, setting values if non-NULL, uses WlzMakeRectValueTb() to assign values which by default will not be freed when the object is freed. The freeptr needs to be explicitly set by the calling procedure. This is a convenience procedure calling WlzMakeIntervalDomain() then WlzMakeRectValueTb() then WlzMakeMain().

Returns
Pointer to the top-level object.
Parameters
line1First line.
lastlnLast line
kol1First column
lastkllast column
pixeltypePixel type for the grey values. If WLZ_GREY_ERROR is given then no values are created.
grey_valuesPointer to the grey values array.
backgrndBackground pixel value.
plistProperty list to be attached.
assoc_objAssociated object.
dstErrError return, values: WLZ_ERR_NONE and valuea from WlzMakeRectValueTb() and WlzMakeMain().
Source:
WlzMakeStructs.c

References _WlzValues::core, _WlzDomain::i, _WlzValues::r, WLZ_2D_DOMAINOBJ, WLZ_ERR_NONE, WLZ_GREY_ERROR, WLZ_GREY_TAB_RECT, WLZ_INTERVALDOMAIN_RECT, WlzFreeDomain(), WlzFreeValues(), WlzGreyValueTableType(), WlzMakeIntervalDomain(), WlzMakeMain(), and WlzMakeRectValueTb().

Referenced by WlzCutObjToValBox2D(), WlzEffReadObjAnl(), WlzEffReadObjJpeg(), WlzEffWriteObjNifti(), WlzFromArray1D(), WlzFromArray2D(), and WlzPolarSample().

WlzObject* WlzNewObjectValueTable ( WlzObject gObj,
WlzPixelV  bgdV,
WlzErrorNum dstErr 
)

Creates a new Woolz object using the given object's domain and a new value table, but uses the grey values of the given object's value table.

Returns
New Woolz object.
Parameters
gObjGiven object.
bgdVRequired background value.
dstErrDestination error pointer, may be NULL.

References AlcCalloc(), _WlzIntervalValues::bckgrnd, _WlzValues::core, _WlzDomain::core, _WlzObject::domain, _WlzValues::i, _WlzGreyP::inp, _WlzRagRValues::kol1, _WlzRectValues::kol1, _WlzIntervalValues::kol1, _WlzRagRValues::lastln, _WlzRectValues::lastln, _WlzIntervalValues::lastln, _WlzVoxelValues::lastpl, _WlzRagRValues::line1, _WlzRectValues::line1, _WlzIntervalValues::line1, _WlzRagRValues::original_table, _WlzRectValues::original_table, _WlzIntervalValues::original_table, _WlzVoxelValues::plane1, _WlzObject::plist, _WlzValues::r, _WlzValues::t, _WlzObject::type, _WlzCoreValues::type, _WlzRagRValues::type, _WlzRectValues::type, _WlzIntervalValues::type, _WlzVoxelValues::type, _WlzValues::v, _WlzObject::values, _WlzRectValues::values, _WlzVoxelValues::values, _WlzIntervalValues::vil, _WlzValues::vox, _WlzRectValues::width, _WlzIntervalValues::width, WLZ_2D_DOMAINOBJ, WLZ_3D_DOMAINOBJ, WLZ_ERR_DOMAIN_NULL, WLZ_ERR_MEM_ALLOC, WLZ_ERR_NONE, WLZ_ERR_OBJECT_NULL, WLZ_ERR_OBJECT_TYPE, WLZ_ERR_VALUES_NULL, WLZ_ERR_VALUES_TYPE, WLZ_GREY_TAB_INTL, WLZ_GREY_TAB_RAGR, WLZ_GREY_TAB_RECT, WLZ_GREY_TAB_TILED, WLZ_VOXELVALUETABLE_GREY, WlzAssignValues(), WlzFreeVoxelValueTb(), WlzGreyTableIsTiled(), WlzGreyTableTypeToGreyType(), WlzGreyTableTypeToTableType(), WlzGreyTypeFromObj(), WlzMakeMain(), WlzMakeRectValueTb(), WlzMakeValueTb(), WlzMakeVoxelValueTb(), WlzNewTiledValues(), and WlzValueConvertPixel().

Referenced by WlzSetBackGroundNewObj().

WlzObject* WlzMakeCuboid ( int  plane1,
int  lastpl,
int  line1,
int  lastln,
int  kol1,
int  lastkl,
WlzGreyType  pixType,
WlzPixelV  bgdV,
WlzPropertyList plist,
WlzObject assocObj,
WlzErrorNum dstErr 
)

Creates a 3D domain object with values, for which the domain is a cuboid and the values are of the given type and initialized to have value zero.

Returns
New 3D domain object with values or NULL on error.
Parameters
plane1First plane.
lastplLast plane.
line1First line.
lastlnLast line.
kol1First column.
lastklLast column.
pixTypePixel type for the grey values. If WLZ_GREY_ERROR is given then no values are created.
bgdVBackground pixel value.
plistProperty list to be attached.
assocObjAssociated object.
dstErrDestination error pointer, may be NULL.

References ALC_ER_NONE, AlcCalloc(), AlcFree(), AlcFreeStackPush(), _WlzValues::core, _WlzDomain::core, _WlzPlaneDomain::domains, _WlzRectValues::freeptr, _WlzDomain::i, _WlzDomain::p, _WlzValues::r, _WlzVoxelValues::values, _WlzValues::vox, _WlzPlaneDomain::voxel_size, WLZ_3D_DOMAINOBJ, WLZ_ERR_GREY_TYPE, WLZ_ERR_MEM_ALLOC, WLZ_ERR_NONE, WLZ_GREY_ERROR, WLZ_GREY_TAB_RECT, WLZ_INTERVALDOMAIN_RECT, WLZ_NULL, WLZ_PLANEDOMAIN_DOMAIN, WLZ_VOXELVALUETABLE_GREY, WlzAssignDomain(), WlzAssignValues(), WlzFreeDomain(), WlzFreeValues(), WlzGreySize(), WlzGreyValueTableType(), WlzMakeIntervalDomain(), WlzMakeMain(), WlzMakePlaneDomain(), WlzMakeRectValueTb(), and WlzMakeVoxelValueTb().

Referenced by WlzEffReadObjAnl(), WlzEffWriteObjNifti(), and WlzFromArray1D().

WlzHistogramDomain* WlzMakeHistogramDomain ( WlzObjectType  type,
int  maxBins,
WlzErrorNum dstErr 
)

Allocates space for a histogram domain with the space for the given maximum number of bins of the appropriate type.

Returns
Pointer to object, NULL on error.
Parameters
typehistogram type, one of: WLZ_HISTOGRAMDOMAIN_INT or WLZ_HISTOGRAMDOMAIN_FLOAT
maxBinsMaximum number of histogram bins.
dstErrError return, values: WLZ_ERR_NONE, WLZ_ERR_PARAM_DATA, WLZ_ERR_MEM_ALLOC.
Source:
WlzMakeStructs.c

References ALC_ER_NONE, AlcCalloc(), AlcFree(), AlcFreeStackPush(), _WlzHistogramDomain::binValues, _WlzGreyP::dbp, _WlzHistogramDomain::freeptr, _WlzGreyP::inp, _WlzHistogramDomain::maxBins, _WlzHistogramDomain::type, WLZ_ERR_DOMAIN_TYPE, WLZ_ERR_MEM_ALLOC, WLZ_ERR_NONE, WLZ_ERR_PARAM_DATA, WLZ_HISTOGRAMDOMAIN_FLOAT, and WLZ_HISTOGRAMDOMAIN_INT.

Referenced by WlzBasisFnScalarMOS3DFromCPts(), WlzCopyDomain(), WlzMakeHistogram(), and WlzReadObj().

WlzObject* WlzMakeEmpty ( WlzErrorNum dstErr)

Convenience procedure to make a top-level empty object.

Returns
Pointer to the Object structure, NULL on error.
Parameters
dstErrError return, values from WlzMakeMain().
Source:
WlzMakeStructs.c

References _WlzValues::core, _WlzDomain::core, WLZ_EMPTY_OBJ, and WlzMakeMain().

Referenced by main(), Wlz3DSectionSegmentObject(), Wlz3DViewTransformObj(), WlzAffineTransformObjCb(), WlzBasisFnTransformObj(), WlzBoundaryToObj(), WlzCbThreshold(), WlzClipObjToBox2D(), WlzClipObjToBox3D(), WlzCMeshDistance2D(), WlzCMeshDistance3D(), WlzCMeshToDomObjValues(), WlzCMeshTransformManyObjAsIdx(), WlzCMeshTransformObj(), WlzCompoundToRGBA(), WlzConComThreshold(), WlzConvolveObj(), WlzCopyObject(), WlzCutObjToValBox2D(), WlzCutObjToValBox3D(), WlzDiffDomain(), WlzDilation(), WlzDomainFill(), WlzDomainNearby(), WlzDrawDomainObj(), WlzErosion(), WlzErosion4(), WlzFromArray2D(), WlzGreyCrossing(), WlzGreyDitherObj(), WlzGreyGradient(), WlzGreyMask(), WlzGreyModGradient(), WlzGreyScale(), WlzGreyShift(), WlzGreyTemplate(), WlzGreyTransfer(), WlzGreyVariance(), WlzHistogramObj(), WlzImageArithmetic(), WlzIndexObjToCompound(), WlzIntersect3d(), WlzIntersectN(), WlzIntRescaleObj(), WlzMakeMarkers(), WlzMakeStdStructElement(), WlzMeshAffineProduct(), WlzNewGrey(), WlzNMSuppress(), WlzObjToConvexPolygon(), WlzOffsetDist(), WlzPointsToDomObj(), WlzPolarSample(), WlzPolygonToObj(), WlzPolyTo8Polygon(), WlzPolyToObj(), WlzRasterLineSetItv2D(), WlzRasterObj(), WlzRGBAMultiThreshold(), WlzRGBAToChannel(), WlzRGBAToCompound(), WlzRGBAToModulus(), WlzRsvFilterObj(), WlzSampleObj(), WlzSampleObjPoint2D(), WlzScalarBinaryOp2(), WlzSepTrans(), WlzShadeCorrectBFDF(), WlzShiftObject(), WlzSkeleton(), WlzStructDilation(), WlzStructErosion(), WlzThreshold(), WlzTransposeObj(), WlzUnionN(), and WlzWindow().

WlzObject* WlzMakeHistogram ( WlzObjectType  type,
int  maxBins,
WlzErrorNum dstErr 
)

Convenience procedure to make a top-level object with a histogram domain.

Returns
Pointer to a Histogram object, NULL on error.
Parameters
typeType of the histogram domain, one of: WLZ_HISTOGRAMDOMAIN_INT or WLZ_HISTOGRAMDOMAIN_FLOAT.
maxBinsMaximum number of histogram bins.
dstErrError return, values: from WlzMakeHistogramDomain() and WlzMakeMain().
Source:
WlzMakeStructs.c

References _WlzValues::core, _WlzDomain::hist, WLZ_ERR_NONE, WLZ_HISTOGRAM, WlzMakeHistogramDomain(), and WlzMakeMain().

Referenced by WlzHistogramCopy(), WlzHistogramObj(), and WlzHistogramRebin().

WlzObject* WlzNewGrey ( WlzObject iobj,
WlzErrorNum dstErr 
)

Make a top-level object with the same domain as iobj (pointer copied and linkcount incremented) and new valuetable with values copied from iobj. If iobj has no valuetable then the returned object will have no value- table. This allows a copy of a 2D grey-value object.

Returns
Pointer to the top-level object, NULL on error.
Parameters
iobjInput object which defines the domain and grey values for which the new grey table will be defined.
dstErrError return, values: WLZ_ERR_NONE, WLZ_ERR_OBJECT_TYPE and errors from WlzNewValueTb(), WlzMakeMain(), WlzInitGreyScan() and WlzNextGreyInterval().
Source:
WlzMakeStructs.c

References _WlzValues::core, _WlzDomain::core, _WlzObject::domain, _WlzIntervalWSpace::lftpos, _WlzGreyWSpace::pixeltype, _WlzObject::plist, _WlzIntervalWSpace::rgtpos, _WlzObject::type, _WlzCoreDomain::type, _WlzCoreValues::type, _WlzGreyWSpace::u_grintptr, _WlzGreyP::ubp, _WlzValues::v, _WlzObject::values, WLZ_2D_DOMAINOBJ, WLZ_EMPTY_OBJ, WLZ_ERR_DOMAIN_TYPE, WLZ_ERR_EOO, WLZ_ERR_NONE, WLZ_ERR_OBJECT_NULL, WLZ_ERR_OBJECT_TYPE, WLZ_ERR_VALUES_TYPE, WLZ_GREY_DOUBLE, WLZ_GREY_FLOAT, WLZ_GREY_INT, WLZ_GREY_RGBA, WLZ_GREY_SHORT, WLZ_GREY_TAB_RAGR, WLZ_GREY_TAB_RECT, WLZ_GREY_UBYTE, WLZ_INTERVALDOMAIN_INTVL, WLZ_INTERVALDOMAIN_RECT, WlzFreeObj(), WlzGetBackground(), WlzGreyTableIsTiled(), WlzGreyTableTypeToGreyType(), WlzGreyValueTableType(), WlzInitGreyScan(), WlzMakeEmpty(), WlzMakeMain(), WlzNewValueTb(), and WlzNextGreyInterval().

Referenced by WlzCopyValues(), WlzGreyDitherObj(), WlzGreyMask(), WlzRsvFilterObj(), and WlzSeqPar().

WlzRagRValues* WlzNewValueTb ( WlzObject obj,
WlzObjectType  type,
WlzPixelV  backgrnd,
WlzErrorNum dstErr 
)

Create a value table of required type with the same size and shape as the domain of obj. This must be of type WLZ_2D_DOMAINOBJ.

Returns
Pointer to new ragged-rectangle value table structure.
Parameters
objGiven object in which the domain defines minimum coverage of the new value table.
typeValue table type.
backgrndBackground pixel value.
dstErrDestination error pointer, may be NULL.

References AlcFreeStackPush(), AlcMalloc(), _WlzDomain::core, _WlzGreyP::dbp, _WlzGreyV::dbv, _WlzObject::domain, _WlzGreyP::flp, _WlzGreyV::flv, _WlzRagRValues::freeptr, _WlzRectValues::freeptr, _WlzValues::i, _WlzDomain::i, _WlzGreyP::inp, _WlzIntervalWSpace::intrmn, _WlzGreyV::inv, _WlzIntervalDomain::kol1, _WlzIntervalDomain::lastkl, _WlzIntervalDomain::lastln, _WlzRectValues::lastln, _WlzIntervalWSpace::lftpos, _WlzIntervalDomain::line1, _WlzRectValues::line1, _WlzIntervalWSpace::linpos, _WlzIntervalWSpace::nwlpos, _WlzValues::r, _WlzGreyP::rgbp, _WlzGreyV::rgbv, _WlzIntervalWSpace::rgtpos, _WlzGreyP::shp, _WlzGreyV::shv, _WlzObject::type, _WlzGreyP::ubp, _WlzGreyV::ubv, _WlzGreyP::v, _WlzPixelV::v, _WlzValues::v, _WlzRectValues::values, _WlzRagRValues::width, _WlzRectValues::width, WLZ_2D_DOMAINOBJ, WLZ_ERR_EOO, WLZ_ERR_GREY_TYPE, WLZ_ERR_MEM_ALLOC, WLZ_ERR_NONE, WLZ_ERR_OBJECT_NULL, WLZ_ERR_OBJECT_TYPE, WLZ_GREY_DOUBLE, WLZ_GREY_FLOAT, WLZ_GREY_INT, WLZ_GREY_RGBA, WLZ_GREY_SHORT, WLZ_GREY_TAB_INTL, WLZ_GREY_TAB_RAGR, WLZ_GREY_TAB_RECT, WLZ_GREY_UBYTE, WLZ_RASTERDIR_ILIC, WlzFreeValueTb(), WlzGreyTableTypeToGreyType(), WlzGreyTableTypeToTableType(), WlzInitRasterScan(), WlzLineArea(), WlzMakeIntervalValues(), WlzMakeRectValueTb(), WlzMakeValueLine(), WlzMakeValueTb(), and WlzNextInterval().

Referenced by Wlz3DViewTransformObj(), WlzAffineTransformGMShell(), WlzBuildObj3(), WlzClassValCon4(), WlzCMeshCurvToImage(), WlzCMeshIntersectDom2D5(), WlzCMeshToDomObjValues(), WlzCMeshTransformObj(), WlzCompoundArrayToScalar(), WlzCompoundToRGBA(), WlzConvertPix(), WlzDistanceTransform(), WlzFillBlankPlanes(), WlzFilterNObjValues(), WlzGetMaskedSectionFromObject(), WlzGetProjectionFromObject(), WlzGetSubSectionFromObject(), WlzGreySetHilbertRankValues(), WlzGreySetIncValues(), WlzGreyTemplate(), WlzGreyTransfer(), WlzIndexObjFromCompound(), WlzIndexToRGBA(), WlzIntersectN(), WlzIntRescaleObj(), WlzLBTMakeNodeIndexObj2D(), WlzLUTTransformObj(), WlzMakeTiledValuesObj2D(), WlzNewGrey(), WlzNewObjectValues(), WlzNewValuesVox(), WlzRGBAModGradient(), WlzRGBAToChannel(), WlzRGBAToCompound(), WlzRGBAToModulus(), WlzRGBChanRatio(), WlzRsvFilterBuffer(), WlzScalarBinaryOp2(), WlzScalarFn(), WlzScalarMulAdd(), WlzShadeCorrectBFDF(), WlzTransposeObj(), WlzUnionN(), and WlzValuesFromCoords().

WlzIntervalDomain* WlzNewIDomain ( WlzObjectType  outDomType,
WlzIntervalDomain inDom,
WlzErrorNum dstErr 
)
WlzIndexedValues* WlzMakeIndexedValues ( WlzObject obj,
int  rank,
int *  dim,
WlzGreyType  vType,
WlzValueAttach  attach,
WlzErrorNum dstErr 
)

Makes a new indexed value table.

Returns
New index value table or NULL on error.
Parameters
objGiven object, the domain of which is used to determine the value allocation.
rankThe rank of the individual values.
dimThe dimensions of individual indexed values.
vTypeThe type of the data in the individual values.
attachSpecifies what the values are to be attached to.
dstErrDestination error pointer, may be NULL.

References AlcCalloc(), AlcMalloc(), AlcVectorNew(), _WlzIndexedValues::attach, _AlcVector::blkCnt, _AlcVector::blkSz, _WlzDomain::cm2, _WlzDomain::cm2d5, _WlzDomain::cm3, _WlzDomain::core, _WlzIndexedValues::dim, _WlzObject::domain, _WlzCMeshRes::elm, _WlzCMeshRes::nod, _WlzIndexedValues::rank, _WlzCMesh2D::res, _WlzCMesh2D5::res, _WlzCMesh3D::res, _WlzCoreDomain::type, _WlzIndexedValues::type, _WlzIndexedValues::values, _WlzCMeshEntRes::vec, _WlzIndexedValues::vType, WLZ_CMESH_2D, WLZ_CMESH_2D5, WLZ_CMESH_3D, WLZ_ERR_DOMAIN_NULL, WLZ_ERR_DOMAIN_TYPE, WLZ_ERR_GREY_TYPE, WLZ_ERR_MEM_ALLOC, WLZ_ERR_NONE, WLZ_ERR_OBJECT_NULL, WLZ_ERR_PARAM_DATA, WLZ_GREY_BIT, WLZ_INDEXED_VALUES, WLZ_VALUE_ATTACH_ELM, WLZ_VALUE_ATTACH_NOD, WlzFreeIndexedValues(), and WlzGreySize().

Referenced by WlzBasisFnInvertMakeCMeshTr2D(), WlzBasisFnInvertMakeCMeshTr3D(), WlzBasisFnMakeCMeshTr2D(), WlzBasisFnMakeCMeshTr3D(), WlzCMeshCompSurfMap(), WlzCMeshComputeCurvaturesFromNodNorm(), WlzCMeshComputeNormalsElm(), WlzCMeshComputeNormalsIxv2D5(), WlzCMeshComputeNormalsNod(), WlzCMeshDistance2D(), WlzCMeshDistance3D(), WlzCMeshExpansion(), WlzCMeshMeshMeshProduct(), WlzCMeshProduct(), WlzCMeshSetDispFromField(), WlzCMeshStrainTensorAtPts(), WlzCMeshTransformFromObj(), WlzCMeshTransformInvert(), WlzCMeshValueTransfer(), WlzCopyObject(), WlzCopyScaleCMeshValue(), WlzCopyValues(), and WlzReadMeshTransform3D().

WlzErrorNum WlzExtendIndexedValues ( WlzIndexedValues ixv,
size_t  n 
)

Extends the given indexed value table. This is just a wrapper for AlcVectorExtend().

Returns
Woolz error code.
Parameters
ixvGiven indexed values.
nNumber of values to extend to.

References ALC_ER_NONE, AlcVectorExtend(), _WlzIndexedValues::values, WLZ_ERR_MEM_ALLOC, WLZ_ERR_NONE, and WLZ_ERR_VALUES_NULL.

WlzTiledValues* WlzMakeTiledValues ( int  dim,
int  vRank,
WlzErrorNum dstErr 
)

Allocates a new tiled value table, but without allocating any indices or tiles.

Returns
New tiled values.
Parameters
dimDimension.
vRankRank of the individual values, zero for scalar values, one for vector values etc....
dstErrDestination error pointer, may be NULL.

References AlcCalloc(), AlcFree(), _WlzTiledValues::dim, _WlzTiledValues::fd, _WlzTiledValues::nIdx, _WlzTiledValues::type, _WlzTiledValues::vDim, _WlzTiledValues::vRank, WLZ_ERR_MEM_ALLOC, WLZ_ERR_NONE, WLZ_ERR_PARAM_DATA, WLZ_GREY_INT, WLZ_GREY_TAB_TILED, and WLZ_GREY_TABLE_TYPE.

Referenced by WlzMakeTiledValuesObj2D(), WlzMakeTiledValuesObj3D(), WlzNewTiledValues(), and WlzReadObj().

WlzTiledValues* WlzNewTiledValues ( WlzTiledValues gVal,
WlzPixelV  bgdV,
WlzErrorNum dstErr 
)

Creates a new tiled values table which shares both the grey value tiles and indexing with the given tiled values. This is done by using the original_table field.

Returns
New tiled values or NULL on error.
Parameters
gValThe given tiled values.
bgdVBackground value for the new values.
dstErrDestination error pointer, may be NULL.

References _WlzTiledValues::bckgrnd, _WlzTiledValues::dim, _WlzTiledValues::fd, _WlzTiledValues::indices, _WlzTiledValues::kol1, _WlzTiledValues::lastkl, _WlzTiledValues::lastln, _WlzTiledValues::lastpl, _WlzTiledValues::line1, _WlzTiledValues::nIdx, _WlzTiledValues::numTiles, _WlzTiledValues::original_table, _WlzTiledValues::plane1, _WlzValues::t, _WlzTiledValues::tileOffset, _WlzTiledValues::tiles, _WlzTiledValues::tileSz, _WlzTiledValues::tileWidth, _WlzTiledValues::type, _WlzGreyP::v, _WlzTiledValues::vDim, _WlzTiledValues::vpe, _WlzTiledValues::vRank, WLZ_ERR_NONE, WLZ_ERR_VALUES_NULL, WlzAssignValues(), WlzFreeTiledValues(), and WlzMakeTiledValues().

Referenced by WlzNewObjectValueTable().

WlzObject* WlzMakeTiledValuesFromObj ( WlzObject gObj,
size_t  tileSz,
int  copyValues,
WlzGreyType  gType,
unsigned int  vRank,
unsigned int *  vDim,
WlzPixelV  bgdV,
WlzErrorNum dstErr 
)

Creates a tiled object from the given object.

Returns
New tiled object or NULL on error.
            The tile size specifies the number of values that the
            tiles will contain and must be an integral power of two.
            The actual size in bytes of the tiles will vary with
            grey type.
Parameters
gObjGiven object which must have an appropriate type for a tiled object. The valid types are currently WLZ_2D_DOMAINOBJ and WLZ_3D_DOMAINOBJ objects with values.
tileSzThe required tile size.
copyValuesNon zero if the grey values should be copied to the tiled object.
gTypeRequired grey type for values table.
vRankRank of the individual values, zero for scalar values, one for vector values etc....
vDimArray of size vRank with individual value dimensions, not used if vRank is zero.
bgdVrequired background value.
dstErrDestination error pointer, may be NULL.

References _WlzObject::type, WLZ_2D_DOMAINOBJ, WLZ_3D_DOMAINOBJ, WLZ_ERR_NONE, WLZ_ERR_OBJECT_NULL, WLZ_ERR_OBJECT_TYPE, WlzMakeTiledValuesObj2D(), and WlzMakeTiledValuesObj3D().

Referenced by WlzFromArray1D().

void WlzFreeTiledValueBuffer ( WlzTiledValueBuffer tBuf)

Frees the given tiled values buffer including it's line buffer.

Parameters
tBufGiven tiled values, may be NULL.

References AlcFree(), _WlzTiledValueBuffer::lnbuf, and _WlzGreyP::v.

Referenced by WlzEndGreyScan().

WlzObject* WlzMakeTiledValuesObj2D ( WlzObject gObj,
size_t  tileSz,
int  setTiles,
WlzGreyType  gType,
unsigned int  vRank,
unsigned int *  vDim,
WlzPixelV  bgdV,
WlzErrorNum dstErr 
)

Creates a 2D domain object which has the same domain as the given 2D domain object but a tiled value table.

Returns
New tiled object or NULL on error.
            The tile size specifies the number of values that the
            tiles will contain and must be an integral power of two.
            The actual size in bytes of the tiles will vary with
            grey type.

            If the given object must have valid values but the
            tiles these are copied to are not allocated if the
            setTiles flag is not set.
Parameters
gObjGiven object known to be valid.
tileSzThe required tile size.
setTilesFlag which must be set for the tiles to be allocated and their values set.
gTypeRequired grey type for values table.
vRankRank of the individual values, zero for scalar values, one for vector values etc....
vDimArray of size vRank with individual value dimensions, not used if vRank is zero.
bgdVrequired background value.
dstErrDestination error pointer, may be NULL.

References AlcFree(), AlgBitNextPowerOfTwo(), _WlzTiledValues::bckgrnd, _WlzValues::core, _WlzDomain::core, _WlzTiledValues::dim, _WlzObject::domain, _WlzDomain::i, _WlzTiledValues::indices, _WlzGreyV::inv, _WlzIntervalDomain::kol1, _WlzTiledValues::kol1, _WlzIntervalDomain::lastkl, _WlzTiledValues::lastkl, _WlzIntervalDomain::lastln, _WlzTiledValues::lastln, _WlzIntervalDomain::line1, _WlzTiledValues::line1, _WlzTiledValues::nIdx, _WlzTiledValues::numTiles, _WlzValues::t, _WlzTiledValues::tiles, _WlzTiledValues::tileSz, _WlzTiledValues::tileWidth, _WlzPixelV::type, _WlzObject::type, _WlzTiledValues::type, _WlzGreyP::v, _WlzPixelV::v, _WlzValues::v, _WlzObject::values, _WlzTiledValues::vDim, _WlzTiledValues::vpe, _WlzTiledValues::vRank, _WlzIVertex2::vtX, _WlzIVertex2::vtY, WLZ_2D_DOMAINOBJ, WLZ_ERR_DOMAIN_NULL, WLZ_ERR_NONE, WLZ_ERR_OBJECT_NULL, WLZ_ERR_OBJECT_TYPE, WLZ_ERR_PARAM_DATA, WLZ_GREY_INT, WLZ_GREY_TAB_RAGR, WLZ_GREY_TAB_TILED, WLZ_INTERPOLATION_NEAREST, WLZ_TRANSFORM_2D_AFFINE, WlzAffineTransformObj(), WlzAffineTransformScaleSet(), WlzAssignObject(), WlzCopyObjectGreyValues(), WlzFreeDomain(), WlzFreeObj(), WlzFreeValueTb(), WlzGreySetHilbertRankValues(), WlzGreySetIncValues(), WlzGreyValueTableType(), WlzMakeAffineTransform(), WlzMakeMain(), WlzMakeRectangleObject(), WlzMakeTiledValues(), WlzMakeTiledValuesTiles(), WlzNewValueTb(), WlzShiftDomain(), WlzStructDilation(), WlzTiledValuesValPerElm(), WlzToArray2D(), and WlzValueConvertPixel().

Referenced by WlzMakeTiledValuesFromObj().

WlzObject* WlzMakeTiledValuesObj3D ( WlzObject gObj,
size_t  tileSz,
int  setTiles,
WlzGreyType  gType,
unsigned int  vRank,
unsigned int *  vDim,
WlzPixelV  bgdV,
WlzErrorNum dstErr 
)

Creates a 3D domain object which has the same domain as the given 3D domain object but a tiled value table.

Returns
New tiled object or NULL on error.
            The tile size specifies the number of values that the
            tiles will contain and must be an integral power of two.
            The actual size in bytes of the tiles will vary with
            grey type.
Parameters
gObjGiven object known to be valid.
tileSzThe required tile size.
setTilesFlag which must be set for the tiles to be allocated and their values set.
gTypeRequired grey type for values table.
vRankRank of the individual values, zero for scalar values, one for vector values etc....
vDimArray of size vRank with individual value dimensions, not used if vRank is zero.
bgdVrequired background value.
dstErrDestination error pointer, may be NULL.

References AlcFree(), AlgBitNextPowerOfTwo(), _WlzTiledValues::bckgrnd, _WlzValues::core, _WlzDomain::core, _WlzTiledValues::dim, _WlzObject::domain, _WlzTiledValues::indices, _WlzGreyV::inv, _WlzPlaneDomain::kol1, _WlzTiledValues::kol1, _WlzPlaneDomain::lastkl, _WlzTiledValues::lastkl, _WlzPlaneDomain::lastln, _WlzTiledValues::lastln, _WlzPlaneDomain::lastpl, _WlzTiledValues::lastpl, _WlzPlaneDomain::line1, _WlzTiledValues::line1, _WlzTiledValues::nIdx, _WlzTiledValues::numTiles, _WlzDomain::p, _WlzPlaneDomain::plane1, _WlzTiledValues::plane1, _WlzValues::t, _WlzTiledValues::tiles, _WlzTiledValues::tileSz, _WlzTiledValues::tileWidth, _WlzPixelV::type, _WlzObject::type, _WlzTiledValues::type, _WlzGreyP::v, _WlzPixelV::v, _WlzObject::values, _WlzTiledValues::vDim, _WlzValues::vox, _WlzTiledValues::vpe, _WlzTiledValues::vRank, _WlzIVertex3::vtX, _WlzIVertex3::vtY, _WlzIVertex3::vtZ, WLZ_3D_DOMAINOBJ, WLZ_ERR_DOMAIN_NULL, WLZ_ERR_NONE, WLZ_ERR_OBJECT_NULL, WLZ_ERR_OBJECT_TYPE, WLZ_ERR_PARAM_DATA, WLZ_GREY_INT, WLZ_GREY_TAB_RAGR, WLZ_GREY_TAB_TILED, WLZ_INTERPOLATION_NEAREST, WLZ_TRANSFORM_3D_AFFINE, WlzAffineTransformObj(), WlzAffineTransformScaleSet(), WlzAssignObject(), WlzCopyObjectGreyValues(), WlzFreeAffineTransform(), WlzFreeDomain(), WlzFreeObj(), WlzFreeVoxelValueTb(), WlzGreySetHilbertRankValues(), WlzGreySetIncValues(), WlzGreyValueTableType(), WlzMakeAffineTransform(), WlzMakeCuboidObject(), WlzMakeMain(), WlzMakeTiledValues(), WlzMakeTiledValuesTiles(), WlzNewValuesVox(), WlzShiftDomain(), WlzStructDilation(), WlzTiledValuesValPerElm(), WlzToArray3D(), and WlzValueConvertPixel().

Referenced by WlzDGTensorSDFeature(), and WlzMakeTiledValuesFromObj().