cim.html 31 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <title>Welcome to SkyAI</title>
  5. <meta charset="utf-8">
  6. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  7. <!--<meta http-equiv="refresh" content="3">-->
  8. <meta http-equiv="pragma" content="no-cache">
  9. <meta http-equiv="Cache-Control" CONTENT="no-cache, must-revalidate">
  10. <meta http-equiv="expires" content="365 days">
  11. <script src="../static/js/jquery.min.js"></script>
  12. <link rel="stylesheet" href="../static/css/bootstrap.min.css">
  13. <script src="../static/js/bootstrap.min.js"></script>
  14. <script src="https://cdnjs.cloudflare.com/ajax/libs/bootstrap-slider/10.2.1/bootstrap-slider.min.js"></script>
  15. <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/bootstrap-slider/10.2.1/css/bootstrap-slider.min.css">
  16. <link rel="stylesheet" href="../static/css/generalstyle.css?<?php echo rand(0,512);?>">
  17. <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
  18. <meta name="viewport" content="width=device-width, initial-scale=1">
  19. <script src="https://cdnjs.cloudflare.com/ajax/libs/paho-mqtt/1.0.1/mqttws31.min.js" type="text/javascript"></script>
  20. <style>
  21. .slider-selection {
  22. background: #BABABA;
  23. }
  24. .slider.slider-horizontal{
  25. width: 90%;
  26. }
  27. #setlight>div>div{
  28. display:inline-block;
  29. vertical-align:middle;
  30. }
  31. img {
  32. display: block;
  33. margin-left: auto;
  34. margin-right: auto;
  35. }
  36. .img1 {
  37. display: block;
  38. margin-left: auto;
  39. margin-right: auto;
  40. margin: auto;
  41. }
  42. .detail{
  43. font-family: Microsoft JhengHei;
  44. border-radius: 100px;
  45. background-color: #008CBA;
  46. border: none;
  47. color: white;
  48. padding: 5px 12px;
  49. text-align: center;
  50. text-decoration: none;
  51. display: inline-block;
  52. font-size: 1.4em;
  53. margin: 4px 2px;
  54. cursor: pointer;
  55. transition-duration: 0.4s;
  56. border: 3px solid white;
  57. }
  58. .detail:hover {
  59. background-color: white;
  60. color: black;
  61. border: 3px solid black;
  62. }
  63. .title{
  64. font-family: Microsoft JhengHei;
  65. border-radius: 100px;
  66. background-color: #f2f2f2;
  67. border: none;
  68. color: black;
  69. padding: 10px 32px;
  70. font-size: 2em;
  71. }
  72. .font {
  73. color: white;
  74. font-size: 1.4em;
  75. }
  76. .font:hover {
  77. color: black;
  78. font-size: 1.5em;
  79. }
  80. .sw_number {
  81. background-color: white;
  82. width:40px;font-size:1.5em;border:1px;border-radius: 100px;
  83. border: 3px solid lightgray;
  84. color: #337ab7;
  85. }
  86. .disabled {
  87. width:40px;font-size:1.5em;border:1px;border-radius: 100px;
  88. border: 3px solid lightgray;
  89. background-color:#e0e0e0;
  90. }
  91. .sw_number:hover {
  92. width:40px;
  93. font-size:1.5em;
  94. border:1px;
  95. border-radius: 100px;
  96. border: 3px solid lightgreen;
  97. background-color: white;
  98. }
  99. .disabled:hover {
  100. width:40px;
  101. font-size:1.5em;
  102. border:1px;
  103. border-radius: 100px;
  104. border: 3px solid lightgray;
  105. background-color: #e0e0e0;
  106. }
  107. .choosed {
  108. width:40px;
  109. font-size:1.5em;
  110. border:1px;
  111. border-radius: 100px;
  112. border: 3px solid red;
  113. background-color: white;
  114. }
  115. .choose_nr {
  116. font-family: Microsoft JhengHei;
  117. color: #333333;
  118. font-size: 1.7em;
  119. /*text-shadow: 1px 2px black;*/
  120. }
  121. button {
  122. background-color: white;
  123. border-radius:10px;
  124. border: 3px solid lightgray;
  125. }
  126. .stn{font-size:20px;background-color: white;border-radius:10px;border: 3px solid lightgray;background-color:white;}
  127. .atn{font-size:20px;background-color:#25AD87;border-radius:10px;}
  128. .stl{background-color:#DDDDDD;}
  129. .atl{background-color:white;}
  130. </style>
  131. <!--js 特效樣式設定-->
  132. <script>
  133. var room_now = 0;
  134. var node_id = {{params.tid}};
  135. node_id = 'GTW00900100' + node_id;
  136. var imgPath = "../static/img/PV.jpg";
  137. //控制拍攝預覽照開關
  138. var setSwh = 0;
  139. var panelSwh = 0;
  140. //從後端讀取資料,顯示已設定的方位
  141. $(function(){
  142. {% if params.mode %}
  143. {% for j in params.mode %}
  144. if({{j}} != 1){
  145. $("input[name=ori" + {{j}} + "]").toggleClass('disabled');
  146. };
  147. {% endfor %}
  148. {% endif %}
  149. <!--var json = {"nr": node_id};-->
  150. <!--$.get('/orientation/' + node_id, json, function (resText) {-->
  151. <!--zoom_now = resText.zoom;-->
  152. <!--$(".zoom").text(zoom_now);-->
  153. <!--var pan = resText.pan_angle;-->
  154. <!--$(".pan-angle").text(pan);-->
  155. <!--var tilt = resText.tilt_angle;-->
  156. <!--$(".tilt-angle").text(tilt);-->
  157. <!--imgPath = resText.img;-->
  158. <!--$("#img3").attr('src',imgPath);-->
  159. <!--}, 'json');-->
  160. //顯示小兵現在位置以及最新照片
  161. $(".zoom").text('{{params.begin_zoom}}');
  162. $(".pan-angle").text('{{params.begin_pan_angle}}');
  163. $(".tilt-angle").text('{{params.begin_tilt_angle}}');
  164. imgPath = '{{params.begin_imgPath}}';
  165. $("#img3").attr('src','{{params.begin_imgPath}}');
  166. });
  167. //倍率函數
  168. function Zoom(evt){
  169. var name = evt.getAttribute('name');
  170. var zoom = $(".zoom");
  171. var zoom_num = 0;
  172. var tilt = $(".tilt-angle");
  173. var pan = $(".pan-angle");
  174. var tilt_history = $(".tilt-angle-history");
  175. var pan_history = $(".pan-angle-history");
  176. var zoom_history = $(".zoom-history");
  177. if(name == 'zoom0'){
  178. zoom.text('0');
  179. zoom_num = 0;
  180. var zoom_diff = (0 - zoom_now).toString();
  181. zoom_now = 0;
  182. var command = {"node_id":node_id, "command":"a016", "Zoom":zoom_diff};
  183. $.get('/mqtt/' + node_id, command, function(resText){
  184. }, 'text');
  185. }else if(name == 'zoom1'){
  186. zoom.text('1');
  187. zoom_num = 1;
  188. var zoom_diff = (1 - zoom_now).toString();
  189. zoom_now = 1;
  190. var command = {"node_id":node_id, "command":"a016", "Zoom":zoom_diff};
  191. $.get('/mqtt/' + node_id, command, function(resText){
  192. }, 'text');
  193. }else if(name == 'zoom2'){
  194. zoom.text('2');
  195. zoom_num = 2;
  196. var zoom_diff = (2 - zoom_now).toString();
  197. zoom_now = 2;
  198. var command = {"node_id":node_id, "command":"a016", "Zoom":zoom_diff};
  199. $.get('/mqtt/' + node_id, command, function(resText){
  200. }, 'text');
  201. }else if(name == 'zoom3'){
  202. zoom.text('3');
  203. zoom_num = 3;
  204. var zoom_diff = (3 - zoom_now).toString();
  205. zoom_now = 3;
  206. var command = {"node_id":node_id, "command":"a016", "Zoom":zoom_diff};
  207. $.get('/mqtt/' + node_id, command, function(resText){
  208. }, 'text');
  209. }else if(name == 'zoom4'){
  210. zoom.text('4');
  211. zoom_num = 4;
  212. var zoom_diff = (4 - zoom_now).toString();
  213. zoom_now = 4;
  214. var command = {"node_id":node_id, "command":"a016", "Zoom":zoom_diff};
  215. $.get('/mqtt/' + node_id, command, function(resText){
  216. }, 'text');
  217. }else{
  218. zoom.text('5');
  219. zoom_num = 5;
  220. var zoom_diff = (5 - zoom_now).toString();
  221. zoom_now = 5;
  222. var command = {"node_id":node_id, "command":"a016", "Zoom":zoom_diff};
  223. $.get('/mqtt/' + node_id, command, function(resText){
  224. }, 'text');
  225. };
  226. $("input[name=zoom]").val(zoom_num);
  227. var pan_num = pan.text();
  228. var tilt_num = tilt.text();
  229. var zoom_num = zoom.text();
  230. tilt_history.text(tilt_num);
  231. pan_history.text(pan_num);
  232. zoom_history.text(zoom_num);
  233. console.log("test");
  234. panelSwh = 1;
  235. };
  236. ////角度函數
  237. function Angle(evt){
  238. var name = evt.getAttribute('name');
  239. var tilt = $(".tilt-angle");
  240. var pan = $(".pan-angle");
  241. var zoom = $(".zoom");
  242. var tilt_history = $(".tilt-angle-history");
  243. var pan_history = $(".pan-angle-history");
  244. var zoom_history = $(".zoom-history");
  245. if(name == 'up'){
  246. var num = Number(tilt.text()) + 5;
  247. if(num > 90){
  248. num = 90;
  249. };
  250. num = num.toString();
  251. tilt.text(num);
  252. var command = {"node_id":node_id, "command":"a014", "Tilt":tilt.text()};
  253. $.get('/mqtt/' + node_id, command, function(resText){
  254. }, 'text');
  255. }else if(name == 'down'){
  256. var num = Number(tilt.text()) - 5;
  257. if(num < -25){
  258. num = -25;
  259. };
  260. num = num.toString();
  261. tilt.text(num);
  262. var command = {"node_id":node_id, "command":"a014", "Tilt":tilt.text()};
  263. $.get('/mqtt/' + node_id, command, function(resText){
  264. }, 'text');
  265. }else if(name == 'left'){
  266. var num = Number(pan.text()) - 5;
  267. if(num == -5){
  268. num = 355;
  269. };
  270. num = num.toString();
  271. pan.text(num);
  272. var command = {"node_id":node_id, "command":"a012", "Pan":pan.text()};
  273. $.get('/mqtt/' + node_id, command, function(resText){
  274. }, 'text');
  275. }else if(name == 'right'){
  276. var num = Number(pan.text()) + 5;
  277. if(num == 360){
  278. num = 0;
  279. };
  280. num = num.toString();
  281. pan.text(num);
  282. var command = {"node_id":node_id, "command":"a012", "Pan":pan.text()};
  283. $.get('/mqtt/' + node_id, command, function(resText){
  284. }, 'text');
  285. }else{
  286. tilt.text("0");
  287. pan.text("0");
  288. zoom.text("0");
  289. var command = {"node_id":node_id, "command":"a052"};
  290. $.get('/mqtt/' + node_id, command, function(resText){
  291. }, 'text');
  292. };
  293. $("input[name=tilt-angle]").val(tilt.text());
  294. $("input[name=pan-angle]").val(pan.text());
  295. var pan_num = pan.text();
  296. var tilt_num = tilt.text();
  297. var zoom_num = zoom.text();
  298. tilt_history.text(tilt_num);
  299. pan_history.text(pan_num);
  300. zoom_history.text(zoom_num);
  301. panelSwh = 1;
  302. };
  303. //手動拍攝函數
  304. function Photo() {
  305. var date = new Date();
  306. var year = (date.getFullYear()).toString();
  307. var month = date.getMonth() + 1;
  308. var day = (date.getDate()).toString();
  309. var hour = date.getHours();
  310. if(month < 10){
  311. month = "0" + month;
  312. };
  313. if(day < 10){
  314. day = "0" + day;
  315. };
  316. if(hour < 10){
  317. hour = "0" + hour;
  318. };
  319. if(min < 10){
  320. min = "0" + min;
  321. };
  322. var filename = year + "-" + month + "-" + day + "_" + hour + "." + min;
  323. var command = {"node_id":node_id, "command": "a051", "position":"0", "time":"1", "filename":filename};
  324. $.get('/mqtt/' + node_id, command, function(resText){
  325. }, 'text');
  326. };
  327. //從後端讀資料,顯示方位的設定
  328. function Orientation(evt){
  329. var val = evt.getAttribute('value');
  330. var set = $(".set-span");
  331. set.text(val);
  332. var nr = {{params.tid}};
  333. nr = nr.toString();
  334. var mode = $(".set-span").text();
  335. var json = {"nr":nr, "mode":mode};
  336. $.get('/cshoot_setting/' + nr, json, function(resText){
  337. $("input[name=ori_name]").val(resText.name);
  338. $(".tilt-angle-history").text(resText.tilt_angle);
  339. $(".pan-angle-history").text(resText.pan_angle);
  340. $(".zoom-history").text(resText.zoom);
  341. $("input[name=m_s1]").val(resText.time1.substring(0,2));
  342. $("input[name=d_s1]").val(resText.time1.substring(2,4));
  343. $("input[name=h_s1]").val(resText.time1.substring(4,6));
  344. $("input[name=min_s1]").val(resText.time1.substring(6,8));
  345. $("input[name=m_s2]").val(resText.time2.substring(0,2));
  346. $("input[name=d_s2]").val(resText.time2.substring(2,4));
  347. $("input[name=h_s2]").val(resText.time2.substring(4,6));
  348. $("input[name=min_s2]").val(resText.time2.substring(6,8));
  349. $("input[name=m_s3]").val(resText.time3.substring(0,2));
  350. $("input[name=d_s3]").val(resText.time3.substring(2,4));
  351. $("input[name=h_s3]").val(resText.time3.substring(4,6));
  352. $("input[name=min_s3]").val(resText.time3.substring(6,8));
  353. $("input[name=m_s4]").val(resText.time4.substring(0,2));
  354. $("input[name=d_s4]").val(resText.time4.substring(2,4));
  355. $("input[name=h_s4]").val(resText.time4.substring(4,6));
  356. $("input[name=min_s4]").val(resText.time4.substring(6,8));
  357. $("input[name=m_s5]").val(resText.time5.substring(0,2));
  358. $("input[name=d_s5]").val(resText.time5.substring(2,4));
  359. $("input[name=h_s5]").val(resText.time5.substring(4,6));
  360. $("input[name=min_s5]").val(resText.time5.substring(6,8));
  361. $("input[name=m_s6]").val(resText.time6.substring(0,2));
  362. $("input[name=d_s6]").val(resText.time6.substring(2,4));
  363. $("input[name=h_s6]").val(resText.time6.substring(4,6));
  364. $("input[name=min_s6]").val(resText.time6.substring(6,8));
  365. $("input[name=m_s7]").val(resText.time7.substring(0,2));
  366. $("input[name=d_s7]").val(resText.time7.substring(2,4));
  367. $("input[name=h_s7]").val(resText.time7.substring(4,6));
  368. $("input[name=min_s7]").val(resText.time7.substring(6,8));
  369. $("input[name=m_s8]").val(resText.time8.substring(0,2));
  370. $("input[name=d_s8]").val(resText.time8.substring(2,4));
  371. $("input[name=h_s8]").val(resText.time8.substring(4,6));
  372. $("input[name=min_s8]").val(resText.time8.substring(6,8));
  373. }, 'json');
  374. };
  375. //開啟設定
  376. function Bts(){
  377. document.getElementById("time_set").style.display = 'block';
  378. };
  379. //可見光
  380. function Btn() {
  381. document.getElementById("img3").src = imgPath;
  382. $.post('/video_feed', 'close', function(resText){
  383. }, 'text');
  384. var command = {"node_id":node_id, "command": "a054"};
  385. $.get('/mqtt/' + node_id, command, function(resText){
  386. }, 'text');
  387. $("#control_panel").css('display', 'none');
  388. };
  389. //影像串流
  390. function Btx() {
  391. var nr = {{params.tid}};
  392. nr = nr.toString();
  393. var json = {"nr":nr};
  394. document.getElementById("img3").src = "{{url_for('main.video_feed_views')}}";
  395. var command = {"node_id":node_id, "command": "a053"};
  396. $.get('/mqtt/' + node_id, command, function(resText){
  397. }, 'text');
  398. $("#control_panel").css('display', 'block');
  399. };
  400. //儲存方位
  401. function Btsv(){
  402. if($("input[name=ori_name]").val() == ''){
  403. alert("請輸入方位名稱");
  404. }else{
  405. var nr = {{params.tid}};
  406. nr = nr.toString();
  407. var ori_name = $("input[name=ori_name]").val();
  408. var mode = $(".set-span").text();
  409. var tilt_angle = $(".tilt-angle-history").text();
  410. var pan_angle = $(".pan-angle-history").text();
  411. var zoom = $(".zoom-history").text();
  412. var time1 = $("input[name=m_s1]").val() + $("input[name=d_s1]").val() + $("input[name=h_s1]").val() + $("input[name=min_s1]").val();
  413. var time2 = $("input[name=m_s2]").val() + $("input[name=d_s2]").val() + $("input[name=h_s2]").val() + $("input[name=min_s2]").val();
  414. var time3 = $("input[name=m_s3]").val() + $("input[name=d_s3]").val() + $("input[name=h_s3]").val() + $("input[name=min_s3]").val();
  415. var time4 = $("input[name=m_s4]").val() + $("input[name=d_s4]").val() + $("input[name=h_s4]").val() + $("input[name=min_s4]").val();
  416. var time5 = $("input[name=m_s5]").val() + $("input[name=d_s5]").val() + $("input[name=h_s5]").val() + $("input[name=min_s5]").val();
  417. var time6 = $("input[name=m_s6]").val() + $("input[name=d_s6]").val() + $("input[name=h_s6]").val() + $("input[name=min_s6]").val();
  418. var time7 = $("input[name=m_s7]").val() + $("input[name=d_s7]").val() + $("input[name=h_s7]").val() + $("input[name=min_s7]").val();
  419. var time8 = $("input[name=m_s8]").val() + $("input[name=d_s8]").val() + $("input[name=h_s8]").val() + $("input[name=min_s8]").val();
  420. var json = {"nr":nr, "ori_name":ori_name, "mode":mode, "tilt_angle":tilt_angle, "pan_angle":pan_angle, "zoom":zoom, "time1":time1, "time2":time2,
  421. "time3":time3, "time4":time4, "time5":time5, "time6":time6, "time7":time7, "time8":time8};
  422. $.post('/cshoot_setting/' + nr, json, function(resText){}, 'json');
  423. if(panelSwh == 1 && setSwh == 1){
  424. //預覽照命令
  425. var command = {"node_id":node_id, "command":"a018", "position":mode};
  426. $.get('/mqtt/' + node_id, command, function(resText){
  427. }, 'text');
  428. panelSwh = 0;
  429. setSwh = 0;
  430. };
  431. document.getElementById("time_set").style.display = "none";
  432. if($("input[name=ori" + mode + "]").attr('class') == 'sw_number disabled'){
  433. $("input[name=ori" + mode + "]").toggleClass('disabled');
  434. };
  435. };
  436. };
  437. //刪除方位
  438. function Btd(){
  439. var nr = {{params.tid}};
  440. nr = nr.toString();
  441. var mode = $(".set-span").text();
  442. var json = {"nr":nr, "mode":mode, "delete":"ok"};
  443. $.get('/cshoot_setting/' + nr, json, function(resText){}, 'json');
  444. if($("input[name=ori" + mode + "]").attr('class') == 'sw_number'){
  445. $("input[name=ori" + mode + "]").toggleClass('disabled');
  446. };
  447. document.getElementById("time_set").style.display = "none";
  448. setSwh = 0;
  449. };
  450. //關閉設定
  451. function Btq(){
  452. document.getElementById("time_set").style.display = "none";
  453. setSwh = 0;
  454. };
  455. //跳轉頁面關閉影像串流
  456. function CloseImage(){
  457. console.log('test');
  458. var command = {"node_id":node_id, "command":"a054"};
  459. $.get('/mqtt/' + node_id, command, function(resText){
  460. }, 'text');
  461. };
  462. //關閉視窗關閉影像串流
  463. var isClose = false;
  464. function close(){
  465. var command = {"node_id":node_id, "command":"a054"};
  466. $.get('/mqtt/' + node_id, command, function(resText){
  467. }, 'text');
  468. //將server的socket關掉
  469. $.post('/video_feed', 'close', function(resText){
  470. }, 'text');
  471. };
  472. window.onbeforeunload = function() {
  473. };
  474. window.onunload = function() {
  475. if(!isClose){
  476. close();
  477. };
  478. };
  479. </script>
  480. </head>
  481. <!-- 進入HTML -->
  482. <body>
  483. <!-- 介面主選單 -->
  484. <div class="container">
  485. <div id="header" class="row" style="background-color:#ffffff;">
  486. <div class="col-md-12 col-md-12" style="text-align:center;margin:auto;">
  487. <div class="col-md-4 col-sm-12" style="">
  488. <img src="../static/img/logo_new.png" width="60%" height="7%">
  489. </div>
  490. <div class="col-md-6 col-sm-12 text-left" style="">
  491. <a href="/cindex/{{params.tid}}"><button class="btn btn-danger btn-lg" style="">地形圖</button></a>
  492. <a href="/cshoot_setting/1"><button class="btn btn-primary btn-lg" style="">拍攝設定</button></a>
  493. <a href="/cimg_history/{{params.tid}}"><button class="btn btn-danger btn-lg" style="">歷史資料</button></a>
  494. </div>
  495. <div class="col-md-1 col-sm-12 text-left" style="">
  496. <a href="/logout"><button class="btn btn-primary btn-lg" style="">登出</button></a>
  497. </div>
  498. </div>
  499. </div>
  500. <div class="col-md-12" style="background-color:red;width:100%;height:5px;margin-top:5px;margin-bottom: 20px;">
  501. </div>
  502. <!-- 設定參數外觀 -->
  503. <div class="col-sm-12" style="text-align:center;background-color:#f2f2f2;padding:15px;border:1px;border-radius: 35px;">
  504. <center>
  505. <h1>{{params.tid}} 號 拍攝設定</h1>
  506. <br><br>
  507. <a href="/cshoot_setting/1"><button class="btn btn-primary btn-lg" style="margin-top:5px;margin-bottom:5px" onclick="CloseImage();">1</button></a>
  508. <a href="/cshoot_setting/2"><button class="btn btn-primary btn-lg" style="margin-top:5px;margin-bottom:5px" onclick="CloseImage();">2</button></a>
  509. <a href="/cshoot_setting/3"><button class="btn btn-primary btn-lg" style="margin-top:5px;margin-bottom:5px" onclick="CloseImage();">3</button></a>
  510. <!-- 預覽畫面設定 -->
  511. <div class="row">
  512. <!-- 按鈕顯示圖片切換功能 -->
  513. <div class="col-md-12" style="text-align:center;margin-top:5px;">
  514. <img id="img3" src="../static/img/PV.jpg" style="max-width:100%;height:auto;">
  515. </div>
  516. <div class="col-md-12" style="text-align:center;margin-top:5px;">
  517. <div class="col-md-6" style="text-align:center;margin-top:5px;">
  518. <button id="btn" style="font-size:20px" onclick="Btn()">可見光</button>
  519. </div>
  520. <div class="col-md-6" style="text-align:center;margin-top:5px;">
  521. <button id="btx" style="font-size:20px" onclick="Btx()">影像串流</button>
  522. </div>
  523. </div>
  524. </div>
  525. &nbsp;
  526. &nbsp;
  527. <form action="" method="post">
  528. <div id = "control_panel" style="display: none;">
  529. <div class="col-md-12">
  530. <!-- 空白的實線 -->
  531. <div style="background-color:#FFFFFF;width:100%;height:5px;margin-top:5px;"></div>
  532. <!-- 拍攝控制板外觀 -->
  533. <div class="col-md-3" style="text-align:center;margin-top:5px;">
  534. <p style="text-align:center;font-weight:bold;font-size: 1.7em;">鏡頭方位</p>
  535. <div class="col-md-12" style="text-align:center;margin-top:5px;">
  536. <button type="button" name="up" class="sub_1" onclick="Angle(up);" style="width:49px;height:49px;font-size:20px;border-radius:10px;">▲</button>
  537. </div>
  538. <div class="col-md-12" style="text-align:center;margin-top:5px;margin-bottom:5px;">
  539. <div class="col-md-4" style="text-align:center;margin-top:5px;padding:0px">
  540. <button type="button" name="left" class="sub_3" onclick="Angle(left);" style="width:49px;height:49px;font-size:20px;border-radius:10px;padding:0px">◄</button>
  541. </div>
  542. <div class="col-md-4" style="text-align:center;margin-top:5px;padding:0px">
  543. <button type="button" name="original" class="sub_3" onclick="Angle(original);" style="width:49px;height:49px;font-size:20px;border-radius:10px;padding:0px;font-weight:bold;font-size: 1.7em;">0</button>
  544. </div>
  545. <div class="col-md-4" style="text-align:center;margin-top:5px;padding:0px">
  546. <button type="button" name="right" class="sub_4" onclick="Angle(right);" style="width:49px;height:49px;font-size:20px;border-radius:10px;padding:0px">►</button>
  547. </div>
  548. </div>
  549. <div class="col-md-12" style="text-align:center;margin-top:5px;">
  550. <button type="button" name="down" class="sub_2" onclick="Angle(down);" style="width:49px;height:49px;font-size:20px;border-radius:10px;">▼</button>
  551. </div>
  552. <input type="hidden" name="tilt-angle">
  553. <input type="hidden" name="pan-angle">
  554. </div>
  555. <div class="col-md-3" style="text-align:center;margin-top:5px;">
  556. <p style="text-align:center;font-weight:bold;font-size: 1.7em;">拍攝倍率</p>
  557. <div class="col-md-12" style="text-align:center;margin-top:5px;">
  558. <div class="col-md-12" style="text-align:center;margin-top:5px;">
  559. <button type="button" name="zoom0" class="sub_5" onclick="Zoom(zoom0);" style="width:60px;height:49px;font-size:20px;border-radius:10px;">0倍</button>
  560. <button type="button" name="zoom1" class="sub_6" onclick="Zoom(zoom1);" style="width:60px;height:49px;font-size:20px;border-radius:10px;">1倍</button>
  561. </div>
  562. <div class="col-md-12" style="text-align:center;margin-top:5px;">
  563. <button type="button" name="zoom2" class="sub_6" onclick="Zoom(zoom2);" style="width:60px;height:49px;font-size:20px;border-radius:10px;">2倍</button>
  564. <button type="button" name="zoom3" class="sub_6" onclick="Zoom(zoom3);" style="width:60px;height:49px;font-size:20px;border-radius:10px;">3倍</button>
  565. </div>
  566. <div class="col-md-12" style="text-align:center;margin-top:5px;">
  567. <button type="button" name="zoom4" class="sub_6" onclick="Zoom(zoom4);" style="width:60px;height:49px;font-size:20px;border-radius:10px;">4倍</button>
  568. <button type="button" name="zoom5" class="sub_6" onclick="Zoom(zoom5);" style="width:60px;height:49px;font-size:20px;border-radius:10px;">5倍</button>
  569. </div>
  570. <input type="hidden" name="zoom">
  571. </div>
  572. </div>
  573. <div class="col-md-3" style="text-align:center;margin-top:5px;">
  574. <p style="text-align:center;font-weight:bold;font-size: 1.7em;">拍攝</p>
  575. <!--<form id="form" name="form" method="POST" action="" target="blankFrame">-->
  576. <button type="button" name="zoom_in" value="1" class="sub_6" onclick="Photo()" style="width:120px;height:80px;font-size:20px;border-radius:10px"><img src="../static/img/camera.png" style="width:50%;height:70%"></button>
  577. <!--</form>-->
  578. </div>
  579. <div class="col-md-3" style="text-align:center;margin-top:5px;">
  580. <p style="text-align:center;font-weight:bold;font-size: 1.7em;">定程方位</p>
  581. <div class="col-md-12" style="text-align:center;margin-top:5px;">
  582. <input type='button' class='sw_number' name='ori1' value='1' onclick="Orientation(ori1);" style='font-size:20px;border-radius:10px;'>
  583. <input type='button' name='ori2' class='sw_number disabled' value='2' onclick="Orientation(ori2);" style='font-size:20px;border-radius:10px;'>
  584. <input type='button' name='ori3' class='sw_number disabled' value='3' onclick="Orientation(ori3);" style='font-size:20px;border-radius:10px;'>
  585. <input type='button' name='ori4' class='sw_number disabled' value='4' onclick="Orientation(ori4);" style='font-size:20px;border-radius:10px;'>
  586. </div>
  587. <div class="col-md-12" style="text-align:center;margin-top:5px;">
  588. <input type='button' name='ori5' class='sw_number disabled' value='5' onclick="Orientation(ori5);" style='font-size:20px;border-radius:10px;'>
  589. <input type='button' name='ori6' class='sw_number disabled' value='6' onclick="Orientation(ori6);" style='font-size:20px;border-radius:10px;'>
  590. <input type='button' name='ori7' class='sw_number disabled' value='7' onclick="Orientation(ori7);" style='font-size:20px;border-radius:10px;'>
  591. <input type='button' name="ori8" class='sw_number disabled' value='8' onclick="Orientation(ori8);" style='font-size:20px;border-radius:10px;'>
  592. </div>
  593. <div class="col-md-12" style="text-align:center;margin-top:5px;">
  594. <button type="button" id="bts" onclick="Bts()" style="width:100px;height:50px;font-size:20px;border-radius:10px;font-weight:bold;font-size: 1.7em;">設定</button>
  595. </div>
  596. </div>
  597. </div>
  598. <p style='text-align:center;font-weight:bold;font-size: 1.7em;'>
  599. 定程方位 垂直:<span class="tilt-angle">0</span> 度 水平:<span class="pan-angle">0</span> 度 倍率:<span class="zoom">0</span> 倍
  600. </p>
  601. </div>
  602. <div class="col-md-12" style="text-align:center;margin-top:5px;">
  603. </div>
  604. <div id="time_set" class="col-md-12" style="display: none;">
  605. <div style="background-color:#FFFFFF;width:100%;height:5px;margin-top:5px;"></div><br>
  606. <p style="text-align:center;font-weight:bold;font-size: 1.7em;">定程方位設定:</p><br>
  607. <p style="text-align:center;font-weight:bold;font-size: 1.7em;">
  608. 方位名稱 : <input type="text" name="ori_name" placeholder="請輸入方位名稱" style="width:200px;">
  609. </p><br>
  610. <p style="text-align:center;font-weight:bold;font-size: 1.7em;"><span class="set-span">0</span>號 方位設定:</p><br>
  611. <p style='text-align:center;font-weight:bold;font-size: 1.7em;'>定程方位 垂直:<span class="tilt-angle-history">0</span> 度 水平:<span class="pan-angle-history">0</span> 度 倍率:<span class="zoom-history">0</span> 倍</p>
  612. <p style='text-align:center;font-weight:bold;font-size: 1.7em;'>拍攝時間:</p><br>
  613. <p style='text-align:center;font-weight:bold;font-size: 1.7em;'></p>
  614. <div class="col-md-6" style="text-align:center;margin-top:5px;">
  615. <p style='text-align:center;font-weight:bold;font-size: 1.7em;'>
  616. 1.<input type='text' name='m_s1' value='00' style='width:50px;' maxlength="2">月<input type='text' name='d_s1' value='00' style='width:50px;' maxlength="2">日<input type='text' name='h_s1' value='00' style='width:50px;' maxlength="2">時<input type='text' name='min_s1' value='00' style='width:50px;' maxlength="2">分<br><br>
  617. 3.<input type='text' name='m_s3' value='00' style='width:50px;' maxlength="2">月<input type='text' name='d_s3' value='00' style='width:50px;' maxlength="2">日<input type='text' name='h_s3' value='00' style='width:50px;' maxlength="2">時<input type='text' name='min_s3' value='00' style='width:50px;' maxlength="2">分<br><br>
  618. 5.<input type='text' name='m_s5' value='00' style='width:50px;' maxlength="2">月<input type='text' name='d_s5' value='00' style='width:50px;' maxlength="2">日<input type='text' name='h_s5' value='00' style='width:50px;' maxlength="2">時<input type='text' name='min_s5' value='00' style='width:50px;' maxlength="2">分<br><br>
  619. 7.<input type='text' name='m_s7' value='00' style='width:50px;' maxlength="2">月<input type='text' name='d_s7' value='00' style='width:50px;' maxlength="2">日<input type='text' name='h_s7' value='00' style='width:50px;' maxlength="2">時<input type='text' name='min_s7' value='00' style='width:50px;' maxlength="2">分<br><br>
  620. </p>
  621. </div>
  622. <div class="col-md-6" style="text-align:center;margin-top:5px;">
  623. <p style='text-align:center;font-weight:bold;font-size: 1.7em;'>
  624. 2.<input type='text' name='m_s2' value='00' style='width:50px;' maxlength="2">月<input type='text' name='d_s2' value='00' style='width:50px;' maxlength="2">日<input type='text' name='h_s2' value='00' style='width:50px;' maxlength="2">時<input type='text' name='min_s2' value='00' style='width:50px;' maxlength="2">分<br><br>
  625. 4.<input type='text' name='m_s4' value='00' style='width:50px;' maxlength="2">月<input type='text' name='d_s4' value='00' style='width:50px;' maxlength="2">日<input type='text' name='h_s4' value='00' style='width:50px;' maxlength="2">時<input type='text' name='min_s4' value='00' style='width:50px;' maxlength="2">分<br><br>
  626. 6.<input type='text' name='m_s6' value='00' style='width:50px;' maxlength="2">月<input type='text' name='d_s6' value='00' style='width:50px;' maxlength="2">日<input type='text' name='h_s6' value='00' style='width:50px;' maxlength="2">時<input type='text' name='min_s6' value='00' style='width:50px;' maxlength="2">分<br><br>
  627. 8.<input type='text' name='m_s8' value='00' style='width:50px;' maxlength="2">月<input type='text' name='d_s8' value='00' style='width:50px;' maxlength="2">日<input type='text' name='h_s8' value='00' style='width:50px;' maxlength="2">時<input type='text' name='min_s8' value='00' style='width:50px;' maxlength="2">分<br><br>
  628. </p>
  629. </div>
  630. <div class="col-md-12" style="text-align:center;margin-top:5px;">
  631. <div class="col-md-4" style="text-align:center;margin-top:5px;">
  632. <input type='button' class="btn btn-primary btn-lg" name='submits' onclick="Btsv()" style='font-weight:bold;font-size:20px' value='儲存'>
  633. </div>
  634. <div class="col-md-4" style="text-align:center;margin-top:5px;">
  635. <input type='button' class="btn btn-primary btn-lg" name='delete' onclick="Btd()" style='font-weight:bold;font-size:20px' value='刪除'>
  636. </div>
  637. <div class="col-md-4" style="text-align:center;margin-top:5px;">
  638. <input type='button' id="btq" class="btn btn-primary btn-lg" onclick="Btq()" style='font-weight:bold;font-size:20px' value='關閉'>
  639. </div>
  640. </div>
  641. </div>
  642. </form>
  643. </center>
  644. </div>
  645. </div>
  646. </body>
  647. </html>