#include "lvkrn.h"
virtual L_INT LVectorBase::EnumGroups()
Enumerates all groups inside the class object's associated vector handle.
Value | Meaning |
---|---|
SUCCESS | The function was successful. |
< 1 | An error occurred. Refer to Return Codes. |
The LVectorBase::EnumGroups function calls the LVectorBase::EnumGroupsCallback function as it gets a pointer to each vector group.
To use the LVectorBase::EnumGroupsCallBack function, you must derive a class from LVectorBase and override the LVectorBase::EnumGroupsCallBack member function.
Required DLLs and Libraries
This example enumerates through all groups in a vector.
#ifdef LMyVectorBase5
class LMyVectorBase5: public LVectorBase
{
public:
L_INT m_nGroupCount ;
public:
LMyVectorBase5() {m_nGroupCount=0;};
virtual ~LMyVectorBase5(){};
virtual L_INT EnumGroupsCallBack(pVECTORHANDLE pVector, pVECTORGROUP pGroup);
};
#endif // #ifdef LMyVectorBase5
L_INT LMyVectorBase5::EnumGroupsCallBack(pVECTORHANDLE pVector, pVECTORGROUP pGroup)
{
UNREFERENCED_PARAMETER(pVector);
LVectorGroup VectorGroup(pGroup, this);
L_TCHAR szMsg[100];
m_nGroupCount++;
VECTORGROUPDESC GroupDesc;
VectorGroup.GetGroupDesc(&GroupDesc);
wsprintf(szMsg, TEXT("Group\nName[%s]\nSize[%d]"),
GroupDesc.szName,
GroupDesc.nSize
);
MessageBox(NULL, szMsg, TEXT(""), MB_OK);
return SUCCESS ;
//...LVectorGroup destructor called when VectorGroup goes out of scope
}
L_INT LVectorBase__EnumGroupsExample(HWND hWnd, LMyVectorBase5 *pMyVector)
{
UNREFERENCED_PARAMETER(hWnd);
L_INT nRet;
LMyVectorBase5 MyVector;
L_TCHAR szMsg[100];
pMyVector->m_nGroupCount=0;
pMyVector->EnableCallBack(TRUE);
nRet = pMyVector->EnumGroups();
if(nRet != SUCCESS)
return nRet;
wsprintf(szMsg, TEXT("Total Groups[%d]"), pMyVector->m_nGroupCount);
MessageBox(NULL, szMsg, TEXT(""), MB_OK);
return SUCCESS;
}
Help Collections
Raster .NET | C API | C++ Class Library | HTML5 JavaScript
Document .NET | C API | C++ Class Library | HTML5 JavaScript
Medical .NET | C API | C++ Class Library | HTML5 JavaScript
Medical Web Viewer .NET
Multimedia
Direct Show .NET | C API | Filters
Media Foundation .NET | C API | Transforms
Supported Platforms
.NET, Java, Android, and iOS/macOS Assemblies
Imaging, Medical, and Document
C API/C++ Class Libraries
Imaging, Medical, and Document
HTML5 JavaScript Libraries
Imaging, Medical, and Document
Your email has been sent to support! Someone should be in touch! If your matter is urgent please come back into chat.
Chat Hours:
Monday - Friday, 8:30am to 6pm ET
Thank you for your feedback!
Please fill out the form again to start a new chat.
All agents are currently offline.
Chat Hours:
Monday - Friday
8:30AM - 6PM EST
To contact us please fill out this form and we will contact you via email.