• 大小: 5.49MB
    文件类型: .zip
    金币: 2
    下载: 1 次
    发布日期: 2023-11-01
  • 语言: C#
  • 标签: 佳能  c#  

资源简介

含有佳能的DLL 文件。 demo可以进行拍照。

资源截图

代码片段和文件信息

using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Drawing;
using System.Globalization;
using System.IO;
using System.Linq;
using System.Threading;
using EDSDKLib;

namespace CanonSDKTutorial
{
    public class SDKHandler : IDisposable
    {
        #region Variables

        /// 
        /// The used camera
        /// 

        public Camera MainCamera { get; private set; }
        /// 
        /// States if a session with the MainCamera is opened
        /// 

        public bool CameraSessionOpen { get; private set; }
        /// 
        /// States if the LiveView is on or not
        /// 

        public bool IsLiveViewOn { get; private set; }
        /// 
        /// States if LiveView is recorded or not
        /// 

        public bool IsEvfFilming { get; private set; }
        /// 
        /// Directory to where photos will be saved
        /// 

        public string ImageSaveDirectory { get; set; }
        /// 
        /// Handles errors that happen with the SDK
        /// 

        public uint Error
        {
            get { return EDSDK.EDS_ERR_OK; }
            set { if (value != EDSDK.EDS_ERR_OK) throw new Exception(“SDK Error: “ + value); }
        }

        /// 
        /// frame buffer for LiveView recording
        /// 

        private Queue frameBuffer = new Queue(1000);
        /// 
        /// LiveView has to be paused when taking a picture
        /// 

        private bool PauseLiveView;

        #endregion
        
        #region Events

        #region SDK Events

        public event EDSDK.EdsCameraAddedHandler SDKCameraAddedEvent;
        public event EDSDK.EdsobjectEventHandler SDKobjectEvent;
        public event EDSDK.EdsProgressCallback SDKProgressCallbackEvent;
        public event EDSDK.EdsPropertyEventHandler SDKPropertyEvent;
        public event EDSDK.EdsStateEventHandler SDKStateEvent;

        #endregion

        #region Custom Events

        public delegate void CameraAddedHandler();
        public delegate void ProgressHandler(int Progress);
        public delegate void ImageUpdate(Image img);
        public delegate void FloatUpdate(float Value);

        /// 
        /// Fires if a camera is added
        /// 

        public event CameraAddedHandler CameraAdded;
        /// 
        /// Fires if any process reports progress
        /// 

        public event ProgressHandler ProgressChanged;
        /// 
        /// Fires if the LiveView image is updated
        /// 

        public event ImageUpdate LiveViewUpdated;
        /// 
        /// Fires if a new framerate is calculated
        /// 

        public event FloatUpdate frameRateUpdated;

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----
     目录           0  2016-10-17 15:54  CanonSDK\
     目录           0  2016-10-17 21:50  CanonSDK\CanonSDKTutorial\
     文件       55036  2013-11-28 05:57  CanonSDK\CanonSDKTutorial\CameraClasses.cs
     文件        4272  2016-10-17 17:16  CanonSDK\CanonSDKTutorial\CanonSDKTutorial.csproj
     文件         228  2016-10-17 15:26  CanonSDK\CanonSDKTutorial\CanonSDKTutorial.csproj.user
     目录           0  2016-10-17 15:55  CanonSDK\CanonSDKTutorial\EDSDK\
     文件     9752576  2014-08-19 10:13  CanonSDK\CanonSDKTutorial\EDSDK\DPPDLL.dll
     文件      110592  2012-02-06 15:27  CanonSDK\CanonSDKTutorial\EDSDK\DPPLibCom.dll
     文件     2949632  2014-08-19 10:10  CanonSDK\CanonSDKTutorial\EDSDK\DPPRSC.dll
     文件      507904  2014-08-19 10:41  CanonSDK\CanonSDKTutorial\EDSDK\EDSDK.dll
     文件      118784  2014-08-19 10:41  CanonSDK\CanonSDKTutorial\EDSDK\EOSPTPIP.dll
     文件     1069056  2014-08-19 10:41  CanonSDK\CanonSDKTutorial\EDSDK\EdsImage.dll
     文件       49152  2014-08-19 10:41  CanonSDK\CanonSDKTutorial\EDSDK\Interop.IWshRuntimeLibrary.dll
     文件      139264  2014-08-25 13:24  CanonSDK\CanonSDKTutorial\EDSDK\MLib.dll
     文件         124  2016-10-17 15:56  CanonSDK\CanonSDKTutorial\EDSDK\README.txt
     文件      778240  2014-08-25 13:24  CanonSDK\CanonSDKTutorial\EDSDK\Ucs32P.dll
     文件      121588  2016-10-17 15:57  CanonSDK\CanonSDKTutorial\EDSDK.cs
     文件       26164  2013-11-27 00:28  CanonSDK\CanonSDKTutorial\MainForm.Designer.cs
     文件       10080  2016-10-17 21:50  CanonSDK\CanonSDKTutorial\MainForm.cs
     文件        6022  2013-11-27 00:28  CanonSDK\CanonSDKTutorial\MainForm.resx
     文件         513  2013-11-25 20:20  CanonSDK\CanonSDKTutorial\Program.cs
     目录           0  2016-10-15 07:04  CanonSDK\CanonSDKTutorial\Properties\
     文件        1549  2013-11-25 20:19  CanonSDK\CanonSDKTutorial\Properties\AssemblyInfo.cs
     文件        3059  2013-11-25 20:19  CanonSDK\CanonSDKTutorial\Properties\Resources.Designer.cs
     文件        5612  2013-11-25 20:19  CanonSDK\CanonSDKTutorial\Properties\Resources.resx
     文件        1103  2013-11-25 20:19  CanonSDK\CanonSDKTutorial\Properties\Settings.Designer.cs
     文件         249  2013-11-25 20:19  CanonSDK\CanonSDKTutorial\Properties\Settings.settings
     目录           0  2016-10-15 07:04  CanonSDK\CanonSDKTutorial\bin\
     目录           0  2016-10-17 19:26  CanonSDK\CanonSDKTutorial\bin\Debug\
     文件       70144  2016-10-17 21:51  CanonSDK\CanonSDKTutorial\bin\Debug\CanonSDKTutorial.exe
     文件       71168  2016-10-17 21:51  CanonSDK\CanonSDKTutorial\bin\Debug\CanonSDKTutorial.pdb
............此处省略54个文件信息

评论

共有 条评论