dmIParameters Class Reference

Handle parameters for processing operations. More...

#include <CCI_Parameters.h>

Inherits dmINotify.

List of all members.

Public Member Functions

bool UseNameSpace (CONST char_t *url)
 Set the url used as namespace for retrieving objects.
bool LockInfo (cci_object *info=NULL)
 Set the current image info attributs as current parameters data.
bool UnlockInfo ()
 release the ImageInfo object obtained with LockInfo()
bool RestoreMask ()
 Restore the current mask parameter as the default mask for the ImageInfo object.
bool Refresh ()
 Call the dmIImageInfo::Update() of the ImageInfo object obtained with LockInfo().
bool SetImage (dmImage *image)
 Set image as the current Image parameter.
bool SetMask (const dmRegion *mask)
 Set the mask parameter.
bool SetRoi (const dmRegion *roi)
 Set the ROI parameter.
bool CreateRoi (dm_uint type, dm_ptr points, dm_uint count=1)
 Create a ROI.
dmImage * GetImage ()
 Return the current image parameter.
dmRegion * GetMask ()
 Return the current mask parameter.
dmRegion * GetRoi ()
 Return the current ROI parameter.
bool SetImageList (cci_object *imagelist)
 Set the imagelist used by this parameter object.
bool SetMaskBuffer (cci_object *maskbuffer)
 Set the mask buffers used by this parameter object.
cci_object * GetImageList ()
 Return the imagelist object held by this dmIParameters object.
cci_object * GetMaskBuffer ()
 Return the mask buffer interface used by this dmIParameters object.
bool MaskToRoi ()
 Transform the current mask into ROI.
bool RoiToMask ()
 Transform the current ROI into mask.
bool KillRoi ()
 Kill/Remove the current ROI.
bool HasMask ()
 Check if there is a valid current mask.
bool StoreBuffer (dm_uint index)
 Store the curent image parameter in buffer index.
bool SelectBuffer (dm_uint index)
 Select the image in buffer index as the current image.
cci_object * GetColorSpace ()
 Return the dmIColorSpace object used by this dmIParameters object.
bool SetColorSpace (cci_object *colorspace)
 Set a dmIColorSpace object used to handle operations on RGB images.
bool SetChannel (dm_uint channel)
 Set the channel used to handle operations on RGB images.
dm_uint GetChannel ()
 Return the channel used to handle operations on RGB images.
bool Fill (dm_bool foreground)
 Fill or Clear the current image according to the ROI.
bool StoreMask (dm_uint index, dm_int op=0)
 Store a copy of the current mask at buffer index index.
bool CallMask (dm_uint index, dm_int op=0)
 Retrieve a copy of the current mask from buffer index index.
bool ClearMask (dm_uint index)
 Clear the current mask at buffer index index.
bool StoreSelection (dm_uint index)
 Store a part of the image according to the current roi.
dm_size GetImageSize (dm_int format, dm_int width, dm_int height)
 Return an estimation of the image size in byte.


Detailed Description

Handle parameters for processing operations.

This interface expose methods for packing the parameters common to all processing operations. It can be used to set custom mask and image parameters as well as retrieving informations in global namespace or from the current image info. If a parameters is not set and is required by by a processing operation, it will be searched in the global namespace and from the current image info.


Member Function Documentation

bool dmIParameters::CreateRoi dm_uint  type,
dm_ptr  points,
dm_uint  count = 1
[inline]
 

Create a ROI.

Parameters:
type : the type of the ROI to be created
points : the object representing the coordinates of the ROI

cci_object* dmIParameters::GetColorSpace  )  [inline]
 

Return the dmIColorSpace object used by this dmIParameters object.

If no colorspaces was assigned, the RGB colorspace will be returned.

See also:
dmIColorSpace

cci_object* dmIParameters::GetImageList  )  [inline]
 

Return the imagelist object held by this dmIParameters object.

Note:
As an exception to rules, the parameter object do not call AddRef() before returning instance of the imagelist object.
See also:
SetImageList()

dmIImageList()

dm_size dmIParameters::GetImageSize dm_int  format,
dm_int  width,
dm_int  height
[inline]
 

Return an estimation of the image size in byte.

If height and width are set to -1 the rectangular part the bounding box of the current roi is used. If format is set to 0, the format of the current image is used

Example :

    GetImageSize(0,-1,-1);
Return the size of the current image cropped to the bounding box of the current roi

cci_object* dmIParameters::GetMaskBuffer  )  [inline]
 

Return the mask buffer interface used by this dmIParameters object.

See also:
SetMaskBuffer()

bool dmIParameters::LockInfo cci_object *  info = NULL  )  [inline]
 

Set the current image info attributs as current parameters data.

The parameters object will hold a reference to the ImageInfo object.

See also:
dmIImageInfo

bool dmIParameters::SetChannel dm_uint  channel  )  [inline]
 

Set the channel used to handle operations on RGB images.

A channel number always start at 1

See also:
SetColorSpace()

bool dmIParameters::SetColorSpace cci_object *  colorspace  )  [inline]
 

Set a dmIColorSpace object used to handle operations on RGB images.

The ColorSpace object will be used to split image into channels components for subsequent use in image processing operations.

See also:
dmIColorSpace

dmIParameters::SetChannel()

bool dmIParameters::SetImage dmImage *  image  )  [inline]
 

Set image as the current Image parameter.

You must ensure that the image pointer reference a valid object while used by the parameters object.

bool dmIParameters::SetImageList cci_object *  imagelist  )  [inline]
 

Set the imagelist used by this parameter object.

Parameters:
imagelist a valid interface to a dmIImageList object.

bool dmIParameters::SetMask const dmRegion *  mask  )  [inline]
 

Set the mask parameter.

If mask is NULL, then the mask parameter will be obtained from the default mask of the dmIMaskBuffer internal object.

See also:
SetMaskBuffer

bool dmIParameters::SetMaskBuffer cci_object *  maskbuffer  )  [inline]
 

Set the mask buffers used by this parameter object.

Parameters:
maskbuffer a valid interface to a dmIMaskBuffer object.

bool dmIParameters::StoreSelection dm_uint  index  )  [inline]
 

Store a part of the image according to the current roi.

Store the rectangular part of the current image corresponding to the bounding box of the current roi


Generated on Tue May 9 12:34:57 2006 for Daim Library Module Set by  doxygen 1.4.6-NO