ReleaseImage Method
Syntax
CWIMAQ.ReleaseImage
Return Type
This method returns 0 on success, a negative number on an error, and a positive number on a warning.
Purpose
Releases an image that you held out of a live acquisition with the ExtractImage method.
Remarks
Call this method to re-enter an image into a continuous ring image pool after analysis.
Example
' This example requires you to have the following controls on the form:
' 1) A button named Acquire.
' 2) A button named Stop.
' 3) A button named Process.
' 4) A CWIMAQ control named CWIMAQ1
Private Sub Acquire_Click()
CWIMAQ1.Start
End Sub
Private Sub Form_Load()
'Setup a ring acquisition
CWIMAQ1.Images.Add (5)
CWIMAQ1.AcquisitionType = cwimaqAcquisitionContinuous
End Sub
Private Sub Process_Click()
Dim ImageToExtract
Dim ImageIndex
'Extract an image
ImageToExtract = CWIMAQ1.LastValidFrame + 5
CWIMAQ1.ExtractImage ImageToExtract, ImageIndex
'Do processing on extracted image CWIMAQ1.Images(ImageIndex)
'Release the extracted image
CWIMAQ1.ReleaseImage
End Sub
Private Sub Stop_Click()
CWIMAQ1.Stop
End
End Sub