ImageGear Professional v18.1 > API Reference Guide > Core Component API Reference > Core Component Functions Reference > Filter Functions > IG_fltr_metad_callback_set |
This function sets the callback functions that ImageGear uses to pass or receive metadata during save and load operations.
Copy Code
|
|
---|---|
AT_ERRCODE ACCUAPI IG_fltr_metad_callback_set( LPVOID lpPrivate, LPAFT_IG_METAD_ITEM_SET_CB lpfnSetCB, LPAFT_IG_METAD_ITEM_ADD_CB lpfnAddCB, LPAFT_IG_METAD_ITEM_GET_CB lpfnGetCB ); |
Name | Type | Description |
lpPrivate | LPVOID | New value for private data to be associated with callback functions. |
lpfnSetCB | LPAFT_IG_METAD_ITEM_SET_CB | New value of callback function of type LPAFT_IG_METAD_ITEM_SET_CB that is to be used for Set metadata operation. |
lpfnAddCB | LPAFT_IG_METAD_ITEM_ADD_CB | New value of callback function of type LPAFT_IG_METAD_ITEM_ADD_CB that is to be used for Add metadata operation. |
lpfnGetCB | LPAFT_IG_METAD_ITEM_GET_CB | New value of callback function of type LPAFT_IG_METAD_ITEM_GET_CB that is to be used for Get metadata operation. |
This function does not process image pixels.
Copy Code
|
|
---|---|
VOID ACCUAPI MetaDataGet( LPVOID lpPrivate, // Private callback data. AT_MODE FilterID, LPCHAR ItemName, // Name of data item DWORD ItemID, // ID of data item AT_MODE ItemType, // Type of item LPVOID ItemValue, // value of item AT_MODE ValueType, // type of value DWORD ValueLength, // length of value AT_BOOL ReadOnlyValue // inform about is value is changeable or not ) { // ... } BOOL ACCUAPI MetaDataSet( LPVOID lpPrivate, // Private callback data. AT_MODE FilterID, LPCHAR ItemName, // Name of data item DWORD ItemID, // ID of data item AT_MODE ItemType, // Type of item LPVOID ItemValue, // value of item AT_MODE ValueType, // type of value DWORD ValueLength, // length of value AT_BOOL ReadOnlyValue, // inform about is value is changeable or not LPVOID *NewItemValue, LPAT_MODE NewValueType, LPDWORD NewValueLength ) { // ... return TRUE; } BOOL ACCUAPI MetaDataAdd( LPVOID lpPrivate, // Private callback data. AT_MODE FilterID, LPCHAR *ItemName, // Name of data item DWORD *ItemID, // ID of data item AT_MODE *ItemType, // Type of item LPVOID *ItemValue, // value of item AT_MODE *ValueType, // type of value DWORD *ValueLength, // length of value AT_BOOL *ReadOnlyValue // inform about is value is changeable or not ) { // ... return TRUE; } void Example_IG_fltr_metad_callback_set() { AT_ERRCOUNT nErrcount; // Count of returned errors on stack // Set metadata callback functions nErrcount = IG_fltr_metad_callback_set(NULL, MetaDataSet, MetaDataAdd, MetaDataGet); } |
See also the section Using Format Filters API for Filter Control.