PXR Family

Datasheet (PDF)

Manual & Guide

Application Notes

Driver Updates

Example Source Code

Compatible Image Processing Software

Product FAQ

All Frame Grabbers

Home Page


Feedback at:
CSinfo@cyberoptics.com or
1-800-366-9131

PXR_GRAB_RT2 - Realtime Display Sample 2

Win32 Systems (Win98, Me, NT, 2000 and XP)

This sample shows you how to grab and display frames in realtime. The PXR800 provides two ways of doing realtime display:
1. Double buffering in software, or
2. Double buffering in hardware..

This sample illustrates method 2. If you are interested in method 1 see PXR_GRAB_RT1.

Method 2:
We allocate a single buffer rather than the two buffers used in RT1. The PXR800 is put into a mode where it is always grabbing another frame in addition to the one that is currently being DMA'd. This gives you the same result as using two buffers in software.

We do not need to set any parameters in order to implement this method. This is the default method for the PXR800. See PXR_GRAB_RT1 for setting the buffering to single.

This method works quite well and will result in a realtime display if a buffer can be copied to the VGA faster than the next grab can take place, which is either 33 or 40 ms depending camera type. Almost any system today can achieve a realtime display by using this method.

In this sample you will learn how to do the following:

1. Create a simple control window.
2. Create a video display window.
3. Initialize the PXR frame grabber.
4. Grab individual frames and display them in the video display window.
5. Grab frames and display them in realtime in the video display window.

In the PXR frame grabber samples, we have decided to use two windows (one for control and one for video display). We do this throughout the samples. We feel that two windows gives you more flexibility in designing controls although it does add some complexity.

This program uses two external modules that will be common to all of our samples for the PXR Series frame grabbers.
1. PXR_DISPLAY.C -- video display common code
2. PXR_FILERW.C -- file read/write common code