// 登录DVR系统 public bool Login() { LPXNS_DEV_DEVICEINFO lp = new LPXNS_DEV_DEVICEINFO(); string content = "123"; IntPtr intptr = Marshal.AllocHGlobal(Marshal.SizeOf(lp)); Marshal.StructureToPtr(lp, intptr, true); _dev_handle = SSNetSDK.XNS_DEV_Login (_ip, _port, _user_name, _password, _model_name , ref content, intptr, true, 10006); if (_dev_handle == 0) { return(false); } return(true); }
public static extern bool XNS_DEV_GetDevInfo(uint ulDeviceHandle, LPXNS_DEV_DEVICEINFO lpDeviceInfo);
// 登录DVR系统 public bool Login() { LPXNS_DEV_DEVICEINFO lp = new LPXNS_DEV_DEVICEINFO(); string content = "123"; IntPtr intptr = Marshal.AllocHGlobal(Marshal.SizeOf(lp)); Marshal.StructureToPtr(lp, intptr, true); _dev_handle = SSNetSDK.XNS_DEV_Login (_ip, _port, _user_name, _password, _model_name , ref content, intptr, true, 10006); if (_dev_handle == 0) return false; return true; }