)
+// SimpleDateFormat sf2 = new SimpleDateFormat("yyyyMMddHHmmss");
+// String curTime2 = sf2.format(new Date());
+// FileOutputStream AddtionData;
+// String AddtionFile = "../pic" + new String(pAlarmer.sDeviceIP).trim() + curTime2 + "_FCAdditionInfo_" + ".xml";
+// try {
+// Data = new FileOutputStream(AddtionFile);
+// //将字节写入文件
+// ByteBuffer dataBuffer = strFaceSnapMatch.struBlockListInfo.struBlockListInfo.pFCAdditionInfoBuffer.getByteBuffer(0, strFaceSnapMatch.struBlockListInfo.struBlockListInfo.dwFCAdditionInfoLen);
+// byte[] dataByte = new byte[dwBufLen];
+// dataBuffer.rewind();
+// dataBuffer.get(dataByte);
+// Data.write(dataByte);
+// Data.close();
+// } catch (FileNotFoundException e) {
+// e.printStackTrace();
+// } catch (IOException e) {
+// e.printStackTrace();
+// }
+// }
+// //人脸比对报警图片保存,图片格式二进制
+// if ((strFaceSnapMatch.dwSnapPicLen > 0) && (strFaceSnapMatch.byPicTransType == 0)) {
+// SimpleDateFormat sf = new SimpleDateFormat("yyyyMMddHHmmss");
+// String newName = sf.format(new Date());
+// FileOutputStream fout;
+// try {
+// String filename = "../pic/" + newName + "_pSnapPicBuffer" + ".jpg";
+// fout = new FileOutputStream(filename);
+// //将字节写入文件
+// long offset = 0;
+// ByteBuffer buffers = strFaceSnapMatch.pSnapPicBuffer.getByteBuffer(offset, strFaceSnapMatch.dwSnapPicLen);
+// byte[] bytes = new byte[strFaceSnapMatch.dwSnapPicLen];
+// buffers.rewind();
+// buffers.get(bytes);
+// fout.write(bytes);
+// fout.close();
+// } catch (FileNotFoundException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// } catch (IOException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// }
+// }
+// if ((strFaceSnapMatch.struSnapInfo.dwSnapFacePicLen > 0) && (strFaceSnapMatch.byPicTransType == 0)) {
+// SimpleDateFormat sf = new SimpleDateFormat("yyyyMMddHHmmss");
+// String newName = sf.format(new Date());
+// FileOutputStream fout;
+// try {
+// String filename = "../pic/" + newName + "_struSnapInfo_pBuffer1" + ".jpg";
+// fout = new FileOutputStream(filename);
+// //将字节写入文件
+// long offset = 0;
+// ByteBuffer buffers = strFaceSnapMatch.struSnapInfo.pBuffer1.getByteBuffer(offset, strFaceSnapMatch.struSnapInfo.dwSnapFacePicLen);
+// byte[] bytes = new byte[strFaceSnapMatch.struSnapInfo.dwSnapFacePicLen];
+// buffers.rewind();
+// buffers.get(bytes);
+// fout.write(bytes);
+// fout.close();
+// } catch (FileNotFoundException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// } catch (IOException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// }
+// }
+// if ((strFaceSnapMatch.struBlockListInfo.dwBlockListPicLen > 0) && (strFaceSnapMatch.byPicTransType == 0)) {
+// SimpleDateFormat sf = new SimpleDateFormat("yyyyMMddHHmmss");
+// String newName = sf.format(new Date());
+// FileOutputStream fout;
+// try {
+// String filename = "../pic/" + newName + "_fSimilarity_" + strFaceSnapMatch.fSimilarity + "_struBlackListInfo_pBuffer1" + ".jpg";
+// fout = new FileOutputStream(filename);
+// //将字节写入文件
+// long offset = 0;
+// ByteBuffer buffers = strFaceSnapMatch.struBlockListInfo.pBuffer1.getByteBuffer(offset, strFaceSnapMatch.struBlockListInfo.dwBlockListPicLen);
+// byte[] bytes = new byte[strFaceSnapMatch.struBlockListInfo.dwBlockListPicLen];
+// buffers.rewind();
+// buffers.get(bytes);
+// fout.write(bytes);
+// fout.close();
+// } catch (FileNotFoundException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// } catch (IOException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// }
+// }
+// //人脸比对报警图片保存,图片格式URL格式
+// if ((strFaceSnapMatch.dwSnapPicLen > 0) && (strFaceSnapMatch.byPicTransType == 1)) {
+//
+// long offset = 0;
+// ByteBuffer buffers = strFaceSnapMatch.pSnapPicBuffer.getByteBuffer(offset, strFaceSnapMatch.dwSnapPicLen);
+// byte[] bytes = new byte[strFaceSnapMatch.dwSnapPicLen];
+// buffers.rewind();
+// buffers.get(bytes);
+// String SnapPicUrl = new String(bytes);
+// System.out.println("抓拍图URL:" + SnapPicUrl);
+// }
+// if ((strFaceSnapMatch.struSnapInfo.dwSnapFacePicLen > 0) && (strFaceSnapMatch.byPicTransType == 1)) {
+//
+// long offset = 0;
+// ByteBuffer buffers = strFaceSnapMatch.struSnapInfo.pBuffer1.getByteBuffer(offset, strFaceSnapMatch.struSnapInfo.dwSnapFacePicLen);
+// byte[] bytes = new byte[strFaceSnapMatch.struSnapInfo.dwSnapFacePicLen];
+// buffers.rewind();
+// buffers.get(bytes);
+// String SnapPicUrl = new String(bytes);
+// System.out.println("抓拍人脸子图URL:" + SnapPicUrl);
+// }
+// if ((strFaceSnapMatch.struBlockListInfo.dwBlockListPicLen > 0) && (strFaceSnapMatch.byPicTransType == 1)) {
+//
+// long offset = 0;
+// ByteBuffer buffers = strFaceSnapMatch.struBlockListInfo.pBuffer1.getByteBuffer(offset, strFaceSnapMatch.struBlockListInfo.dwBlockListPicLen);
+// byte[] bytes = new byte[strFaceSnapMatch.struBlockListInfo.dwBlockListPicLen];
+// buffers.rewind();
+// buffers.get(bytes);
+// String SnapPicUrl = new String(bytes);
+// System.out.println("人脸库人脸图的URL:" + SnapPicUrl);
+// }
+//
+//
+// break;
+// // 客流量报警信息
+// case HCNetSDK.COMM_ALARM_PDC:
+// HCNetSDK.NET_DVR_PDC_ALRAM_INFO strPDCResult = new HCNetSDK.NET_DVR_PDC_ALRAM_INFO();
+// strPDCResult.write();
+// Pointer pPDCInfo = strPDCResult.getPointer();
+// pPDCInfo.write(0, pAlarmInfo.getByteArray(0, strPDCResult.size()), 0, strPDCResult.size());
+// strPDCResult.read();
+// // byMode=0-实时统计结果(联合体中struStatFrame有效),
+// if (strPDCResult.byMode == 0) {
+// strPDCResult.uStatModeParam.setType(HCNetSDK.NET_DVR_STATFRAME.class);
+// String sAlarmPDC0Info = "实时客流量统计,进入人数:" + strPDCResult.dwEnterNum + ",离开人数:" + strPDCResult.dwLeaveNum +
+// ", byMode:" + strPDCResult.byMode + ", dwRelativeTime:" + strPDCResult.uStatModeParam.struStatFrame.dwRelativeTime +
+// ", dwAbsTime:" + strPDCResult.uStatModeParam.struStatFrame.dwAbsTime;
+// }
+// // byMode=1-周期统计结果(联合体中struStatTime有效),
+// if (strPDCResult.byMode == 1) {
+// strPDCResult.uStatModeParam.setType(HCNetSDK.NET_DVR_STATTIME.class);
+// String strtmStart = "" + String.format("%04d", strPDCResult.uStatModeParam.struStatTime.tmStart.dwYear) +
+// String.format("%02d", strPDCResult.uStatModeParam.struStatTime.tmStart.dwMonth) +
+// String.format("%02d", strPDCResult.uStatModeParam.struStatTime.tmStart.dwDay) +
+// String.format("%02d", strPDCResult.uStatModeParam.struStatTime.tmStart.dwHour) +
+// String.format("%02d", strPDCResult.uStatModeParam.struStatTime.tmStart.dwMinute) +
+// String.format("%02d", strPDCResult.uStatModeParam.struStatTime.tmStart.dwSecond);
+// String strtmEnd = "" + String.format("%04d", strPDCResult.uStatModeParam.struStatTime.tmEnd.dwYear) +
+// String.format("%02d", strPDCResult.uStatModeParam.struStatTime.tmEnd.dwMonth) +
+// String.format("%02d", strPDCResult.uStatModeParam.struStatTime.tmEnd.dwDay) +
+// String.format("%02d", strPDCResult.uStatModeParam.struStatTime.tmEnd.dwHour) +
+// String.format("%02d", strPDCResult.uStatModeParam.struStatTime.tmEnd.dwMinute) +
+// String.format("%02d", strPDCResult.uStatModeParam.struStatTime.tmEnd.dwSecond);
+// String sAlarmPDC1Info = "周期性客流量统计,进入人数:" + strPDCResult.dwEnterNum + ",离开人数:" + strPDCResult.dwLeaveNum +
+// ", byMode:" + strPDCResult.byMode + ", tmStart:" + strtmStart + ",tmEnd :" + strtmEnd;
+// }
+// break;
+// case HCNetSDK.COMM_ALARM_V30: //移动侦测、视频丢失、遮挡、IO信号量等报警信息(V3.0以上版本支持的设备)
+// HCNetSDK.NET_DVR_ALARMINFO_V30 struAlarmInfo = new HCNetSDK.NET_DVR_ALARMINFO_V30();
+// struAlarmInfo.write();
+// Pointer pAlarmInfo_V30 = struAlarmInfo.getPointer();
+// pAlarmInfo_V30.write(0, pAlarmInfo.getByteArray(0, struAlarmInfo.size()), 0, struAlarmInfo.size());
+// struAlarmInfo.read();
+// System.out.println("报警类型:" + struAlarmInfo.dwAlarmType); // 3-移动侦测
+// break;
+// case HCNetSDK.COMM_ALARM_V40: //移动侦测、视频丢失、遮挡、IO信号量等报警信息,报警数据为可变长
+//
+// HCNetSDK.NET_DVR_ALARMINFO_V40 struAlarmInfoV40 = new HCNetSDK.NET_DVR_ALARMINFO_V40();
+// struAlarmInfoV40.write();
+// Pointer pAlarmInfoV40 = struAlarmInfoV40.getPointer();
+// pAlarmInfoV40.write(0, pAlarmInfo.getByteArray(0, struAlarmInfoV40.size()), 0, struAlarmInfoV40.size());
+// struAlarmInfoV40.read();
+// switch (struAlarmInfoV40.struAlarmFixedHeader.dwAlarmType) {
+// case 0:
+// struAlarmInfoV40.struAlarmFixedHeader.ustruAlarm.setType(HCNetSDK.struIOAlarm.class);
+// struAlarmInfoV40.read();
+// System.out.println("信号量报警,报警输入口:"+struAlarmInfoV40.struAlarmFixedHeader.ustruAlarm.struioAlarm.dwAlarmInputNo);
+// break;
+// case 1:
+// System.out.println("硬盘满");
+// break;
+// case 2:
+// System.out.println("信号丢失");
+// break;
+// case 3:
+// String sAlarmType="";
+// struAlarmInfoV40.struAlarmFixedHeader.ustruAlarm.setType(HCNetSDK.struAlarmChannel.class);
+// struAlarmInfoV40.read();
+// int iChanNum = struAlarmInfoV40.struAlarmFixedHeader.ustruAlarm.strualarmChannel.dwAlarmChanNum;
+// sAlarmType = sAlarmType + new String(":移动侦测") + "," + "报警通道个数:" + iChanNum + "," + "报警通道号:";
+//
+// for (int i = 0; i < iChanNum; i++) {
+// byte[] byChannel = struAlarmInfoV40.pAlarmData.getByteArray(i * 4, 4);
+//
+// int iChanneNo = 0;
+// for (int j = 0; j < 4; j++) {
+// int ioffset = j * 8;
+// int iByte = byChannel[j] & 0xff;
+// iChanneNo = iChanneNo + (iByte << ioffset);
+// }
+//
+// sAlarmType = sAlarmType + "+ch[" + iChanneNo + "]";
+// }
+// System.out.println(sAlarmType);
+// break;
+// case 4:
+// System.out.println("硬盘未格式化");
+// break;
+// case 5:
+// System.out.println("读写硬盘出错");
+// break;
+// case 6:
+// System.out.println("遮挡报警");
+// break;
+// case 7:
+// System.out.println("制式不匹配");
+// break;
+// case 8:
+// System.out.println("非法访问");
+// break;
+// }
+//
+// break;
+// case HCNetSDK.COMM_THERMOMETRY_ALARM: //温度报警信息
+// HCNetSDK.NET_DVR_THERMOMETRY_ALARM struTemInfo = new HCNetSDK.NET_DVR_THERMOMETRY_ALARM();
+// struTemInfo.write();
+// Pointer pTemInfo = struTemInfo.getPointer();
+// pTemInfo.write(0, pAlarmInfo.getByteArray(0, struTemInfo.size()), 0, struTemInfo.size());
+// struTemInfo.read();
+// String sThermAlarmInfo = "规则ID:" + struTemInfo.byRuleID + "预置点号:" + struTemInfo.wPresetNo + "报警等级:" + struTemInfo.byAlarmLevel + "报警类型:" +
+// struTemInfo.byAlarmType + "当前温度:" + struTemInfo.fCurrTemperature;
+// System.out.println(sThermAlarmInfo);
+// //可见光图片保存
+// if ((struTemInfo.dwPicLen > 0) && (struTemInfo.byPicTransType == 0)) {
+// SimpleDateFormat sf = new SimpleDateFormat("yyyyMMddHHmmss");
+// String newName = sf.format(new Date());
+// FileOutputStream fout;
+//
+// try {
+// String filename = "../pic/" + newName + "_" + struTemInfo.fCurrTemperature + ".jpg";
+// fout = new FileOutputStream(filename);
+// //将字节写入文件
+// long offset = 0;
+// ByteBuffer buffers = struTemInfo.pPicBuff.getByteBuffer(offset, struTemInfo.dwPicLen);
+// byte[] bytes = new byte[struTemInfo.dwPicLen];
+// buffers.rewind();
+// buffers.get(bytes);
+// fout.write(bytes);
+// fout.close();
+// } catch (FileNotFoundException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// } catch (IOException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// }
+// }
+//
+// if ((struTemInfo.dwThermalPicLen > 0) && (struTemInfo.byPicTransType == 0)) {
+// SimpleDateFormat sf = new SimpleDateFormat("yyyyMMddHHmmss");
+// String newName = sf.format(new Date());
+// FileOutputStream fout;
+//
+// try {
+// String filename = "../pic/" + newName + "_" + "_ThermalPiC" + ".jpg";
+// fout = new FileOutputStream(filename);
+// //将字节写入文件
+// long offset = 0;
+// ByteBuffer buffers = struTemInfo.pThermalPicBuff.getByteBuffer(offset, struTemInfo.dwThermalPicLen);
+// byte[] bytes = new byte[struTemInfo.dwThermalPicLen];
+// buffers.rewind();
+// buffers.get(bytes);
+// fout.write(bytes);
+// fout.close();
+// } catch (FileNotFoundException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// } catch (IOException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// }
+//
+// }
+// break;
+// case HCNetSDK.COMM_THERMOMETRY_DIFF_ALARM: //温差检测报警
+// HCNetSDK.NET_DVR_THERMOMETRY_DIFF_ALARM strThermDiffAlarm = new HCNetSDK.NET_DVR_THERMOMETRY_DIFF_ALARM();
+// strThermDiffAlarm.write();
+// Pointer pTemDiffInfo = strThermDiffAlarm.getPointer();
+// pTemDiffInfo.write(0, pAlarmInfo.getByteArray(0, strThermDiffAlarm.size()), 0, strThermDiffAlarm.size());
+// strThermDiffAlarm.read();
+// String sThremDiffInfo = "通道号:" + strThermDiffAlarm.dwChannel + ",报警规则:" + strThermDiffAlarm.byAlarmRule + ",当前温差:" + strThermDiffAlarm.fCurTemperatureDiff;
+// System.out.println(sThremDiffInfo);
+// //可见光图片保存
+// if ((strThermDiffAlarm.dwPicLen > 0) && (strThermDiffAlarm.byPicTransType == 0)) {
+// SimpleDateFormat sf = new SimpleDateFormat("yyyyMMddHHmmss");
+// String newName = sf.format(new Date());
+// FileOutputStream fout;
+//
+// try {
+// String filename = "../pic/" + newName + "_" + strThermDiffAlarm.fCurTemperatureDiff + ".jpg";
+// fout = new FileOutputStream(filename);
+// //将字节写入文件
+// long offset = 0;
+// ByteBuffer buffers = strThermDiffAlarm.pPicBuff.getByteBuffer(offset, strThermDiffAlarm.dwPicLen);
+// byte[] bytes = new byte[strThermDiffAlarm.dwPicLen];
+// buffers.rewind();
+// buffers.get(bytes);
+// fout.write(bytes);
+// fout.close();
+// } catch (FileNotFoundException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// } catch (IOException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// }
+// }
+// //热成像图片保存
+// if ((strThermDiffAlarm.dwThermalPicLen > 0) && (strThermDiffAlarm.byPicTransType == 0)) {
+// SimpleDateFormat sf = new SimpleDateFormat("yyyyMMddHHmmss");
+// String newName = sf.format(new Date());
+// FileOutputStream fout;
+//
+// try {
+// String filename = "../pic/" + newName + "_" + "_ThermalDiffPiC" + ".jpg";
+// fout = new FileOutputStream(filename);
+// //将字节写入文件
+// long offset = 0;
+// ByteBuffer buffers = strThermDiffAlarm.pThermalPicBuff.getByteBuffer(offset, strThermDiffAlarm.dwThermalPicLen);
+// byte[] bytes = new byte[strThermDiffAlarm.dwThermalPicLen];
+// buffers.rewind();
+// buffers.get(bytes);
+// fout.write(bytes);
+// fout.close();
+// } catch (FileNotFoundException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// } catch (IOException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// }
+//
+// }
+// break;
+// case HCNetSDK.COMM_ALARM_SHIPSDETECTION: //船只检测报警
+// HCNetSDK.NET_DVR_SHIPSDETECTION_ALARM struShipAlarm = new HCNetSDK.NET_DVR_SHIPSDETECTION_ALARM();
+// struShipAlarm.write();
+// Pointer pShipAlarm = struShipAlarm.getPointer();
+// pShipAlarm.write(0, pAlarmInfo.getByteArray(0, struShipAlarm.size()), 0, struShipAlarm.size());
+// struShipAlarm.read();
+// String sShipAlarm = "绝对时间:" + struShipAlarm.dwAbsTime + ",正跨越检测线的船只数:" + struShipAlarm.byShipsNum + ",船头检测的船只数 :" + struShipAlarm.byShipsNumHead
+// + ", 船尾检测的船只数 :" + struShipAlarm.byShipsNumEnd;
+// System.out.println(sShipAlarm);
+// //可见光图片保存
+// if ((struShipAlarm.dwPicLen > 0) && (struShipAlarm.byPicTransType == 0)) {
+// SimpleDateFormat sf = new SimpleDateFormat("yyyyMMddHHmmss");
+// String newName = sf.format(new Date());
+// FileOutputStream fout;
+//
+// try {
+// String filename = "../pic/" + newName + "_ShipAlarm" + ".jpg";
+// fout = new FileOutputStream(filename);
+// //将字节写入文件
+// long offset = 0;
+// ByteBuffer buffers = struShipAlarm.pPicBuffer.getByteBuffer(offset, struShipAlarm.dwPicLen);
+// byte[] bytes = new byte[struShipAlarm.dwPicLen];
+// buffers.rewind();
+// buffers.get(bytes);
+// fout.write(bytes);
+// fout.close();
+// } catch (FileNotFoundException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// } catch (IOException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// }
+// }
+// //热成像图片保存
+// if ((struShipAlarm.dwThermalPicLen > 0) && (struShipAlarm.byPicTransType == 0)) {
+// SimpleDateFormat sf = new SimpleDateFormat("yyyyMMddHHmmss");
+// String newName = sf.format(new Date());
+// FileOutputStream fout;
+//
+// try {
+// String filename = "../pic/" + newName + "_" + "_ThermalShipAlarm" + ".jpg";
+// fout = new FileOutputStream(filename);
+// //将字节写入文件
+// long offset = 0;
+// ByteBuffer buffers = struShipAlarm.pThermalPicBuffer.getByteBuffer(offset, struShipAlarm.dwThermalPicLen);
+// byte[] bytes = new byte[struShipAlarm.dwThermalPicLen];
+// buffers.rewind();
+// buffers.get(bytes);
+// fout.write(bytes);
+// fout.close();
+// } catch (FileNotFoundException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// } catch (IOException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// }
+//
+// }
+// break;
+//
+// case HCNetSDK.COMM_FIREDETECTION_ALARM://烟火检测
+// HCNetSDK.NET_DVR_FIREDETECTION_ALARM struFireDecAlarm = new HCNetSDK.NET_DVR_FIREDETECTION_ALARM();
+// struFireDecAlarm.write();
+// Pointer pFireDecAlarm = struFireDecAlarm.getPointer();
+// pFireDecAlarm.write(0, pAlarmInfo.getByteArray(0, struFireDecAlarm.size()), 0, struFireDecAlarm.size());
+// struFireDecAlarm.read();
+// String sFireDecAlarmInfo = "绝对时间:" + struFireDecAlarm.dwAbsTime + ",报警子类型:" + struFireDecAlarm.byAlarmSubType + ",火点最高温度 :" +
+// struFireDecAlarm.wFireMaxTemperature + ",火点目标距离:" + struFireDecAlarm.wTargetDistance;
+// System.out.println(sFireDecAlarmInfo);
+// //可见光图片保存
+// if ((struFireDecAlarm.dwVisiblePicLen > 0) && (struFireDecAlarm.byPicTransType == 0)) {
+// SimpleDateFormat sf = new SimpleDateFormat("yyyyMMddHHmmss");
+// String newName = sf.format(new Date());
+// FileOutputStream fout;
+//
+// try {
+// String filename = "../pic/" + newName + "_FireDecAlarm" + ".jpg";
+// fout = new FileOutputStream(filename);
+// //将字节写入文件
+// long offset = 0;
+// ByteBuffer buffers = struFireDecAlarm.pVisiblePicBuf.getByteBuffer(offset, struFireDecAlarm.dwVisiblePicLen);
+// byte[] bytes = new byte[struFireDecAlarm.dwVisiblePicLen];
+// buffers.rewind();
+// buffers.get(bytes);
+// fout.write(bytes);
+// fout.close();
+// } catch (FileNotFoundException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// } catch (IOException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// }
+// }
+// //热成像图片保存
+// if ((struFireDecAlarm.dwPicDataLen > 0) && (struFireDecAlarm.byPicTransType == 0)) {
+// SimpleDateFormat sf = new SimpleDateFormat("yyyyMMddHHmmss");
+// String newName = sf.format(new Date());
+// FileOutputStream fout;
+//
+// try {
+// String filename = "../pic/" + newName + "_" + "_ThermalFireAlarm" + ".jpg";
+// fout = new FileOutputStream(filename);
+// //将字节写入文件
+// long offset = 0;
+// ByteBuffer buffers = struFireDecAlarm.pBuffer.getByteBuffer(offset, struFireDecAlarm.dwPicDataLen);
+// byte[] bytes = new byte[struFireDecAlarm.dwPicDataLen];
+// buffers.rewind();
+// buffers.get(bytes);
+// fout.write(bytes);
+// fout.close();
+// } catch (FileNotFoundException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// } catch (IOException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// }
+//
+// }
+// break;
+// case HCNetSDK.COMM_UPLOAD_AIOP_VIDEO: //AI开放平台接入视频检测报警信息
+// System.out.println("AI开放平台接入视频检测报警上传");
+// HCNetSDK.NET_AIOP_VIDEO_HEAD struAIOPVideo = new HCNetSDK.NET_AIOP_VIDEO_HEAD();
+// struAIOPVideo.write();
+// Pointer pAIOPVideo = struAIOPVideo.getPointer();
+// pAIOPVideo.write(0, pAlarmInfo.getByteArray(0, struAIOPVideo.size()), 0, struAIOPVideo.size());
+// struAIOPVideo.read();
+// System.out.println("视频任务ID" + new String(struAIOPVideo.szTaskID));
+// System.out.println("通道号:" + struAIOPVideo.dwChannel);
+// System.out.println("检测模型包ID" + new String(struAIOPVideo.szMPID));
+// String strTime = String.format("%04d", struAIOPVideo.struTime.wYear) +
+// String.format("%02d", struAIOPVideo.struTime.wMonth) +
+// String.format("%02d", struAIOPVideo.struTime.wDay) +
+// String.format("%02d", struAIOPVideo.struTime.wHour) +
+// String.format("%02d", struAIOPVideo.struTime.wMinute) +
+// String.format("%02d", struAIOPVideo.struTime.wSecond) +
+// String.format("%03d", struAIOPVideo.struTime.wMilliSec);
+// //AIOPData数据
+// if (struAIOPVideo.dwAIOPDataSize > 0) {
+// FileOutputStream fout;
+// try {
+// String filename = "../pic/" + new String(pAlarmer.sDeviceIP).trim() +
+// "_" + strTime + "_VideoData.json";
+// fout = new FileOutputStream(filename);
+// //将字节写入文件
+// long offset = 0;
+// ByteBuffer buffers = struAIOPVideo.pBufferAIOPData.getByteBuffer(offset, struAIOPVideo.dwAIOPDataSize);
+// byte[] bytes = new byte[struAIOPVideo.dwAIOPDataSize];
+// buffers.rewind();
+// buffers.get(bytes);
+// fout.write(bytes);
+// fout.close();
+// } catch (FileNotFoundException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// } catch (IOException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// }
+// }
+// //图片数据保存
+// if (struAIOPVideo.dwPictureSize > 0) {
+// FileOutputStream fout;
+// try {
+// String filename = "../pic/" + new String(pAlarmer.sDeviceIP).trim() +
+// "_" + strTime + "_VideoPic.jpg";
+// fout = new FileOutputStream(filename);
+// //将字节写入文件
+// long offset = 0;
+// ByteBuffer buffers = struAIOPVideo.pBufferPicture.getByteBuffer(offset, struAIOPVideo.dwPictureSize);
+// byte[] bytes = new byte[struAIOPVideo.dwPictureSize];
+// buffers.rewind();
+// buffers.get(bytes);
+// fout.write(bytes);
+// fout.close();
+// } catch (FileNotFoundException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// } catch (IOException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// }
+// }
+// break;
+// case HCNetSDK.COMM_UPLOAD_AIOP_PICTURE: //AI开放平台接入图片检测报警信息
+// System.out.println("AI开放平台接入图片检测报警上传");
+// HCNetSDK.NET_AIOP_PICTURE_HEAD struAIOPPic = new HCNetSDK.NET_AIOP_PICTURE_HEAD();
+// struAIOPPic.write();
+// Pointer pAIOPPic = struAIOPPic.getPointer();
+// pAIOPPic.write(0, pAlarmInfo.getByteArray(0, struAIOPPic.size()), 0, struAIOPPic.size());
+// struAIOPPic.read();
+// System.out.println("图片ID:" + new String(struAIOPPic.szPID));
+// System.out.println("检测模型包ID:" + new String(struAIOPPic.szMPID));
+// String strPicTime = "" + String.format("%04d", struAIOPPic.struTime.wYear) +
+// String.format("%02d", struAIOPPic.struTime.wMonth) +
+// String.format("%02d", struAIOPPic.struTime.wDay) +
+// String.format("%02d", struAIOPPic.struTime.wHour) +
+// String.format("%02d", struAIOPPic.struTime.wMinute) +
+// String.format("%02d", struAIOPPic.struTime.wSecond) +
+// String.format("%03d", struAIOPPic.struTime.wMilliSec);
+// //AIOPData数据
+// if (struAIOPPic.dwAIOPDataSize > 0) {
+// FileOutputStream fout;
+// try {
+// String filename = "../pic/" + new String(pAlarmer.sDeviceIP).trim() +
+// "_" + strPicTime + "_AIO_PicData.json";
+// fout = new FileOutputStream(filename);
+// //将字节写入文件
+// long offset = 0;
+// ByteBuffer buffers = struAIOPPic.pBufferAIOPData.getByteBuffer(offset, struAIOPPic.dwAIOPDataSize);
+// byte[] bytes = new byte[struAIOPPic.dwAIOPDataSize];
+// buffers.rewind();
+// buffers.get(bytes);
+// fout.write(bytes);
+// fout.close();
+// } catch (FileNotFoundException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// } catch (IOException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// }
+// }
+// break;
+//
+// //AI开放平台接入轮询抓图检测报警信息
+// case HCNetSDK.COMM_UPLOAD_AIOP_POLLING_SNAP:
+// System.out.println("AI开放平台接入轮询抓图检测报警事件上传");
+// HCNetSDK.NET_AIOP_POLLING_SNAP_HEAD strAiopPollingPic = new HCNetSDK.NET_AIOP_POLLING_SNAP_HEAD();
+// strAiopPollingPic.write();
+// Pointer pAiopPollingPic = strAiopPollingPic.getPointer();
+// pAiopPollingPic.write(0, pAlarmInfo.getByteArray(0, strAiopPollingPic.size()), 0, strAiopPollingPic.size());
+// strAiopPollingPic.read();
+// System.out.println("通道号:" + strAiopPollingPic.dwChannel);
+// System.out.println("轮询抓图任务ID:" + new String(strAiopPollingPic.szTaskID));
+// String strPollingPicTime = "" + String.format("%04d", strAiopPollingPic.struTime.wYear) +
+// String.format("%02d", strAiopPollingPic.struTime.wMonth) +
+// String.format("%02d", strAiopPollingPic.struTime.wDay) +
+// String.format("%02d", strAiopPollingPic.struTime.wHour) +
+// String.format("%02d", strAiopPollingPic.struTime.wMinute) +
+// String.format("%02d", strAiopPollingPic.struTime.wSecond) +
+// String.format("%03d", strAiopPollingPic.struTime.wMilliSec);
+// //AIOPData数据保存
+// if (strAiopPollingPic.dwAIOPDataSize > 0) {
+// FileOutputStream fout;
+// try {
+// String filename = "../pic/" + new String(pAlarmer.sDeviceIP).trim() +
+// "_" + strPollingPicTime + "_PollingPicData.json";
+// fout = new FileOutputStream(filename);
+// //将字节写入文件
+// long offset = 0;
+// ByteBuffer buffers = strAiopPollingPic.pBufferAIOPData.getByteBuffer(offset, strAiopPollingPic.dwAIOPDataSize);
+// byte[] bytes = new byte[strAiopPollingPic.dwAIOPDataSize];
+// buffers.rewind();
+// buffers.get(bytes);
+// fout.write(bytes);
+// fout.close();
+// } catch (FileNotFoundException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// } catch (IOException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// }
+// }
+// //轮询抓图图片保存
+// if (strAiopPollingPic.dwPictureSize > 0) {
+// FileOutputStream fout;
+// try {
+// String filename = "../pic/" + new String(pAlarmer.sDeviceIP).trim() +
+// "_" + strPollingPicTime + "_PollingPic.jpg";
+// fout = new FileOutputStream(filename);
+// //将字节写入文件
+// long offset = 0;
+// ByteBuffer buffers = strAiopPollingPic.pBufferPicture.getByteBuffer(offset, strAiopPollingPic.dwPictureSize);
+// byte[] bytes = new byte[strAiopPollingPic.dwPictureSize];
+// buffers.rewind();
+// buffers.get(bytes);
+// fout.write(bytes);
+// fout.close();
+// } catch (FileNotFoundException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// } catch (IOException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// }
+// }
+//
+// break;
+// //AI开放平台接入轮询视频检测报警信息
+// case HCNetSDK.COMM_UPLOAD_AIOP_POLLING_VIDEO:
+// System.out.println("AI开放平台接入轮询视频检测报警事件上传");
+// HCNetSDK.NET_AIOP_POLLING_VIDEO_HEAD strAiopPollingVideo = new HCNetSDK.NET_AIOP_POLLING_VIDEO_HEAD();
+// strAiopPollingVideo.write();
+// Pointer pAiopPollingVideo = strAiopPollingVideo.getPointer();
+// pAiopPollingVideo.write(0, pAlarmInfo.getByteArray(0, strAiopPollingVideo.size()), 0, strAiopPollingVideo.size());
+// strAiopPollingVideo.read();
+// System.out.println("通道号:" + strAiopPollingVideo.dwChannel);
+// System.out.println("轮询视频任务ID:" + new String(strAiopPollingVideo.szTaskID));
+// String AiopPollingVideoTime = "" + String.format("%04d", strAiopPollingVideo.struTime.wYear) +
+// String.format("%02d", strAiopPollingVideo.struTime.wMonth) +
+// String.format("%02d", strAiopPollingVideo.struTime.wDay) +
+// String.format("%02d", strAiopPollingVideo.struTime.wHour) +
+// String.format("%02d", strAiopPollingVideo.struTime.wMinute) +
+// String.format("%02d", strAiopPollingVideo.struTime.wSecond) +
+// String.format("%03d", strAiopPollingVideo.struTime.wMilliSec);
+// //AIOPData数据保存
+// if (strAiopPollingVideo.dwAIOPDataSize > 0) {
+// FileOutputStream fout;
+// try {
+// String filename = "../pic/" + new String(pAlarmer.sDeviceIP).trim() +
+// "_" + AiopPollingVideoTime + "_PollingVideoData.json";
+// fout = new FileOutputStream(filename);
+// //将字节写入文件
+// long offset = 0;
+// ByteBuffer buffers = strAiopPollingVideo.pBufferAIOPData.getByteBuffer(offset, strAiopPollingVideo.dwAIOPDataSize);
+// byte[] bytes = new byte[strAiopPollingVideo.dwAIOPDataSize];
+// buffers.rewind();
+// buffers.get(bytes);
+// fout.write(bytes);
+// fout.close();
+// } catch (FileNotFoundException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// } catch (IOException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// }
+// }
+// //对应分析图片数据
+// if (strAiopPollingVideo.dwPictureSize > 0) {
+// FileOutputStream fout;
+// try {
+// String filename = "../pic/" + new String(pAlarmer.sDeviceIP).trim() +
+// "_" + AiopPollingVideoTime + "_PollingVideo.jpg";
+// fout = new FileOutputStream(filename);
+// //将字节写入文件
+// long offset = 0;
+// ByteBuffer buffers = strAiopPollingVideo.pBufferPicture.getByteBuffer(offset, strAiopPollingVideo.dwPictureSize);
+// byte[] bytes = new byte[strAiopPollingVideo.dwPictureSize];
+// buffers.rewind();
+// buffers.get(bytes);
+// fout.write(bytes);
+// fout.close();
+// } catch (FileNotFoundException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// } catch (IOException e) {
+// // TODO Auto-generated catch block
+// e.printStackTrace();
+// }
+// }
+// break;
+// default:
+// System.out.println("报警类型" + Integer.toHexString(lCommand));
+// break;
+// }
+// }
+//}
diff --git a/src/main/java/com/shxy/xyhkcamera/alarm/FMSGCallBack.java b/src/main/java/com/shxy/xyhkcamera/alarm/FMSGCallBack.java
new file mode 100644
index 0000000..d27354b
--- /dev/null
+++ b/src/main/java/com/shxy/xyhkcamera/alarm/FMSGCallBack.java
@@ -0,0 +1,17 @@
+//package com.shxy.xyhkcamera.alarm;
+//
+//import NetSDKDemo.HCNetSDK;
+//import com.sun.jna.Pointer;
+//
+//
+///**
+// * @author jiangxin
+// * @create 2022-08-15-17:26
+// */
+//public class FMSGCallBack implements HCNetSDK.FMSGCallBack {
+// //报警信息回调函数
+// public void invoke(int lCommand, HCNetSDK.NET_DVR_ALARMER pAlarmer, Pointer pAlarmInfo, int dwBufLen, Pointer pUser) {
+// AlarmDataParse.alarmDataHandle(lCommand, pAlarmer, pAlarmInfo, dwBufLen, pUser);
+// return;
+// }
+//}
diff --git a/src/main/java/com/shxy/xyhkcamera/alarm/FMSGCallBack_V31.java b/src/main/java/com/shxy/xyhkcamera/alarm/FMSGCallBack_V31.java
new file mode 100644
index 0000000..13ff71a
--- /dev/null
+++ b/src/main/java/com/shxy/xyhkcamera/alarm/FMSGCallBack_V31.java
@@ -0,0 +1,22 @@
+//
+//package com.shxy.xyhkcamera.alarm;
+//
+//import com.shxy.xyhkcamera.HCNetSDK;
+//import com.sun.jna.Pointer;
+//
+//
+//
+//public class FMSGCallBack_V31 implements HCNetSDK.FMSGCallBack_V31 {
+// //报警信息回调函数
+// public boolean invoke(int lCommand, HCNetSDK.NET_DVR_ALARMER pAlarmer, Pointer pAlarmInfo, int dwBufLen, Pointer pUser) {
+// AlarmDataParse.alarmDataHandle(lCommand, pAlarmer, pAlarmInfo, dwBufLen, pUser);
+// return true;
+// }
+//}
+//
+//
+//
+//
+//
+//
+//
diff --git a/src/main/java/com/shxy/xyhkcamera/configure/MybatisMetaObjectHandler.java b/src/main/java/com/shxy/xyhkcamera/configure/MybatisMetaObjectHandler.java
new file mode 100644
index 0000000..013b41f
--- /dev/null
+++ b/src/main/java/com/shxy/xyhkcamera/configure/MybatisMetaObjectHandler.java
@@ -0,0 +1,34 @@
+package com.shxy.xyhkcamera.configure;
+
+import com.baomidou.mybatisplus.core.handlers.MetaObjectHandler;
+import org.apache.ibatis.reflection.MetaObject;
+import org.springframework.stereotype.Component;
+
+import java.time.LocalDateTime;
+import java.util.Objects;
+
+@Component
+public class MybatisMetaObjectHandler implements MetaObjectHandler {
+ @Override
+ public void insertFill(MetaObject metaObject) {
+ insertOrUpdateFill(metaObject, true);
+ }
+
+ @Override
+ public void updateFill(MetaObject metaObject) {
+ insertOrUpdateFill(metaObject, false);
+ }
+
+ private void insertOrUpdateFill(MetaObject metaObject, boolean isInsert) {
+ if (isInsert) {
+ if (Objects.isNull(getFieldValByName("createTime", metaObject)))
+ this.setFieldValByName("createTime", LocalDateTime.now(), metaObject);
+ this.setFieldValByName("deleted", 0, metaObject);
+ } else {
+ if (Objects.isNull(getFieldValByName("updateTime", metaObject)))
+ this.setFieldValByName("updateTime", LocalDateTime.now(), metaObject);
+ }
+ }
+}
+
+
diff --git a/src/main/java/com/shxy/xyhkcamera/configure/MybatisPlusConfig.java b/src/main/java/com/shxy/xyhkcamera/configure/MybatisPlusConfig.java
new file mode 100644
index 0000000..c5bccfe
--- /dev/null
+++ b/src/main/java/com/shxy/xyhkcamera/configure/MybatisPlusConfig.java
@@ -0,0 +1,26 @@
+//package com.shxy.xyhkcamera.configure;
+//
+//import com.baomidou.mybatisplus.annotation.DbType;
+//import com.baomidou.mybatisplus.autoconfigure.ConfigurationCustomizer;
+//import com.baomidou.mybatisplus.extension.plugins.MybatisPlusInterceptor;
+//import com.baomidou.mybatisplus.extension.plugins.inner.PaginationInnerInterceptor;
+//import org.springframework.context.annotation.Bean;
+//import org.springframework.context.annotation.Configuration;
+//import org.springframework.transaction.annotation.EnableTransactionManagement;
+//
+//@Configuration
+//@EnableTransactionManagement
+//public class MybatisPlusConfig {
+//
+// @Bean
+// public MybatisPlusInterceptor mybatisPlusInterceptor() {
+// MybatisPlusInterceptor interceptor = new MybatisPlusInterceptor();
+// PaginationInnerInterceptor pii = new PaginationInnerInterceptor();
+// pii.setDbType(DbType.MYSQL);
+// pii.setMaxLimit(500L);
+// interceptor.addInnerInterceptor(pii);
+// return interceptor;
+// }
+//
+//}
+//
diff --git a/src/main/java/com/shxy/xyhkcamera/controller/DataEaifHController.java b/src/main/java/com/shxy/xyhkcamera/controller/DataEaifHController.java
new file mode 100644
index 0000000..8f64fea
--- /dev/null
+++ b/src/main/java/com/shxy/xyhkcamera/controller/DataEaifHController.java
@@ -0,0 +1,18 @@
+package com.shxy.xyhkcamera.controller;
+
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RestController;
+
+/**
+ *
+ * 红外区域测温数据表 前端控制器
+ *
+ *
+ * @author jingjing
+ * @since 2024-05-20
+ */
+@RestController
+@RequestMapping("/data-eaif-hentity")
+public class DataEaifHController {
+
+}
diff --git a/src/main/java/com/shxy/xyhkcamera/controller/ModevEaifController.java b/src/main/java/com/shxy/xyhkcamera/controller/ModevEaifController.java
new file mode 100644
index 0000000..414ba62
--- /dev/null
+++ b/src/main/java/com/shxy/xyhkcamera/controller/ModevEaifController.java
@@ -0,0 +1,18 @@
+package com.shxy.xyhkcamera.controller;
+
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RestController;
+
+/**
+ *
+ * 前端控制器
+ *
+ *
+ * @author jingjing
+ * @since 2024-05-20
+ */
+@RestController
+@RequestMapping("/modev-eaif-entity")
+public class ModevEaifController {
+
+}
diff --git a/src/main/java/com/shxy/xyhkcamera/entity/DataEaifHEntity.java b/src/main/java/com/shxy/xyhkcamera/entity/DataEaifHEntity.java
new file mode 100644
index 0000000..9167c67
--- /dev/null
+++ b/src/main/java/com/shxy/xyhkcamera/entity/DataEaifHEntity.java
@@ -0,0 +1,78 @@
+package com.shxy.xyhkcamera.entity;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableField;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+
+import java.io.Serializable;
+import java.time.LocalDateTime;
+
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Getter;
+import lombok.Setter;
+
+/**
+ *
+ * 红外区域测温数据表
+ *
+ *
+ * @author jingjing
+ * @since 2024-05-20
+ */
+@Getter
+@Setter
+@TableName("data_eaif_h")
+@ApiModel(value = "DataEaifHEntity对象", description = "红外区域测温数据表")
+public class DataEaifHEntity implements Serializable {
+
+ private static final long serialVersionUID = 1L;
+
+ @ApiModelProperty("自动编号")
+ @TableId(value = "data_id", type = IdType.AUTO)
+ private Integer dataId;
+
+ @ApiModelProperty("设备ID")
+ @TableField("eqmid")
+ private Integer eqmid;
+
+ @ApiModelProperty("点、线、区域ID")
+ @TableField("areaid")
+ private Integer areaid;
+
+ @ApiModelProperty("采集时间")
+ @TableField("capturetime")
+ private LocalDateTime capturetime;
+
+ @ApiModelProperty("最大温度")
+ @TableField("maxtemp")
+ private Double maxtemp;
+
+ @ApiModelProperty("最小温度")
+ @TableField("mintemp")
+ private Double mintemp;
+
+ @ApiModelProperty("平均温度")
+ @TableField("avgtemp")
+ private Double avgtemp;
+
+ @ApiModelProperty("1=>摄氏度2=>华氏度")
+ @TableField("unit")
+ private Byte unit;
+
+ @ApiModelProperty("1->点2->线3->框")
+ @TableField("type")
+ private Byte type;
+
+ @ApiModelProperty("中间差")
+ @TableField("mid")
+ private Double mid;
+
+ @ApiModelProperty("标准方差值")
+ @TableField("std")
+ private Double std;
+
+ @TableField("isupload")
+ private Integer isupload;
+}
diff --git a/src/main/java/com/shxy/xyhkcamera/entity/ModevEaifEntity.java b/src/main/java/com/shxy/xyhkcamera/entity/ModevEaifEntity.java
new file mode 100644
index 0000000..59f8052
--- /dev/null
+++ b/src/main/java/com/shxy/xyhkcamera/entity/ModevEaifEntity.java
@@ -0,0 +1,46 @@
+package com.shxy.xyhkcamera.entity;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableField;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import java.io.Serializable;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Getter;
+import lombok.Setter;
+
+/**
+ *
+ *
+ *
+ *
+ * @author jingjing
+ * @since 2024-05-20
+ */
+@Getter
+@Setter
+@TableName("modev_eaif")
+@ApiModel(value = "ModevEaifEntity对象", description = "")
+public class ModevEaifEntity implements Serializable {
+
+ private static final long serialVersionUID = 1L;
+
+ @TableId(value = "id", type = IdType.AUTO)
+ private Integer id;
+
+ @TableField("eqmid")
+ private Integer eqmid;
+
+ @ApiModelProperty("预置点id")
+ @TableField("nPresetId")
+ private Integer nPresetId;
+
+ @ApiModelProperty("规则编号")
+ @TableField("nRuleId")
+ private Integer nRuleId;
+
+ @ApiModelProperty("规则类型")
+ @TableField("nMeterType")
+ private Integer nMeterType;
+}
diff --git a/src/main/java/com/shxy/xyhkcamera/mapper/DataEaifHMapper.java b/src/main/java/com/shxy/xyhkcamera/mapper/DataEaifHMapper.java
new file mode 100644
index 0000000..b950122
--- /dev/null
+++ b/src/main/java/com/shxy/xyhkcamera/mapper/DataEaifHMapper.java
@@ -0,0 +1,16 @@
+package com.shxy.xyhkcamera.mapper;
+
+import com.shxy.xyhkcamera.entity.DataEaifHEntity;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+
+/**
+ *
+ * 红外区域测温数据表 Mapper 接口
+ *
+ *
+ * @author jingjing
+ * @since 2024-05-20
+ */
+public interface DataEaifHMapper extends BaseMapper {
+
+}
diff --git a/src/main/java/com/shxy/xyhkcamera/mapper/ModevEaifMapper.java b/src/main/java/com/shxy/xyhkcamera/mapper/ModevEaifMapper.java
new file mode 100644
index 0000000..30deec8
--- /dev/null
+++ b/src/main/java/com/shxy/xyhkcamera/mapper/ModevEaifMapper.java
@@ -0,0 +1,16 @@
+package com.shxy.xyhkcamera.mapper;
+
+import com.shxy.xyhkcamera.entity.ModevEaifEntity;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+
+/**
+ *
+ * Mapper 接口
+ *
+ *
+ * @author jingjing
+ * @since 2024-05-20
+ */
+public interface ModevEaifMapper extends BaseMapper {
+
+}
diff --git a/src/main/java/com/shxy/xyhkcamera/mapper/xml/DataEaifHMapper.xml b/src/main/java/com/shxy/xyhkcamera/mapper/xml/DataEaifHMapper.xml
new file mode 100644
index 0000000..1c63135
--- /dev/null
+++ b/src/main/java/com/shxy/xyhkcamera/mapper/xml/DataEaifHMapper.xml
@@ -0,0 +1,5 @@
+
+
+
+
+
diff --git a/src/main/java/com/shxy/xyhkcamera/mapper/xml/ModevEaifMapper.xml b/src/main/java/com/shxy/xyhkcamera/mapper/xml/ModevEaifMapper.xml
new file mode 100644
index 0000000..829e47b
--- /dev/null
+++ b/src/main/java/com/shxy/xyhkcamera/mapper/xml/ModevEaifMapper.xml
@@ -0,0 +1,5 @@
+
+
+
+
+
diff --git a/src/main/java/com/shxy/xyhkcamera/service/DataEaifHService.java b/src/main/java/com/shxy/xyhkcamera/service/DataEaifHService.java
new file mode 100644
index 0000000..2c0fe3d
--- /dev/null
+++ b/src/main/java/com/shxy/xyhkcamera/service/DataEaifHService.java
@@ -0,0 +1,16 @@
+package com.shxy.xyhkcamera.service;
+
+import com.shxy.xyhkcamera.entity.DataEaifHEntity;
+import com.baomidou.mybatisplus.extension.service.IService;
+
+/**
+ *
+ * 红外区域测温数据表 服务类
+ *
+ *
+ * @author jingjing
+ * @since 2024-05-20
+ */
+public interface DataEaifHService extends IService {
+
+}
diff --git a/src/main/java/com/shxy/xyhkcamera/service/ModevEaifService.java b/src/main/java/com/shxy/xyhkcamera/service/ModevEaifService.java
new file mode 100644
index 0000000..52a03cf
--- /dev/null
+++ b/src/main/java/com/shxy/xyhkcamera/service/ModevEaifService.java
@@ -0,0 +1,16 @@
+package com.shxy.xyhkcamera.service;
+
+import com.shxy.xyhkcamera.entity.ModevEaifEntity;
+import com.baomidou.mybatisplus.extension.service.IService;
+
+/**
+ *
+ * 服务类
+ *
+ *
+ * @author jingjing
+ * @since 2024-05-20
+ */
+public interface ModevEaifService extends IService {
+
+}
diff --git a/src/main/java/com/shxy/xyhkcamera/service/impl/DataEaifHServiceImp.java b/src/main/java/com/shxy/xyhkcamera/service/impl/DataEaifHServiceImp.java
new file mode 100644
index 0000000..daf37f9
--- /dev/null
+++ b/src/main/java/com/shxy/xyhkcamera/service/impl/DataEaifHServiceImp.java
@@ -0,0 +1,20 @@
+package com.shxy.xyhkcamera.service.impl;
+
+import com.shxy.xyhkcamera.entity.DataEaifHEntity;
+import com.shxy.xyhkcamera.mapper.DataEaifHMapper;
+import com.shxy.xyhkcamera.service.DataEaifHService;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import org.springframework.stereotype.Service;
+
+/**
+ *
+ * 红外区域测温数据表 服务实现类
+ *
+ *
+ * @author jingjing
+ * @since 2024-05-20
+ */
+@Service
+public class DataEaifHServiceImp extends ServiceImpl implements DataEaifHService {
+
+}
diff --git a/src/main/java/com/shxy/xyhkcamera/service/impl/ModevEaifServiceImp.java b/src/main/java/com/shxy/xyhkcamera/service/impl/ModevEaifServiceImp.java
new file mode 100644
index 0000000..a906f41
--- /dev/null
+++ b/src/main/java/com/shxy/xyhkcamera/service/impl/ModevEaifServiceImp.java
@@ -0,0 +1,20 @@
+package com.shxy.xyhkcamera.service.impl;
+
+import com.shxy.xyhkcamera.entity.ModevEaifEntity;
+import com.shxy.xyhkcamera.mapper.ModevEaifMapper;
+import com.shxy.xyhkcamera.service.ModevEaifService;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import org.springframework.stereotype.Service;
+
+/**
+ *
+ * 服务实现类
+ *
+ *
+ * @author jingjing
+ * @since 2024-05-20
+ */
+@Service
+public class ModevEaifServiceImp extends ServiceImpl implements ModevEaifService {
+
+}
diff --git a/src/main/java/com/shxy/xyhkcamera/utils/CommonUtil.java b/src/main/java/com/shxy/xyhkcamera/utils/CommonUtil.java
new file mode 100644
index 0000000..e656452
--- /dev/null
+++ b/src/main/java/com/shxy/xyhkcamera/utils/CommonUtil.java
@@ -0,0 +1,67 @@
+package com.shxy.xyhkcamera.utils;
+
+
+
+import java.io.*;
+
+public class CommonUtil {
+
+ //SDK时间解析
+ public static String parseTime(int time) {
+ int year = (time >> 26) + 2000;
+ int month = (time >> 22) & 15;
+ int day = (time >> 17) & 31;
+ int hour = (time >> 12) & 31;
+ int min = (time >> 6) & 63;
+ int second = (time >> 0) & 63;
+ String sTime = year + "-" + month + "-" + day + "-" + hour + ":" + min + ":" + second;
+// System.out.println(sTime);
+ return sTime;
+
+
+ }
+
+ //分辨率解析
+ public static String parseResolution(int dwResolution) {
+ int interlace = (((dwResolution) >> 28) & 0x1);
+ int width = ((((dwResolution) >> 19) & 0x1ff) << 3); //宽
+ int hight = ((((dwResolution) >> 8) & 0x7ff) << 1); //高
+ int fps = ((dwResolution) & 0xff); //帧率
+ String result = width + "*" + hight + "_" + fps;
+ return result;
+
+
+ }
+
+ /**
+ * 读取本地文件到数组中
+ *
+ * @param filename 本地文件
+ * @return 返回读取到的数据到 byte数组
+ * @throws IOException
+ */
+ public static byte[] toByteArray(String filename) throws IOException {
+ File file = new File(filename);
+ if (!file.exists()) {
+ throw new FileNotFoundException(filename);
+ }
+ ByteArrayOutputStream bos = new ByteArrayOutputStream((int) file.length());
+ BufferedInputStream in = new BufferedInputStream(new FileInputStream(file));
+ try {
+ byte[] buffer = new byte[1024];
+ int len;
+ while (-1 != (len = in.read(buffer, 0, buffer.length))) {
+ bos.write(buffer, 0, len);
+ }
+ return bos.toByteArray();
+ } catch (IOException e) {
+ e.printStackTrace();
+ throw e;
+ } finally {
+ bos.close();
+ in.close();
+ }
+ }
+
+
+}
diff --git a/src/main/java/com/shxy/xyhkcamera/utils/MyBatisPlusGenerator.java b/src/main/java/com/shxy/xyhkcamera/utils/MyBatisPlusGenerator.java
new file mode 100644
index 0000000..0b72b40
--- /dev/null
+++ b/src/main/java/com/shxy/xyhkcamera/utils/MyBatisPlusGenerator.java
@@ -0,0 +1,68 @@
+package com.shxy.xyhkcamera.utils;
+
+import com.baomidou.mybatisplus.annotation.DbType;
+import com.baomidou.mybatisplus.annotation.FieldFill;
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.core.toolkit.ArrayUtils;
+import com.baomidou.mybatisplus.generator.AutoGenerator;
+import com.baomidou.mybatisplus.generator.FastAutoGenerator;
+import com.baomidou.mybatisplus.generator.config.DataSourceConfig;
+import com.baomidou.mybatisplus.generator.config.GlobalConfig;
+import com.baomidou.mybatisplus.generator.config.PackageConfig;
+import com.baomidou.mybatisplus.generator.config.StrategyConfig;
+import com.baomidou.mybatisplus.generator.config.converts.MySqlTypeConvert;
+import com.baomidou.mybatisplus.generator.config.po.TableField;
+import com.baomidou.mybatisplus.generator.config.rules.DateType;
+import com.baomidou.mybatisplus.generator.config.rules.IColumnType;
+import com.baomidou.mybatisplus.generator.config.rules.NamingStrategy;
+import com.baomidou.mybatisplus.generator.engine.VelocityTemplateEngine;
+
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Collections;
+import java.util.List;
+
+public class MyBatisPlusGenerator {
+ // 处理 all 情况
+ protected static List getTables(String tables) {
+ return "all".equals(tables) ? Collections.emptyList() : Arrays.asList(tables.split(","));
+ }
+
+ public static void main(String[] args) {
+ String projectPath = System.getProperty("user.dir");
+ FastAutoGenerator.create("jdbc:mysql://192.168.1.190:3306/cac", "root", "123456")
+ // 全局配置
+ .globalConfig((scanner, builder) -> {
+ builder.author(scanner.apply("请输入作者名称?"));
+ builder.enableSwagger();
+ builder.outputDir(projectPath + "/src/main/java");
+ })
+ // 包配置
+ .packageConfig((scanner, builder) -> {
+ builder.parent(scanner.apply("请输入包名?"));
+ })
+ // 策略配置
+ .strategyConfig((scanner, builder) -> {
+ builder.addInclude(MyBatisPlusGenerator.getTables(scanner.apply("请输入表名,多个英文逗号分隔?所有输入 all")))
+ .controllerBuilder().enableRestStyle().enableHyphenStyle().build();
+ builder.serviceBuilder()
+ .formatServiceFileName("%sService")
+ .formatServiceImplFileName("%sServiceImp")
+ .build();
+ //entity的策略配置
+ builder.entityBuilder()
+ .enableLombok()
+ .enableTableFieldAnnotation()
+ .versionColumnName("version")
+ .logicDeleteColumnName("is_delete")
+ .columnNaming(NamingStrategy.underline_to_camel)
+ .idType(IdType.ASSIGN_ID)
+ .formatFileName("%sEntity")
+ .build();
+ })
+ .execute();
+ }
+}
+
+
+
diff --git a/src/main/resources/application-test.yml b/src/main/resources/application-test.yml
index 9b7a43f..fc07402 100644
--- a/src/main/resources/application-test.yml
+++ b/src/main/resources/application-test.yml
@@ -8,22 +8,86 @@ server:
hkconfig:
winpath: D:\\Workspace\\HK\\HCNetSDK.dll
linuxpath: ere
-# tomcat:
-# # tomcat的URI编码
-# uri-encoding: UTF-8
-# # 连接数满后的排队数,默认为100
-# accept-count: 1000
-# max-swallow-size: -1 # tomcat默认大小2M,超过2M的文件不会被捕获,需要调整此处大小为100MB或者-1即可
-# threads:
-# # tomcat最大线程数,默认为200
-# max: 800
-# # Tomcat启动初始化的线程数,默认值10
-# min-spare: 100
+ tomcat:
+ # tomcat的URI编码
+ uri-encoding: UTF-8
+ # 连接数满后的排队数,默认为100
+ accept-count: 1000
+ max-swallow-size: -1 # tomcat默认大小2M,超过2M的文件不会被捕获,需要调整此处大小为100MB或者-1即可
+ threads:
+ # tomcat最大线程数,默认为200
+ max: 800
+ # Tomcat启动初始化的线程数,默认值10
+ min-spare: 100
-## 日志配置
-#logging:
-# config: classpath:log4j2.xml
-# level:
-# com.shxy: trace
-# org.springframework: warn
+spring:
+ task:
+ scheduling:
+ pool:
+ size: 20
+ # 数据源配置
+ datasource:
+ type: com.alibaba.druid.pool.DruidDataSource
+ driverClassName: com.mysql.cj.jdbc.Driver
+ druid:
+ # 主库数据源
+ url: jdbc:mysql://192.168.1.190:3306/iec104?allowMultiQueries=true&useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
+ username: root
+ password: 123456
+ # 初始连接数
+ initialSize: 10
+ # 最小连接池数量
+ minIdle: 20
+ # 最大连接池数量
+ maxActive: 50
+ # 配置获取连接等待超时的时间
+ maxWait: 60000
+ # 配置间隔多久才进行一次检测,检测需要关闭的空闲连接,单位是毫秒
+ timeBetweenEvictionRunsMillis: 30000
+ # 配置一个连接在池中最小生存的时间,单位是毫秒
+ minEvictableIdleTimeMillis: 300000
+ # 配置一个连接在池中最大生存的时间,单位是毫秒
+ maxEvictableIdleTimeMillis: 900000
+ # 配置检测连接是否有效
+ validationQuery: SELECT 1 FROM DUAL
+ testWhileIdle: true
+ testOnBorrow: false
+ testOnReturn: false
+ webStatFilter:
+ enabled: true
+ statViewServlet:
+ enabled: true
+ # 设置白名单,不填则允许所有访问
+ allow:
+ url-pattern: /druid/*
+ # 控制台管理用户名和密码
+ login-username: root
+ login-password: 123456
+ filter:
+ stat:
+ enabled: true
+ # 慢SQL记录
+ log-slow-sql: true
+ slow-sql-millis: 1000
+ merge-sql: true
+ wall:
+ config:
+ multi-statement-allow: true
+mybatis-plus:
+ configuration:
+ #开启驼峰命名自动映射
+ map-underscore-to-camel-case: true
+ #开启日志打印
+ log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
+ # entity包路径,自行修改
+ type-aliases-package: com.shxy.xyhkcamera.entity
+ #扫描mapper文件
+ mapper-locations: classpath:mapper/*.xml
+
+# 日志配置
+logging:
+ config: classpath:log4j2.xml
+ level:
+ com.shxy: trace
+ org.springframework: warn
diff --git a/src/main/resources/lib/libcrypto.so.1.1 b/src/main/resources/lib/libcrypto.so.1.1
deleted file mode 100644
index 88c3746..0000000
Binary files a/src/main/resources/lib/libcrypto.so.1.1 and /dev/null differ
diff --git a/src/main/resources/lib/libhcnetsdk.so b/src/main/resources/lib/libhcnetsdk.so
deleted file mode 100644
index 2607cee..0000000
Binary files a/src/main/resources/lib/libhcnetsdk.so and /dev/null differ
diff --git a/src/main/resources/lib/libssl.so.1.1 b/src/main/resources/lib/libssl.so.1.1
deleted file mode 100644
index f3e4481..0000000
Binary files a/src/main/resources/lib/libssl.so.1.1 and /dev/null differ
diff --git a/src/main/resources/lib/win/AudioRender.dll b/src/main/resources/lib/win/AudioRender.dll
deleted file mode 100644
index 4935684..0000000
Binary files a/src/main/resources/lib/win/AudioRender.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/ClientDemo.exe b/src/main/resources/lib/win/ClientDemo.exe
deleted file mode 100644
index 75aedfa..0000000
Binary files a/src/main/resources/lib/win/ClientDemo.exe and /dev/null differ
diff --git a/src/main/resources/lib/win/ClientDemoDll/ReadMe.txt b/src/main/resources/lib/win/ClientDemoDll/ReadMe.txt
deleted file mode 100644
index 8006f36..0000000
--- a/src/main/resources/lib/win/ClientDemoDll/ReadMe.txt
+++ /dev/null
@@ -1 +0,0 @@
-The dll in this directoryiconv.dll,libxml2.dll,zlib1.dll,calib.dllonly used in ClientDemo.
\ No newline at end of file
diff --git a/src/main/resources/lib/win/ClientDemoDll/calib.dll b/src/main/resources/lib/win/ClientDemoDll/calib.dll
deleted file mode 100644
index 328c63e..0000000
Binary files a/src/main/resources/lib/win/ClientDemoDll/calib.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/ClientDemoDll/iconv.dll b/src/main/resources/lib/win/ClientDemoDll/iconv.dll
deleted file mode 100644
index df71882..0000000
Binary files a/src/main/resources/lib/win/ClientDemoDll/iconv.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/ClientDemoDll/libcrypto-1_1-x64.dll b/src/main/resources/lib/win/ClientDemoDll/libcrypto-1_1-x64.dll
deleted file mode 100644
index f2f96d7..0000000
Binary files a/src/main/resources/lib/win/ClientDemoDll/libcrypto-1_1-x64.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/ClientDemoDll/libssl-1_1-x64.dll b/src/main/resources/lib/win/ClientDemoDll/libssl-1_1-x64.dll
deleted file mode 100644
index 8034d79..0000000
Binary files a/src/main/resources/lib/win/ClientDemoDll/libssl-1_1-x64.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/ClientDemoDll/libxml2.dll b/src/main/resources/lib/win/ClientDemoDll/libxml2.dll
deleted file mode 100644
index c8d57f3..0000000
Binary files a/src/main/resources/lib/win/ClientDemoDll/libxml2.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/ClientDemoDll/zlib1.dll b/src/main/resources/lib/win/ClientDemoDll/zlib1.dll
deleted file mode 100644
index 82913fb..0000000
Binary files a/src/main/resources/lib/win/ClientDemoDll/zlib1.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/GdiPlus.dll b/src/main/resources/lib/win/GdiPlus.dll
deleted file mode 100644
index b759ed6..0000000
Binary files a/src/main/resources/lib/win/GdiPlus.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/GdiPlus.lib b/src/main/resources/lib/win/GdiPlus.lib
deleted file mode 100644
index 6fb1bb6..0000000
Binary files a/src/main/resources/lib/win/GdiPlus.lib and /dev/null differ
diff --git a/src/main/resources/lib/win/HCCore.dll b/src/main/resources/lib/win/HCCore.dll
deleted file mode 100644
index 48f8411..0000000
Binary files a/src/main/resources/lib/win/HCCore.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/HCCore.lib b/src/main/resources/lib/win/HCCore.lib
deleted file mode 100644
index 495c74a..0000000
Binary files a/src/main/resources/lib/win/HCCore.lib and /dev/null differ
diff --git a/src/main/resources/lib/win/HCNetSDK.dll b/src/main/resources/lib/win/HCNetSDK.dll
deleted file mode 100644
index 2ed412e..0000000
Binary files a/src/main/resources/lib/win/HCNetSDK.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/HCNetSDK.lib b/src/main/resources/lib/win/HCNetSDK.lib
deleted file mode 100644
index ff8e9e2..0000000
Binary files a/src/main/resources/lib/win/HCNetSDK.lib and /dev/null differ
diff --git a/src/main/resources/lib/win/HCNetSDKCom/AnalyzeData.dll b/src/main/resources/lib/win/HCNetSDKCom/AnalyzeData.dll
deleted file mode 100644
index 2317b39..0000000
Binary files a/src/main/resources/lib/win/HCNetSDKCom/AnalyzeData.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/HCNetSDKCom/AudioIntercom.dll b/src/main/resources/lib/win/HCNetSDKCom/AudioIntercom.dll
deleted file mode 100644
index 071a5e2..0000000
Binary files a/src/main/resources/lib/win/HCNetSDKCom/AudioIntercom.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/HCNetSDKCom/AudioRender.dll b/src/main/resources/lib/win/HCNetSDKCom/AudioRender.dll
deleted file mode 100644
index 4935684..0000000
Binary files a/src/main/resources/lib/win/HCNetSDKCom/AudioRender.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/HCNetSDKCom/HCAlarm.dll b/src/main/resources/lib/win/HCNetSDKCom/HCAlarm.dll
deleted file mode 100644
index bdb8406..0000000
Binary files a/src/main/resources/lib/win/HCNetSDKCom/HCAlarm.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/HCNetSDKCom/HCAlarm.lib b/src/main/resources/lib/win/HCNetSDKCom/HCAlarm.lib
deleted file mode 100644
index 0aa0d4c..0000000
Binary files a/src/main/resources/lib/win/HCNetSDKCom/HCAlarm.lib and /dev/null differ
diff --git a/src/main/resources/lib/win/HCNetSDKCom/HCCoreDevCfg.dll b/src/main/resources/lib/win/HCNetSDKCom/HCCoreDevCfg.dll
deleted file mode 100644
index 7cd924e..0000000
Binary files a/src/main/resources/lib/win/HCNetSDKCom/HCCoreDevCfg.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/HCNetSDKCom/HCDisplay.dll b/src/main/resources/lib/win/HCNetSDKCom/HCDisplay.dll
deleted file mode 100644
index f0a2b7c..0000000
Binary files a/src/main/resources/lib/win/HCNetSDKCom/HCDisplay.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/HCNetSDKCom/HCGeneralCfgMgr.dll b/src/main/resources/lib/win/HCNetSDKCom/HCGeneralCfgMgr.dll
deleted file mode 100644
index 3719694..0000000
Binary files a/src/main/resources/lib/win/HCNetSDKCom/HCGeneralCfgMgr.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/HCNetSDKCom/HCGeneralCfgMgr.lib b/src/main/resources/lib/win/HCNetSDKCom/HCGeneralCfgMgr.lib
deleted file mode 100644
index 7091c25..0000000
Binary files a/src/main/resources/lib/win/HCNetSDKCom/HCGeneralCfgMgr.lib and /dev/null differ
diff --git a/src/main/resources/lib/win/HCNetSDKCom/HCIndustry.dll b/src/main/resources/lib/win/HCNetSDKCom/HCIndustry.dll
deleted file mode 100644
index 9af77a1..0000000
Binary files a/src/main/resources/lib/win/HCNetSDKCom/HCIndustry.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/HCNetSDKCom/HCPlayBack.dll b/src/main/resources/lib/win/HCNetSDKCom/HCPlayBack.dll
deleted file mode 100644
index 8d8e8a7..0000000
Binary files a/src/main/resources/lib/win/HCNetSDKCom/HCPlayBack.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/HCNetSDKCom/HCPreview.dll b/src/main/resources/lib/win/HCNetSDKCom/HCPreview.dll
deleted file mode 100644
index 005656d..0000000
Binary files a/src/main/resources/lib/win/HCNetSDKCom/HCPreview.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/HCNetSDKCom/HCPreview.lib b/src/main/resources/lib/win/HCNetSDKCom/HCPreview.lib
deleted file mode 100644
index 18d4d63..0000000
Binary files a/src/main/resources/lib/win/HCNetSDKCom/HCPreview.lib and /dev/null differ
diff --git a/src/main/resources/lib/win/HCNetSDKCom/HCVoiceTalk.dll b/src/main/resources/lib/win/HCNetSDKCom/HCVoiceTalk.dll
deleted file mode 100644
index eb04a1e..0000000
Binary files a/src/main/resources/lib/win/HCNetSDKCom/HCVoiceTalk.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/HCNetSDKCom/OpenAL32.dll b/src/main/resources/lib/win/HCNetSDKCom/OpenAL32.dll
deleted file mode 100644
index 4b35df4..0000000
Binary files a/src/main/resources/lib/win/HCNetSDKCom/OpenAL32.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/HCNetSDKCom/StreamTransClient.dll b/src/main/resources/lib/win/HCNetSDKCom/StreamTransClient.dll
deleted file mode 100644
index a69e9bf..0000000
Binary files a/src/main/resources/lib/win/HCNetSDKCom/StreamTransClient.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/HCNetSDKCom/SystemTransform.dll b/src/main/resources/lib/win/HCNetSDKCom/SystemTransform.dll
deleted file mode 100644
index f704e49..0000000
Binary files a/src/main/resources/lib/win/HCNetSDKCom/SystemTransform.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/HCNetSDKCom/libiconv2.dll b/src/main/resources/lib/win/HCNetSDKCom/libiconv2.dll
deleted file mode 100644
index 978e2fa..0000000
Binary files a/src/main/resources/lib/win/HCNetSDKCom/libiconv2.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/HXVA.dll b/src/main/resources/lib/win/HXVA.dll
deleted file mode 100644
index b7ebfcc..0000000
Binary files a/src/main/resources/lib/win/HXVA.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/HmMerge.dll b/src/main/resources/lib/win/HmMerge.dll
deleted file mode 100644
index d46a6ac..0000000
Binary files a/src/main/resources/lib/win/HmMerge.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/LocalSensorAdd.dat b/src/main/resources/lib/win/LocalSensorAdd.dat
deleted file mode 100644
index e69de29..0000000
diff --git a/src/main/resources/lib/win/LocalXml.zip b/src/main/resources/lib/win/LocalXml.zip
deleted file mode 100644
index 3620e68..0000000
Binary files a/src/main/resources/lib/win/LocalXml.zip and /dev/null differ
diff --git a/src/main/resources/lib/win/MP_Render.dll b/src/main/resources/lib/win/MP_Render.dll
deleted file mode 100644
index e5cde63..0000000
Binary files a/src/main/resources/lib/win/MP_Render.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/NPQos.dll b/src/main/resources/lib/win/NPQos.dll
deleted file mode 100644
index c709f56..0000000
Binary files a/src/main/resources/lib/win/NPQos.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/OpenAL32.dll b/src/main/resources/lib/win/OpenAL32.dll
deleted file mode 100644
index 4b35df4..0000000
Binary files a/src/main/resources/lib/win/OpenAL32.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/PlayCtrl.dll b/src/main/resources/lib/win/PlayCtrl.dll
deleted file mode 100644
index 2a5eb97..0000000
Binary files a/src/main/resources/lib/win/PlayCtrl.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/PlayCtrl.lib b/src/main/resources/lib/win/PlayCtrl.lib
deleted file mode 100644
index ddcf2f4..0000000
Binary files a/src/main/resources/lib/win/PlayCtrl.lib and /dev/null differ
diff --git a/src/main/resources/lib/win/SuperRender.dll b/src/main/resources/lib/win/SuperRender.dll
deleted file mode 100644
index b00c0c2..0000000
Binary files a/src/main/resources/lib/win/SuperRender.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/YUVProcess.dll b/src/main/resources/lib/win/YUVProcess.dll
deleted file mode 100644
index d86ec3f..0000000
Binary files a/src/main/resources/lib/win/YUVProcess.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/hlog.dll b/src/main/resources/lib/win/hlog.dll
deleted file mode 100644
index fe2298a..0000000
Binary files a/src/main/resources/lib/win/hlog.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/hpr.dll b/src/main/resources/lib/win/hpr.dll
deleted file mode 100644
index eef0d55..0000000
Binary files a/src/main/resources/lib/win/hpr.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/libcrypto-1_1-x64.dll b/src/main/resources/lib/win/libcrypto-1_1-x64.dll
deleted file mode 100644
index 6731338..0000000
Binary files a/src/main/resources/lib/win/libcrypto-1_1-x64.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/libmmd.dll b/src/main/resources/lib/win/libmmd.dll
deleted file mode 100644
index 8becb5e..0000000
Binary files a/src/main/resources/lib/win/libmmd.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/libssl-1_1-x64.dll b/src/main/resources/lib/win/libssl-1_1-x64.dll
deleted file mode 100644
index ac5e8fd..0000000
Binary files a/src/main/resources/lib/win/libssl-1_1-x64.dll and /dev/null differ
diff --git a/src/main/resources/lib/win/zlib1.dll b/src/main/resources/lib/win/zlib1.dll
deleted file mode 100644
index 9c37a84..0000000
Binary files a/src/main/resources/lib/win/zlib1.dll and /dev/null differ
diff --git a/src/main/resources/log4j2.xml b/src/main/resources/log4j2.xml
index b16e25c..6f9ad53 100644
--- a/src/main/resources/log4j2.xml
+++ b/src/main/resources/log4j2.xml
@@ -21,8 +21,8 @@
value="%d{yyyy-MM-dd HH:mm:ss.SSS} %highlight{%-5level}[%thread] %style{%logger{36}}{cyan} : %msg%n"/>
-
-
+
+
@@ -45,10 +45,10 @@
-
+
-
+
@@ -61,10 +61,10 @@
-
+
-
+
@@ -76,10 +76,10 @@
-
+
-
+
@@ -87,14 +87,14 @@
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
diff --git a/src/test/java/com/shxy/xyhkcamera/XyhkcameraApplicationTests.java b/src/test/java/com/shxy/xyhkcamera/XyhkcameraApplicationTests.java
index ee8b77d..0153be3 100644
--- a/src/test/java/com/shxy/xyhkcamera/XyhkcameraApplicationTests.java
+++ b/src/test/java/com/shxy/xyhkcamera/XyhkcameraApplicationTests.java
@@ -1,5 +1,6 @@
package com.shxy.xyhkcamera;
+import com.sun.jna.Pointer;
import org.junit.jupiter.api.Test;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.context.SpringBootTest;
@@ -7,8 +8,10 @@ import org.springframework.boot.test.context.SpringBootTest;
@SpringBootTest
class XyhkcameraApplicationTests {
-// @Autowired
-// HcNetSdkUtil hcNetSdkUtil;
+ @Autowired
+ HcNetSdkUtil hcNetSdkUtil;
+ private int handle;
+
@Test
void contextLoads() {
// hcNetSdkUtil.init();
@@ -21,16 +24,31 @@ class XyhkcameraApplicationTests {
// String loadLibrary = OSUtils.getLoadLibrary();
// System.out.println(loadLibrary);
-
- HCNetSDK.NET_DVR_SDKSTATE sdkState = new HCNetSDK.NET_DVR_SDKSTATE();
- //获取当前SDK状态信息
- boolean result = SdkInitService.hCNetSDK.NET_DVR_GetSDKState(sdkState);
- if (result) {
- sdkState.read();
- } else {
- int error = SdkInitService.hCNetSDK.NET_DVR_GetLastError();
+ hcNetSdkUtil.init();
+ HCNetSDK instance = hcNetSdkUtil.createSDKInstance();
+ int admin = hcNetSdkUtil.login_V40("192.168.1.64", (short) 8000, "admin", "SHxy@510");
+ if (admin != -1) {
+ HCNetSDK.NET_DVR_REALTIME_THERMOMETRY_COND cond = new HCNetSDK.NET_DVR_REALTIME_THERMOMETRY_COND();
+ cond.dwSize = cond.size();
+ cond.byRuleID = 1;
+ cond.dwChan = 2;
+
+ HCNetSDK.FRemoteConfigCallBack cbStateCallBack = new HCNetSDK.FRemoteConfigCallBack() {
+ @Override
+ public void invoke(int dwType, Pointer lpBuffer, int dwBufLen, Pointer pUserData) {
+ System.out.println("dfsafasd");
+ instance.NET_DVR_StopRemoteConfig(handle);
+
+ }
+ };
+ handle = instance.NET_DVR_StartRemoteConfig(admin, HCNetSDK.NET_DVR_GET_REALTIME_THERMOMETRY, cond.getPointer(), cond.size(), cbStateCallBack, null);
+ if (handle < 0) {
+ System.out.println(instance.NET_DVR_GetLastError());
+ }
+ System.out.println("fdsafa");
}
+
}
}