| | |
| | | using System.Threading; |
| | | using System.Collections.Generic; |
| | | using HDL_ON.UI.UI2.PersonalCenter.PirDevice; |
| | | using HDL_ON.Entity; |
| | | |
| | | #if __IOS__ |
| | | using Shared.IOS.ESVideoOnSDK; |
| | |
| | | int.TryParse(mESVideoInfo.roomno, out roomID); |
| | | |
| | | #if __IOS__ |
| | | if (interphoneType == "IMOUVISIAL") |
| | | if (interphoneType == InterphoneType.IMOUVISIAL.ToString()) |
| | | { |
| | | //乐橙可视对讲 |
| | | //1.初始化LCOpenSDK_Api |
| | |
| | | } |
| | | #else |
| | | Intent intent = null; |
| | | if (interphoneType == "IMOUVISIAL") |
| | | if (interphoneType == InterphoneType.IMOUVISIAL.ToString()) |
| | | { |
| | | intent = new Intent(Shared.Application.Activity, typeof(HDL_ON_Android.LeChengVideoActivity)); |
| | | } |
| | |
| | | int roomID = 0; |
| | | int.TryParse(mESVideoInfo.roomno, out roomID); |
| | | #if __IOS__ |
| | | if (interphoneType == "IMOUVISIAL") |
| | | if (interphoneType == InterphoneType.IMOUVISIAL.ToString()) |
| | | { |
| | | //乐橙可视对讲 |
| | | //1.初始化LCOpenSDK_Api |
| | |
| | | vc.MLCCallDelegate = mOnLCCallDelegate; |
| | | //vc.MLCCallDelegate = new OnLCCallDelegate(this); |
| | | Shared.Application.currentVC.NavigationController.PushViewController(vc, true); |
| | | } |
| | | else if (interphoneType == InterphoneType.EZVIZ.ToString()) |
| | | { |
| | | //萤石猫眼呼叫 |
| | | //初始化萤石云SDK,中文国内key、英文海外key 开发者账号使用应用包名申请的APPKEY,不同包名应用需配置不同的APPKEY |
| | | EZSDK.IOS.EZSDK.InitLibWithAppKey("1aa98a90489b4838b966b57018b4b04b", "1aa98a90489b4838b966b57018b4b04b"); |
| | | //1.设置所需河东的AccessToken和RefreshToken、域名地址 |
| | | EZSDK.IOS.EZSDK.SetHDlAccessToken(UserInfo.Current.LoginTokenString, UserInfo.Current.RefreshToken); |
| | | |
| | | EZSDK.IOS.EZSDK.SetRequestHttpsHostAndPlatform(OnAppConfig.Instance.RequestHttpsHost, 1, mESVideoInfo.HomeId); |
| | | //2.设置萤石子账号的AccessToken到SDK |
| | | EZSDK.IOS.EZSDK.SetEZAccessToken(mESVideoInfo.Lc_AccessToken); |
| | | //3.打开视频播放页面 |
| | | EZSDK.IOS.EZSDK.PlayWithDeviceSerial(mESVideoInfo.DeviceSerial); |
| | | |
| | | } |
| | | else |
| | | { |
| | |
| | | #region |
| | | |
| | | Intent intent = null; |
| | | if (interphoneType == "IMOUVISIAL") |
| | | if (interphoneType == InterphoneType.IMOUVISIAL.ToString()) |
| | | { |
| | | intent = new Intent(Shared.Application.Activity, typeof(HDL_ON_Android.LeChengVideoActivity)); |
| | | } else if (interphoneType == InterphoneType.EZVIZ.ToString()) |
| | | { |
| | | //萤石猫眼呼叫处理 |
| | | } |
| | | else |
| | | { |
| | |
| | | } |
| | | |
| | | #endregion |
| | | |
| | | |
| | | #endif |
| | | |
| | | /// <summary> |
| | | /// 测试方法 |
| | | /// </summary> |
| | | /// <param name="isMonitor"></param> |
| | | public void Test(bool isMonitor = true) |
| | | { |
| | | ESVideoInfo eSVideoInfo = new ESVideoInfo() |
| | | { |
| | | DeviceName = "室外机88", |
| | | ESVideoUUID = "JJY000019VPLLF", |
| | | ///// <summary> |
| | | ///// 测试方法 |
| | | ///// </summary> |
| | | ///// <param name="isMonitor"></param> |
| | | //public void Test(bool isMonitor = true) |
| | | //{ |
| | | // ESVideoInfo eSVideoInfo = new ESVideoInfo() |
| | | // { |
| | | // DeviceName = "室外机88", |
| | | // ESVideoUUID = "JJY000019VPLLF", |
| | | |
| | | }; |
| | | if (isMonitor) |
| | | { |
| | | ShowESVideoMonitor(eSVideoInfo, ""); |
| | | } |
| | | else |
| | | { |
| | | eSVideoInfo.callId = "88888"; |
| | | ShowESvideoVideoIntercom(eSVideoInfo, ""); |
| | | } |
| | | // }; |
| | | // if (isMonitor) |
| | | // { |
| | | // ShowESVideoMonitor(eSVideoInfo, ""); |
| | | // } |
| | | // else |
| | | // { |
| | | // eSVideoInfo.callId = "88888"; |
| | | // ShowESvideoVideoIntercom(eSVideoInfo, ""); |
| | | // } |
| | | |
| | | } |
| | | //} |
| | | } |
| | | |
| | | /// <summary> |
| | |
| | | |
| | | |
| | | //========================大华========================== |
| | | |
| | | /// <summary> |
| | | /// 账号accessToken |
| | | /// 萤石子账号Token也共用这个字段 |
| | | /// </summary> |
| | | public string Lc_AccessToken = string.Empty; |
| | | |
| | |
| | | /// 账号标记:0国内,1国外;国内国外访问都地址不一样 |
| | | /// </summary> |
| | | public int Lc_Location = 0; |
| | | |
| | | //========================萤石云猫眼========================== |
| | | /// <summary> |
| | | /// 住宅Id |
| | | /// </summary> |
| | | public string HomeId = string.Empty; |
| | | /// <summary> |
| | | /// 设备序列号 |
| | | /// </summary> |
| | | public string DeviceSerial = string.Empty; |
| | | |
| | | |
| | | } |
| | | |
| | |
| | | /// 大华可视对讲平台 |
| | | /// </summary> |
| | | IMOUVISIAL, |
| | | /// <summary> |
| | | /// 萤石猫眼呼叫 |
| | | /// </summary> |
| | | EZVIZ, |
| | | |
| | | |
| | | } |
| | | } |