zjxpcyc 6 年 前
コミット
1a99813265
共有100 個のファイルを変更した5990 個の追加0 個の削除を含む
  1. 1
    0
      .idea/.name
  2. 13
    0
      .idea/compiler.xml
  3. 7
    0
      .idea/kotlinc.xml
  4. 14
    0
      .idea/misc.xml
  5. 124
    0
      .idea/uiDesigner.xml
  6. 772
    0
      .idea/workspace.xml
  7. 2
    0
      hardware.iml
  8. バイナリ
      hklib/AudioRender.dll
  9. バイナリ
      hklib/ClientDemo.exe
  10. 1
    0
      hklib/ClientDemoDll/ReadMe.txt
  11. バイナリ
      hklib/ClientDemoDll/calib.dll
  12. バイナリ
      hklib/ClientDemoDll/iconv.dll
  13. バイナリ
      hklib/ClientDemoDll/libxml2.dll
  14. バイナリ
      hklib/ClientDemoDll/zlib1.dll
  15. バイナリ
      hklib/EagleEyeRender.dll
  16. バイナリ
      hklib/GdiPlus.dll
  17. バイナリ
      hklib/GdiPlus.lib
  18. バイナリ
      hklib/HCCore.dll
  19. バイナリ
      hklib/HCCore.lib
  20. バイナリ
      hklib/HCNetSDK.dll
  21. バイナリ
      hklib/HCNetSDK.lib
  22. バイナリ
      hklib/HCNetSDKCom/AnalyzeData.dll
  23. バイナリ
      hklib/HCNetSDKCom/AudioIntercom.dll
  24. バイナリ
      hklib/HCNetSDKCom/HCAlarm.dll
  25. バイナリ
      hklib/HCNetSDKCom/HCAlarm.lib
  26. バイナリ
      hklib/HCNetSDKCom/HCCoreDevCfg.dll
  27. バイナリ
      hklib/HCNetSDKCom/HCDisplay.dll
  28. バイナリ
      hklib/HCNetSDKCom/HCGeneralCfgMgr.dll
  29. バイナリ
      hklib/HCNetSDKCom/HCGeneralCfgMgr.lib
  30. バイナリ
      hklib/HCNetSDKCom/HCIndustry.dll
  31. バイナリ
      hklib/HCNetSDKCom/HCPlayBack.dll
  32. バイナリ
      hklib/HCNetSDKCom/HCPreview.dll
  33. バイナリ
      hklib/HCNetSDKCom/HCPreview.lib
  34. バイナリ
      hklib/HCNetSDKCom/HCVoiceTalk.dll
  35. バイナリ
      hklib/HCNetSDKCom/OpenAL32.dll
  36. バイナリ
      hklib/HCNetSDKCom/StreamTransClient.dll
  37. バイナリ
      hklib/HCNetSDKCom/SystemTransform.dll
  38. バイナリ
      hklib/HCNetSDKCom/libiconv2.dll
  39. バイナリ
      hklib/HWDecode.dll
  40. バイナリ
      hklib/LocalXml.zip
  41. バイナリ
      hklib/MP_Render.dll
  42. バイナリ
      hklib/NPQos.dll
  43. バイナリ
      hklib/PlayCtrl.dll
  44. バイナリ
      hklib/PlayCtrl.lib
  45. バイナリ
      hklib/SuperRender.dll
  46. バイナリ
      hklib/YUVProcess.dll
  47. バイナリ
      hklib/hlog.dll
  48. バイナリ
      hklib/hpr.dll
  49. バイナリ
      hklib/libeay32.dll
  50. バイナリ
      hklib/libmmd.dll
  51. 26
    0
      hklib/log4cxx.properties
  52. バイナリ
      hklib/ssleay32.dll
  53. 50
    0
      pom.xml
  54. 9
    0
      setting.conf
  55. 303
    0
      src/main/java/Camera.java
  56. 25
    0
      src/main/java/Main.java
  57. 27
    0
      src/main/java/Monitor.java
  58. 4296
    0
      src/main/java/hik/HCNetSDK.java
  59. 66
    0
      src/main/java/utils/Configer.java
  60. 50
    0
      src/main/java/utils/Ping.java
  61. 16
    0
      src/main/java/utils/Rand.java
  62. 146
    0
      src/main/java/utils/Server.java
  63. 42
    0
      src/main/java/utils/TinyLog.java
  64. バイナリ
      src/main/resources/libs/examples.jar
  65. バイナリ
      target/classes/Camera.class
  66. バイナリ
      target/classes/Main.class
  67. バイナリ
      target/classes/Monitor.class
  68. バイナリ
      target/classes/hik/GDI32.class
  69. バイナリ
      target/classes/hik/HCNetSDK$BYTE_ARRAY.class
  70. バイナリ
      target/classes/hik/HCNetSDK$CAPTURE_MODE.class
  71. バイナリ
      target/classes/hik/HCNetSDK$CARDRIGHTPLAN.class
  72. バイナリ
      target/classes/hik/HCNetSDK$DISPLAY_MODE.class
  73. バイナリ
      target/classes/hik/HCNetSDK$FColGlobalDataCallBack.class
  74. バイナリ
      target/classes/hik/HCNetSDK$FColLocalDataCallBack.class
  75. バイナリ
      target/classes/hik/HCNetSDK$FDrawFun.class
  76. バイナリ
      target/classes/hik/HCNetSDK$FExceptionCallBack.class
  77. バイナリ
      target/classes/hik/HCNetSDK$FJpegdataCallBack.class
  78. バイナリ
      target/classes/hik/HCNetSDK$FMSGCallBack.class
  79. バイナリ
      target/classes/hik/HCNetSDK$FMSGCallBack_V31.class
  80. バイナリ
      target/classes/hik/HCNetSDK$FMessCallBack.class
  81. バイナリ
      target/classes/hik/HCNetSDK$FMessCallBack_EX.class
  82. バイナリ
      target/classes/hik/HCNetSDK$FMessCallBack_NEW.class
  83. バイナリ
      target/classes/hik/HCNetSDK$FMessageCallBack.class
  84. バイナリ
      target/classes/hik/HCNetSDK$FPlayDataCallBack.class
  85. バイナリ
      target/classes/hik/HCNetSDK$FPostMessageCallBack.class
  86. バイナリ
      target/classes/hik/HCNetSDK$FRealDataCallBack_V30.class
  87. バイナリ
      target/classes/hik/HCNetSDK$FRemoteConfigCallback.class
  88. バイナリ
      target/classes/hik/HCNetSDK$FRowDataCallBack.class
  89. バイナリ
      target/classes/hik/HCNetSDK$FSerialDataCallBack.class
  90. バイナリ
      target/classes/hik/HCNetSDK$FStdDataCallBack.class
  91. バイナリ
      target/classes/hik/HCNetSDK$FVoiceDataCallBack.class
  92. バイナリ
      target/classes/hik/HCNetSDK$FVoiceDataCallBack2.class
  93. バイナリ
      target/classes/hik/HCNetSDK$FVoiceDataCallBack_MR.class
  94. バイナリ
      target/classes/hik/HCNetSDK$FVoiceDataCallBack_MR_V30.class
  95. バイナリ
      target/classes/hik/HCNetSDK$FVoiceDataCallBack_V30.class
  96. バイナリ
      target/classes/hik/HCNetSDK$GpsDataParamUion.class
  97. バイナリ
      target/classes/hik/HCNetSDK$NET_DVRRECEIVER.class
  98. バイナリ
      target/classes/hik/HCNetSDK$NET_DVR_ACS_ALARM_INFO.class
  99. バイナリ
      target/classes/hik/HCNetSDK$NET_DVR_ACS_EVENT_INFO.class
  100. 0
    0
      target/classes/hik/HCNetSDK$NET_DVR_ADDIT_POSITION.class

+ 1
- 0
.idea/.name ファイルの表示

@@ -0,0 +1 @@
1
+welcome-hardware

+ 13
- 0
.idea/compiler.xml ファイルの表示

@@ -0,0 +1,13 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+<project version="4">
3
+  <component name="CompilerConfiguration">
4
+    <annotationProcessing>
5
+      <profile name="Maven default annotation processors profile" enabled="true">
6
+        <sourceOutputDir name="target/generated-sources/annotations" />
7
+        <sourceTestOutputDir name="target/generated-test-sources/test-annotations" />
8
+        <outputRelativeToContentRoot value="true" />
9
+        <module name="hardware" />
10
+      </profile>
11
+    </annotationProcessing>
12
+  </component>
13
+</project>

+ 7
- 0
.idea/kotlinc.xml ファイルの表示

@@ -0,0 +1,7 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+<project version="4">
3
+  <component name="Kotlin2JsCompilerArguments">
4
+    <option name="sourceMapEmbedSources" />
5
+    <option name="sourceMapPrefix" />
6
+  </component>
7
+</project>

+ 14
- 0
.idea/misc.xml ファイルの表示

@@ -0,0 +1,14 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+<project version="4">
3
+  <component name="ExternalStorageConfigurationManager" enabled="true" />
4
+  <component name="MavenProjectsManager">
5
+    <option name="originalFiles">
6
+      <list>
7
+        <option value="$PROJECT_DIR$/pom.xml" />
8
+      </list>
9
+    </option>
10
+  </component>
11
+  <component name="ProjectRootManager" version="2" languageLevel="JDK_1_8" project-jdk-name="1.8" project-jdk-type="JavaSDK">
12
+    <output url="file://$PROJECT_DIR$/out" />
13
+  </component>
14
+</project>

+ 124
- 0
.idea/uiDesigner.xml ファイルの表示

