예제 #1
0
 void brief_MoveObjectDClick4OCX(BriefMoveobjInfo obj)
 {
     if (IsHandleCreated && OnBriefObjectPlayBackNote != null)
     {
         OnBriefObjectPlayBackNote(obj.MoveObjID, Convert.ToInt32(obj.MoveObjType), Convert.ToInt32(obj.MoveObjColor), Convert.ToInt32(obj.BeginTimeS.Subtract(new DateTime()).TotalSeconds), Convert.ToInt32(obj.EndTimeS.Subtract(new DateTime()).TotalSeconds));
     }
 }
예제 #2
0
        /// <summary>
        /// 获取当前选中的摘要运动目标信息
        /// </summary>
        /// <param name="sessionId">播放标示句柄</param>
        /// <returns>选中的运动目标相关信息</returns>
        public BriefMoveobjInfo GetSelectBriefMoveObjInfo(int sessionId)
        {
            MyLog4Net.ILogExtension.DebugWithDebugView(MyLog4Net.Container.Instance.Log, string.Format("IVXSDKProtocol VdaSdk_GetSelectBriefMoveObjInfo sessionId:{0}"
                                                                                                       , sessionId
                                                                                                       ));
            TVDASDK_BRIEF_MOVEOBJ_INFO ptBriefMoveObjInfo;

            bool bRet = IVXSDKProtocol.VdaSdk_GetSelectBriefMoveObjInfo(sessionId, out ptBriefMoveObjInfo);

            if (!bRet)
            {
                CheckError();
                // 如果不抛异常, 应该是记录不存在, 返回 null
                return(null);
            }
            BriefMoveobjInfo retVal = new BriefMoveobjInfo();

            retVal.BeginTimeS   = ModelParser.ConvertLinuxTime(ptBriefMoveObjInfo.dwBeginTimeS);
            retVal.EndTimeS     = ModelParser.ConvertLinuxTime(ptBriefMoveObjInfo.dwEndTimeS);
            retVal.MoveObjColor = ptBriefMoveObjInfo.dwMoveObjColor;
            retVal.MoveObjID    = ptBriefMoveObjInfo.dwMoveObjID;
            retVal.MoveObjType  = (E_VDA_MOVEOBJ_TYPE)ptBriefMoveObjInfo.dwMoveObjType;
            MyLog4Net.ILogExtension.DebugWithDebugView(MyLog4Net.Container.Instance.Log, string.Format("IVXSDKProtocol VdaSdk_GetSelectBriefMoveObjInfo ret:{0}"
                                                                                                       + ",BeginTimeS:{1}"
                                                                                                       + ",EndTimeS:{2}"
                                                                                                       + ",MoveObjColor:{3}"
                                                                                                       + ",MoveObjID:{4}"
                                                                                                       + ",MoveObjType:{5}"
                                                                                                       , bRet
                                                                                                       , ptBriefMoveObjInfo.dwBeginTimeS
                                                                                                       , ptBriefMoveObjInfo.dwEndTimeS
                                                                                                       , ptBriefMoveObjInfo.dwMoveObjColor
                                                                                                       , ptBriefMoveObjInfo.dwMoveObjID
                                                                                                       , ptBriefMoveObjInfo.dwMoveObjType
                                                                                                       ));

            return(retVal);
        }
예제 #3
0
        public void ObjectPlayBack()
        {
            try
            {
                HidePlayBackWnd = false;
                RaisePropertyChangedEvent("HidePlayBackWnd");
                bool isselected = Framework.Container.Instance.BriefVideoPlayService.IsSelectBriefMoveObj(m_player.HWnd);
                if (isselected)
                {
                    BriefMoveobjInfo bfinfo = Framework.Container.Instance.BriefVideoPlayService.GetSelectBriefMoveObjInfo(m_player.HWnd);

                    VodInfo info = new VodInfo();
                    info.VideoTaskUnitID = m_currBriefTaskUnitID;
                    info.StartTime       = bfinfo.BeginTimeS;
                    info.IsPlayAllFile   = false;
                    info.EndTime         = bfinfo.EndTimeS;
                    Framework.Container.Instance.EvtAggregator.GetEvent <BriefObjectPlayBackEvent>().Publish(info);;
                }
            }
            catch (SDKCallException ex)
            {
                Common.SDKCallExceptionHandler.Handle(ex, "回溯视频");
            }
        }