Halcom 发表于 2016-11-2 22:46:11

打开摄像头拍照

* Image Acquisition 01: Code generated by Image Acquisition 01
open_framegrabber ('DirectShow', 1, 1, 0, 0, 0, 0, 'default', 8, 'rgb', -1, 'false', 'default', ' HP TrueVision HD', 0, -1, AcqHandle)
grab_image_start (AcqHandle, -1)
for i :=0 to 100 by 1
    grab_image_async (Image, AcqHandle, -1)
    * Image Acquisition 01: Do something
endfor
close_framegrabber (AcqHandle)


注意:
有时候我们使用1394接口的相机,需要设置open_framegrabber的拍照比例时,例如最大化7:0:0,此时可能只能显示灰度图,我们需要将其置为7:0:4
页: [1]
查看完整版本: 打开摄像头拍照