@@ -0,0 +1,124 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+<project version="4">
3
+  <component name="Palette2">
4
+    <group name="Swing">
5
+      <item class="com.intellij.uiDesigner.HSpacer" tooltip-text="Horizontal Spacer" icon="/com/intellij/uiDesigner/icons/hspacer.png" removable="false" auto-create-binding="false" can-attach-label="false">
6
+        <default-constraints vsize-policy="1" hsize-policy="6" anchor="0" fill="1" />
7
+      </item>
8
+      <item class="com.intellij.uiDesigner.VSpacer" tooltip-text="Vertical Spacer" icon="/com/intellij/uiDesigner/icons/vspacer.png" removable="false" auto-create-binding="false" can-attach-label="false">
9
+        <default-constraints vsize-policy="6" hsize-policy="1" anchor="0" fill="2" />
10
+      </item>
11
+      <item class="javax.swing.JPanel" icon="/com/intellij/uiDesigner/icons/panel.png" removable="false" auto-create-binding="false" can-attach-label="false">
12
+        <default-constraints vsize-policy="3" hsize-policy="3" anchor="0" fill="3" />
13
+      </item>
14
+      <item class="javax.swing.JScrollPane" icon="/com/intellij/uiDesigner/icons/scrollPane.png" removable="false" auto-create-binding="false" can-attach-label="true">
15
+        <default-constraints vsize-policy="7" hsize-policy="7" anchor="0" fill="3" />
16
+      </item>
17
+      <item class="javax.swing.JButton" icon="/com/intellij/uiDesigner/icons/button.png" removable="false" auto-create-binding="true" can-attach-label="false">
18
+        <default-constraints vsize-policy="0" hsize-policy="3" anchor="0" fill="1" />
19
+        <initial-values>
20
+          <property name="text" value="Button" />
21
+        </initial-values>
22
+      </item>
23
+      <item class="javax.swing.JRadioButton" icon="/com/intellij/uiDesigner/icons/radioButton.png" removable="false" auto-create-binding="true" can-attach-label="false">
24
+        <default-constraints vsize-policy="0" hsize-policy="3" anchor="8" fill="0" />
25
+        <initial-values>
26
+          <property name="text" value="RadioButton" />
27
+        </initial-values>
28
+      </item>
29
+      <item class="javax.swing.JCheckBox" icon="/com/intellij/uiDesigner/icons/checkBox.png" removable="false" auto-create-binding="true" can-attach-label="false">
30
+        <default-constraints vsize-policy="0" hsize-policy="3" anchor="8" fill="0" />
31
+        <initial-values>
32
+          <property name="text" value="CheckBox" />
33
+        </initial-values>
34
+      </item>
35
+      <item class="javax.swing.JLabel" icon="/com/intellij/uiDesigner/icons/label.png" removable="false" auto-create-binding="false" can-attach-label="false">
36
+        <default-constraints vsize-policy="0" hsize-policy="0" anchor="8" fill="0" />
37
+        <initial-values>
38
+          <property name="text" value="Label" />
39
+        </initial-values>
40
+      </item>
41
+      <item class="javax.swing.JTextField" icon="/com/intellij/uiDesigner/icons/textField.png" removable="false" auto-create-binding="true" can-attach-label="true">
42
+        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1">
43
+          <preferred-size width="150" height="-1" />
44
+        </default-constraints>
45
+      </item>
46
+      <item class="javax.swing.JPasswordField" icon="/com/intellij/uiDesigner/icons/passwordField.png" removable="false" auto-create-binding="true" can-attach-label="true">
47
+        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1">
48
+          <preferred-size width="150" height="-1" />
49
+        </default-constraints>
50
+      </item>
51
+      <item class="javax.swing.JFormattedTextField" icon="/com/intellij/uiDesigner/icons/formattedTextField.png" removable="false" auto-create-binding="true" can-attach-label="true">
52
+        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1">
53
+          <preferred-size width="150" height="-1" />
54
+        </default-constraints>
55
+      </item>
56
+      <item class="javax.swing.JTextArea" icon="/com/intellij/uiDesigner/icons/textArea.png" removable="false" auto-create-binding="true" can-attach-label="true">
57
+        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
58
+          <preferred-size width="150" height="50" />
59
+        </default-constraints>
60
+      </item>
61
+      <item class="javax.swing.JTextPane" icon="/com/intellij/uiDesigner/icons/textPane.png" removable="false" auto-create-binding="true" can-attach-label="true">
62
+        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
63
+          <preferred-size width="150" height="50" />
64
+        </default-constraints>
65
+      </item>
66
+      <item class="javax.swing.JEditorPane" icon="/com/intellij/uiDesigner/icons/editorPane.png" removable="false" auto-create-binding="true" can-attach-label="true">
67
+        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
68
+          <preferred-size width="150" height="50" />
69
+        </default-constraints>
70
+      </item>
71
+      <item class="javax.swing.JComboBox" icon="/com/intellij/uiDesigner/icons/comboBox.png" removable="false" auto-create-binding="true" can-attach-label="true">
72
+        <default-constraints vsize-policy="0" hsize-policy="2" anchor="8" fill="1" />
73
+      </item>
74
+      <item class="javax.swing.JTable" icon="/com/intellij/uiDesigner/icons/table.png" removable="false" auto-create-binding="true" can-attach-label="false">
75
+        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
76
+          <preferred-size width="150" height="50" />
77
+        </default-constraints>
78
+      </item>
79
+      <item class="javax.swing.JList" icon="/com/intellij/uiDesigner/icons/list.png" removable="false" auto-create-binding="true" can-attach-label="false">
80
+        <default-constraints vsize-policy="6" hsize-policy="2" anchor="0" fill="3">
81
+          <preferred-size width="150" height="50" />
82
+        </default-constraints>
83
+      </item>
84
+      <item class="javax.swing.JTree" icon="/com/intellij/uiDesigner/icons/tree.png" removable="false" auto-create-binding="true" can-attach-label="false">
85
+        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
86
+          <preferred-size width="150" height="50" />
87
+        </default-constraints>
88
+      </item>
89
+      <item class="javax.swing.JTabbedPane" icon="/com/intellij/uiDesigner/icons/tabbedPane.png" removable="false" auto-create-binding="true" can-attach-label="false">
90
+        <default-constraints vsize-policy="3" hsize-policy="3" anchor="0" fill="3">
91
+          <preferred-size width="200" height="200" />
92
+        </default-constraints>
93
+      </item>
94
+      <item class="javax.swing.JSplitPane" icon="/com/intellij/uiDesigner/icons/splitPane.png" removable="false" auto-create-binding="false" can-attach-label="false">
95
+        <default-constraints vsize-policy="3" hsize-policy="3" anchor="0" fill="3">
96
+          <preferred-size width="200" height="200" />
97
+        </default-constraints>
98
+      </item>
99
+      <item class="javax.swing.JSpinner" icon="/com/intellij/uiDesigner/icons/spinner.png" removable="false" auto-create-binding="true" can-attach-label="true">
100
+        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1" />
101
+      </item>
102
+      <item class="javax.swing.JSlider" icon="/com/intellij/uiDesigner/icons/slider.png" removable="false" auto-create-binding="true" can-attach-label="false">
103
+        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1" />
104
+      </item>
105
+      <item class="javax.swing.JSeparator" icon="/com/intellij/uiDesigner/icons/separator.png" removable="false" auto-create-binding="false" can-attach-label="false">
106
+        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3" />
107
+      </item>
108
+      <item class="javax.swing.JProgressBar" icon="/com/intellij/uiDesigner/icons/progressbar.png" removable="false" auto-create-binding="true" can-attach-label="false">
109
+        <default-constraints vsize-policy="0" hsize-policy="6" anchor="0" fill="1" />
110
+      </item>
111
+      <item class="javax.swing.JToolBar" icon="/com/intellij/uiDesigner/icons/toolbar.png" removable="false" auto-create-binding="false" can-attach-label="false">
112
+        <default-constraints vsize-policy="0" hsize-policy="6" anchor="0" fill="1">
113
+          <preferred-size width="-1" height="20" />
114
+        </default-constraints>
115
+      </item>
116
+      <item class="javax.swing.JToolBar$Separator" icon="/com/intellij/uiDesigner/icons/toolbarSeparator.png" removable="false" auto-create-binding="false" can-attach-label="false">
117
+        <default-constraints vsize-policy="0" hsize-policy="0" anchor="0" fill="1" />
118
+      </item>
119
+      <item class="javax.swing.JScrollBar" icon="/com/intellij/uiDesigner/icons/scrollbar.png" removable="false" auto-create-binding="true" can-attach-label="false">
120
+        <default-constraints vsize-policy="6" hsize-policy="0" anchor="0" fill="2" />
121
+      </item>
122
+    </group>
123
+  </component>
124
+</project>

+ 772
- 0
.idea/workspace.xml ファイルの表示

