Skip to content

Examples

Framegrabber API Examples#

The Framegrabber SDK installation comes with several examples in the subdirectory SDKExamples. Some examples are located in a subdirectory called vs10. The examples come with project files for Visual Studio 2010 or newer and CMakeLists.txt files to generate build files for various other compilers and development environments using CMake. See Prerequisites for more details on projects and how to use CMake.

The project in the subdirectory SDKExamples/SimpleExample is a starting point for a first project using the frame grabber library fglib5.

The subdirectory SDKExamples/GenICam contains several projects to get started using the camera control library siso_genicam.

To get started using the image input/output library iolibrt, the subdirectory SDKExamples/SisoIoLib provides one example project.

The subdirectory SDKExamples/Functionality provides more in-depth examples for various topics of the frame grabber control library fglib5.

The following table gives an overview which examples are available and what these examples demonstrate:

Example Name Description
CameraLink\ClSer An example for using the Camera Link serial interface library clsersis.lib, which is used to communicate with a camera connected to a Camera Link frame grabber.
Functionality\Acquisition_mode This folder contains the examples for the acquisition modes ACQ_STANDARD, ACQ_BLOCK, and ACQ_SELECT with and without asynchronous procedure call.
Functionality\Acquisition_mode\AcqAPCStandard An example for the acquisition model ACQ_STANDARD with an APC handler to retrieve a frame index.
Functionality\Acquisition_mode\AcqAPCBlock An example for the acquisition model ACQ_BLOCK with an APC handler to retrieve FG_IMAGE_NUMBER via Fg_getParameterEx, and to unblock a buffer via Fg_setStatusEx
Functionality\Acquisition_mode\AcqAPCSelect An example for the acquisition model ACQ_SELECT with an APC handler for selecting the next buffer via Fg_setStatusEx.
Functionality\Acquisition_mode\AcqStandard An example for the acquisition model ACQ_STANDARD with a simple acquisition loop.
Functionality\Acquisition_mode\AcqBlock An example for the acquisition model ACQ_BLOCK with a simple acquisition loop.
Functionality\Acquisition_mode\AcqSelect An example for the acquisition model ACQ_SELECT with a simple acquisition loop.
Functionality\Basic_Parametrization An example for setting and getting parameters such as width, height, pixel format or alignment.
Functionality\Configuration_file This folder contains the examples for using microEnable Configuration Files (MCFs).
Functionality\Configuration_file\ConfigFileInit An example for initializing frame grabbers via parameters in an MCF file.
Functionality\Configuration_file\ConfigFileLoad An example for loading parameters from an MCF file for initialized frame grabber.
Functionality\Data_Format This folder contains the examples for several pixel formats. For mE5 Boards, the available data format depends on the selected applet.
Functionality\Data_Format\Gray8 An example for setting the pixel format FG_GRAY for the tap format FG_CL_SINGLETAP_8_BIT in a grayscale applet for a BASE camera.
Functionality\Data_Format\Gray16 An example for setting the pixel format FG_GRAY16 for the tap format FG_CL_SINGLETAP_16_BIT in a grayscale applet for a BASE camera.
Functionality\Data_Format\MediumGray An example for setting the pixel format FG_GRAY for the tap format FG_CL_MEDIUM_8_BIT in a grayscale applet for a MEDIUM camera.
Functionality\Data_Format\MediumGray16 An example for setting the pixel format FG_GRAY16 for the tap format FG_CL_MEDIUM_16_BIT in a grayscale (gray-16) applet for a MEDIUM camera.
Functionality\Data_Format\MediumRGB24 An example for setting the pixel format FG_COL24 for the tap format FG_CL_MEDIUM_RGB_30 in an RGB applet for a MEDIUM camera.
Functionality\Data_Format\MediumRGB48 An example for setting the pixel format FG_COL48 for the tap format FG_CL_MEDIUM_RGB_30 in an RGB applet for a MEDIUM camera.
Functionality\Data_Format\RGB24 An example for setting the pixel format FG_COL24 for the tap format FG_CL_MEDIUM_RGB_30 in an RGB (RGB36) applet for a MEDIUM camera.
Functionality\Events This folder contains the examples for the event subsystem.
Functionality\Events\EventSubsystemAsync An example for using the event subsystem with the asynchronous event interface.
Functionality\Events\EventSubsystemSync An example for using the event subsystem with the synchronous event interface.
Functionality\Info This folder contains the examples for several ways to retrieve frame and acquisition information.
Functionality\Info\BoardInformation An example for listing board type, board name and board serial.
Functionality\Info\ImageTag An example for retrieving image tag information for each image.
Functionality\Info\SystemInfo An example for retrieving system information, such as number of board, name, index, type, serial, status, PCI payload mode or versions of firmware and driver.
Functionality\Info\TimeStamps An example for retrieving time stamp and acquisition duration for each image.
Functionality\KneeLut This folder contains the examples for handling lookup tables.
Functionality\KneeLut\KneeLutGray An example for initializing and setting a gray value lookup table.
Functionality\KneeLut\KneeLutGrayFile An example for saving a single component KneeLUT to a file and for reading this file.
Functionality\KneeLut\KneeLutRGB An example for initializing and setting the RGB value lookup table.
Functionality\KneeLut\KneeLutRGBFile An example for saving a three component KneeLUT to a file and for reading this file.
Functionality\MasterSlave This folder contains the examples for interactions between master and slave processes accessing the same frame grabber.
Functionality\MasterSlave\Master An example for the frame grabber in master mode and for grabbing images in standard acquisition mode on port A.
Functionality\MasterSlave\Slave An example for the frame grabber in slave mode and for grabbing images in standard acquisition mode on port B.
Functionality\Memory_management This folder contains the examples for showing the differences of basic, advanced and flexible memory management.
Functionality\Memory_management\AllocMem An example for basic memory management which is only available in ACQ_STANDARD mode.
Functionality\Memory_management\AllocMemEx An example for advanced memory management which allocates one contiguous block of memory subdivided in equal frame buffers.
Functionality\Memory_management\AllocUserMem An example for flexible memory management which is similar to advanced mode, but offers dynamic memory allocation per buffer.
Functionality\Operation_mode This folder contains the examples for comparing several ways to trigger an acquisition from external and internal generators.
Functionality\Operation_mode\AreaExternal An example for acquisition of frames started from an external trigger source.
Functionality\Operation_mode\AreaFreeRun An example for acquisition started in free run, as fast as the camera can provide frames.
Functionality\Operation_mode\AreaGrabberControl An example for frame grabber-controlled acquisition, which means that the frame grabber actively requests frames from the camera.
Functionality\Operation_mode\AreaSoftware An example for acquisition of frames started from a software trigger.
Functionality\Operation_mode\LineFreeRunImg An example for acquisition started in free run, as fast as the camera can provide lines.
Functionality\Operation_mode\LineGatedAsyncTriggerLine An example for acquisition via external trigger controlled by a gated line trigger.
Functionality\Operation_mode\LineGatedGrabberControlledLine An example for acquisition via the frame grabber controlled by a gated line trigger.
Functionality\Operation_mode\LineGrabberControlledLine An example for acquisition via the frame grabber controlled by a line trigger.
Functionality\Operation_mode\LineStartTriggerImage An example for image acquisition started via an asynchronous external trigger.
Functionality\Operation_mode\LineStartTriggerLine An example for line acquisition started via an asynchronous external trigger.
Functionality\Operation_mode\LineTriggerGatedImg An example for image acquisition started via a gated asynchronous external trigger.
Functionality\Operation_mode\LineTriggerGatedMultiBufferImg An example for image multi buffer acquisition started via a gated asynchronous external trigger.
Functionality\SensorReadout An example for accessing various sensor readouts from the board.
GenICam\BoardEvents An example for receiving various GenICam events from the frame grabber during camera discovery, e.g., link speed.
GenICam\CameraDiscovery An example for reading GenICam information from the camera, e.g., vendor name or serial number.
GenICam\ImageAcquisition An example for GenICam-compliant configuration and acquisition.
GenICam\UsingGenApi An example for accessing the GenICam nodemap through GenApi.
SDKWrapper\CSharpWrapper This folder contains the examples for the C# Wrapper.
SDKWrapper\CSharpWrapper\AcqAPC An example in C# for defining an asynchronous procedure call and starting acquisition.
SDKWrapper\CSharpWrapper\FgEvents An example in C# for registering events.
SDKWrapper\CSharpWrapper\MyFirstSDK An example in C# for acquiring images via ACQ_STANDARD from the CameraSimulator.
SDKWrapper\PythonWrapper This folder contains the examples for the Python Wrapper.
SDKWrapper\PythonWrapper\AcqAPC An example in python for defining an asynchronous procedure call, iterate boards and applets and start acquisition.
SDKWrapper\PythonWrapper\MyFirstSDK An example in python for configuring and starting acquisition.
SimpleExample A small example for an ACQ_STANDARD acquisition.
SisoIoLib An example for loading and saving images using the iolibrt.
GPUDIRECT This folder contains the examples for interacting with NVIDIA GPUDirect for video.
GPUDIRECT\cuda_example_cxp An example for initializing the frame grabber via a GenICam and CUDA device to apply a fish-eye kernel.
GPUDIRECT\simple_cuda_example An example for initializing a CUDA device and frame grabber and announcing a buffer location via GDAnnounceCUDAArray.