LAnnPoint::GetBitmap

#include "ltwrappr.h"

virtual L_INT LAnnPoint::GetBitmap(pBitmap)

virtual L_INT LAnnPoint::GetBitmap(pBitmap)

LBitmapBase L_FAR * pBitmap;

/* pointer to an LBitmapBase object */

pBITMAPHANDLE pBitmap;

/* address of the variable to be updated */

Gets the bitmap handle of the annotation object. This function is available in the Document/Medical Toolkits.

Parameter

Description

pBitmap

Pointer to an LBitmapBase object to be updated with the handle to the annotation object's bitmap.

pBitmap

Address of the variable to be updated with the handle to the annotation object's bitmap.

Returns

SUCCESS

The function was successful.

< 1

An error occurred. Refer to Return Codes.

Comments

Before calling LAnnPoint::GetBitmap(pBitmap), where pBitmap is of type LBitmapBase L_FAR, you must declare aan LBitmapBase object. Then, pass the address of the object in the pBitmap parameter. This function will update the object with the handle to the annotation object's bitmap.

Before calling LAnnPoint::GetBitmap(pBitmap), where pBitmap is of type pBITMAPHANDLE, you must declare a variable of data type BITMAPHANDLE. Then, pass the address of the variable in the pBitmap parameter. This function will update the variable with the handle to the annotation object's bitmap.

Required DLLs and Libraries

LTANN

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

See Also

Functions:

LAnnPoint::SetBitmap, Class Members

Topics:

Annotation Functions: Object Properties

 

Using Annotation Bitmap Objects

Example

This is an example of both forms of LAnnPoint::GetBitmap(pBitmap:

void CVCAnnotation11Dlg::OnButtonPointGetSetBitmap() 
{
   ANNPOINT annPoint = {50,50};
   ANNRECT  annRect =  {50,50,150,150};

   L_UNLOCKSUPPORT(L_SUPPORT_DOCUMENT, L_KEY_DOCUMENT);

   LAnnPoint *pMyAnnPoint = new(LAnnPoint);

   pMyAnnPoint->SetPoints(&annPoint);
   pMyAnnPoint->SetVisible(TRUE);

   //Invert the primary bitmap
   LBitmapBase *pBitmapBase = new(LBitmapBase);
   pMyAnnPoint->GetBitmap(pBitmapBase);
   //or
   //BITMAPHANDLE LeadBitmap;
   //pMyAnnPoint->GetBitmap(&LeadBitmap);

   //Make the annotation point all white
   pBitmapBase->Fill(RGB(255,255,255));

   //Create container and insert annotation
   LAnnContainer m_AnnContainer; 
   m_AnnContainer.Create(m_hWnd, &annRect, TRUE);
   m_AnnContainer.Insert(*pMyAnnPoint);
   m_AnnContainer.SetUserMode(ANNUSER_RUN);
}