ChunkAdapterGeneric.h
Go to the documentation of this file.
00001 //-----------------------------------------------------------------------------
00002 //  (c) 2006 by Leutron Vision
00003 //  Project:  GenApi
00004 //    Author:  Jan Becvar
00005 //  $Header$
00006 //
00007 //  License: This file is published under the license of the EMVA GenICam  Standard Group.
00008 //  A text file describing the legal terms is included in  your installation as 'GenICam_license.pdf'.
00009 //  If for some reason you are missing  this file please contact the EMVA or visit the website
00010 //  (http://www.genicam.org) for a full copy.
00011 //
00012 //  THIS SOFTWARE IS PROVIDED BY THE EMVA GENICAM STANDARD GROUP "AS IS"
00013 //  AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
00014 //  THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
00015 //  PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE EMVA GENICAM STANDARD  GROUP
00016 //  OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,  SPECIAL,
00017 //  EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT  LIMITED TO,
00018 //  PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,  DATA, OR PROFITS;
00019 //  OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY  THEORY OF LIABILITY,
00020 //  WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT  (INCLUDING NEGLIGENCE OR OTHERWISE)
00021 //  ARISING IN ANY WAY OUT OF THE USE  OF THIS SOFTWARE, EVEN IF ADVISED OF THE
00022 //  POSSIBILITY OF SUCH DAMAGE.
00023 //-----------------------------------------------------------------------------
00029 #ifndef GENAPI_CHUNKADAPTERGENERIC_H
00030 #define GENAPI_CHUNKADAPTERGENERIC_H
00031 
00032 #include <GenApi/ChunkAdapter.h>
00033 
00034 namespace GENAPI_NAMESPACE
00035 {
00036     /* ------------------------------------------- */
00037     // Single chunk info
00038 
00039     // make sure everything is properly packed
00040     #pragma pack(push, 1)
00041 
00042     typedef struct SingleChunkData_t
00043     {
00044         uint64_t ChunkID;
00045         ptrdiff_t ChunkOffset;
00046         size_t ChunkLength;
00047     } SingleChunkData_t;
00048 
00049     // the extended version holding ChunkID as string should be used only in special cases
00050     // when the ChunkID does not fit into a 64-bit integer
00051     typedef struct SingleChunkDataStr_t
00052     {
00053         GENICAM_NAMESPACE::gcstring ChunkID;
00054         ptrdiff_t ChunkOffset;
00055         size_t ChunkLength;
00056     } SingleChunkDataStr_t;
00057 
00058     // restore the previous packing
00059     #pragma pack(pop)
00060     /* ------------------------------------------- */
00061 
00062 
00064     class GENAPI_DECL CChunkAdapterGeneric : public CChunkAdapter
00065     {
00066 
00067     public:
00069         CChunkAdapterGeneric(INodeMap* pNodeMap = NULL, int64_t MaxChunkCacheSize = -1);
00070 
00072         virtual ~CChunkAdapterGeneric();
00073 
00074         // Does not have implementation, use the version with EventID
00075         virtual bool CheckBufferLayout(uint8_t *pBuffer, int64_t BufferLength);
00076 
00077         // Does not have implementation, use the generic version
00078         virtual void AttachBuffer(uint8_t *pBuffer, int64_t BufferLength, AttachStatistics_t *pAttachStatistics = NULL);
00079 
00080         virtual void AttachBuffer(uint8_t *pBuffer, SingleChunkData_t *ChunkData, int64_t NumChunks, AttachStatistics_t *pAttachStatistics = NULL);
00081 
00082         virtual void AttachBuffer(uint8_t *pBuffer, SingleChunkDataStr_t *ChunkData, int64_t NumChunks, AttachStatistics_t *pAttachStatistics = NULL);
00083     };
00084 
00085 }
00086 
00087 #endif // GENAPI_CHUNKADAPTERGENERIC_H


rc_genicam_api
Author(s): Heiko Hirschmueller
autogenerated on Thu Jun 6 2019 18:42:46