GenApi 3.5.1
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
CChunkAdapter Class Referenceabstract

Connects a chunked buffer to a node map.

#include <ChunkAdapter.h>

Inheritance diagram for CChunkAdapter:
CChunkAdapterDcam CChunkAdapterGEV CChunkAdapterGeneric CChunkAdapterU3V CChunkAdapterUniversal CChunkAdapterGenDC

Public Member Functions

virtual ~CChunkAdapter ()
 Destructor.
 
void AttachNodeMap (INodeMap *pNodeMap)
 Attaches to a node map and retrieves the chunk ports.
 
void DetachNodeMap ()
 Detaches from the node map.
 
virtual bool CheckBufferLayout (uint8_t *pBuffer, int64_t BufferLength)=0
 Checks if a buffer contains chunks in a known format.
 
virtual void AttachBuffer (uint8_t *pBuffer, int64_t BufferLength, AttachStatistics_t *pAttachStatistics=NULL)=0
 Attaches a buffer to the matching ChunkPort.
 
void DetachBuffer ()
 Detaches a buffer.
 
void UpdateBuffer (uint8_t *pBaseAddress)
 Updates the base address of the buffer.
 
void ClearCaches ()
 Clears the chunk caches.
 

Protected Member Functions

 CChunkAdapter (INodeMap *pNodeMap=NULL, int64_t MaxChunkCacheSize=-1)
 Serves as default constructor.
 

Protected Attributes

std::vector< CChunkPort * > * m_ppChunkPorts
 An array of attached ChunkPorts.
 
int64_t m_MaxChunkCacheSize
 the maximum size of a chunk to be cached
 

Member Function Documentation

◆ CheckBufferLayout()

virtual bool CheckBufferLayout ( uint8_t * pBuffer,
int64_t BufferLength )
pure virtual

Implement that for a specific buffer layout

Implemented in CChunkAdapterDcam, CChunkAdapterGEV, and CChunkAdapterU3V.

◆ AttachBuffer()

virtual void AttachBuffer ( uint8_t * pBuffer,
int64_t BufferLength,
AttachStatistics_t * pAttachStatistics = NULL )
pure virtual

Implement that for a specific buffer layout

Implemented in CChunkAdapterDcam, CChunkAdapterGEV, and CChunkAdapterU3V.

Member Data Documentation

◆ m_ppChunkPorts

std::vector<CChunkPort*>* m_ppChunkPorts
protected

Note that this must be a pointer otherwise we'll get into DLL hell (see warning C4251)

◆ m_MaxChunkCacheSize

int64_t m_MaxChunkCacheSize
protected

0 : no caching, -1 : all caching