Beispiel #1
0
        private void OnImageFrameHandlerEvent(VideoAppAdapterHandler adapterHandler, Image image)
        {
            lock (this)
            {
                _videoFrameHeight = image.Height;
                _videoFrameWidth  = image.Width;

                if (!_videoFrame.IsNull())
                {
                    _videoFrame.Dispose();
                }

                _videoFrame = new Bitmap(image.Width, image.Height);
                Graphics g = Graphics.FromImage(_videoFrame);
                g.DrawImage(image, 0, 0);
                g.Dispose();
            }
            this.pictureBox.Image = image;
        }
Beispiel #2
0
 private void OnCameraNotStartupHandlerEvent(VideoAppAdapterHandler adapterHandler, int errorCode)
 {
     this.ShowTip("视频打开失败,未检测到视频设备!");
 }
Beispiel #3
0
 private void OnImageFrameHandlerEvent(VideoAppAdapterHandler adapterHandler, Image image)
 {
     this.pictureBox.Image = image;
 }