@@ -0,0 +1,772 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+<project version="4">
3
+  <component name="BookmarkManager">
4
+    <bookmark url="file://$PROJECT_DIR$/src/main/java/Camera.java" line="164" mnemonic="1" />
5
+  </component>
6
+  <component name="ChangeListManager">
7
+    <list default="true" id="ad2fe330-f201-4a05-ab3f-71348d2d007b" name="Default" comment="" />
8
+    <ignored path="$PROJECT_DIR$/out/" />
9
+    <ignored path="$PROJECT_DIR$/target/" />
10
+    <option name="EXCLUDED_CONVERTED_TO_IGNORED" value="true" />
11
+    <option name="TRACKING_ENABLED" value="true" />
12
+    <option name="SHOW_DIALOG" value="false" />
13
+    <option name="HIGHLIGHT_CONFLICTS" value="true" />
14
+    <option name="HIGHLIGHT_NON_ACTIVE_CHANGELIST" value="false" />
15
+    <option name="LAST_RESOLUTION" value="IGNORE" />
16
+  </component>
17
+  <component name="FileEditorManager">
18
+    <leaf>
19
+      <file leaf-file-name="Server.java" pinned="false" current-in-tab="false">
20
+        <entry file="file://$PROJECT_DIR$/src/main/java/utils/Server.java">
21
+          <provider selected="true" editor-type-id="text-editor">
22
+            <state relative-caret-position="779">
23
+              <caret line="50" column="13" lean-forward="true" selection-start-line="50" selection-start-column="13" selection-end-line="50" selection-end-column="13" />
24
+              <folding>
25
+                <element signature="imports" expanded="true" />
26
+                <element signature="e#118#119#0" expanded="true" />
27
+                <element signature="e#149#150#0" expanded="true" />
28
+                <element signature="e#3998#3999#0" expanded="true" />
29
+                <element signature="e#4053#4054#0" expanded="true" />
30
+              </folding>
31
+            </state>
32
+          </provider>
33
+        </entry>
34
+      </file>
35
+      <file leaf-file-name="Camera.java" pinned="false" current-in-tab="true">
36
+        <entry file="file://$PROJECT_DIR$/src/main/java/Camera.java">
37
+          <provider selected="true" editor-type-id="text-editor">
38
+            <state relative-caret-position="807">
39
+              <caret line="74" lean-forward="true" selection-start-line="74" selection-end-line="74" />
40
+              <folding>
41
+                <element signature="imports" expanded="true" />
42
+                <element signature="e#450#451#0" expanded="true" />
43
+                <element signature="e#481#482#0" expanded="true" />
44
+                <element signature="e#8420#8421#0" expanded="true" />
45
+                <element signature="e#8496#8497#0" expanded="true" />
46
+              </folding>
47
+            </state>
48
+          </provider>
49
+        </entry>
50
+      </file>
51
+      <file leaf-file-name="setting.conf" pinned="false" current-in-tab="false">
52
+        <entry file="file://$PROJECT_DIR$/setting.conf">
53
+          <provider selected="true" editor-type-id="text-editor">
54
+            <state relative-caret-position="76">
55
+              <caret line="4" column="17" selection-start-line="4" selection-start-column="17" selection-end-line="4" selection-end-column="17" />
56
+            </state>
57
+          </provider>
58
+        </entry>
59
+      </file>
60
+      <file leaf-file-name="Request.class" pinned="false" current-in-tab="false">
61
+        <entry file="jar://D:/REPO/com/squareup/okhttp3/okhttp/3.14.0/okhttp-3.14.0.jar!/okhttp3/Request.class">
62
+          <provider selected="true" editor-type-id="text-editor">
63
+            <state relative-caret-position="582">
64
+              <caret line="202" column="20" lean-forward="true" selection-start-line="202" selection-start-column="20" selection-end-line="202" selection-end-column="20" />
65
+            </state>
66
+          </provider>
67
+        </entry>
68
+      </file>
69
+      <file leaf-file-name="Main.java" pinned="false" current-in-tab="false">
70
+        <entry file="file://$PROJECT_DIR$/src/main/java/Main.java">
71
+          <provider selected="true" editor-type-id="text-editor">
72
+            <state relative-caret-position="57">
73
+              <caret line="3" column="13" selection-start-line="3" selection-start-column="13" selection-end-line="3" selection-end-column="13" />
74
+              <folding>
75
+                <element signature="imports" expanded="true" />
76
+              </folding>
77
+            </state>
78
+          </provider>
79
+        </entry>
80
+      </file>
81
+      <file leaf-file-name="Ping.java" pinned="false" current-in-tab="false">
82
+        <entry file="file://$PROJECT_DIR$/src/main/java/utils/Ping.java">
83
+          <provider selected="true" editor-type-id="text-editor">
84
+            <state relative-caret-position="703">
85
+              <caret line="37" selection-start-line="37" selection-end-line="37" />
86
+              <folding>
87
+                <element signature="imports" expanded="true" />
88
+              </folding>
89
+            </state>
90
+          </provider>
91
+        </entry>
92
+      </file>
93
+      <file leaf-file-name="Monitor.java" pinned="false" current-in-tab="false">
94
+        <entry file="file://$PROJECT_DIR$/src/main/java/Monitor.java">
95
+          <provider selected="true" editor-type-id="text-editor">
96
+            <state relative-caret-position="380">
97
+              <caret line="20" selection-start-line="20" selection-end-line="20" />
98
+            </state>
99
+          </provider>
100
+        </entry>
101
+      </file>
102
+      <file leaf-file-name="HCNetSDK.java" pinned="false" current-in-tab="false">
103
+        <entry file="file://$PROJECT_DIR$/src/main/java/hik/HCNetSDK.java">
104
+          <provider selected="true" editor-type-id="text-editor">
105
+            <state relative-caret-position="437">
106
+              <caret line="39" column="83" selection-start-line="39" selection-start-column="83" selection-end-line="39" selection-end-column="83" />
107
+              <folding>
108
+                <element signature="imports" expanded="true" />
109
+                <element signature="e#184910#184911#0" expanded="true" />
110
+                <element signature="e#184958#184959#0" expanded="true" />
111
+              </folding>
112
+            </state>
113
+          </provider>
114
+        </entry>
115
+      </file>
116
+      <file leaf-file-name="TinyLog.java" pinned="false" current-in-tab="false">
117
+        <entry file="file://$PROJECT_DIR$/src/main/java/utils/TinyLog.java">
118
+          <provider selected="true" editor-type-id="text-editor">
119
+            <state relative-caret-position="437">
120
+              <caret line="23" column="5" selection-start-line="23" selection-start-column="5" selection-end-line="23" selection-end-column="5" />
121
+              <folding>
122
+                <element signature="imports" expanded="true" />
123
+                <element signature="e#539#540#0" expanded="true" />
124
+                <element signature="e#577#578#0" expanded="true" />
125
+                <element signature="e#612#613#0" expanded="true" />
126
+                <element signature="e#699#700#0" expanded="true" />
127
+              </folding>
128
+            </state>
129
+          </provider>
130
+        </entry>
131
+      </file>
132
+      <file leaf-file-name="Configer.java" pinned="false" current-in-tab="false">
133
+        <entry file="file://$PROJECT_DIR$/src/main/java/utils/Configer.java">
134
+          <provider selected="true" editor-type-id="text-editor">
135
+            <state relative-caret-position="641">
136
+              <caret line="52" column="13" lean-forward="true" selection-start-line="52" selection-start-column="13" selection-end-line="52" selection-end-column="13" />
137
+              <folding>
138
+                <element signature="imports" expanded="true" />
139
+                <element signature="e#277#293#0" expanded="true" />
140
+                <element signature="e#358#359#0" expanded="true" />
141
+                <element signature="e#384#385#0" expanded="true" />
142
+                <element signature="e#1548#1549#0" expanded="true" />
143
+                <element signature="e#1584#1585#0" expanded="true" />
144
+              </folding>
145
+            </state>
146
+          </provider>
147
+        </entry>
148
+      </file>
149
+    </leaf>
150
+  </component>
151
+  <component name="FileTemplateManagerImpl">
152
+    <option name="RECENT_TEMPLATES">
153
+      <list>
154
+        <option value="Class" />
155
+      </list>
156
+    </option>
157
+  </component>
158
+  <component name="FindInProjectRecents">
159
+    <findStrings>
160
+      <find>examples</find>
161
+      <find>HWND</find>
162
+      <find>hik</find>
163
+      <find>hasHKError</find>
164
+      <find>../lib/HCNetSDK</find>
165
+      <find>/HCNetSDK</find>
166
+      <find>Pointer</find>
167
+    </findStrings>
168
+  </component>
169
+  <component name="IdeDocumentHistory">
170
+    <option name="CHANGED_PATHS">
171
+      <list>
172
+        <option value="$PROJECT_DIR$/src/main/java/utils/Http.java" />
173
+        <option value="$PROJECT_DIR$/pom.xml" />
174
+        <option value="$PROJECT_DIR$/src/main/java/utils/TinyLog.java" />
175
+        <option value="$PROJECT_DIR$/src/main/java/utils/Rand.java" />
176
+        <option value="$PROJECT_DIR$/src/main/java/Monitor.java" />
177
+        <option value="$PROJECT_DIR$/src/main/java/Main.java" />
178
+        <option value="$PROJECT_DIR$/src/main/java/hik/HCNetSDK.java" />
179
+        <option value="$PROJECT_DIR$/src/main/java/utils/Configer.java" />
180
+        <option value="$PROJECT_DIR$/src/main/java/utils/Server.java" />
181
+        <option value="$PROJECT_DIR$/src/main/java/utils/Ping.java" />
182
+        <option value="$PROJECT_DIR$/setting.conf" />
183
+        <option value="$PROJECT_DIR$/src/main/java/Camera.java" />
184
+      </list>
185
+    </option>
186
+  </component>
187
+  <component name="JsBuildToolGruntFileManager" detection-done="true" sorting="DEFINITION_ORDER" />
188
+  <component name="JsBuildToolPackageJson" detection-done="true" sorting="DEFINITION_ORDER" />
189
+  <component name="JsGulpfileManager">
190
+    <detection-done>true</detection-done>
191
+    <sorting>DEFINITION_ORDER</sorting>
192
+  </component>
193
+  <component name="MavenImportPreferences">
194
+    <option name="generalSettings">
195
+      <MavenGeneralSettings>
196
+        <option name="mavenHome" value="D:/Application/apache-maven-3.6.0" />
197
+        <option name="userSettingsFile" value="D:\Application\apache-maven-3.6.0\conf\settings.xml" />
198
+      </MavenGeneralSettings>
199
+    </option>
200
+    <option name="importingSettings">
201
+      <MavenImportingSettings>
202
+        <option name="importAutomatically" value="true" />
203
+      </MavenImportingSettings>
204
+    </option>
205
+  </component>
206
+  <component name="NodePackageJsonFileManager">
207
+    <packageJsonPaths />
208
+  </component>
209
+  <component name="ProjectFrameBounds" extendedState="6">
210
+    <option name="x" value="-16" />
211
+    <option name="width" value="1100" />
212
+    <option name="height" value="1940" />
213
+  </component>
214
+  <component name="ProjectView">
215
+    <navigator proportions="" version="1">
216
+      <foldersAlwaysOnTop value="true" />
217
+    </navigator>
218
+    <panes>
219
+      <pane id="PackagesPane" />
220
+      <pane id="AndroidView" />
221
+      <pane id="Scope" />
222
+      <pane id="ProjectPane">
223
+        <subPane>
224
+          <expand>
225
+            <path>
226
+              <item name="welcome-hardware" type="b2602c69:ProjectViewProjectNode" />
227
+              <item name="hardware" type="462c0819:PsiDirectoryNode" />
228
+            </path>
229
+            <path>
230
+              <item name="welcome-hardware" type="b2602c69:ProjectViewProjectNode" />
231
+              <item name="hardware" type="462c0819:PsiDirectoryNode" />
232
+              <item name="hklib" type="462c0819:PsiDirectoryNode" />
233
+            </path>
234
+            <path>
235
+              <item name="welcome-hardware" type="b2602c69:ProjectViewProjectNode" />
236
+              <item name="hardware" type="462c0819:PsiDirectoryNode" />
237
+              <item name="src" type="462c0819:PsiDirectoryNode" />
238
+            </path>
239
+            <path>
240
+              <item name="welcome-hardware" type="b2602c69:ProjectViewProjectNode" />
241
+              <item name="hardware" type="462c0819:PsiDirectoryNode" />
242
+              <item name="src" type="462c0819:PsiDirectoryNode" />
243
+              <item name="main" type="462c0819:PsiDirectoryNode" />
244
+            </path>
245
+            <path>
246
+              <item name="welcome-hardware" type="b2602c69:ProjectViewProjectNode" />
247
+              <item name="hardware" type="462c0819:PsiDirectoryNode" />
248
+              <item name="src" type="462c0819:PsiDirectoryNode" />
249
+              <item name="main" type="462c0819:PsiDirectoryNode" />
250
+              <item name="java" type="462c0819:PsiDirectoryNode" />
251
+            </path>
252
+            <path>
253
+              <item name="welcome-hardware" type="b2602c69:ProjectViewProjectNode" />
254
+              <item name="hardware" type="462c0819:PsiDirectoryNode" />
255
+              <item name="src" type="462c0819:PsiDirectoryNode" />
256
+              <item name="main" type="462c0819:PsiDirectoryNode" />
257
+              <item name="java" type="462c0819:PsiDirectoryNode" />
258
+              <item name="hik" type="462c0819:PsiDirectoryNode" />
259
+            </path>
260
+            <path>
261
+              <item name="welcome-hardware" type="b2602c69:ProjectViewProjectNode" />
262
+              <item name="hardware" type="462c0819:PsiDirectoryNode" />
263
+              <item name="src" type="462c0819:PsiDirectoryNode" />
264
+              <item name="main" type="462c0819:PsiDirectoryNode" />
265
+              <item name="java" type="462c0819:PsiDirectoryNode" />
266
+              <item name="hik" type="462c0819:PsiDirectoryNode" />
267
+              <item name="HCNetSDK.java" type="529ef68f:ClassesTreeStructureProvider$PsiClassOwnerTreeNode" />
268
+            </path>
269
+            <path>
270
+              <item name="welcome-hardware" type="b2602c69:ProjectViewProjectNode" />
271
+              <item name="hardware" type="462c0819:PsiDirectoryNode" />
272
+              <item name="src" type="462c0819:PsiDirectoryNode" />
273
+              <item name="main" type="462c0819:PsiDirectoryNode" />
274
+              <item name="java" type="462c0819:PsiDirectoryNode" />
275
+              <item name="utils" type="462c0819:PsiDirectoryNode" />
276
+            </path>
277
+            <path>
278
+              <item name="welcome-hardware" type="b2602c69:ProjectViewProjectNode" />
279
+              <item name="hardware" type="462c0819:PsiDirectoryNode" />
280
+              <item name="src" type="462c0819:PsiDirectoryNode" />
281
+              <item name="main" type="462c0819:PsiDirectoryNode" />
282
+              <item name="resources" type="462c0819:PsiDirectoryNode" />
283
+            </path>
284
+            <path>
285
+              <item name="welcome-hardware" type="b2602c69:ProjectViewProjectNode" />
286
+              <item name="hardware" type="462c0819:PsiDirectoryNode" />
287
+              <item name="src" type="462c0819:PsiDirectoryNode" />
288
+              <item name="main" type="462c0819:PsiDirectoryNode" />
289
+              <item name="resources" type="462c0819:PsiDirectoryNode" />
290
+              <item name="libs" type="462c0819:PsiDirectoryNode" />
291
+            </path>
292
+            <path>
293
+              <item name="welcome-hardware" type="b2602c69:ProjectViewProjectNode" />
294
+              <item name="External Libraries" type="cb654da1:ExternalLibrariesNode" />
295
+            </path>
296
+          </expand>
297
+          <select />
298
+        </subPane>
299
+      </pane>
300
+    </panes>
301
+  </component>
302
+  <component name="PropertiesComponent">
303
+    <property name="WebServerToolWindowFactoryState" value="false" />
304
+    <property name="aspect.path.notification.shown" value="true" />
305
+    <property name="nodejs_interpreter_path.stuck_in_default_project" value="undefined stuck path" />
306
+    <property name="nodejs_npm_path_reset_for_default_project" value="true" />
307
+    <property name="project.structure.last.edited" value="Project" />
308
+    <property name="project.structure.proportion" value="0.15" />
309
+    <property name="project.structure.side.proportion" value="0.2" />
310
+    <property name="settings.editor.selected.configurable" value="project.kotlinCompiler" />
311
+  </component>
312
+  <component name="RecentsManager">
313
+    <key name="CopyFile.RECENT_KEYS">
314
+      <recent name="E:\JavaProjects\welcome3.0\hardware\src\main\resources" />
315
+    </key>
316
+  </component>
317
+  <component name="RunDashboard">
318
+    <option name="ruleStates">
319
+      <list>
320
+        <RuleState>
321
+          <option name="name" value="ConfigurationTypeDashboardGroupingRule" />
322
+        </RuleState>
323
+        <RuleState>
324
+          <option name="name" value="StatusDashboardGroupingRule" />
325
+        </RuleState>
326
+      </list>
327
+    </option>
328
+  </component>
329
+  <component name="RunManager">
330
+    <configuration name="Main" type="Application" factoryName="Application" temporary="true" nameIsGenerated="true">
331
+      <option name="MAIN_CLASS_NAME" value="Main" />
332
+      <module name="hardware" />
333
+      <option name="WORKING_DIRECTORY" value="$PROJECT_DIR$" />
334
+    </configuration>
335
+    <configuration default="true" type="Application" factoryName="Application">
336
+      <option name="WORKING_DIRECTORY" value="$PROJECT_DIR$" />
337
+    </configuration>
338
+    <configuration default="true" type="JUnit" factoryName="JUnit">
339
+      <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
340
+      <option name="ALTERNATIVE_JRE_PATH" />
341
+      <option name="PACKAGE_NAME" />
342
+      <option name="MAIN_CLASS_NAME" />
343
+      <option name="METHOD_NAME" />
344
+      <option name="TEST_OBJECT" value="class" />
345
+      <option name="VM_PARAMETERS" value="-ea" />
346
+      <option name="PARAMETERS" />
347
+      <option name="WORKING_DIRECTORY" value="%MODULE_WORKING_DIR%" />
348
+      <option name="PASS_PARENT_ENVS" value="true" />
349
+      <option name="TEST_SEARCH_SCOPE">
350
+        <value defaultName="singleModule" />
351
+      </option>
352
+      <patterns />
353
+    </configuration>
354
+    <configuration default="true" type="TestNG" factoryName="TestNG">
355
+      <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
356
+      <option name="ALTERNATIVE_JRE_PATH" />
357
+      <option name="SUITE_NAME" />
358
+      <option name="PACKAGE_NAME" />
359
+      <option name="MAIN_CLASS_NAME" />
360
+      <option name="METHOD_NAME" />
361
+      <option name="GROUP_NAME" />
362
+      <option name="TEST_OBJECT" value="CLASS" />
363
+      <option name="VM_PARAMETERS" value="-ea" />
364
+      <option name="PARAMETERS" />
365
+      <option name="WORKING_DIRECTORY" value="%MODULE_WORKING_DIR%" />
366
+      <option name="OUTPUT_DIRECTORY" />
367
+      <option name="PASS_PARENT_ENVS" value="true" />
368
+      <option name="TEST_SEARCH_SCOPE">
369
+        <value defaultName="singleModule" />
370
+      </option>
371
+      <option name="USE_DEFAULT_REPORTERS" value="false" />
372
+      <option name="PROPERTIES_FILE" />
373
+      <properties />
374
+      <listeners />
375
+    </configuration>
376
+    <recent_temporary>
377
+      <list>
378
+        <item itemvalue="Application.Main" />
379
+      </list>
380
+    </recent_temporary>
381
+  </component>
382
+  <component name="SvnConfiguration">
383
+    <configuration />
384
+  </component>
385
+  <component name="TaskManager">
386
+    <task active="true" id="Default" summary="Default task">
387
+      <changelist id="ad2fe330-f201-4a05-ab3f-71348d2d007b" name="Default" comment="" />
388
+      <created>1554695584672</created>
389
+      <option name="number" value="Default" />
390
+      <option name="presentableId" value="Default" />
391
+      <updated>1554695584672</updated>
392
+      <workItem from="1554695586148" duration="42395000" />
393
+    </task>
394
+    <servers />
395
+  </component>
396
+  <component name="TimeTrackingManager">
397
+    <option name="totallyTimeSpent" value="42395000" />
398
+  </component>
399
+  <component name="ToolWindowManager">
400
+    <frame x="-8" y="-8" width="1096" height="1855" extended-state="6" />
401
+    <editor active="true" />
402
+    <layout>
403
+      <window_info anchor="right" id="Palette" />
404
+      <window_info anchor="bottom" id="TODO" order="6" />
405
+      <window_info anchor="bottom" id="Messages" />
406
+      <window_info anchor="right" id="Palette&#9;" />
407
+      <window_info id="Image Layers" />
408
+      <window_info anchor="right" id="Capture Analysis" />
409
+      <window_info anchor="bottom" id="Event Log" side_tool="true" />
410
+      <window_info anchor="right" id="Maven Projects" />
411
+      <window_info anchor="bottom" id="Database Changes" show_stripe_button="false" />
412
+      <window_info anchor="bottom" id="Run" order="2" weight="0.32964474" />
413
+      <window_info anchor="bottom" id="Version Control" show_stripe_button="false" />
414
+      <window_info anchor="bottom" id="Terminal" weight="0.32964474" />
415
+      <window_info id="Capture Tool" />
416
+      <window_info id="Designer" />
417
+      <window_info content_ui="combo" id="Project" order="0" visible="true" weight="0.22104247" />
418
+      <window_info anchor="right" id="Database" />
419
+      <window_info anchor="bottom" id="Find" order="1" weight="0.32964474" />
420
+      <window_info id="Structure" order="1" side_tool="true" weight="0.25" />
421
+      <window_info anchor="right" id="Ant Build" order="1" weight="0.25" />
422
+      <window_info id="UI Designer" />
423
+      <window_info anchor="right" id="Theme Preview" />
424
+      <window_info anchor="bottom" id="Debug" order="3" weight="0.39953408" />
425
+      <window_info id="Favorites" side_tool="true" />
426
+      <window_info anchor="right" id="Commander" internal_type="SLIDING" order="0" type="SLIDING" weight="0.4" />
427
+      <window_info anchor="bottom" id="Inspection" order="5" weight="0.4" />
428
+      <window_info anchor="right" content_ui="combo" id="Hierarchy" order="2" weight="0.25" />
429
+      <window_info anchor="bottom" id="Message" order="0" />
430
+      <window_info anchor="bottom" id="Cvs" order="4" weight="0.25" />
431
+    </layout>
432
+  </component>
433
+  <component name="TypeScriptGeneratedFilesManager">
434
+    <option name="version" value="1" />
435
+  </component>
436
+  <component name="VcsContentAnnotationSettings">
437
+    <option name="myLimit" value="2678400000" />
438
+  </component>
439
+  <component name="XDebuggerManager">
440
+    <breakpoint-manager>
441
+      <option name="time" value="9" />
442
+    </breakpoint-manager>
443
+  </component>
444
+  <component name="editorHistoryManager">
445
+    <entry file="jar://$PROJECT_DIR$/src/main/resources/libs/examples.jar!/com/sun/jna/examples/AlphaMaskDemo.class">
446
+      <provider selected="true" editor-type-id="text-editor">
447
+        <state relative-caret-position="-1482">
448
+          <caret line="69" column="13" selection-start-line="69" selection-start-column="13" selection-end-line="69" selection-end-column="13" />
449
+        </state>
450
+      </provider>
451
+    </entry>
452
+    <entry file="jar://$PROJECT_DIR$/src/main/resources/libs/examples.jar!/com/sun/jna/examples/AlphaMaskDemo2.class">
453
+      <provider selected="true" editor-type-id="text-editor">
454
+        <state relative-caret-position="113">
455
+          <caret line="47" column="13" selection-start-line="47" selection-start-column="13" selection-end-line="47" selection-end-column="13" />
456
+        </state>
457
+      </provider>
458
+    </entry>
459
+    <entry file="file://$PROJECT_DIR$/pom.xml">
460
+      <provider selected="true" editor-type-id="text-editor">
461
+        <state relative-caret-position="931">
462
+          <caret line="49" column="10" selection-start-line="49" selection-start-column="10" selection-end-line="49" selection-end-column="10" />
463
+        </state>
464
+      </provider>
465
+    </entry>
466
+    <entry file="jar://D:/REPO/com/alibaba/fastjson/1.2.56/fastjson-1.2.56.jar!/com/alibaba/fastjson/JSON.class">
467
+      <provider selected="true" editor-type-id="text-editor">
468
+        <state relative-caret-position="564">
469
+          <caret line="89" column="25" selection-start-line="89" selection-start-column="25" selection-end-line="89" selection-end-column="25" />
470
+          <folding>
471
+            <element signature="e#3555#3556#0" expanded="true" />
472
+            <element signature="e#3613#3614#0" expanded="true" />
473
+          </folding>
474
+        </state>
475
+      </provider>
476
+    </entry>
477
+    <entry file="file://$PROJECT_DIR$/src/main/java/utils/TinyLog.java">
478
+      <provider selected="true" editor-type-id="text-editor">
479
+        <state relative-caret-position="437">
480
+          <caret line="23" column="5" selection-start-line="23" selection-start-column="5" selection-end-line="23" selection-end-column="5" />
481
+          <folding>
482
+            <element signature="imports" expanded="true" />
483
+            <element signature="e#539#540#0" expanded="true" />
484
+            <element signature="e#577#578#0" expanded="true" />
485
+            <element signature="e#612#613#0" expanded="true" />
486
+            <element signature="e#699#700#0" expanded="true" />
487
+          </folding>
488
+        </state>
489
+      </provider>
490
+    </entry>
491
+    <entry file="jar://D:/REPO/com/sun/jna/jna/3.0.9/jna-3.0.9.jar!/com/sun/jna/Structure.class">
492
+      <provider selected="true" editor-type-id="text-editor">
493
+        <state relative-caret-position="547">
494
+          <caret line="408" column="16" selection-start-line="408" selection-start-column="16" selection-end-line="408" selection-end-column="16" />
495
+        </state>
496
+      </provider>
497
+    </entry>
498
+    <entry file="jar://D:/Application/jdk1.8.0_161/src.zip!/java/nio/ByteBuffer.java">
499
+      <provider selected="true" editor-type-id="text-editor">
500
+        <state relative-caret-position="564">
501
+          <caret line="713" column="22" selection-start-line="713" selection-start-column="22" selection-end-line="713" selection-end-column="22" />
502
+          <folding>
503
+            <element signature="e#19972#19973#0" expanded="true" />
504
+            <element signature="e#20018#20019#0" expanded="true" />
505
+          </folding>
506
+        </state>
507
+      </provider>
508
+    </entry>
509
+    <entry file="jar://D:/Application/jdk1.8.0_161/src.zip!/java/nio/Buffer.java">
510
+      <provider selected="true" editor-type-id="text-editor">
511
+        <state relative-caret-position="-424">
512
+          <caret line="377" column="24" selection-start-line="377" selection-start-column="24" selection-end-line="377" selection-end-column="24" />
513
+        </state>
514
+      </provider>
515
+    </entry>
516
+    <entry file="jar://D:/Application/jdk1.8.0_161/src.zip!/java/util/Map.java">
517
+      <provider selected="true" editor-type-id="text-editor">
518
+        <state relative-caret-position="556">
519
+          <caret line="395" column="10" selection-start-line="395" selection-start-column="10" selection-end-line="395" selection-end-column="10" />
520
+        </state>
521
+      </provider>
522
+    </entry>
523
+    <entry file="jar://D:/Application/jdk1.8.0_161/src.zip!/java/lang/String.java">
524
+      <provider selected="true" editor-type-id="text-editor">
525
+        <state relative-caret-position="564">
526
+          <caret line="110" column="19" selection-start-line="110" selection-start-column="19" selection-end-line="110" selection-end-column="19" />
527
+        </state>
528
+      </provider>
529
+    </entry>
530
+    <entry file="jar://D:/Application/jdk1.8.0_161/src.zip!/java/lang/Class.java">
531
+      <provider selected="true" editor-type-id="text-editor">
532
+        <state relative-caret-position="697">
533
+          <caret line="1350" column="44" selection-start-line="1350" selection-start-column="28" selection-end-line="1350" selection-end-column="44" />
534
+        </state>
535
+      </provider>
536
+    </entry>
537
+    <entry file="file://$PROJECT_DIR$/src/main/java/utils/Rand.java">
538
+      <provider selected="true" editor-type-id="text-editor">
539
+        <state relative-caret-position="304">
540
+          <caret line="16" lean-forward="true" selection-start-line="16" selection-end-line="16" />
541
+        </state>
542
+      </provider>
543
+    </entry>
544
+    <entry file="jar://D:/Application/jdk1.8.0_161/src.zip!/java/util/regex/Matcher.java">
545
+      <provider selected="true" editor-type-id="text-editor">
546
+        <state relative-caret-position="-6">
547
+          <caret line="587" column="43" selection-start-line="587" selection-start-column="43" selection-end-line="587" selection-end-column="43" />
548
+        </state>
549
+      </provider>
550
+    </entry>
551
+    <entry file="jar://D:/REPO/com/sun/jna/jna/3.0.9/jna-3.0.9.jar!/com/sun/jna/win32/StdCallLibrary.class">
552
+      <provider selected="true" editor-type-id="text-editor">
553
+        <state relative-caret-position="114">
554
+          <caret line="11" column="17" selection-start-line="11" selection-start-column="17" selection-end-line="11" selection-end-column="17" />
555
+        </state>
556
+      </provider>
557
+    </entry>
558
+    <entry file="file://$PROJECT_DIR$/src/main/java/hik/HCNetSDK.java">
559
+      <provider selected="true" editor-type-id="text-editor">
560
+        <state relative-caret-position="437">
561
+          <caret line="39" column="83" selection-start-line="39" selection-start-column="83" selection-end-line="39" selection-end-column="83" />
562
+          <folding>
563
+            <element signature="imports" expanded="true" />
564
+            <element signature="e#184910#184911#0" expanded="true" />
565
+            <element signature="e#184958#184959#0" expanded="true" />
566
+          </folding>
567
+        </state>
568
+      </provider>
569
+    </entry>
570
+    <entry file="jar://D:/REPO/com/sun/jna/jna/3.0.9/jna-3.0.9.jar!/com/sun/jna/Pointer.class">
571
+      <provider selected="true" editor-type-id="text-editor">
572
+        <state relative-caret-position="304">
573
+          <caret line="26" column="17" selection-start-line="26" selection-start-column="13" selection-end-line="26" selection-end-column="17" />
574
+        </state>
575
+      </provider>
576
+    </entry>
577
+    <entry file="jar://D:/REPO/com/sun/jna/jna/3.0.9/jna-3.0.9.jar!/com/sun/jna/ptr/NativeLongByReference.class">
578
+      <provider selected="true" editor-type-id="text-editor">
579
+        <state relative-caret-position="133">
580
+          <caret line="10" column="11" selection-start-line="10" selection-start-column="11" selection-end-line="10" selection-end-column="11" />
581
+          <folding>
582
+            <element signature="e#256#257#0" expanded="true" />
583
+            <element signature="e#296#297#0" expanded="true" />
584
+          </folding>
585
+        </state>
586
+      </provider>
587
+    </entry>
588
+    <entry file="jar://D:/REPO/com/sun/jna/jna/3.0.9/jna-3.0.9.jar!/com/sun/jna/NativeLong.class">
589
+      <provider selected="true" editor-type-id="text-editor">
590
+        <state relative-caret-position="133">
591
+          <caret line="10" column="11" selection-start-line="10" selection-start-column="11" selection-end-line="10" selection-end-column="11" />
592
+          <folding>
593
+            <element signature="e#233#234#0" expanded="true" />
594
+            <element signature="e#257#258#0" expanded="true" />
595
+          </folding>
596
+        </state>
597
+      </provider>
598
+    </entry>
599
+    <entry file="file://$PROJECT_DIR$/src/main/java/Main.java">
600
+      <provider selected="true" editor-type-id="text-editor">
601
+        <state relative-caret-position="57">
602
+          <caret line="3" column="13" selection-start-line="3" selection-start-column="13" selection-end-line="3" selection-end-column="13" />
603
+          <folding>
604
+            <element signature="imports" expanded="true" />
605
+          </folding>
606
+        </state>
607
+      </provider>
608
+    </entry>
609
+    <entry file="file://$PROJECT_DIR$/src/main/java/utils/Configer.java">
610
+      <provider selected="true" editor-type-id="text-editor">
611
+        <state relative-caret-position="641">
612
+          <caret line="52" column="13" lean-forward="true" selection-start-line="52" selection-start-column="13" selection-end-line="52" selection-end-column="13" />
613
+          <folding>
614
+            <element signature="imports" expanded="true" />
615
+            <element signature="e#277#293#0" expanded="true" />
616
+            <element signature="e#358#359#0" expanded="true" />
617
+            <element signature="e#384#385#0" expanded="true" />
618
+            <element signature="e#1548#1549#0" expanded="true" />
619
+            <element signature="e#1584#1585#0" expanded="true" />
620
+          </folding>
621
+        </state>
622
+      </provider>
623
+    </entry>
624
+    <entry file="jar://D:/REPO/com/squareup/okhttp3/okhttp/3.14.0/okhttp-3.14.0.jar!/okhttp3/Request.class">
625
+      <provider selected="true" editor-type-id="text-editor">
626
+        <state relative-caret-position="582">
627
+          <caret line="202" column="20" lean-forward="true" selection-start-line="202" selection-start-column="20" selection-end-line="202" selection-end-column="20" />
628
+        </state>
629
+      </provider>
630
+    </entry>
631
+    <entry file="file://$PROJECT_DIR$/src/main/java/utils/Server.java">
632
+      <provider selected="true" editor-type-id="text-editor">
633
+        <state relative-caret-position="779">
634
+          <caret line="50" column="13" lean-forward="true" selection-start-line="50" selection-start-column="13" selection-end-line="50" selection-end-column="13" />
635
+          <folding>
636
+            <element signature="imports" expanded="true" />
637
+            <element signature="e#118#119#0" expanded="true" />
638
+            <element signature="e#149#150#0" expanded="true" />
639
+            <element signature="e#3998#3999#0" expanded="true" />
640
+            <element signature="e#4053#4054#0" expanded="true" />
641
+          </folding>
642
+        </state>
643
+      </provider>
644
+    </entry>
645
+    <entry file="file://$PROJECT_DIR$/setting.conf">
646
+      <provider selected="true" editor-type-id="text-editor">
647
+        <state relative-caret-position="76">
648
+          <caret line="4" column="17" selection-start-line="4" selection-start-column="17" selection-end-line="4" selection-end-column="17" />
649
+        </state>
650
+      </provider>
651
+    </entry>
652
+    <entry file="file://$PROJECT_DIR$/src/main/java/Monitor.java">
653
+      <provider selected="true" editor-type-id="text-editor">
654
+        <state relative-caret-position="380">
655
+          <caret line="20" selection-start-line="20" selection-end-line="20" />
656
+        </state>
657
+      </provider>
658
+    </entry>
659
+    <entry file="file://$PROJECT_DIR$/src/main/java/utils/Ping.java">
660
+      <provider selected="true" editor-type-id="text-editor">
661
+        <state relative-caret-position="703">
662
+          <caret line="37" selection-start-line="37" selection-end-line="37" />
663
+          <folding>
664
+            <element signature="imports" expanded="true" />
665
+          </folding>
666
+        </state>
667
+      </provider>
668
+    </entry>
669
+    <entry file="file://$PROJECT_DIR$/src/main/java/Camera.java">
670
+      <provider selected="true" editor-type-id="text-editor">
671
+        <state relative-caret-position="807">
672
+          <caret line="74" lean-forward="true" selection-start-line="74" selection-end-line="74" />
673
+          <folding>
674
+            <element signature="imports" expanded="true" />
675
+            <element signature="e#450#451#0" expanded="true" />
676
+            <element signature="e#481#482#0" expanded="true" />
677
+            <element signature="e#8420#8421#0" expanded="true" />
678
+            <element signature="e#8496#8497#0" expanded="true" />
679
+          </folding>
680
+        </state>
681
+      </provider>
682
+    </entry>
683
+  </component>
684
+  <component name="masterDetails">
685
+    <states>
686
+      <state key="ArtifactsStructureConfigurable.UI">
687
+        <settings>
688
+          <artifact-editor />
689
+          <splitter-proportions>
690
+            <option name="proportions">
691
+              <list>
692
+                <option value="0.2" />
693
+              </list>
694
+            </option>
695
+          </splitter-proportions>
696
+        </settings>
697
+      </state>
698
+      <state key="FacetStructureConfigurable.UI">
699
+        <settings>
700
+          <last-edited>No facets are configured</last-edited>
701
+          <splitter-proportions>
702
+            <option name="proportions">
703
+              <list>
704
+                <option value="0.2" />
705
+              </list>
706
+            </option>
707
+          </splitter-proportions>
708
+        </settings>
709
+      </state>
710
+      <state key="GlobalLibrariesConfigurable.UI">
711
+        <settings>
712
+          <splitter-proportions>
713
+            <option name="proportions">
714
+              <list>
715
+                <option value="0.2" />
716
+              </list>
717
+            </option>
718
+          </splitter-proportions>
719
+        </settings>
720
+      </state>
721
+      <state key="JdkListConfigurable.UI">
722
+        <settings>
723
+          <last-edited>1.8</last-edited>
724
+          <splitter-proportions>
725
+            <option name="proportions">
726
+              <list>
727
+                <option value="0.2" />
728
+              </list>
729
+            </option>
730
+          </splitter-proportions>
731
+        </settings>
732
+      </state>
733
+      <state key="ModuleStructureConfigurable.UI">
734
+        <settings>
735
+          <last-edited>hardware</last-edited>
736
+          <splitter-proportions>
737
+            <option name="proportions">
738
+              <list>
739
+                <option value="0.2" />
740
+                <option value="0.6" />
741
+              </list>
742
+            </option>
743
+          </splitter-proportions>
744
+        </settings>
745
+      </state>
746
+      <state key="ProjectJDKs.UI">
747
+        <settings>
748
+          <last-edited>1.8</last-edited>
749
+          <splitter-proportions>
750
+            <option name="proportions">
751
+              <list>
752
+                <option value="0.2" />
753
+              </list>
754
+            </option>
755
+          </splitter-proportions>
756
+        </settings>
757
+      </state>
758
+      <state key="ProjectLibrariesConfigurable.UI">
759
+        <settings>
760
+          <last-edited>Maven: com.squareup.okhttp3:okhttp:3.14.0</last-edited>
761
+          <splitter-proportions>
762
+            <option name="proportions">
763
+              <list>
764
+                <option value="0.2" />
765
+              </list>
766
+            </option>
767
+          </splitter-proportions>
768
+        </settings>
769
+      </state>
770
+    </states>
771
+  </component>
772
+</project>

