Sample Image List (Sil.dll) 14.0
SIL type descriptors

Exported functions for SIL type descriptor treatment. More...

Typedefs

typedef void * TSILDATATYPE
 
typedef void * TSILLABELTYPE
 

Functions

cvbval_t SilCompareDataTypes (TSILDATATYPE TypeA, TSILDATATYPE TypeB)
 Compares two data type descriptor objects. More...
 
cvbval_t SilCompareLabelTypes (TSILLABELTYPE TypeA, TSILLABELTYPE TypeB)
 Compares two label type descriptor objects. More...
 
TSILDATATYPE SilCreateDataTypeFloatVector (cvbval_t nDimension)
 Creates a SIL data type descriptor object that represents floating point data vectors of a given dimension. More...
 
TSILDATATYPE SilCreateDataTypeImage (cvbdim_t nWidth, cvbdim_t nHeight, cvbdim_t nDimension, cvbdim_t nDataType, cvbdim_t nFWLeft, cvbdim_t nFWTop, cvbdim_t nFWWidth, cvbdim_t nFWHeight, cvbdim_t nFWOrgX, cvbdim_t nFWOrgY)
 Creates a SIL data type descriptor object that represents images with a given dimension (# of planes), width, height, feature window and origin. More...
 
TSILDATATYPE SilCreateDataTypeImageEx (cvbdim_t nWidth, cvbdim_t nHeight, cvbdim_t nDimension, cvbdim_t nDataType, cvbdim_t nFWOrgX, cvbdim_t nFWOrgY)
 Creates a SIL data type descriptor object that represents images with a given dimension (# of planes), width, height, feature window and origin. More...
 
TSILLABELTYPE SilCreateLabelTypeFloatVector (cvbval_t nDimension)
 Creates a SIL label type descriptor object that represents floating point vector labels of a given length. More...
 
TSILLABELTYPE SilCreateLabelTypeString ()
 Creates a SIL label type descriptor object that represents a string label. More...
 
cvbres_t SilGetFeatureWindow (TSILDATATYPE DataType, cvbdim_t &Left, cvbdim_t &Top, cvbdim_t &Width, cvbdim_t &Height, cvbdim_t &OriginX, cvbdim_t &OriginY)
 Gets the feature window dimensions of the SIL. More...
 
cvbres_t SilGetFloatVectorDataDim (TSILDATATYPE DataType, size_t &nDimension)
 Gets the dimension of the float vector data type descriptor. More...
 
cvbres_t SilGetFloatVectorLabelDim (TSILLABELTYPE LabelType, size_t &nDimension)
 Retrieves the dimension of the float label type descriptor. More...
 
cvbres_t SilGetFringes (TSILDATATYPE DataType, cvbdim_t &Left, cvbdim_t &Top, cvbdim_t &Right, cvbdim_t &Bottom)
 Get the extent of the fringes on a SIL that contains images. More...
 
cvbres_t SilGetImageDataGeometry (TSILDATATYPE DataType, cvbdim_t &nWidth, cvbdim_t &nHeight, cvbdim_t &nDimension, cvbdatatype_t &nDataType)
 Gets the geometry parameters of the image data type. More...
 
cvbres_t SilSetFeatureWindow (TSILDATATYPE DataType, cvbdim_t Left, cvbdim_t Top, cvbdim_t Width, cvbdim_t Height, cvbdim_t OriginX, cvbdim_t OriginY)
 Sets new feature window parameters of the SIL. More...
 

Detailed Description

Exported functions for SIL type descriptor treatment.

Author
VGi
Since
1.0.0 First version. (VGi, 21.04.2009)

Typedef Documentation

◆ TSILDATATYPE

typedef void* TSILDATATYPE

Handle to a SIL data type descriptor.

◆ TSILLABELTYPE

typedef void* TSILLABELTYPE

Handle to a SIL label type descriptor.

Function Documentation

◆ SilCompareDataTypes()

cvbval_t SilCompareDataTypes ( TSILDATATYPE  TypeA,
TSILDATATYPE  TypeB 
)

Compares two data type descriptor objects.

Parameters
[in]TypeAHandle to a Data type object to be compared.
[in]TypeBHandle to a Data type object to be compared.
Returns
  • 0: the two objects match
  • 1: rhs describes a data type other than *this
  • -1: rhs describes a vector of different length

◆ SilCompareLabelTypes()

cvbval_t SilCompareLabelTypes ( TSILLABELTYPE  TypeA,
TSILLABELTYPE  TypeB 
)

Compares two label type descriptor objects.

Parameters
[in]TypeAHandle to a label type object to be compared.
[in]TypeBHandle to a label type object to be compared.
Returns
  • 0: the two objects match
  • 1: rhs describes a label type other than *this
  • -1: rhs describes a vector of different length

◆ SilCreateDataTypeFloatVector()

TSILDATATYPE SilCreateDataTypeFloatVector ( cvbval_t  nDimension)

Creates a SIL data type descriptor object that represents floating point data vectors of a given dimension.

The returned data type descriptor can then be used for creating a new TSIL object using the function SilCreate. Note that the object needs to be disposed of after use by calling ReleaseObject on it.

See also
SilCreate, SilCreateDataTypeImage, SilGetFloatVectorDataDim, SilGetDataType, IsSilDataType, SilCompareDataTypes, SilVerifyDataCompatibility
Parameters
[in]nDimensionlength of the data vectors
Returns
Returns NULL if an invalid combination of input values is given (e.g. a negative or zero dimension), otherwise returns data type descriptor object handle.

◆ SilCreateDataTypeImage()

TSILDATATYPE SilCreateDataTypeImage ( cvbdim_t  nWidth,
cvbdim_t  nHeight,
cvbdim_t  nDimension,
cvbdim_t  nDataType,
cvbdim_t  nFWLeft,
cvbdim_t  nFWTop,
cvbdim_t  nFWWidth,
cvbdim_t  nFWHeight,
cvbdim_t  nFWOrgX,
cvbdim_t  nFWOrgY 
)

Creates a SIL data type descriptor object that represents images with a given dimension (# of planes), width, height, feature window and origin.

The returned data type descriptor can then be used for creating a new TSIL object using the function SilCreate. Note that the object needs to be disposed of after use by calling ReleaseObject on it.

Remarks
For a simpler version see SilCreateDataTypeImageEx.
See also
SilCreate, SilCreateDataTypeFloatVector, SilGetImageDataGeometry, SilGetDataType, SilGetFeatureWindow, SilSetFeatureWindow, SilGetFringes, IsSilDataType, SilCompareDataTypes, SilVerifyDataCompatibility
Parameters
[in]nWidthWidth of the image.
[in]nHeightHeight of the image.
[in]nDimensionNumber of image planes.
[in]nDataTypeData type of the input image.
[in]nFWLeftLocation of the feature window's left edge in the image.
[in]nFWTopLocation of the feature window's top edge in the image.
[in]nFWWidthWidth of the feature window.
[in]nFWHeightHeight of the feature window.
[in]nFWOrgXX component of origin
[in]nFWOrgYY component of origin
Returns
Returns NULL if an invalid combination of input values is given (e.g. a feature window that is bigger than the image), otherwise returns data type descriptor object handle.

◆ SilCreateDataTypeImageEx()

TSILDATATYPE SilCreateDataTypeImageEx ( cvbdim_t  nWidth,
cvbdim_t  nHeight,
cvbdim_t  nDimension,
cvbdim_t  nDataType,
cvbdim_t  nFWOrgX,
cvbdim_t  nFWOrgY 
)

Creates a SIL data type descriptor object that represents images with a given dimension (# of planes), width, height, feature window and origin.

The returned data type descriptor can then be used for creating a new TSIL object using the function SilCreate. Note that the object needs to be disposed of after use by calling ReleaseObject on it.

Remarks
Unlike its sibling, SilCreateDataTypeImage, this function does not require the specification of a fringe - feature window and image size are simply assumed to be identical.
See also
SilCreate, SilCreateDataTypeFloatVector, SilGetImageDataGeometry, SilGetDataType, SilGetFeatureWindow, SilSetFeatureWindow, SilGetFringes, IsSilDataType, SilCompareDataTypes, SilVerifyDataCompatibility
Parameters
[in]nWidthWidth of the image.
[in]nHeightHeight of the image.
[in]nDimensionNumber of image planes.
[in]nDataTypeData type of the input image.
[in]nFWOrgXX component of origin
[in]nFWOrgYY component of origin
Returns
Returns NULL if an invalid combination of input values is given (e.g. a feature window that is bigger than the image), otherwise returns data type descriptor object handle.

◆ SilCreateLabelTypeFloatVector()

TSILLABELTYPE SilCreateLabelTypeFloatVector ( cvbval_t  nDimension)

Creates a SIL label type descriptor object that represents floating point vector labels of a given length.

The returned data type descriptor handle can then be used for creating a a new TSIL object using the function SilCreate. Note that the object needs to be disposed of after use by calling ReleaseObject on it.

See also
SilCreateLabelTypeString, SilGetLabelType, IsSilLabelType, SilCompareLabelTypes, SilVerifyLabelCompatibility, SilGetFloatVectorLabelDim
Parameters
nDimension- length of the vector
Returns
type descriptor object if successful else NULL

◆ SilCreateLabelTypeString()

TSILLABELTYPE SilCreateLabelTypeString ( void  )

Creates a SIL label type descriptor object that represents a string label.

The returned data type descriptor handle can then be used for creating a a new TSIL object using the function SilCreate. Note that the object needs to be disposed of after use by calling ReleaseObject on it.

See also
SilCreateLabelTypeFloatVector, SilGetLabelType, IsSilLabelType, SilCompareLabelTypes, SilVerifyLabelCompatibility
Returns
type descriptor object if successful else NULL

◆ SilGetFeatureWindow()

cvbres_t SilGetFeatureWindow ( TSILDATATYPE  DataType,
cvbdim_t &  Left,
cvbdim_t &  Top,
cvbdim_t &  Width,
cvbdim_t &  Height,
cvbdim_t &  OriginX,
cvbdim_t &  OriginY 
)

Gets the feature window dimensions of the SIL.

Of course this function can only operate sensibly on a SIL that contains image data - on other SILs an error will be returned.

See also
SilSetFeatureWindow, SilGetFringes
Parameters
[in]DataTypeSIL data type descriptor handle.
[out]LeftLeft edge of the feature window.
[out]TopTop edge of the feature window.
[out]WidthWidth of the feature window.
[out]HeightHeight of the feature window.
[out]OriginXOrigin of the feature window (relative to top left corner).
[out]OriginYOrigin of the feature window (relative to top left corner).
Returns
HRESULT (< 0 = failure)

◆ SilGetFloatVectorDataDim()

cvbres_t SilGetFloatVectorDataDim ( TSILDATATYPE  DataType,
size_t &  nDimension 
)

Gets the dimension of the float vector data type descriptor.

If DataType does not refer to a float vector, an error will be returned.

Parameters
[in]DataTypeSIL data type descriptor handle.
[out]nDimensionDimension the descriptor describes (in float elements).
Returns
HRESULT (<0 : error)

◆ SilGetFloatVectorLabelDim()

cvbres_t SilGetFloatVectorLabelDim ( TSILLABELTYPE  LabelType,
size_t &  nDimension 
)

Retrieves the dimension of the float label type descriptor.

If the input LabelType does not refer to a float vector, an error will be returned.

Parameters
[in]LabelTypeSIL label type descriptor handle.
[out]nDimensionDimension the descriptor describes (in float elements).
Returns
HRESULT (<0 : error)

◆ SilGetFringes()

cvbres_t SilGetFringes ( TSILDATATYPE  DataType,
cvbdim_t &  Left,
cvbdim_t &  Top,
cvbdim_t &  Right,
cvbdim_t &  Bottom 
)

Get the extent of the fringes on a SIL that contains images.

On SILs that do not operate on images, an error will be returned.

The fringes of a SIL are a direct consequence of the geometry of the images stored inside the SIL and the currently set feature window (query with SilGetFeatureWindow), therefore the fringes are a read-only property.

See also
SilSetFeatureWindow, SilGetFeatureWindow
Parameters
[in]DataTypedata type descriptor handle
[out]Leftfringe left of the feature window
[out]Topfringe above the feature window
[out]Rightfringe right of the feature window
[out]Bottomfringe below the feature window
Returns
HRESULT (<0: error)

◆ SilGetImageDataGeometry()

cvbres_t SilGetImageDataGeometry ( TSILDATATYPE  DataType,
cvbdim_t &  nWidth,
cvbdim_t &  nHeight,
cvbdim_t &  nDimension,
cvbdatatype_t &  nDataType 
)

Gets the geometry parameters of the image data type.

If DataType does not refer to an image data type descriptor, an error will be returned.

Parameters
[in]DataTypeSIL data type descriptor handle.
[out]nWidthWidth of the images in the SIL.
[out]nHeightHeight of the images in the SIL.
[out]nDimensionDepth of the images in the SIL.
[out]nDataTypeCVB data type of the images in the SIL.
Returns
HRESULT (< 0 on failure).

◆ SilSetFeatureWindow()

cvbres_t SilSetFeatureWindow ( TSILDATATYPE  DataType,
cvbdim_t  Left,
cvbdim_t  Top,
cvbdim_t  Width,
cvbdim_t  Height,
cvbdim_t  OriginX,
cvbdim_t  OriginY 
)

Sets new feature window parameters of the SIL.

Note that the input parameters need to match the dimensions of the SIL images (feature window must be entirely inside the image, origin must be inside the feature window) and the SIL must be configured to use image data, otherwise this function will fail.

See also
SilGetFeatureWindow, SilGetFringes
Parameters
[in]DataTypeData type descriptor handle to work on.
[in]LeftLeft edge of the feature window.
[in]TopTop edge of the feature window.
[in]WidthWidth of the feature window.
[in]HeightHeight of the feature window.
[in]OriginXOrigin of the feature window.
[in]OriginYOrigin of the feature window.
Returns
HRESULT (<0: error)