IC Imaging Control .NET

FrameHandlerSink.LastAcquiredBuffer Property

FrameHandlerSink.LastAcquiredBuffer Property

Returns the ImageBuffer that contains the last captured frame.
Syntax:
[VB.NET]
Public LastAcquiredBuffer As ImageBuffer
[C#]
public ImageBuffer LastAcquiredBuffer;
Limitations:

Read only.

Remarks:

After stopping or pausing the sink, this method returns the image buffer that contains last acquired frame until the sink is restarted.

If an error occurred, the exception INVALID_MEMBUFFER is thrown.

LastAcquiredBuffer returns NULL in case of an error.

Example:

The following example shows how to save the last acquired image in a JPG file:

[C#]
FrameHandlerSink fhs = new FrameHandlerSink(); fhs.SnapMode = false; ICImagingControl1.Sink = fhs; ICImagingControl1.LiveStart(); // Do something, wait for user action, ... ICImagingControl1.LiveStop(); // Save the last acquired image to a JPG file. fhs.LastAcquiredBuffer.SaveAsJpeg( "last.jpg", 75 );
[VB.NET]
Dim fhs As New FrameHandlerSink fhs.SnapMode = False IcImagingControl1.Sink = fhs IcImagingControl1.LiveStart() ' Do something, wait for user action, ... IcImagingControl1.LiveStop() ' Save the last acquired image to a JPG file. fhs.LastAcquiredBuffer.SaveAsJpeg("last.jpg", 75)
See also: FrameHandlerSink, FrameHandlerSink.ImageBuffers, ImageBuffer

<< FrameHandlerSink

Get in touch with us


About The Imaging Source

Established in 1990, The Imaging Source is one of the leading manufacturers of industrial cameras, frame grabbers and video converters for production automation, quality assurance, logistics, medicine, science and security.

Our comprehensive range of cameras with USB 3.1, USB 3.0, USB 2.0, GigE interfaces and other innovative machine vision products are renowned for their high quality and ability to meet the performance requirements of demanding applications.

Automated Imaging Association ISO 9001:2015 certified

Contact us