+ 2
- 0
hardware.iml ファイルの表示

@@ -0,0 +1,2 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+<module type="JAVA_MODULE" version="4" />

バイナリ
hklib/AudioRender.dll ファイルの表示


バイナリ
hklib/ClientDemo.exe ファイルの表示


+ 1
- 0
hklib/ClientDemoDll/ReadMe.txt ファイルの表示

@@ -0,0 +1 @@
1
+The dll in this directory£¨iconv.dll,libxml2.dll,zlib1.dll,calib.dll£©only used in ClientDemo.

バイナリ
hklib/ClientDemoDll/calib.dll ファイルの表示


バイナリ
hklib/ClientDemoDll/iconv.dll ファイルの表示


バイナリ
hklib/ClientDemoDll/libxml2.dll ファイルの表示


バイナリ
hklib/ClientDemoDll/zlib1.dll ファイルの表示


バイナリ
hklib/EagleEyeRender.dll ファイルの表示


バイナリ
hklib/GdiPlus.dll ファイルの表示


バイナリ
hklib/GdiPlus.lib ファイルの表示


バイナリ
hklib/HCCore.dll ファイルの表示


バイナリ
hklib/HCCore.lib ファイルの表示


バイナリ
hklib/HCNetSDK.dll ファイルの表示


バイナリ
hklib/HCNetSDK.lib ファイルの表示


