Esempio n. 1
0
 /// <summary>
 /// 弹出色彩设置对话框
 /// </summary>
 public void SetCaptureSource()
 {
     AviCapture.CAPDRIVERCAPS caps = new AviCapture.CAPDRIVERCAPS();
     AviCapture.SendMessage(lwndC, AviCapture.WM_CAP_GET_CAPS, AviCapture.SizeOf(caps), ref caps);
     if (caps.fHasDlgVideoSource)
     {
         AviCapture.SendMessage(lwndC, AviCapture.WM_CAP_DLG_VIDEOSOURCE, 0, 0);
     }
 }
Esempio n. 2
0
        /// <summary>
        /// 抓图到文件
        /// </summary>
        /// <param name="path"></param>
        public void GrabImage(string path)
        {
            IntPtr hBmp = Marshal.StringToHGlobalAnsi(path);

            AviCapture.SendMessage(lwndC, AviCapture.WM_CAP_SAVEDIB, 0, hBmp.ToInt32());
        }
Esempio n. 3
0
 /// <summary>
 /// 抓图到剪切板
 /// </summary>
 /// <returns></returns>
 public bool GrabImageToClipBoard()
 {
     return(AviCapture.SendMessage(lwndC, AviCapture.WM_CAP_EDIT_COPY, 0, 0));
 }
Esempio n. 4
0
 private bool capSetVideoFormat(IntPtr hCapWnd, ref AviCapture.BITMAPINFO BmpFormat, int CapFormatSize)
 {
     return(AviCapture.SendMessage(hCapWnd, AviCapture.WM_CAP_SET_VIDEOFORMAT, CapFormatSize, ref BmpFormat));
 }
Esempio n. 5
0
 private bool capOverlay(IntPtr lwnd, bool f)
 {
     return(AviCapture.SendMessage(lwnd, AviCapture.WM_CAP_SET_OVERLAY, f, 0));
 }
Esempio n. 6
0
 private bool capSetCallbackOnFrame(IntPtr lwnd, AviCapture.FrameEventHandler lpProc)
 {
     return(AviCapture.SendMessage(lwnd, AviCapture.WM_CAP_SET_CALLBACK_FRAME, 0, lpProc));
 }
Esempio n. 7
0
 private bool capPreviewRate(IntPtr lwnd, short wMS)
 {
     return(AviCapture.SendMessage(lwnd, AviCapture.WM_CAP_SET_PREVIEWRATE, wMS, 0));
 }
Esempio n. 8
0
 private bool capPreview(IntPtr lwnd, bool f)
 {
     return(AviCapture.SendMessage(lwnd, AviCapture.WM_CAP_SET_PREVIEW, f, 0));
 }
Esempio n. 9
0
 private bool capDriverDisconnect(IntPtr lwnd)
 {
     return(AviCapture.SendMessage(lwnd, AviCapture.WM_CAP_DRIVER_DISCONNECT, 0, 0));
 }
Esempio n. 10
0
 private bool capDriverConnect(IntPtr lwnd, short i)
 {
     return(AviCapture.SendMessage(lwnd, AviCapture.WM_CAP_DRIVER_CONNECT, i, 0));
 }