L_DicomGetLayerImageRefElement

#include "l_bitmap.h"

L_LTDIC_API pDICOMELEMENT L_DicomGetLayerImageRefElement(hDS, pGraphicAnnSQItem, pszImageSOPInstance)

HDICOMDS hDS;

/* a DICOM handle */

pDICOMELEMENT pGraphicAnnSQItem;

/* pointer to a DICOMELEMENT structure */

L_TCHAR* pszImageSOPInstance;

/* referenced image SOP instance UID */

Gets the item element of the specified SOP instance under the "Referenced Image Sequence" (0008,1140) in the specified "Graphic Annotation Sequence" (0070,0001) item.

Parameter

Description

hDS

A DICOM handle.

pGraphicAnnSQItem

Pointer to an item element under the "Graphic Annotation Sequence" (0008,1115) in the "Graphic Annotation Module".

pszImageSOPInstance

SOP Instance UID of the image whose item element is to be retrieved.

Returns

!NULL

The function was successful.

NULL

An error occurred. Refer to Return Codes.

Comments

This function retrieves the item element of the specified SOP instance under the "Referenced Image Sequence" (0008,1140) in the specified "Graphic Annotation Sequence" (0070,0001) item.

Required DLLs and Libraries

LTDIC

For a listing of the exact DLLs and Libraries needed, based on the toolkit version, refer to Files To Be Included With Your Application

Platforms

Win32, x64

See Also

Functions:

L_DicomAddLayerImageRef, L_DicomGetLayerImageRefCount, L_DicomRemoveImageRefFromLayer, L_DicomRemoveAllImageRefsFromLayer, L_DicomRemoveAllImageRefFromAllLayers

Topics:

Working with DICOM Annotations

 

Dicom Annotations: Layers

Example

L_INT DicomGetImageElementInAnnSequenceExample(HDICOMDS hPresStateDS)
{
   pDICOMELEMENT pGraphicAnnSQItem  = L_DicomFindFirstGraphicAnnSQItem(hPresStateDS);
   L_TCHAR* pszSOPInstanceUID        = L_DicomGetPresStateImageRefSOPInstance( hPresStateDS,
                                                                              L_DicomFindFirstPresStateRefSeriesItem(hPresStateDS),0);
   pDICOMELEMENT pElement = L_DicomGetLayerImageRefElement (hPresStateDS,
                                                            pGraphicAnnSQItem, 
                                                            pszSOPInstanceUID);
   if (pElement)
   {
      MessageBox( NULL, 
                  TEXT("Element item found."), 
                  TEXT("Note"), 
                  MB_OK);
      return DICOM_SUCCESS;
   }
   return DICOM_ERROR_NULL_PTR;
}