バイナリ
hklib/HCNetSDKCom/AnalyzeData.dll ファイルの表示


バイナリ
hklib/HCNetSDKCom/AudioIntercom.dll ファイルの表示


バイナリ
hklib/HCNetSDKCom/HCAlarm.dll ファイルの表示


バイナリ
hklib/HCNetSDKCom/HCAlarm.lib ファイルの表示


バイナリ
hklib/HCNetSDKCom/HCCoreDevCfg.dll ファイルの表示


バイナリ
hklib/HCNetSDKCom/HCDisplay.dll ファイルの表示


バイナリ
hklib/HCNetSDKCom/HCGeneralCfgMgr.dll ファイルの表示


バイナリ
hklib/HCNetSDKCom/HCGeneralCfgMgr.lib ファイルの表示


バイナリ
hklib/HCNetSDKCom/HCIndustry.dll ファイルの表示


バイナリ
hklib/HCNetSDKCom/HCPlayBack.dll ファイルの表示


バイナリ
hklib/HCNetSDKCom/HCPreview.dll ファイルの表示


バイナリ
hklib/HCNetSDKCom/HCPreview.lib ファイルの表示


バイナリ
hklib/HCNetSDKCom/HCVoiceTalk.dll ファイルの表示


バイナリ
hklib/HCNetSDKCom/OpenAL32.dll ファイルの表示


