static void videoInfoFramCallback(int nPort, int nType, string pBuf, int nSize, IntPtr nUser) { //收到信息帧, 0x03 代表GPRS信息 if (nType == 0x03) { VideoForm form = new VideoForm(); Marshal.PtrToStructure(nUser, form); form.m_strInfoFrame[nPort] = pBuf; } }
public ClientDemo() { for (int i = 0; i < 32; i++) { m_videoform[i] = new VideoForm(); this.Controls.Add(this.m_videoform[i]); m_videoform[i].SetWndIndex(i); } InitializeComponent(); devForm = new DevForm(); this.Controls.Add(devForm); devForm.Location = new System.Drawing.Point(880, 10); devForm.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right))); this.comboBox1.SelectedIndex = 1; InitSDK(); reconnect = new System.Timers.ElapsedEventHandler(ReConnect); GC.KeepAlive(reconnect); timerDisconnect.Elapsed += new System.Timers.ElapsedEventHandler(reconnect); ArrayWindow(4); SetActiveWnd(0); }
static void videoInfoFramCallback(int nPort, int nType, string pBuf,int nSize, IntPtr nUser) { //�յ���Ϣ֡, 0x03 ����GPRS��Ϣ if (nType == 0x03) { VideoForm form = new VideoForm(); Marshal.PtrToStructure(nUser, form); form.m_strInfoFrame[nPort] = pBuf; } }