public void hm_video_display_open_portTest() { UInt32 iResult = 0; UInt32 Temp_iResult = 0; Init(); if (!GetNode_ByIndex(iRootNode, 3)) { Release(); Assert.Fail(); } if (!LoginDev()) { Release(); Assert.Fail(); } if (!OpenRealVideo()) { Release(); Assert.Fail(); } if (!StartOpenVideo()) { Release(); Assert.Fail(); } FrmPlay.MinimizeBox = false; FrmPlay.MaximizeBox = false; FrmPlay.StartPosition = FormStartPosition.CenterScreen; FrmPlay.Width = 640; FrmPlay.Height = 300; FrmPlay.Show(); DISPLAY_OPTION disp_op = new DISPLAY_OPTION(); disp_op.dm = DISPLAY_MODE.HME_DM_DX; disp_op.pq = PIC_QUALITY.HME_PQ_HIGHT; iResult = SDK_HuaMai.hm_video_display_open_port(FrmPlay.Handle, ref disp_op, ref iPort); Thread.Sleep(10000); Temp_iResult = hm_video_display_stop(iPort); Release(); Assert.AreEqual(Convert.ToUInt32(0), iResult); }
public bool DisplayOpenPort() { UInt32 iResult = 0; FrmPlay.MinimizeBox = false; FrmPlay.MaximizeBox = false; FrmPlay.StartPosition = FormStartPosition.CenterScreen; FrmPlay.Width = 640; FrmPlay.Height = 300; //FrmPlay.Show(); DISPLAY_OPTION disp_op = new DISPLAY_OPTION(); disp_op.dm = DISPLAY_MODE.HME_DM_DX; disp_op.pq = PIC_QUALITY.HME_PQ_HIGHT; iResult = SDK_HuaMai.hm_video_display_open_port(FrmPlay.Handle, ref disp_op, ref iPort); if (Convert.ToUInt32(0) == iResult) { return(true); } return(false); }
public static extern UInt32 hm_video_display_open_port(IntPtr iWnd, ref DISPLAY_OPTION option, ref IntPtr iPort);