Grab of an image from the specified frame grabber and start of the asynchronous grab of the next image.
The operator ::grab_image_async grabs an image via theframe grabber specified by FGHandle and starts the asynchronous grab of the next image. The desired operational mode of the frame grabber as well as a suitable image area can be adjusted via the operator ::open_framegrabber. Additional (frame grabber specific) settings might be possible via ::set_framegrabber_param. The grab of the next image is finished via ::grab_image or again via ::grab_image_async. If more than MaxDelay ms have passed since the asynchronous grab was started, a new image is grabbed (the asynchronously grabbed image is considered as too old). If a negative value is assigned to MaxDelay this control mechanism is deactivated.
|
Image (output_object) |
image -> Hobject * : HImage |
| Grabbed image. | |
|
FGHandle (input_control) |
framegrabber -> HTuple.long |
| Handle of the frame grabber to be used. | |
|
MaxDelay (input_control) |
number -> HTuple.double |
| Maximum tolerated delay beteween the start of the asynchronous grab and the delivery of the image [ms]. | |
| Default value: -1.0 | |
| Suggested values: -1.0, 20.0, 33.3, 40.0, 66.6, 80.0, 99.9 | |
/* Select a suitable frame grabber FgName */
info_framegrabber(FgName,"ports",&Information,&Val) ;
/* Choose the port P and the input line L your camera is connected to */
open_framegrabber(FgName,1,1,0,0,0,0,"default",-1,"default",-1.0,
"default","default","default",P,L,&FgHandle) ;
/* grab image + start next grab */
grab_image_async(&Img,FgHandle,-1.0) ;
/* Process Img ... */
/* Finish asynchronous grab + start next grab */
grab_image_async(Img,FgHandle,-1.0) ;
close_framegrabber(FgHandle) ;
If the frame grabber is open and supports asynchronous grabbing the operator ::grab_image_async returns the value H_MSG_TRUE. Otherwise an exception handling is raised.
::grab_image, ::grab_image_async, ::close_framegrabber
::grab_image_start, ::open_framegrabber, ::info_framegrabber, ::set_framegrabber_param
Image / region / XLD management