ImageGear for C and C++ on Windows v19.1 - Updated
MED_DCM_DS_info_get
API Reference Guide > MD Component API Reference > MD Component Functions Reference > Data Set Functions > MED_DCM_DS_info_get

This function returns the number of Data Elements (DEs) associated with the Data Set of the HIGEAR image.

Declaration:

 
Copy Code
AT_ERRCOUNT ACCUAPI MED_DCM_DS_info_get(
       const HIGEAR hIGear, 
       LPDWORD lpNumTags, 
       LPDWORD lpMaxLevel
);

Arguments:

Name Type Description
hIGear const HIGEAR HIGEAR handle to an image.
lpNumTags LPDWORD A far pointer to a DWORD which returns the number of Data Elements (same as the number of Tags) associated with the image's Data Set.
lpMaxLevel LPDWORD A far pointer to a DWORD which returns the maximum SQ Level of the Data Set.

Return Value:

Returns the number of ImageGear errors that occurred during the function call.

Supported Raster Image Formats:

This function does not process image pixels.

The image must have a DICOM DataSet attached to it. Use MED_DCM_DS_exists to check whether the image contains a DataSet.

Remarks:

You might use the number of DEs returned to set the limit on a loop that iterates through each Data Element in a Data Set. If the DataSet contains SQ (Sequence of Items) data elements, the function returns the total number of data elements, including data elements contained within sequences. If there are no SQ Data Elements, lpMaxLevel is set to 0.