National Instruments Image Acqusition Software NI-IMAQdx Manual De Usuario

Descargar
Página de 65
Chapter 2
Basic Acquisition with NI-IMAQdx
2-10
ni.com
Note
If you do not have a valid session, a temporary session is created using 
cam0
Then, the snap acquires the next incoming image into a user buffer. After 
the image is acquired, the program calls image processing and analysis 
functions. When the processing and analysis functions are finished, the 
program calls the Close Camera function using the camera handle. This 
function instructs NI-IMAQdx to free all of the resources associated with 
this camera, which releases the session.
Grab
A grab initiates a continuous high-speed acquisition of images to one or 
more internal buffers. Figure 2-3 illustrates the typical programming order 
of a high-level grab acquisition.
Figure 2-3.  High-Level Grab Flowchart
Use a grab for high-speed applications during which you need to process 
only one image at a time. You can copy the last acquired buffer to a separate 
user buffer for processing or analysis. To use these functions, you must 
have a valid session. If you do not have a valid session, the NI-IMAQdx 
Configure Grab function creates a session using 
cam0
.
Opens and configures camera
Copies contents of internal buffer 
to user buffer; can call grab function 
multiple times for high-speed acquisition
Executes user-specific image processing
Closes the camera session
Configures camera for 
continuous acquisition
(Loop)
Open
Configure Grab
Grab
User-Specific Functions
Close