1)用capCreateCaptureWindow创建视频捕捉窗口。 2)用capDriverConnect()连接摄像头驱动 3)用capPreview()开始预览 ok~'// The two functions exported by AVICap Declare Function capCreateCaptureWindowA Lib "avicap32.dll" ( _ ByVal lpszWindowName As String, _ ByVal dwStyle As Long, _ ByVal x As Long, ByVal y As Long, ByVal nWidth As Long, ByVal nHeight As Integer, _ ByVal hWndParent As Long, ByVal nID As Long) As LongFunction capDriverConnect(ByVal lwnd As Long, ByVal i As Integer) As Boolean capDriverConnect = SendMessage(lwnd, WM_CAP_DRIVER_CONNECT, i, 0) End FunctionFunction capPreview(ByVal lwnd As Long, ByVal f As Boolean) As Boolean capPreview = SendMessage(lwnd, WM_CAP_SET_PREVIEW, f, 0) End Function
1)用capCreateCaptureWindow创建视频捕捉窗口。 2)用capDriverConnect()连接摄像头驱动 3)用capPreview()开始预览 ok~'// The two functions exported by AVICap Declare Function capCreateCaptureWindowA Lib "avicap32.dll" ( _ ByVal lpszWindowName As String, _ ByVal dwStyle As Long, _ ByVal x As Long, ByVal y As Long, ByVal nWidth As Long, ByVal nHeight As Integer, _ ByVal hWndParent As Long, ByVal nID As Long) As LongFunction capDriverConnect(ByVal lwnd As Long, ByVal i As Integer) As Boolean capDriverConnect = SendMessage(lwnd, WM_CAP_DRIVER_CONNECT, i, 0) End FunctionFunction capPreview(ByVal lwnd As Long, ByVal f As Boolean) As Boolean capPreview = SendMessage(lwnd, WM_CAP_SET_PREVIEW, f, 0) End Function
1)用capCreateCaptureWindow创建视频捕捉窗口。 2)用capDriverConnect()连接摄像头驱动 3)用capPreview()开始预览 ok~'// The two functions exported by AVICap Declare Function capCreateCaptureWindowA Lib "avicap32.dll" ( _ ByVal lpszWindowName As String, _ ByVal dwStyle As Long, _ ByVal x As Long, ByVal y As Long, ByVal nWidth As Long, ByVal nHeight As Integer, _ ByVal hWndParent As Long, ByVal nID As Long) As LongFunction capDriverConnect(ByVal lwnd As Long, ByVal i As Integer) As Boolean capDriverConnect = SendMessage(lwnd, WM_CAP_DRIVER_CONNECT, i, 0) End FunctionFunction capPreview(ByVal lwnd As Long, ByVal f As Boolean) As Boolean capPreview = SendMessage(lwnd, WM_CAP_SET_PREVIEW, f, 0) End Function
1)用capCreateCaptureWindow创建视频捕捉窗口。 2)用capDriverConnect()连接摄像头驱动 3)用capPreview()开始预览 ok~'// The two functions exported by AVICap Declare Function capCreateCaptureWindowA Lib "avicap32.dll" ( _ ByVal lpszWindowName As String, _ ByVal dwStyle As Long, _ ByVal x As Long, ByVal y As Long, ByVal nWidth As Long, ByVal nHeight As Integer, _ ByVal hWndParent As Long, ByVal nID As Long) As LongFunction capDriverConnect(ByVal lwnd As Long, ByVal i As Integer) As Boolean capDriverConnect = SendMessage(lwnd, WM_CAP_DRIVER_CONNECT, i, 0) End FunctionFunction capPreview(ByVal lwnd As Long, ByVal f As Boolean) As Boolean capPreview = SendMessage(lwnd, WM_CAP_SET_PREVIEW, f, 0) End Function
2)用capDriverConnect()连接摄像头驱动
3)用capPreview()开始预览
ok~'// The two functions exported by AVICap
Declare Function capCreateCaptureWindowA Lib "avicap32.dll" ( _
ByVal lpszWindowName As String, _
ByVal dwStyle As Long, _
ByVal x As Long, ByVal y As Long, ByVal nWidth As Long, ByVal nHeight As Integer, _
ByVal hWndParent As Long, ByVal nID As Long) As LongFunction capDriverConnect(ByVal lwnd As Long, ByVal i As Integer) As Boolean
capDriverConnect = SendMessage(lwnd, WM_CAP_DRIVER_CONNECT, i, 0)
End FunctionFunction capPreview(ByVal lwnd As Long, ByVal f As Boolean) As Boolean
capPreview = SendMessage(lwnd, WM_CAP_SET_PREVIEW, f, 0)
End Function
2)用capDriverConnect()连接摄像头驱动
3)用capPreview()开始预览
ok~'// The two functions exported by AVICap
Declare Function capCreateCaptureWindowA Lib "avicap32.dll" ( _
ByVal lpszWindowName As String, _
ByVal dwStyle As Long, _
ByVal x As Long, ByVal y As Long, ByVal nWidth As Long, ByVal nHeight As Integer, _
ByVal hWndParent As Long, ByVal nID As Long) As LongFunction capDriverConnect(ByVal lwnd As Long, ByVal i As Integer) As Boolean
capDriverConnect = SendMessage(lwnd, WM_CAP_DRIVER_CONNECT, i, 0)
End FunctionFunction capPreview(ByVal lwnd As Long, ByVal f As Boolean) As Boolean
capPreview = SendMessage(lwnd, WM_CAP_SET_PREVIEW, f, 0)
End Function
2)用capDriverConnect()连接摄像头驱动
3)用capPreview()开始预览
ok~'// The two functions exported by AVICap
Declare Function capCreateCaptureWindowA Lib "avicap32.dll" ( _
ByVal lpszWindowName As String, _
ByVal dwStyle As Long, _
ByVal x As Long, ByVal y As Long, ByVal nWidth As Long, ByVal nHeight As Integer, _
ByVal hWndParent As Long, ByVal nID As Long) As LongFunction capDriverConnect(ByVal lwnd As Long, ByVal i As Integer) As Boolean
capDriverConnect = SendMessage(lwnd, WM_CAP_DRIVER_CONNECT, i, 0)
End FunctionFunction capPreview(ByVal lwnd As Long, ByVal f As Boolean) As Boolean
capPreview = SendMessage(lwnd, WM_CAP_SET_PREVIEW, f, 0)
End Function
2)用capDriverConnect()连接摄像头驱动
3)用capPreview()开始预览
ok~'// The two functions exported by AVICap
Declare Function capCreateCaptureWindowA Lib "avicap32.dll" ( _
ByVal lpszWindowName As String, _
ByVal dwStyle As Long, _
ByVal x As Long, ByVal y As Long, ByVal nWidth As Long, ByVal nHeight As Integer, _
ByVal hWndParent As Long, ByVal nID As Long) As LongFunction capDriverConnect(ByVal lwnd As Long, ByVal i As Integer) As Boolean
capDriverConnect = SendMessage(lwnd, WM_CAP_DRIVER_CONNECT, i, 0)
End FunctionFunction capPreview(ByVal lwnd As Long, ByVal f As Boolean) As Boolean
capPreview = SendMessage(lwnd, WM_CAP_SET_PREVIEW, f, 0)
End Function