示例#1
0
 public Form1()
 {
     InitializeComponent();
     m_nDeviceNum    = 0;
     m_nDeviceCurSel = -1;
     // 初始化动态库
     KSJApiBase.KSJ_Init();
     previewCallBack   = new KSJApiCallback.KSJ_PREVIEWCALLBACK(PreviewCallback);
     previewCallBackEx = new KSJApiCallback.KSJ_PREVIEWCALLBACKEX(PreviewCallbackEx);
 }
示例#2
0
        private void CheckBox_SET_CALLBACK_CheckedChanged(object sender, EventArgs e)
        {
            previewCallBack = new KSJApiCallback.KSJ_PREVIEWCALLBACK(PreviewCallback);
            bool bCheck = CheckBox_SET_CALLBACK.Checked;

            if (bCheck)
            {
                KSJApiCallback.KSJ_PreviewSetCallback(m_nDeviceCurSel, previewCallBack, PictureBox_PREVIEWWND.Handle);
            }
            else
            {
                KSJApiCallback.KSJ_PreviewSetCallback(m_nDeviceCurSel, null, PictureBox_PREVIEWWND.Handle);
            }
        }