バイナリ
hklib/HCNetSDKCom/StreamTransClient.dll ファイルの表示


バイナリ
hklib/HCNetSDKCom/SystemTransform.dll ファイルの表示


バイナリ
hklib/HCNetSDKCom/libiconv2.dll ファイルの表示


バイナリ
hklib/HWDecode.dll ファイルの表示


バイナリ
hklib/LocalXml.zip ファイルの表示


バイナリ
hklib/MP_Render.dll ファイルの表示


バイナリ
hklib/NPQos.dll ファイルの表示


バイナリ
hklib/PlayCtrl.dll ファイルの表示


バイナリ
hklib/PlayCtrl.lib ファイルの表示


バイナリ
hklib/SuperRender.dll ファイルの表示


バイナリ
hklib/YUVProcess.dll ファイルの表示


バイナリ
hklib/hlog.dll ファイルの表示


バイナリ
hklib/hpr.dll ファイルの表示


バイナリ
hklib/libeay32.dll ファイルの表示


バイナリ
hklib/libmmd.dll ファイルの表示


+ 26
- 0
hklib/log4cxx.properties ファイルの表示

@@ -0,0 +1,26 @@
1
+#缺省不输出日志到控制台
2
+#FATAL、ERROR、WARN、INFO、DEBUG 优先级顺序  如果子模块和根模块都匹配,那么都会输出
3
+log4j.rootLogger=DEBUG, stdout
4
+#log4j.rootLogger=DEBUG
5
+##hlog.async=false
6
+##hlog.secret.show=true
7
+##hlog.secret.encrypt=false
8
+#log4j.logger用于控制日志采集级别及采集内容,Threshold用于控制日志输出级别
9
+
10
+#应用于控制台
11
+log4j.appender.stdout=org.apache.log4j.ConsoleAppender 
12
+log4j.appender.stdout.layout=org.apache.log4j.PatternLayout 
13
+log4j.appender.stdout.layout.ConversionPattern=[%d][%t][%-5p]- %m%n
14
+
15
+log4j.logger.NPQ=ERROR, NPQ
16
+log4j.appender.NPQ=org.apache.log4j.RollingFileAppender
17
+log4j.appender.NPQ.File=./NPQLog/NPQ.log
18
+log4j.appender.NPQ.MaxFileSize=80MB
19
+log4j.appender.NPQ.MaxBackupIndex=12
20
+log4j.appender.NPQ.Append=true
21
+log4j.appender.NPQ.Threshold=TRACE
22
+log4j.appender.NPQ.layout=org.apache.log4j.PatternLayout
23
+log4j.appender.NPQ.layout.ConversionPattern=[%d][%t][%-5p]- %m%n
24
+log4j.additivity.NPQ = false
25
+#最后一位修改为true 既可以控制台输出又可以文件输出
26
+

バイナリ
hklib/ssleay32.dll ファイルの表示


+ 50
- 0
pom.xml ファイルの表示

@@ -0,0 +1,50 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+<project xmlns="http://maven.apache.org/POM/4.0.0"
3
+         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
4
+         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
5
+    <modelVersion>4.0.0</modelVersion>
6
+
7
+    <groupId>com.huiju.welcome</groupId>
8
+    <artifactId>hardware</artifactId>
9
+    <version>v3.0.0</version>
10
+    <build>
11
+        <plugins>
12
+            <plugin>
13
+                <groupId>org.apache.maven.plugins</groupId>
14
+                <artifactId>maven-compiler-plugin</artifactId>
15
+                <configuration>
16
+                    <source>8</source>
17
+                    <target>8</target>
18
+                </configuration>
19
+            </plugin>
20
+        </plugins>
21
+    </build>
22
+
23
+    <dependencies>
24
+        <dependency>
25
+            <groupId>com.huiju</groupId>
26
+            <artifactId>examples</artifactId>
27
+            <version>1.0.0</version>
28
+            <scope>system</scope>
29
+            <systemPath>${project.basedir}\src\main\resources\libs\examples.jar</systemPath>
30
+        </dependency>
31
+
32
+        <dependency>
33
+            <groupId>com.sun.jna</groupId>
34
+            <artifactId>jna</artifactId>
35
+            <version>3.0.9</version>
36
+        </dependency>
37
+
38
+        <dependency>
39
+            <groupId>com.squareup.okhttp3</groupId>
40
+            <artifactId>okhttp</artifactId>
41
+            <version>3.14.0</version>
42
+        </dependency>
43
+
44
+        <dependency>
45
+            <groupId>com.alibaba</groupId>
46
+            <artifactId>fastjson</artifactId>
47
+            <version>1.2.56</version>
48
+        </dependency>
49
+    </dependencies>
50
+</project>

+ 9
- 0
setting.conf ファイルの表示

@@ -0,0 +1,9 @@
1
+id = 170
2
+name = 展厅抓拍相机
3
+user = huiju
4
+password = huiju999
5
+ip = 192.168.0.13
6
+port = 8000
7
+api = 
8
+hiklib = E:\JavaProjects\welcome3.0\hardware\hklib
9
+server = http://127.0.0.1:8080

+ 303
- 0
src/main/java/Camera.java ファイルの表示

