Foxtable(狐表)用户栏目专家坐堂 → 拍照


  共有2411人关注过本帖平板打印复制链接

主题:拍照

帅哥哟,离线,有人找我吗?
kaituozhe
  1楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:九尾狐 帖子:2232 积分:15257 威望:0 精华:0 注册:2015/7/18 10:10:00
拍照  发帖心情 Post By:2019/9/10 20:57:00 [只看该作者]

这是一个例子,可以打开扫描仪,但是不能拍照,原因是在以下黄色部分代码执行时出现了错误,是什么原因?

Dim pic As WinForm.PictureBox = e.Form.Controls("PicView")
Dim pic2 As WinForm.PictureBox = e.Form.Controls("PicView2")
Dim cam As WinForm.Control = e.Form.Controls("CamView")
Dim box As WinForm.Control = e.Form.Controls("LineBox")
msgbox(1)
'预览框尺寸
Dim x As Integer = cam.Left
Dim y As Integer = cam.Top
Dim w As Integer = cam.Width
Dim h As Integer = cam.Height
'截图框尺寸
Dim x1 As Integer = box.Left
Dim y1 As Integer = box.Top
Dim w1 As Integer = box.Width
Dim h1 As Integer = box.Height
msgbox(2)
'摄像头拍照
_Cap.GrapImg()
msgbox(5)
pic.Image = _Cap.GetBitmap()
msgbox(4)
'摄像头分辨率
msgbox(pic.Image.Width)
Dim camw As Integer = pic.Image.Width

Dim camh As Integer = pic.Image.Height

 下载信息  [文件大小:   下载次数: ]
图片点击可在新窗口打开查看点击浏览该文件:摄像头拍照 (1).zip


 回到顶部
总数 24 1 2 3 下一页