Exemplo n.º 1
0
        public CHKDVRBackPlayer(IVideoSourceConfig config, CHKDVRDevice device, IVideoSourceFactory factory, string fileName, IntPtr hWnd)
            : base(config, device, factory)
        {
            RecordFile = new CHKDVRRecordFile(device);
            RecordFile.RemoteFileName = fileName;

            HWnd = hWnd;
            if (HWnd == IntPtr.Zero)
            {
                if (mPanel == null)
                {
                    mPanel = new Panel();
                }

                HWnd = mPanel.Handle;
            }
            mType = 1;

            Target = fileName;
        }
Exemplo n.º 2
0
        public CHKDVRBackPlayer(IVideoSourceConfig config, CHKDVRDevice device, IVideoSourceFactory factory, int channel, ref DateTime startTime, ref DateTime stopTime, IntPtr hWnd)
            : base(config, device, factory)
        {
            RecordFile           = new CHKDVRRecordFile(device);
            RecordFile.Channel   = channel;
            RecordFile.StartTime = startTime;
            RecordFile.StopTime  = stopTime;

            HWnd = hWnd;
            if (HWnd == IntPtr.Zero)
            {
                if (mPanel == null)
                {
                    mPanel = new Panel();
                }

                HWnd = mPanel.Handle;
            }

            mType = 2;

            mTStartTime         = startTime;
            mStartTime.dwYear   = startTime.Year;
            mStartTime.dwMonth  = startTime.Month;
            mStartTime.dwDay    = startTime.Day;
            mStartTime.dwHour   = startTime.Hour;
            mStartTime.dwMinute = startTime.Minute;
            mStartTime.dwSecond = startTime.Second;

            mTStopTime         = stopTime;
            mStopTime.dwYear   = stopTime.Year;
            mStopTime.dwMonth  = stopTime.Month;
            mStopTime.dwDay    = stopTime.Day;
            mStopTime.dwHour   = stopTime.Hour;
            mStopTime.dwMinute = stopTime.Minute;
            mStopTime.dwSecond = stopTime.Second;

            Target = (Int32)channel;
        }