Assembly: Cognex.VisionPro.Core (in Cognex.VisionPro.Core.dll) Version: 69.0.0.0
Parameters
- triggerNumber
- Type: System Int32
A trigger sequence number.
Return Value
Type: ICogImageThe acquired image.
| Event Type | Reason |
|---|---|
| ICogAcqFifo Complete | The acquisition request completed, possibly unsuccessfully. |
| ICogAcqFifo MovePart | Fired when the camera's field of view can be changed without affecting the acquired image. |
| ICogAcqFifo Overrun | Fired from an acquisition FIFO when a trigger is missed or an overrun occurs. |
| Exception | Condition |
|---|---|
| CogAcqTimeoutException | Timeout period expired. |
| CogAcqWrongTriggerModelException | Trigger model is Auto or Slave. |
| CogAcqOverrunException | A trigger could not be serviced. |
| CogAcqAbnormalException | The acquisition failed because of a fault in the acquisition hardware or because of some other unusual problem. |
| CogAcqEncoderOverrunException | Encoder overrun. |
| CogAcqInvalidROIException | The region of interest is not valid. |
| CogAcqOtherFifoErrorException | There was an error in another FIFO in the same master/slave group. |
| CogAcqTooManyStartsException | No more acquisition requests can be made. The limit is 32 acquisition requests. |
Acquires a new image. This method waits until an image is acquired. To start an acquisition without waiting, use StartAcquire and CompleteAcquire(Int32, Int32 , Int32 ).
using Cognex.VisionPro; private CogFrameGrabbers myFrameGrabbers; private ICogFrameGrabber myFrameGrabber; private ICogAcqFifo myAcqFifo; private void AcquireDisplay () { const string VIDEO_FORMAT = "Sony XC75 640x480"; int tNum; myFrameGrabbers = new CogFrameGrabbers(); myFrameGrabber = myFrameGrabbers[0]; myAcqFifo = myFrameGrabber.CreateAcqFifo(VIDEO_FORMAT, Cognex.VisionPro.CogAcqFifoPixelFormatConstants.Format8Grey, 0, false); cogDisplay1.Image = myAcqFifo.Acquire(out tNum); }
Imports Cognex.VisionPro
Private myFrameGrabbers As CogFrameGrabbers
Private myFrameGrabber As Cognex.VisionPro.ICogFrameGrabber
Private myAcqFifo As Cognex.VisionPro.ICogAcqFifo
Private Sub AcquireDisplay()
Const VIDEO_FORMAT = "Sony XC75 640x480"
Dim tNum As Integer
myFrameGrabbers = New CogFrameGrabbers
myFrameGrabber = myFrameGrabbers.Item(0)
myAcqFifo = myFrameGrabber.CreateAcqFifo(VIDEO_FORMAT, CogAcqFifoPixelFormatConstants.Format8Grey, 0, False)
CogDisplay1.Image = myAcqFifo.Acquire(tNum)
End Sub