1.  PIXCI® Frame Grabbers: Use with National Instruments LabView

National Instruments LabView’s Virtual Instruments (VI) can gain control of PIXCI® frame grabbers and access image data via the XCLIB SDK/Library, provided as a Windows DLL. National Instruments supports invoking named functions in a named DLL; a header (.h) file provided with XCLIB declares the available functions in a LabView compatible format.

Installation

In LabView 32-bit, use

    Tools
    Import
    Shared Library (.dll)...
    Select Create VIs for a Shared Library
    Next

In field:

    Shared Library (.dll) File

specify the XCLIB 32 bit DLL:

    ...\XCLIB\Lib\XCLIBWNT.DLL

replacing ‘...’ with XCLIB’s installation directory, typically:

    C:\Program Files\EPIX

In field:

    Header (.h) File

specify the XCLIB header file:

    ...\XCLIB\Inc\XCLIBWNT_LABVIEW.H

If using the optional PXIPL library, repeat importing of a shared library and specify the PXIPL 32 bit DLL and Header:

    ...\XCLIB\Lib\PXIPLWNT.DLL
    ...\XCLIB\Inc\PXIPLWNT_LABVIEW.H

Finally, click through the remainder of LabView’s ‘Import Shared Library Wizard’ using the default settings.

After Importing, there should be a collection of VI’s each correlating directly to one XCLIB /or PXIPL function.

The above references to ‘XCLIBWNT.DLL’, ‘XCLIBWNT_LABVIEW.H’, ‘PXIPLWNT.DLL’, and/or ‘PXIPLWNT_LABVIEW.H’ are for XCLIB 32 bit and/or PXIPLWNT 32 bit. Alternates are:

    XCLIBWNT.DLL          for XCLIB 32 bit
    XCLIBW64.DLL          for XCLIB 64 bit
    XCLYBWNT.DLL          for XCLIB-Lite 32 bit
    XCLYBW64.DLL          for XCLIB-Lite 64 bit
    PXIPLWNT.DLL          for PXIPL 32 bit
    PXIPLW64.DLL          for PXIPL 64 bit
    XCLIBWNT_LABVIEW.H    for XCLIB 32 bit
    XCLIBW64_LABVIEW64.H  for XCLIB 64 bit
    XCLYBWNT_LABVIEW.H    for XCLIB-Lite 32 bit
    XCLYBW64_LABVIEW64.H  for XCLIB-Lite 64 bit
    PXIPLWNT_LABVIEW.H    for PXIPL 32 bit
    PXIPLW64_LABVIEW64.H  for PXIPL 64 bit

The bit depth must match LabView’s bit depth, not Window’s bit depth.

The location of XCLIB within the file system may vary, depending on system settings and options chosen during installation of XCLIB. Typically, XCLIB 32 bit on Windows 32 bit, or XCLIB 64 bit on Windows 64 bit is in:

    C:\Program Files\EPIX\XCLIB\Lib\XCLIBWNT.DLL
    C:\Program Files\EPIX\XCLIB\Inc\XCLIBWNT_LABVIEW.H


    C:\Program Files\EPIX\XCLIB\Lib\XCLIBW64.DLL
    C:\Program Files\EPIX\XCLIB\Inc\XCLIBW64_LABVIEW64.H

Typically, XCLIB 32 bit on Windows 64 bit may be located in:

    C:\Program Files (x86)\EPIX\XCLIB\Lib\XCLIBWNT.DLL
    C:\Program Files (x86)\EPIX\XCLIB\Inc\XCLIBWNT_LABVIEW.H

And older XCLIB installations may be located in:

    C:\XCLIB\XCLIBWNT.DLL
    C:\XCLIB\XCLIBWNT_LABVIEW.H

Examples

Two examples of using PIXCI® frame grabbers from LabView are provided with XCLIB. These are intended to be ‘skeletons’; working examples intended to be modified to fit your application requirements. The examples are intended to be used with LabView 32-bit.

LabView supports several levels of error reporting, starting with no reporting. The ‘example_01’ uses VIs created without error wires. The ‘example_02’ uses VIs created with level 1 error reporting. Typically, VIs for different levels of error reporting are not interchangeable; different sets of VIs would be needed to match different selections of error reporting. (As to whether there are exceptions or methods for conversion - consult National Instruments).

Note that ‘example_02’ requires the free ‘NI−IMAQ’ software package from National Instruments. Note that the ‘example_02’ display routine expects 8 bit pixel values (i.e. 8 bit monochrome, or 24 bit RGB); it can be modified for use with other pixel depths by using the BMP format instead of TIFF (BMP files are always saved as 8 bit values, required by the NI display routine used, while TIFF files are (by default) saved at the video format’s bit depth). Or, modify the parameters used to save the TIFF file, specifically savemode=8, so as to force saving 8 bits.

Both examples use pxd_PIXCIopen to open XCLIB and configure for a ‘default’ video format, which may or may not be appropriate for the camera in-hand. See the discussion of the pxd_PIXCIopen function and/or the Using a Video Format Configuration Exported by XCAP application note in the XCLIB Reference Manual. In brief, if the ‘default’ video configuration is not appropriate, (a) Run the XCAP GUI application, configure camera and PIXCI® frame grabber as desired, and export the video configuration using PIXCI®, PIXCI® Export Video Setup. (b) In the VIs’ call to pxd_PIXCIopen use

    pxd_PIXCIopen(..., "", pathnameToVideoSetup.fmt);

Reading XCLIB’s C/C++ examples can be helpful to learn which XCLIB functions are used, and how they are used, for various tasks. In particular, the C examples are linear code and easier to read; in contrast to the GUI structure built by the C++ examples.

Alternatives

LabView can also acquire images via Windows’ Media Foundation[1] or DirectShow API’s. A suitable driver for PIXCI® frame grabbers is available; see PIXCI® Imaging Drivers: Media Foundation Frame Server (Windows ’Camera’ Device & DirectShow Source). XCLIB is not required for use of the MF driver. An optional National Instruments package may be required for support for Media Foundation or DirectShow API’s.

Compatibility

All PIXCI® frame grabbers supported by XCLIB, under all versions of Windows supported by XCLIB, can be utilized from LabView.

Tech Support

For general questions regarding National Instruments LabView, consult National Instruments or search for relevant topics via Google or other search engines.

For questions specifically related to PIXCI® frame grabbers and the XCLIB SDK/Library, email support@epixinc.com .

Copyright (C) EPIX, Inc. All Rights Reserved

Updated: 27 March 2023

Footnotes __________

1. The Windows Media Foundation (MF) is the successor to Windows Direct-
Show.