Buffer Interface
CircularInterface.h
Go to the documentation of this file.
1 #pragma once
2 #include "BufferInterface.h"
3 #include "BiApi.h"
4 
5 namespace BufferAcquisition
6 {
18  class BFDLL CircularInterface : public BufferInterface
19  {
20  public:
21  // create instance
23 
24  // create instance and open board.
25  CircularInterface (const BFU32 brdNumber);
26 
27  // create instance, open and setup board.
28  CircularInterface (const BFU32 brdNumber, const BFU32 numBuffers, const BFU32 errorMode, const BFU32 options);
29 
30  // create instance, open and setup the board with the buffers aligned
31  // on a specified alignment boundary.
32  CircularInterface (const BFU32 brdNumber, const BFU32 numBuffers, const BFU32 errorMode, const BFU32 options, const BFSIZET alignment);
33 
35 
36  // Sets up the board for circular acquisition.
37  BFVOID setup (const BFU32 numBuffers, const BFU32 errorMode, const BFU32 options);
38 
39  // Sets up the board for circular acquisition aligning each buffer
40  // on a specified alignment boundary.
41  BFVOID setup (const BFU32 numBuffers, const BFU32 errorMode, const BFU32 options, const BFSIZET alignment);
42 
43  // Sets up the board for sequence acquisition.
44  BFVOID setup (PBFU32 *const pMemArray, const BFU32 numBuffers, const BFU32 errorMode, const BFU32 options);
45 
46  // Frees resources allocated by setup.
47  BFVOID cleanup (BFVOID);
48 
49  // Issue circular commands.
50  BFVOID cirControl (const BFU32 command, const BFU32 options);
51 
52  // Wait for error.
53  BFU32 cirErrorWait (BFVOID) const;
54 
55  // Returns error from the error stack
56  BFRC getCirError (BFVOID);
57 
58  // Returns when a frame has been DMAed into memory.
59  BFU32 waitDoneFrame (const BFU32 timeout, const PBiCirHandle CirHandle) const;
60 
61  // Set status of a buffer to BIAVAILABLE or BIHOLD
62  BFU32 setBufferStatus (BiCirHandle &cirHandle, const BFU32 status);
63 
64  // Set status of a buffer to BIAVAILABLE or BIHOLD
65  BFU32 setBufferStatus (const BFU32 bufferNumber, const BFU32 status);
66 
67  // Returns the status of a buffer
68  BFU32 getBufferStatus (BiCirHandle const& cirHandle) const;
69 
70  // Returns the status of the buffer
71  BFU32 getBufferStatus (const BFU32 bufferNumber) const;
72 
73  // SMS - in the future
74  //BFVOID setNextBufferForAcq(BFU32 bufferNumber);
75  //BFVOID addAdditionalBuffers(BFU32 numBuffers);
76 
77  };
78 
88 }
struct _BiCirHandle BiCirHandle
struct _BiCirHandle * PBiCirHandle
unsigned long BFU32
Definition: BFTypeNT.h:55
BFU32 BFRC
Definition: BFType.h:92
unsigned long * PBFU32
Definition: BFTypeNT.h:55
Acquire images into a circular buffer using a BitFlow frame grabber.
Definition: CircularInterface.h:18
Class library for BitFlow frame grabber acquisition.
Definition: BFGTLUtilities.hpp:114
size_t BFSIZET
Definition: BFTypeNT.h:93
void BFVOID
Definition: BFTypeNT.h:32
Base class for buffered acquisition using a BitFlow frame grabber.
Definition: BufferInterface.h:63