修复获取设备信息信令Catalog不标准问题 PTZType,级联的Longitude、Latitude、PTZType等
This commit is contained in:
parent
726963ba77
commit
206f47f42a
@ -222,7 +222,13 @@ public class SIPCommanderFroPlatform implements ISIPCommanderForPlatform {
|
||||
catalogXml.append("<Secrecy>" + channel.getSecrecy() + "</Secrecy>\r\n");
|
||||
catalogXml.append("<RegisterWay>" + channel.getRegisterWay() + "</RegisterWay>\r\n");
|
||||
catalogXml.append("<Status>" + (channel.getStatus() == 0?"OFF":"ON") + "</Status>\r\n");
|
||||
catalogXml.append("<Info></Info>\r\n");
|
||||
catalogXml.append("<Longitude>" + channel.getLongitude() + "</Longitude>\r\n");
|
||||
catalogXml.append("<Latitude>" + channel.getLatitude() + "</Latitude>\r\n");
|
||||
catalogXml.append("<IPAddress>" + channel.getIpAddress() + "</IPAddress>\r\n");
|
||||
catalogXml.append("<Port>" + channel.getPort() + "</Port>\r\n");
|
||||
catalogXml.append("<Info>\r\n");
|
||||
catalogXml.append("<PTZType>" + channel.getPTZType() + "</PTZType>\r\n");
|
||||
catalogXml.append("</Info>\r\n");
|
||||
}
|
||||
|
||||
|
||||
|
@ -166,10 +166,11 @@ public class CatalogResponseMessageHandler extends SIPRequestProcessorParent imp
|
||||
} else {
|
||||
deviceChannel.setLatitude(0.00);
|
||||
}
|
||||
if (getText(itemDevice, "PTZType") == null || getText(itemDevice, "PTZType") == "") {
|
||||
Element InfoNode = channelDeviceElement.element("Info");
|
||||
if (getText(InfoNode, "PTZType") == null || getText(InfoNode, "PTZType") == "") {
|
||||
deviceChannel.setPTZType(0);
|
||||
} else {
|
||||
deviceChannel.setPTZType(Integer.parseInt(getText(itemDevice, "PTZType")));
|
||||
deviceChannel.setPTZType(Integer.parseInt(getText(InfoNode, "PTZType")));
|
||||
}
|
||||
deviceChannel.setHasAudio(true); // 默认含有音频,播放时再检查是否有音频及是否AAC
|
||||
channelList.add(deviceChannel);
|
||||
|
Loading…
Reference in New Issue
Block a user