LDicomDS::OnConvertLEADAnnObjToDicomAnnObj

#include "Ltdic.h"

virtual L_UINT16 LDicomDS::OnConvertLEADAnnObjToDicomAnnObj(pGraphicObject, pTextObject)

const pDICOMGRAPHICOBJECT pGraphicObject;

pointer to a DICOM graphic annotation object

const pDICOMTEXTOBJECT pTextObject;

pointer to a DICOM text annotation object

Called for each DICOM annotation object generated by LDicomDS::ConvertLEADAnnObjToDicomAnnObjs.

Parameter

Description

pGraphicObject

Pointer to a DICOMGRAPHICOBJECT structure, which will hold the attributes of the generated DICOM graphic annotation object. If set to NULL, then the resulting object is a DICOM text annotation and in this case pTextObject cannot be NULL.

pTextObject

Pointer to a DICOMTEXTOBJECT structure, which will hold the attributes of the generated DICOM text annotation object. If set to NULL then the resulting object is a DICOM graphic annotation and in this case pGraphicObject cannot be NULL.

Returns

0

SUCCESS

>0

An error occurred. Refer to Return Codes

Comments

As a result of calling LDicomDS::ConvertLEADAnnObjToDicomAnnObjs one or more DICOM annotation objects will be generated. For each of the resulting objects this overridable virtual function will get called once. If the resulting object is a "Graphic Object", then the parameter pGraphicObject will point to a DICOMGRAPHICOBJECT structure, which describes the new object, and in this case pTextObject will be set to NULL.

If the resulting object is a "Text Object", then the parameter pTextObject will point to a DICOMTEXTOBJECT structure, which describes the new object, and in this case pGraphicObject will be set to NULL. Suppose that a LEAD annotation object will get converted into two DICOM graphic objects and one DICOM text object. This means that this function will get called three times, it will be called twice with pGraphicObject != NULL and pTextObject == NULL and will be called once with pGraphicObject == NULL and pTextObject != NULL.

pTextObject and pGraphicObject cannot both be valid or both be NULL at the same time.

The implementation of the LDicomDS class for the function OnConvertLEADAnnObjToDicomAnnObj simply returns DICOM_SUCCESS. In order to make use of this callback function, you should create a new class derived from the LDicomDS class and override the function OnConvertLEADAnnObjToDicomAnnObj, providing the desired implementation.

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:

LDicomDS::ConvertLEADAnnObjToDicomAnnObjs, LDicomDS::ConvertDicomAnnObjToLEADAnnObj, Class Members

Topics:

Working with DICOM Annotations

 

How to Disable the Automatic Loading of the default DICOM IOD Table

Example

L_UINT16 OnConvertLEADAnnObjToDicomAnnObj( const pDICOMGRAPHICOBJECT pGraphicObject,const pDICOMTEXTOBJECT pTextObject) 
{ 
   if (pGraphicObject) 
   { 
      MessageBox(NULL,TEXT("A Graphical object has been created."),NULL,0); 
   } 
   else if (pTextObject) 
   { 
      MessageBox(NULL,TEXT("A Textual object has been created."),NULL,0); 
   } 
   return SUCCESS; 
} 

Help Version 19.0.2017.10.27
Products | Support | Contact Us | Copyright Notices
© 1991-2017 LEAD Technologies, Inc. All Rights Reserved.
LEADTOOLS DICOM C++ Class Library Help