@@ -0,0 +1,303 @@
1
+import com.sun.jna.NativeLong;
2
+import com.sun.jna.Pointer;
3
+import com.sun.jna.ptr.NativeLongByReference;
4
+import hik.HCNetSDK;
5
+import utils.Configer;
6
+import utils.Server;
7
+import utils.TinyLog;
8
+
9
+import java.io.UnsupportedEncodingException;
10
+import java.nio.ByteBuffer;
11
+import java.util.HashMap;
12
+import java.util.Map;
13
+
14
+/**
15
+ * 一个进程只允许连接一个设备
16
+ * 人脸抓拍流程 - 使用的是海康报警布防流程
17
+ *
18
+ * 1、初始化SDK NET_DVR_Init
19
+ * 2、用户注册  NET_DVR_Login_V40
20
+ * 3、设置报警回调函数 NET_DVR_SetDVRMessCallBack_V30
21
+ * 4、报警布防 NET_DVR_SetupAlarmChan_V41
22
+ *
23
+ * 剩下的步骤为撤销动作
24
+ * 5、报警撤防 NET_DVR_CloseAlarmChan_V30
25
+ * 6、注销用户  NET_DVR_Logout
26
+ * 7、释放SDK资源  NET_DVR_Cleanup
27
+ */
28
+public class Camera implements HCNetSDK.FMSGCallBack_V31 {
29
+    // sdk instance
30
+    private static HCNetSDK hk = HCNetSDK.INSTANCE;
31
+
32
+    // 网络是OK的
33
+    private boolean netError = false;
34
+
35
+    // 配置参数
36
+    private String deviceID;
37
+    private String deviceName;
38
+    private String deviceAPI;
39
+    private String serverAPI;
40
+    private String ip;
41
+    private String userName;
42
+    private String password;
43
+    private int port;
44
+
45
+    // sdk 初始化
46
+    private boolean sdkInited = false;
47
+    private boolean logged = false;
48
+    private boolean registed = false;
49
+    private boolean setCallback = false;
50
+
51
+    // 摄像头
52
+    HCNetSDK.NET_DVR_DEVICEINFO_V30 device = new HCNetSDK.NET_DVR_DEVICEINFO_V30();
53
+    // 用户
54
+    private NativeLong user = new NativeLong(-1);
55
+
56
+    // 单例
57
+    private static final Camera INSTANCE = new Camera();
58
+    private Camera(){}
59
+    public static Camera getInstance(){
60
+        return INSTANCE;
61
+    }
62
+
63
+    // 接口初始化 - 必须先调用
64
+    // 主要有3个动作, sdk init, user login, device registe
65
+    // 其中 device registe 是通知主服务的, 跟海康没关系
66
+    public void connect() {
67
+        int tryTimes = 0;
68
+        int waitSec = 5;
69
+
70
+        while (!sdkInited || !logged || !registed || !setCallback) {
71
+            if (netError) {
72
+                TinyLog.error("网络不通, 取消设备连接");
73
+                return;
74
+            }
75
+
76
+            if (!sdkInited) {
77
+                init();
78
+            }
79
+
80
+            if (sdkInited && !logged) {
81
+                login();
82
+            }
83
+
84
+            if (sdkInited && logged && !setCallback) {
85
+                setAlarmCallback();
86
+            }
87
+
88
+            if (sdkInited && logged && setCallback && !registed) {
89
+                setOnline();
90
+            }
91
+
92
+            tryTimes += 1;
93
+            TinyLog.error("连接并注册设备失败");
94
+            TinyLog.error(String.valueOf(waitSec) + " 秒后第 " +String.valueOf(tryTimes)+ " 次重试");
95
+            try {
96
+                Thread.sleep(waitSec * 1000);
97
+            } catch (InterruptedException e) {
98
+                e.printStackTrace();
99
+            }
100
+
101
+            if (tryTimes >=5 ) {
102
+                waitSec *= 2; // 等待时间翻倍
103
+            }
104
+
105
+            TinyLog.error("开始重试...");
106
+        }
107
+    }
108
+
109
+    // 海康回调
110
+    public boolean invoke(NativeLong lCommand, HCNetSDK.NET_DVR_ALARMER pAlarmer, Pointer pAlarmInfo, int dwBufLen, Pointer pUser) {
111
+        // 回调类型
112
+        switch (lCommand.intValue()){
113
+            // 实时人脸抓拍上传 - 获取到抓拍图片后需要手动上传到比对库
114
+            case HCNetSDK.COMM_UPLOAD_FACESNAP_RESULT:
115
+                TinyLog.info("接收到抓拍人脸");
116
+                HCNetSDK.NET_VCA_FACESNAP_RESULT strFaceSnapInfo = new HCNetSDK.NET_VCA_FACESNAP_RESULT();
117
+                strFaceSnapInfo.write();
118
+                Pointer pFaceSnapInfo = strFaceSnapInfo.getPointer();
119
+                pFaceSnapInfo.write(0, pAlarmInfo.getByteArray(0, strFaceSnapInfo.size()), 0, strFaceSnapInfo.size());
120
+                TinyLog.info("已入库, 开始进行人脸比对...");
121
+//                strFaceSnapInfo.read();
122
+                break;
123
+
124
+            // 人脸黑名单比对报警
125
+            case HCNetSDK.COMM_SNAP_MATCH_ALARM:
126
+                TinyLog.info("人脸比对完成, 正在读取比对结果...");
127
+                HCNetSDK.NET_VCA_FACESNAP_MATCH_ALARM strFaceSnapMatch = new HCNetSDK.NET_VCA_FACESNAP_MATCH_ALARM();
128
+                strFaceSnapMatch.write();
129
+                Pointer pFaceSnapMatch = strFaceSnapMatch.getPointer();
130
+                pFaceSnapMatch.write(0, pAlarmInfo.getByteArray(0, strFaceSnapMatch.size()), 0, strFaceSnapMatch.size());
131
+                strFaceSnapMatch.read();
132
+
133
+                // 抓拍人脸图片
134
+                ByteBuffer avatar = strFaceSnapMatch.struSnapInfo.pBuffer1.getByteBuffer(0, strFaceSnapMatch.struSnapInfo.dwSnapFacePicLen);
135
+
136
+                Map<String, Object> result = new HashMap<>();
137
+                result.put("status", String.valueOf(strFaceSnapMatch.byContrastStatus & 0xFF));
138
+                result.put("similarity", String.valueOf(strFaceSnapMatch.fSimilarity));
139
+                result.put("score", String.valueOf(strFaceSnapMatch.struSnapInfo.byFaceScore & 0xFF));
140
+                result.put("sex", String.valueOf(strFaceSnapMatch.struSnapInfo.bySex & 0xFF));
141
+                result.put("avatar", avatar);
142
+
143
+                TinyLog.info("以下为本次比对结果:");
144
+                TinyLog.info("比对结果[0-保留,1-比对成功,2-比对失败]:", strFaceSnapMatch.byContrastStatus);
145
+                TinyLog.info("比对相似度[0.001-1]:", strFaceSnapMatch.fSimilarity);
146
+                TinyLog.info("抓拍人脸质量[0-100]:", strFaceSnapMatch.struSnapInfo.byFaceScore);
147
+                TinyLog.info("抓拍人脸性别[0-未知,1-男,2-女]:", strFaceSnapMatch.struSnapInfo.bySex);
148
+
149
+                // 如果比对到人脸
150
+                if (strFaceSnapMatch.struBlackListInfo.dwBlackListPicLen > 0) {
151
+                    try {
152
+                        String personId = new String(strFaceSnapMatch.struBlackListInfo.struBlackListInfo.struAttribute.byName,"GBK").trim();
153
+                        result.put("sysperson", personId);
154
+                        TinyLog.info("比对人脸名称(业务库ID)", personId);
155
+                    } catch (UnsupportedEncodingException e) {
156
+                        TinyLog.error("获取比对人员ID失败");
157
+                        e.printStackTrace();
158
+                    }
159
+                }
160
+
161
+                // 上传到主服务
162
+                TinyLog.info("准备上传比对数据到主服务...");
163
+                Server serv = new Server(serverAPI);
164
+                boolean success = serv.uploadResult(result);
165
+                if (!success) {
166
+                    TinyLog.error("上传比对数据到主服务失败");
167
+                } else {
168
+                    TinyLog.info("上传比对数据到主服务完成");
169
+                }
170
+
171
+                break;
172
+        }
173
+
174
+        return true;
175
+    }
176
+
177
+    // 设置网络情况
178
+    public void setNetError(boolean isError) {
179
+        if (isError) {
180
+            sdkInited = false;
181
+            logged = false;
182
+            registed = false;
183
+            setCallback = false;
184
+            TinyLog.error("检测到网络不通");
185
+        }
186
+
187
+        netError = isError;
188
+    }
189
+
190
+    // SDK 初始化
191
+    private boolean init() {
192
+        if (sdkInited) return sdkInited;
193
+
194
+        sdkInited = hk.NET_DVR_Init();
195
+
196
+        if (sdkInited) {
197
+            TinyLog.info("海康 SDK init 成功");
198
+        } else {
199
+            TinyLog.error("海康 SDK init 失败");
200
+            TinyLog.error("获取到海康错误信息: ", getHKError());
201
+        }
202
+
203
+        return sdkInited;
204
+    }
205
+
206
+    // 用户登录
207
+    private boolean login() {
208
+        if (logged) return logged;
209
+
210
+        user = hk.NET_DVR_Login_V30(ip,(short) port, userName, password, device);
211
+        logged = user.longValue() != -1;
212
+
213
+        if (logged) {
214
+            TinyLog.info("用户 ["+userName+"] 登录海康设备 ["+ip+"] 成功");
215
+        } else {
216
+            TinyLog.error("用户 ["+userName+"] 登录海康设备 ["+ip+"] 失败");
217
+            TinyLog.error("获取到海康错误信息: ", getHKError());
218
+        }
219
+
220
+
221
+        return logged;
222
+    }
223
+
224
+    // 设置设备回调
225
+    private boolean setAlarmCallback() {
226
+        if (setCallback) return setCallback;
227
+
228
+        // 设置回调 - 回调自己的 invoke 方法
229
+        Pointer pUser = null;
230
+        setCallback = hk.NET_DVR_SetDVRMessageCallBack_V31(this, pUser);
231
+        if (!setCallback) {
232
+            TinyLog.error("设置设备回调失败");
233
+            TinyLog.error(getHKError());
234
+            return setCallback;
235
+        }
236
+
237
+        // 建立报警上传通道
238
+        HCNetSDK.NET_DVR_SETUPALARM_PARAM alarmInfo = new HCNetSDK.NET_DVR_SETUPALARM_PARAM();
239
+        alarmInfo.dwSize = alarmInfo.size();
240
+        alarmInfo.byLevel = 1;
241
+        alarmInfo.byAlarmInfoType = 1;
242
+        alarmInfo.byDeployType = 1;
243
+        alarmInfo.write();
244
+        NativeLong handle = hk.NET_DVR_SetupAlarmChan_V41(user, alarmInfo);
245
+        setCallback = handle.intValue() != -1;
246
+
247
+        if (!setCallback){
248
+            TinyLog.error("建立报警上传通道失败");
249
+            TinyLog.error("获取到海康错误信息: ", getHKError());
250
+        }else{
251
+            TinyLog.info("建立报警上传通道成功");
252
+        }
253
+
254
+        return setCallback;
255
+    }
256
+
257
+    private boolean isHKError() {
258
+        int code = hk.NET_DVR_GetLastError();
259
+        if (code == 0) return false;
260
+
261
+        TinyLog.error("获取到海康错误码: " + String.valueOf(code));
262
+        return true;
263
+    }
264
+
265
+    private String getHKError() {
266
+        return isHKError() ? hk.NET_DVR_GetErrorMsg(null) : null;
267
+    }
268
+
269
+    // 通知服务端设备上线
270
+    private boolean setOnline() {
271
+        if (registed) return registed;
272
+
273
+        Server serv = new Server(serverAPI);
274
+
275
+        Map<String, String> query = new HashMap<>();
276
+        query.put("deviceId", deviceID);
277
+        query.put("deviceName", deviceName);
278
+        query.put("ip", ip);
279
+        query.put("port", String.valueOf(port));
280
+        query.put("username", userName);
281
+        query.put("password", password);
282
+        query.put("api", deviceAPI);
283
+
284
+        TinyLog.info("设备" + deviceName + "["+ip+"] 准备注册上线...");
285
+        registed = serv.registe(query);
286
+
287
+        return registed;
288
+    }
289
+
290
+    // 读取配置文件
291
+    public void setConfig(Configer conf) {
292
+        deviceID = conf.get("id");
293
+        deviceName = conf.get("name");
294
+        deviceAPI = conf.get("callback");
295
+        serverAPI = conf.get("server");
296
+        ip = conf.get("ip");
297
+        userName = conf.get("user");
298
+        password = conf.get("password");
299
+        port = Integer.parseInt(conf.get("port"));
300
+
301
+        TinyLog.info("配置文件读取成功");
302
+    }
303
+}

+ 25
- 0
src/main/java/Main.java ファイルの表示

@@ -0,0 +1,25 @@
1
+import utils.Configer;
2
+import utils.TinyLog;
3
+
4
+public class Main {
5
+    public static void main(String[] args) {
6
+
7
+        TinyLog.info("开始读取配置文件...");
8
+
9
+        Configer conf = new Configer();
10
+        String err = conf.read("E:\\JavaProjects\\welcome3.0\\hardware\\setting.conf");
11
+        if (null != err && !"".equals(err)) {
12
+            TinyLog.error("读取配置文件失败");
13
+            TinyLog.error(err);
14
+            return;
15
+        }
16
+
17
+        Camera camera = Camera.getInstance();
18
+        Monitor monitor = new Monitor();
19
+
20
+        camera.setConfig(conf);
21
+        monitor.listen(camera, conf.get("ip"));
22
+        monitor.start();
23
+        camera.connect();
24
+    }
25
+}

+ 27
- 0
src/main/java/Monitor.java ファイルの表示

@@ -0,0 +1,27 @@
1
+import utils.Ping;
2
+
3
+/**
4
+ * 主要为了监控设备网络是否在线
5
+ */
6
+public class Monitor extends Thread {
7
+    private Camera camera;
8
+    private String host;
9
+
10
+    public final void listen(Camera dev, String ip) {
11
+        camera = dev;
12
+        host = ip;
13
+    }
14
+
15
+    public void run() {
16
+        while (true) {
17
+            boolean netOk = Ping.attemp(host);
18
+            camera.setNetError(!netOk);
19
+
20
+            try {
21
+                Thread.sleep(50000);
22
+            } catch (InterruptedException e) {
23
+                e.printStackTrace();
24
+            }
25
+        }
26
+    }
27
+}

+ 4296
- 0
src/main/java/hik/HCNetSDK.java
ファイル差分が大きすぎるため省略します
ファイルの表示


+ 66
- 0
src/main/java/utils/Configer.java ファイルの表示

@@ -0,0 +1,66 @@
1
+package utils;
2
+
3
+import java.io.BufferedReader;
4
+import java.io.FileReader;
5
+import java.util.HashMap;
6
+import java.util.Map;
7
+
8
+/**
9
+ * 简易版读取配置文件, 非 property, 非 json 等主流文件
10
+ * 仅支持 key = value 的形式的单行, 非树形结构文件
11
+ */
12
+public class Configer {
13
+    private Map<String, String> mp = new HashMap<String, String>();
14
+    private static Configer inst;
15
+
16
+    public Configer() {
17
+        inst = this;
18
+    }
19
+
20
+    public String read(String filePath) {
21
+        BufferedReader reader = null;
22
+        try {
23
+            reader = new BufferedReader(new FileReader(filePath));
24
+            String tmp = "";
25
+            while ((tmp = reader.readLine()) != null) {
26
+                int p = tmp.indexOf("=");
27
+
28
+                // 无效行
29
+                if (p < 1) {
30
+                    continue;
31
+                }
32
+
33
+                // 注释行
34
+                if (tmp.startsWith("#") || tmp.startsWith("//")) {
35
+                    continue;
36
+                }
37
+
38
+                String k = tmp.substring(0, p).trim();
39
+                String v = tmp.substring(p + 1).trim();
40
+
41
+                mp.put(k, v);
42
+            }
43
+            reader.close();
44
+        } catch (Exception e) {
45
+            e.printStackTrace();
46
+            return "Can't read the config file";
47
+        } finally {
48
+            if (reader != null) {
49
+                try {
50
+                    reader.close();
51
+                } catch (Exception e1) {
52
+                }
53
+            }
54
+        }
55
+
56
+        return null;
57
+    }
58
+
59
+    public String get(String key) {
60
+        return mp.get(key);
61
+    }
62
+
63
+    public static String pick(String key) {
64
+        return inst.get(key);
65
+    }
66
+}

+ 50
- 0
src/main/java/utils/Ping.java ファイルの表示

@@ -0,0 +1,50 @@
1
+package utils;
2
+
3
+import java.io.BufferedReader;
4
+import java.io.IOException;
5
+import java.io.InputStreamReader;
6
+import java.util.regex.Matcher;
7
+import java.util.regex.Pattern;
8
+
9
+/**
10
+ * 本系统只运行在 windows 系统下, 所以不针对 linux 系统做特殊处理
11
+ */
12
+public class Ping {
13
+    public static boolean attemp (String host) {
14
+        try {
15
+            BufferedReader in = null;
16
+            Runtime rt = Runtime.getRuntime();
17
+            int maxTimes = 5;
18
+            int connTimes = 4;
19
+            Process p = rt.exec("ping " + host + " -n " + maxTimes);
20
+            if (null == p) return false;
21
+
22
+            in = new BufferedReader(new InputStreamReader(p.getInputStream()));
23
+            String line = null;
24
+            int okTimes = 0;
25
+
26
+            while ((line = in.readLine()) != null) {
27
+                // 空行跳过
28
+                if ("".equals(line)) {
29
+                    continue;
30
+                }
31
+
32
+                if (check(line)) {
33
+                    okTimes += 1;
34
+                }
35
+            }
36
+
37
+            in.close();
38
+            return okTimes >= connTimes;
39
+        } catch (IOException e) {
40
+            e.printStackTrace();
41
+            return false;
42
+        }
43
+    }
44
+
45
+    private static boolean check(String line) {
46
+        Pattern pattern = Pattern.compile("(\\d+ms)(\\s+)(TTL=\\d+)",    Pattern.CASE_INSENSITIVE);
47
+        Matcher matcher = pattern.matcher(line);
48
+        return matcher.find();
49
+    }
50
+}

+ 16
- 0
src/main/java/utils/Rand.java ファイルの表示

@@ -0,0 +1,16 @@
1
+package utils;
2
+
3
+import java.util.Random;
4
+
5
+public class Rand {
6
+    public static String string(int length){
7
+        String str="abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789";
8
+        Random random=new Random();
9
+        StringBuffer sb=new StringBuffer();
10
+        for(int i=0;i<length;i++){
11
+            int number=random.nextInt(62);
12
+            sb.append(str.charAt(number));
13
+        }
14
+        return sb.toString();
15
+    }
16
+}

+ 146
- 0
src/main/java/utils/Server.java ファイルの表示

@@ -0,0 +1,146 @@
1
+package utils;
2
+
3
+import com.alibaba.fastjson.JSON;
4
+import com.alibaba.fastjson.JSONObject;
5
+import okhttp3.*;
6
+
7
+import java.io.File;
8
+import java.io.FileOutputStream;
9
+import java.io.IOException;
10
+import java.net.HttpURLConnection;
11
+import java.nio.ByteBuffer;
12
+import java.nio.channels.FileChannel;
13
+import java.util.Map;
14
+
15
+/**
16
+ * 主服务
17
+ */
18
+public class Server {
19
+    private String apiURL;
20
+
21
+    public Server(String serverURL) {
22
+        apiURL = serverURL;
23
+    }
24
+
25
+    // 设备上线
26
+    public boolean registe(Map<String, String> params) {
27
+        if (null == params) {
28
+            return false;
29
+        }
30
+
31
+        // 构造 url
32
+        HttpUrl.Builder b = HttpUrl.parse(apiURL + "/device").newBuilder();
33
+        params.forEach((k, v) -> {
34
+            b.addQueryParameter(k, v);
35
+        });
36
+        b.addQueryParameter("status", String.valueOf(1));
37
+        HttpUrl api = b.build();
38
+
39
+        // 构造 request
40
+        RequestBody reqBody = RequestBody.create(null, null, 0, 0);
41
+        Request request = new Request.Builder().url(api).post(reqBody).build();
42
+
43
+        // 发送请求
44
+        try {
45
+            TinyLog.info("发送请求到主服务:", api);
46
+            Response response = new OkHttpClient().newCall(request).execute();
47
+            if (!response.isSuccessful()) {
48
+                TinyLog.error("设备注册上线失败");
49
+                TinyLog.error(response.message());
50
+                return false;
51
+            }
52
+
53
+            String err = checkResponse(response);
54
+            if (null != err) {
55
+                TinyLog.error("设备注册上线失败");
56
+            }
57
+        } catch (IOException e) {
58
+            TinyLog.error("设备注册上线失败");
59
+            e.printStackTrace();
60
+            return false;
61
+        }
62
+
63
+        return true;
64
+    }
65
+
66
+    // 人员比对结果上传
67
+    public boolean uploadResult(Map<String, Object> data) {
68
+
69
+        MultipartBody.Builder fmt = new MultipartBody.Builder();
70
+        fmt.setType(MultipartBody.FORM);
71
+        RequestBody reqBody = RequestBody.create(null, null, 0, 0);
72
+        String api = apiURL + "/device/compare";
73
+
74
+        data.forEach((k, v) -> {
75
+            if (v instanceof String) {
76
+                fmt.addFormDataPart(k, (String)v);
77
+            } else if (v instanceof ByteBuffer) {
78
+                String fname = getRandFileName(k, ".jpg");
79
+
80
+                try {
81
+                    buf2File((ByteBuffer)v, fname);
82
+                    fmt.addFormDataPart(k, fname, reqBody);
83
+                } catch (IOException e) {
84
+                    TinyLog.error("对比图片保存本地失败");
85
+                    e.printStackTrace();
86
+                }
87
+            } else {
88
+                TinyLog.error("转换对比结果数据失败, 不支持的数据类型:", v.getClass());
89
+            }
90
+        });
91
+
92
+        Request request = new Request.Builder().url(api).post(fmt.build()).build();
93
+
94
+        try {
95
+            TinyLog.info("发送请求到主服务:", api);
96
+            Response response = new OkHttpClient().newCall(request).execute();
97
+
98
+            if (!response.isSuccessful()) {
99
+                TinyLog.error("人脸比对结果上传失败");
100
+                TinyLog.error(response.message());
101
+                return false;
102
+            }
103
+
104
+            String err = checkResponse(response);
105
+            if (null != err) {
106
+                TinyLog.error("人脸比对结果上传失败");
107
+            }
108
+        } catch (IOException e) {
109
+            TinyLog.error("人脸比对结果上传失败");
110
+            e.printStackTrace();
111
+            return false;
112
+        }
113
+
114
+        return true;
115
+    }
116
+
117
+    private String checkResponse(Response response) {
118
+        String responseStr = response.body().toString();
119
+        if (null == responseStr || "".equals(responseStr)) {
120
+            return "没有拿到主业务端返回内容";
121
+        }
122
+
123
+        JSONObject result = (JSONObject) JSON.parse(responseStr);
124
+        if (result.getInteger("code").intValue() == HttpURLConnection.HTTP_OK) {
125
+            TinyLog.info("主业务请求成功");
126
+            return null;
127
+        } else {
128
+            TinyLog.error("主业务请求失败, 返回内容:", responseStr);
129
+            return responseStr;
130
+        }
131
+    }
132
+
133
+    private File buf2File(ByteBuffer buf, String fname) throws IOException {
134
+
135
+        File f = new File(fname);
136
+        FileChannel fout = new FileOutputStream(f).getChannel();
137
+        fout.write(buf);
138
+        fout.close();
139
+
140
+        return f;
141
+    }
142
+
143
+    private String getRandFileName(String key, String ext) {
144
+        return key + "-" + Rand.string(8) + ext;
145
+    }
146
+}

+ 42
- 0
src/main/java/utils/TinyLog.java ファイルの表示

@@ -0,0 +1,42 @@
1
+package utils;
2
+
3
+import java.text.SimpleDateFormat;
4
+import java.util.Date;
5
+
6
+/**
7
+ * 简易版日志记录器
8
+ * 固定的格式输入到标准输出
9
+ */
10
+public class TinyLog {
11
+    public static boolean onlyError = false;
12
+
13
+    public static void info(Object ...msgs) {
14
+        if (onlyError) {
15
+            return;
16
+        }
17
+
18
+        System.out.printf("%s [Info]:", now());
19
+        for(Object msg : msgs) {
20
+            System.out.print(msg);
21
+            System.out.print(" ");
22
+        }
23
+        System.out.println();
24
+    }
25
+
26
+    public static void error(Object ...errs) {
27
+        System.err.printf("%s [Error]: ",  now());
28
+        for(Object err : errs) {
29
+            System.err.print(err);
30
+            System.err.print(" ");
31
+        }
32
+        System.err.println();
33
+    }
34
+
35
+    public static void raw(String str) {
36
+        System.out.printf(str);
37
+    }
38
+
39
+    private static String now() {
40
+        return (new SimpleDateFormat("yyyy-mm-dd HH:mm:ss")).format(new Date());
41
+    }
42
+}

バイナリ
src/main/resources/libs/examples.jar ファイルの表示


バイナリ
target/classes/Camera.class ファイルの表示


バイナリ
target/classes/Main.class ファイルの表示


バイナリ
target/classes/Monitor.class ファイルの表示


バイナリ
target/classes/hik/GDI32.class ファイルの表示


バイナリ
target/classes/hik/HCNetSDK$BYTE_ARRAY.class ファイルの表示


バイナリ
target/classes/hik/HCNetSDK$CAPTURE_MODE.class ファイルの表示


バイナリ
target/classes/hik/HCNetSDK$CARDRIGHTPLAN.class ファイルの表示


バイナリ
target/classes/hik/HCNetSDK$DISPLAY_MODE.class ファイルの表示


バイナリ
target/classes/hik/HCNetSDK$FColGlobalDataCallBack.class ファイルの表示


バイナリ
target/classes/hik/HCNetSDK$FColLocalDataCallBack.class ファイルの表示


バイナリ
target/classes/hik/HCNetSDK$FDrawFun.class ファイルの表示


バイナリ
target/classes/hik/HCNetSDK$FExceptionCallBack.class ファイルの表示


バイナリ
target/classes/hik/HCNetSDK$FJpegdataCallBack.class ファイルの表示


バイナリ
target/classes/hik/HCNetSDK$FMSGCallBack.class ファイルの表示


バイナリ
target/classes/hik/HCNetSDK$FMSGCallBack_V31.class ファイルの表示


バイナリ
target/classes/hik/HCNetSDK$FMessCallBack.class ファイルの表示


バイナリ
target/classes/hik/HCNetSDK$FMessCallBack_EX.class ファイルの表示


バイナリ
target/classes/hik/HCNetSDK$FMessCallBack_NEW.class ファイルの表示


バイナリ
target/classes/hik/HCNetSDK$FMessageCallBack.class ファイルの表示


バイナリ
target/classes/hik/HCNetSDK$FPlayDataCallBack.class ファイルの表示


バイナリ
target/classes/hik/HCNetSDK$FPostMessageCallBack.class ファイルの表示


バイナリ
target/classes/hik/HCNetSDK$FRealDataCallBack_V30.class ファイルの表示


バイナリ
target/classes/hik/HCNetSDK$FRemoteConfigCallback.class ファイルの表示


バイナリ
target/classes/hik/HCNetSDK$FRowDataCallBack.class ファイルの表示


バイナリ
target/classes/hik/HCNetSDK$FSerialDataCallBack.class ファイルの表示


バイナリ
target/classes/hik/HCNetSDK$FStdDataCallBack.class ファイルの表示


バイナリ
target/classes/hik/HCNetSDK$FVoiceDataCallBack.class ファイルの表示


バイナリ
target/classes/hik/HCNetSDK$FVoiceDataCallBack2.class ファイルの表示


バイナリ
target/classes/hik/HCNetSDK$FVoiceDataCallBack_MR.class ファイルの表示


バイナリ
target/classes/hik/HCNetSDK$FVoiceDataCallBack_MR_V30.class ファイルの表示


バイナリ
target/classes/hik/HCNetSDK$FVoiceDataCallBack_V30.class ファイルの表示


バイナリ
target/classes/hik/HCNetSDK$GpsDataParamUion.class ファイルの表示


バイナリ
target/classes/hik/HCNetSDK$NET_DVRRECEIVER.class ファイルの表示


バイナリ
target/classes/hik/HCNetSDK$NET_DVR_ACS_ALARM_INFO.class ファイルの表示


バイナリ
target/classes/hik/HCNetSDK$NET_DVR_ACS_EVENT_INFO.class ファイルの表示


+ 0
- 0
target/classes/hik/HCNetSDK$NET_DVR_ADDIT_POSITION.class ファイルの表示


多くのファイルが変更されたため、一部のファイルはこの差分に表示されません